> On March 26, 2015, 7:03 p.m., Vinod Kone wrote: > > src/slave/containerizer/isolators/network/port_mapping.cpp, line 1459 > > <https://reviews.apache.org/r/32426/diff/2/?file=905705#file905705line1459> > > > > If this returns a Result as commented above, we could do a > > CHECK(!pid.isNone()), because that's the invariant right?
I would rather not use a CHECK here. THe cleanup logic in the isolator is best effort. So it's possible (though unlikely) that symlink removal failed but the removal of bind mounts succeeds. Instead of using a CHECK here, I'll just remove the dangling symlink and continue the recovery logic. - Jie ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/32426/#review77780 ----------------------------------------------------------- On March 25, 2015, 6:43 p.m., Jie Yu wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/32426/ > ----------------------------------------------------------- > > (Updated March 25, 2015, 6:43 p.m.) > > > Review request for mesos, Chi Zhang, Ian Downes, and Vinod Kone. > > > Bugs: MESOS-2528 > https://issues.apache.org/jira/browse/MESOS-2528 > > > Repository: mesos > > > Description > ------- > > Symlink the namespace handle with ContainerID for the port mapping isolator. > > See ticket for details. This patch will allow a smooth upgrade (i.e., rolling > foward and back are both safe). > > > Diffs > ----- > > src/slave/containerizer/isolators/network/port_mapping.hpp > 4dd066a47d43cb1d52f93294d86309151738743e > src/slave/containerizer/isolators/network/port_mapping.cpp > 4bf0adeeac1cb6fe59f9c2ca8d5980b1500f5ddd > src/tests/port_mapping_tests.cpp 623840e71938791a562a32989775818275e6d37e > > Diff: https://reviews.apache.org/r/32426/diff/ > > > Testing > ------- > > sudo make check > > Many existing tests should already capture the regression. For example, > ROOT_CleanUpOrphanTest checks if the bind mount dir is empty after the > container is destroyed. > > Will add a compatibility test tomorrow. > > > Thanks, > > Jie Yu > >