----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/26736/#review59483 -----------------------------------------------------------
src/docker/docker.hpp <https://reviews.apache.org/r/26736/#comment100761> We strongly type things like timeout with a Duration, not an int. Otherwise, is this timeout in seconds? Milliseconds? Etc. src/docker/docker.cpp <https://reviews.apache.org/r/26736/#comment100762> Should this comment be in the header instead of in the implementation? Also, using a Duration lets you kill '(seconds)' here. src/docker/docker.cpp <https://reviews.apache.org/r/26736/#comment100763> The style in the code base is to put the operator on the previous line, so please move '+' on previous line. For posterity, same is true with || and &&, e.g., we do: if (foo && bar && baz) { } Instead of: if (foo && bar && baz) { } Thanks! src/docker/docker.cpp <https://reviews.apache.org/r/26736/#comment100764> This is where you can convert to seconds. src/slave/containerizer/docker.cpp <https://reviews.apache.org/r/26736/#comment100766> Can we update this comment now that we're no longer doing Docker::rm or Docker::kill? It should have been updated before as well, thanks for helping out! src/slave/containerizer/docker.cpp <https://reviews.apache.org/r/26736/#comment100767> Like above, let's update this comment to stay relevant with the code please. src/slave/containerizer/docker.cpp <https://reviews.apache.org/r/26736/#comment100765> Woah! Why did this go from 'false' to 'true'? We don't remove the container till later (the default is false so let's just drop this argument all together). src/tests/docker_containerizer_tests.cpp <https://reviews.apache.org/r/26736/#comment100768> Why do we need this? - Benjamin Hindman On Nov. 1, 2014, 5:13 p.m., Ryan Thomas wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/26736/ > ----------------------------------------------------------- > > (Updated Nov. 1, 2014, 5:13 p.m.) > > > Review request for mesos. > > > Bugs: MESOS-1925 > https://issues.apache.org/jira/browse/MESOS-1925 > > > Repository: mesos-git > > > Description > ------- > > Ensure docker calls stop if a docker_stop_timeout is provided Added the flag > docker_stop_timeout that defaults to 0, if the timeout is 0 the a docker kill > will be run, otherwise a docker stop with the timeout in seconds is used. A > negative value will result in a Failure. > > > Diffs > ----- > > src/docker/docker.hpp 2dc692c51d6f9d45d8d7c59f8678991fd80c6e89 > src/docker/docker.cpp 0c0a1bfd3c1260ebdf342d0a6e0e04d7b6a111a4 > src/slave/containerizer/docker.cpp a6689203adbdcb0ad12583389eaeb83329e4ef6b > src/slave/flags.hpp 319c002c66212ffb11759dbcc39f7661203a3e4e > src/tests/docker_containerizer_tests.cpp > 9d4ccc57f58d61c62aab5cdc79a129e987920bf6 > src/tests/docker_tests.cpp ff06a01d7f20656c05bcf5afd3bc10059dc5378d > > Diff: https://reviews.apache.org/r/26736/diff/ > > > Testing > ------- > > make check > sudo bin/mesos-tests.sh --gtest_filter="DOCKER" --verbose > support/mesos-style.py > > > Thanks, > > Ryan Thomas > >