> On Sept. 14, 2015, 5:34 p.m., Connor Doyle wrote:
> > src/hook/manager.cpp, line 261
> > <https://reviews.apache.org/r/38279/diff/1/?file=1067842#file1067842line261>
> >
> >     Please add a comment describing how the order of hook execution is 
> > determined.  e.g. order in which they appear in the modules json passed to 
> > the slave, etc.
> 
> Felix Abecassis wrote:
>     Actually, it seems there is no predefined order right now since 
> src/hook/manager.cpp is using a hashmap, should I open another issue to 
> discuss how to fix this?

Yes, please do.  A HashMap might be overkill for that use case.  Maybe the hook 
manager can get by with a simpler order-preserving data structure.  As modules 
become more common, operators will probably want to control the invocation 
order.  For now the flag value is the only control surface exposed.


- Connor


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/38279/#review98860
-----------------------------------------------------------


On Sept. 19, 2015, 12:51 a.m., Felix Abecassis wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/38279/
> -----------------------------------------------------------
> 
> (Updated Sept. 19, 2015, 12:51 a.m.)
> 
> 
> Review request for mesos, Connor Doyle and Niklas Nielsen.
> 
> 
> Bugs: MESOS-3366
>     https://issues.apache.org/jira/browse/MESOS-3366
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> First API draft for MESOS-3366.
> 
> 1) Only supports resources for now, we can add another hook for attributes 
> with a very similar code.
> 2) The callback currently receives the full SlaveInfo structure and construct 
> a new Resources object.
> 3) If there is multiple callbacks, each callback will see the changes made by 
> previous callbacks and are free to override or merge the detected resources 
> as they see fit.
> 
> 
> Diffs
> -----
> 
>   include/mesos/hook.hpp 2353602 
>   src/examples/test_hook_module.cpp 0dc74d6 
>   src/hook/manager.hpp a517c05 
>   src/hook/manager.cpp 691976e 
>   src/slave/slave.cpp ad710d7 
>   src/tests/hook_tests.cpp b23a587 
> 
> Diff: https://reviews.apache.org/r/38279/diff/
> 
> 
> Testing
> -------
> 
> make clean && make && make check
> 
> 
> Thanks,
> 
> Felix Abecassis
> 
>

Reply via email to