MCPcopy Create free account
hub / github.com/apache/mesos / max_usage_in_bytes

Function max_usage_in_bytes

src/linux/cgroups.cpp:2452–2462  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2450
2451
2452Try<Bytes> max_usage_in_bytes(const string& hierarchy, const string& cgroup)
2453{
2454 Try<string> read = cgroups::read(
2455 hierarchy, cgroup, "memory.max_usage_in_bytes");
2456
2457 if (read.isError()) {
2458 return Error(read.error());
2459 }
2460
2461 return Bytes::parse(strings::trim(read.get()) + "B");
2462}
2463
2464
2465namespace oom {

Callers 1

oomWaitedMethod · 0.85

Calls 7

trimFunction · 0.85
readFunction · 0.70
parseFunction · 0.70
errorMethod · 0.65
ErrorFunction · 0.50
isErrorMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected