17 #ifndef __MASTER_VALIDATION_HPP__ 18 #define __MASTER_VALIDATION_HPP__ 22 #include <google/protobuf/repeated_field.h> 47 namespace validation {
118 const FrameworkInfo& oldInfo,
119 const FrameworkInfo& newInfo);
130 const FrameworkInfo& oldInfo,
131 FrameworkInfo* newInfo);
134 const std::set<std::string>& validFrameworkRoles,
135 const std::set<std::string>& suppressedRoles);
138 const std::set<std::string>& validFrameworkRoles,
139 const scheduler::OfferConstraints& offerConstraints);
144 namespace scheduler {
163 const google::protobuf::RepeatedPtrField<Resource>& resources);
170 const std::vector<Resources>& resources);
176 const google::protobuf::RepeatedPtrField<Resource>& resources);
210 const TaskInfo& task,
249 const TaskGroupInfo& taskGroup,
250 const ExecutorInfo& executor,
264 const TaskGroupInfo& taskGroup,
265 const ExecutorInfo& executor);
285 const google::protobuf::RepeatedPtrField<OfferID>& offerIds,
292 const google::protobuf::RepeatedPtrField<OfferID>& offerIds,
299 namespace operation {
303 const Offer::Operation::Reserve& reserve,
311 const Offer::Operation::Unreserve& unreserve,
322 const Offer::Operation::Create&
create,
334 const Offer::Operation::Destroy&
destroy,
341 const Offer::Operation::GrowVolume& growVolume,
346 const Offer::Operation::ShrinkVolume& shrinkVolume,
362 #endif // __MASTER_VALIDATION_HPP__ Option< Error > validateExecutorID(const ExecutorInfo &executor)
Option< Error > validateFrameworkId(const mesos::FrameworkInfo &frameworkInfo)
Definition: master.hpp:27
Option< Error > validateMaxCompletionTime(const TaskInfo &task)
Definition: protobuf_utils.hpp:332
Option< Error > validateSuppressedRoles(const std::set< std::string > &validFrameworkRoles, const std::set< std::string > &suppressedRoles)
InverseOffer * getInverseOffer(Master *master, const OfferID &offerId)
mesos::v1::scheduler::Call Call
Definition: mesos.hpp:2851
Definition: resources.hpp:83
Slave * getSlave(Master *master, const SlaveID &slaveId)
Option< Error > validateResources(const TaskInfo &task)
Option< Error > reregisterSlave(const ReregisterSlaveMessage &message)
Definition: hashmap.hpp:38
Option< Error > validateUpdate(const FrameworkInfo &oldInfo, const FrameworkInfo &newInfo)
Option< Error > validateInverseOffers(const google::protobuf::RepeatedPtrField< OfferID > &offerIds, Master *master, Framework *framework)
Option< Error > validateKillPolicy(const TaskInfo &task)
Option< Error > validateRoles(const mesos::FrameworkInfo &frameworkInfo)
Option< Error > validateType(const ExecutorInfo &executor)
process::Future< Nothing > destroy(const std::string &hierarchy, const std::string &cgroup="/")
Option< Error > validateTaskGroupAndExecutorResources(const TaskGroupInfo &taskGroup, const ExecutorInfo &executor)
Option< Error > validateCheck(const TaskInfo &task)
bool detectOverlappingSetAndRangeResources(const std::vector< Resources > &resources)
Definition: attributes.hpp:24
Option< Error > validateHealthCheck(const TaskInfo &task)
Option< Error > validateOfferFilters(const FrameworkInfo &frameworkInfo)
Definition: master.hpp:122
Option< Error > validateOfferConstraintsRoles(const std::set< std::string > &validFrameworkRoles, const scheduler::OfferConstraints &offerConstraints)
Option< Error > validate(const mesos::master::Call &call)
Option< Error > validateTaskAndExecutorResources(const TaskInfo &task)
Offer * getOffer(Master *master, const OfferID &offerId)
Option< Error > validateSingleResourceProvider(const google::protobuf::RepeatedPtrField< Resource > &resources)
Try< Nothing > create(const std::string &hierarchy, const std::string &cgroup, bool recursive=false)
void preserveImmutableFields(const FrameworkInfo &oldInfo, FrameworkInfo *newInfo)
Definition: master.hpp:2397
Definition: master.hpp:355
Option< Error > registerSlave(const RegisterSlaveMessage &message)