Re: Review Request 27461: fix OsTest.killtreeNoRoot: check for reparent and not zombie

2014-11-03 Thread Joris Van Remoortere

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

(Updated Nov. 4, 2014, 12:17 a.m.)


Review request for mesos and Ian Downes.


Changes
---

Modify checks to address Ian's comment.


Summary (updated)
-

fix OsTest.killtreeNoRoot: check for reparent and not zombie


Bugs: MESOS-2025
https://issues.apache.org/jira/browse/MESOS-2025


Repository: mesos-git


Description (updated)
---

Reparenting does not always assign pid 1 (/sbin/init). If there is a user init 
such as init --user with some other pid, this will be the new parent.
Modify os_tests to check that the subtree has been reparented to a process 
different from its original parent (a.k.a. child) and that it is not a zombie.


Diffs (updated)
-

  3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 3f39017 

Diff: https://reviews.apache.org/r/27461/diff/


Testing
---

make check


Thanks,

Joris Van Remoortere



Re: Review Request 27461: fix OsTest.killtreeNoRoot: check for reparent and not zombie

2014-11-03 Thread Ian Downes

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

Ship it!


Could you please add to the comment to clarify why this is done, i.e., because 
some systems don't reparent to init pid 1.

Thanks!

- Ian Downes


On Nov. 3, 2014, 4:17 p.m., Joris Van Remoortere wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/27461/
 ---
 
 (Updated Nov. 3, 2014, 4:17 p.m.)
 
 
 Review request for mesos and Ian Downes.
 
 
 Bugs: MESOS-2025
 https://issues.apache.org/jira/browse/MESOS-2025
 
 
 Repository: mesos-git
 
 
 Description
 ---
 
 Reparenting does not always assign pid 1 (/sbin/init). If there is a user 
 init such as init --user with some other pid, this will be the new parent.
 Modify os_tests to check that the subtree has been reparented to a process 
 different from its original parent (a.k.a. child) and that it is not a zombie.
 
 
 Diffs
 -
 
   3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 3f39017 
 
 Diff: https://reviews.apache.org/r/27461/diff/
 
 
 Testing
 ---
 
 make check
 
 
 Thanks,
 
 Joris Van Remoortere
 




Re: Review Request 27461: fix OsTest.killtreeNoRoot: check for reparent and not zombie

2014-11-03 Thread Adam B

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



3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp
https://reviews.apache.org/r/27461/#comment100986

Is this comment still valid?



3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp
https://reviews.apache.org/r/27461/#comment100987

Couldn't this be grandchild.children.front()?



3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp
https://reviews.apache.org/r/27461/#comment100988

Should this also check if _grandchild.get().parent isn't a zombie?


- Adam B


On Nov. 3, 2014, 4:36 p.m., Joris Van Remoortere wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/27461/
 ---
 
 (Updated Nov. 3, 2014, 4:36 p.m.)
 
 
 Review request for mesos and Ian Downes.
 
 
 Bugs: MESOS-2025
 https://issues.apache.org/jira/browse/MESOS-2025
 
 
 Repository: mesos-git
 
 
 Description
 ---
 
 Reparenting does not always assign pid 1 (/sbin/init). If there is a user 
 init such as init --user with some other pid, this will be the new parent.
 Modify os_tests to check that the subtree has been reparented to a process 
 different from its original parent (a.k.a. child) and that it is not a zombie.
 
 
 Diffs
 -
 
   3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 3f39017 
 
 Diff: https://reviews.apache.org/r/27461/diff/
 
 
 Testing
 ---
 
 make check
 
 
 Thanks,
 
 Joris Van Remoortere
 




Re: Review Request 27461: fix OsTest.killtreeNoRoot: check for reparent and not zombie

2014-11-03 Thread Joris Van Remoortere

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

(Updated Nov. 4, 2014, 12:36 a.m.)


Review request for mesos and Ian Downes.


Changes
---

Clarifying comment as per Ian's request.


Bugs: MESOS-2025
https://issues.apache.org/jira/browse/MESOS-2025


Repository: mesos-git


Description
---

Reparenting does not always assign pid 1 (/sbin/init). If there is a user init 
such as init --user with some other pid, this will be the new parent.
Modify os_tests to check that the subtree has been reparented to a process 
different from its original parent (a.k.a. child) and that it is not a zombie.


Diffs (updated)
-

  3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 3f39017 

Diff: https://reviews.apache.org/r/27461/diff/


Testing
---

make check


Thanks,

Joris Van Remoortere



