Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
Description
During the review of MESOS-3063 (Example of Dynamic Reservation), we found several helper functions are duplicated if de-coupled example from internal codes.
For example, there is a helper function named UNRESERVE(const Resources& resources) in src/tests/mesos.hpp. But we can not use it to compile example code with installed Mesos binaries & headers.
// Helpers for creating unreserve operations. inline Offer::Operation UNRESERVE(const Resources& resources) { Offer::Operation operation; operation.set_type(Offer::Operation::UNRESERVE); operation.mutable_unreserve()->mutable_resources()->CopyFrom(resources); return operation; }
The proposal is to move such kind of helper functions into include/mesos/, so example code, test code and framework developer can reuse those helper functions. One concern is how to manage the compatibility of those helper functions.
cc mcypark