17 #ifndef __POSIX_DISK_ISOLATOR_HPP__ 18 #define __POSIX_DISK_ISOLATOR_HPP__ 38 class DiskUsageCollectorProcess;
52 const std::string&
path,
53 const std::vector<std::string>& excludes);
56 DiskUsageCollectorProcess*
process;
81 bool supportsNesting()
override;
82 bool supportsStandalone()
override;
85 const std::vector<mesos::slave::ContainerState>& states,
89 const ContainerID& containerId,
90 const mesos::slave::ContainerConfig& containerConfig)
override;
93 const ContainerID& containerId,
97 const ContainerID& containerId)
override;
100 const ContainerID& containerId,
102 const google::protobuf::Map<
103 std::string, Value::Scalar>& resourceLimits = {})
override;
106 const ContainerID& containerId)
override;
109 const ContainerID& containerId)
override;
115 const ContainerID& containerId,
116 const std::string&
path);
119 const ContainerID& containerId,
120 const std::string& path,
128 explicit Info(
const std::string& _directory)
129 : directories({_directory}), sandbox(_directory) {}
131 Bytes ephemeralUsage()
const;
164 #endif // __POSIX_DISK_ISOLATOR_HPP__ Protocol< RecoverRequest, RecoverResponse > recover
Try< Nothing > isolate(const std::string &hierarchy, const std::string &cgroup, pid_t pid)
Try< bool > update(const std::string &link, const Handle &parent, uint16_t protocol, const action::Mirror &mirror)
process::Future< Bytes > usage(const std::string &path, const std::vector< std::string > &excludes)
process::Future< bool > cleanup(const std::string &hierarchy)
Definition: resources.hpp:83
std::string paths()
Definition: os.hpp:138
Definition: duration.hpp:32
Future< std::vector< T > > collect(const std::vector< Future< T >> &futures)
Definition: collect.hpp:274
process::Future< Bytes > usage
Definition: disk.hpp:150
Definition: hashmap.hpp:38
DWORD pid_t
Definition: windows.hpp:181
Try< std::vector< Info > > infos(int familiy, int states)
DiskUsageCollector(const Duration &interval)
Definition: isolator.hpp:82
#define flags
Definition: decoder.hpp:18
Definition: attributes.hpp:24
Definition: executor.hpp:48
Try< std::string > prepare(const std::string &baseHierarchy, const std::string &subsystem, const std::string &cgroup)
Try< Nothing > create(const std::string &hierarchy, const std::string &cgroup, bool recursive=false)
Resources quota
Definition: disk.hpp:149
Option< Bytes > lastUsage
Definition: disk.hpp:151