Re: Review Request 27461: fix OsTest.killtreeNoRoot: check for reparent and not zombie

2014-11-03 Thread Joris Van Remoortere


 On Nov. 4, 2014, 12:37 a.m., Adam B wrote:
  3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp, line 661
  https://reviews.apache.org/r/27461/diff/3/?file=747878#file747878line661
 
  Couldn't this be grandchild.children.front()?

we'd have to keep a reference to the object rather than the implicit conversion 
to pid_t for that to work.


- Joris


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


On Nov. 4, 2014, 12:36 a.m., Joris Van Remoortere wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/27461/
 ---
 
 (Updated Nov. 4, 2014, 12:36 a.m.)
 
 
 Review request for mesos and Ian Downes.
 
 
 Bugs: MESOS-2025
 https://issues.apache.org/jira/browse/MESOS-2025
 
 
 Repository: mesos-git
 
 
 Description
 ---
 
 Reparenting does not always assign pid 1 (/sbin/init). If there is a user 
 init such as init --user with some other pid, this will be the new parent.
 Modify os_tests to check that the subtree has been reparented to a process 
 different from its original parent (a.k.a. child) and that it is not a zombie.
 
 
 Diffs
 -
 
   3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 3f39017 
 
 Diff: https://reviews.apache.org/r/27461/diff/
 
 
 Testing
 ---
 
 make check
 
 
 Thanks,
 
 Joris Van Remoortere
 




Re: Review Request 27461: fix OsTest.killtreeNoRoot: check for reparent and not zombie

2014-11-03 Thread Joris Van Remoortere

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

(Updated Nov. 4, 2014, 12:49 a.m.)


Review request for mesos and Ian Downes.


Changes
---

Address Adam's comments.


Bugs: MESOS-2025
https://issues.apache.org/jira/browse/MESOS-2025


Repository: mesos-git


Description
---

Reparenting does not always assign pid 1 (/sbin/init). If there is a user init 
such as init --user with some other pid, this will be the new parent.
Modify os_tests to check that the subtree has been reparented to a process 
different from its original parent (a.k.a. child) and that it is not a zombie.


Diffs (updated)
-

  3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 3f39017 

Diff: https://reviews.apache.org/r/27461/diff/


Testing
---

make check


Thanks,

Joris Van Remoortere



Re: Review Request 27461: fix OsTest.killtreeNoRoot: check for reparent and not zombie

2014-11-03 Thread Adam B

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

Ship it!


Ship It!

- Adam B


On Nov. 3, 2014, 4:49 p.m., Joris Van Remoortere wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/27461/
 ---
 
 (Updated Nov. 3, 2014, 4:49 p.m.)
 
 
 Review request for mesos and Ian Downes.
 
 
 Bugs: MESOS-2025
 https://issues.apache.org/jira/browse/MESOS-2025
 
 
 Repository: mesos-git
 
 
 Description
 ---
 
 Reparenting does not always assign pid 1 (/sbin/init). If there is a user 
 init such as init --user with some other pid, this will be the new parent.
 Modify os_tests to check that the subtree has been reparented to a process 
 different from its original parent (a.k.a. child) and that it is not a zombie.
 
 
 Diffs
 -
 
   3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 3f39017 
 
 Diff: https://reviews.apache.org/r/27461/diff/
 
 
 Testing
 ---
 
 make check
 
 
 Thanks,
 
 Joris Van Remoortere
 




Re: Review Request 27461: fix OsTest.killtreeNoRoot: check for reparent and not zombie

2014-11-03 Thread Mesos ReviewBot

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


Patch looks great!

Reviews applied: [27461]

All tests passed.

- Mesos ReviewBot


On Nov. 4, 2014, 12:49 a.m., Joris Van Remoortere wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/27461/
 ---
 
 (Updated Nov. 4, 2014, 12:49 a.m.)
 
 
 Review request for mesos and Ian Downes.
 
 
 Bugs: MESOS-2025
 https://issues.apache.org/jira/browse/MESOS-2025
 
 
 Repository: mesos-git
 
 
 Description
 ---
 
 Reparenting does not always assign pid 1 (/sbin/init). If there is a user 
 init such as init --user with some other pid, this will be the new parent.
 Modify os_tests to check that the subtree has been reparented to a process 
 different from its original parent (a.k.a. child) and that it is not a zombie.
 
 
 Diffs
 -
 
   3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 3f39017 
 
 Diff: https://reviews.apache.org/r/27461/diff/
 
 
 Testing
 ---
 
 make check
 
 
 Thanks,
 
 Joris Van Remoortere