You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Anand Mazumdar <an...@apache.org> on 2017/08/10 19:32:56 UTC

Review Request 61573: Made the default executor support signal escalation.

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

Review request for mesos and Vinod Kone.


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


Repository: mesos


Description
-------

This modifies the default executor to perform signal escalation
via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
by a SIGKILL after some grace period. Note that support for kill
policies still needs to be done instead of using a constant grace
period.


Diffs
-----

  src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 


Diff: https://reviews.apache.org/r/61573/diff/1/


Testing
-------

make check


Thanks,

Anand Mazumdar


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Vinod Kone <vi...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/#review182989
-----------------------------------------------------------


Ship it!




Ship It!

- Vinod Kone


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/3/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Gastón Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/#review182966
-----------------------------------------------------------




src/launcher/default_executor.cpp
Line 1054 (original), 1057 (patched)
<https://reviews.apache.org/r/61573/#comment258932>

    The task ID is user-generated, so we usually put it in single quotes.



src/launcher/default_executor.cpp
Line 1059 (original), 1064 (patched)
<https://reviews.apache.org/r/61573/#comment258933>

    Ditto.


- Gastón Kleiman


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/3/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Vinod Kone <vi...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/#review182902
-----------------------------------------------------------




src/launcher/default_executor.cpp
Lines 1044 (patched)
<https://reviews.apache.org/r/61573/#comment258845>

    s/retry attempt/signal escalation timeout/


- Vinod Kone


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Anand Mazumdar <an...@apache.org>.

> On Aug. 14, 2017, 6:45 p.m., Gastón Kleiman wrote:
> > src/launcher/default_executor.cpp
> > Line 233 (original), 233 (patched)
> > <https://reviews.apache.org/r/61573/diff/2/?file=1796672#file1796672line233>
> >
> >     shouldn't we also pass the `event.kill().kill_policy()`? It allows frameworks/operators to override the kill policy, see: https://github.com/apache/mesos/blob/628d6609b6eeb90767e5799d0177bfe4828d71aa/include/mesos/executor/executor.proto#L96-L106
> 
> Gastón Kleiman wrote:
>     Droppping the issue, I just noticed that the commit message says that this doesn't include support for kill policies.

Yeah, we still need to add support for `KillPolicy` later. Hopefully, it should be trivial after this change (still would need an additional test)

I had added this information to the review description already:
```Note that support for kill
policies still needs to be done instead of using a constant grace
period.```


- Anand


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


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Gastón Kleiman <ga...@mesosphere.io>.

> On Aug. 14, 2017, 6:45 p.m., Gastón Kleiman wrote:
> > src/launcher/default_executor.cpp
> > Line 233 (original), 233 (patched)
> > <https://reviews.apache.org/r/61573/diff/2/?file=1796672#file1796672line233>
> >
> >     shouldn't we also pass the `event.kill().kill_policy()`? It allows frameworks/operators to override the kill policy, see: https://github.com/apache/mesos/blob/628d6609b6eeb90767e5799d0177bfe4828d71aa/include/mesos/executor/executor.proto#L96-L106

Droppping the issue, I just noticed that the commit message says that this doesn't include support for kill policies.


- Gastón


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


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Gastón Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/#review182888
-----------------------------------------------------------




src/launcher/default_executor.cpp
Line 233 (original), 233 (patched)
<https://reviews.apache.org/r/61573/#comment258825>

    shouldn't we also pass the `event.kill().kill_policy()`? It allows frameworks/operators to override the kill policy, see: https://github.com/apache/mesos/blob/628d6609b6eeb90767e5799d0177bfe4828d71aa/include/mesos/executor/executor.proto#L96-L106


- Gastón Kleiman


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Gastón Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/#review182893
-----------------------------------------------------------




src/launcher/default_executor.cpp
Line 996 (original), 996-997 (patched)
<https://reviews.apache.org/r/61573/#comment258835>

    I think that it'd be useful to include the task ID in this message.



src/launcher/default_executor.cpp
Lines 1002-1003 (patched)
<https://reviews.apache.org/r/61573/#comment258836>

    Ditto (and also the container ID).



src/launcher/default_executor.cpp
Lines 1053-1054 (patched)
<https://reviews.apache.org/r/61573/#comment258833>

    Ditto.



src/launcher/default_executor.cpp
Lines 1058-1059 (patched)
<https://reviews.apache.org/r/61573/#comment258834>

    Ditto.


- Gastón Kleiman


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Gastón Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/#review182968
-----------------------------------------------------------




src/launcher/default_executor.cpp
Line 995 (original), 995 (patched)
<https://reviews.apache.org/r/61573/#comment258937>

    We should send a `TASK_KILLING` update here, and address the TODOs added by AlexR.


- Gastón Kleiman


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/3/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Anand Mazumdar <an...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/
-----------------------------------------------------------

(Updated Aug. 16, 2017, 12:21 a.m.)


Review request for mesos and Vinod Kone.


Changes
-------

Review comments.


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


Repository: mesos


Description (updated)
-------

This modifies the default executor to perform signal escalation
via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
by a SIGKILL after some grace period. Note that support for kill
policies still needs to be done instead of using a constant grace
period.

Review: https://reviews.apache.org/r/61573


Diffs (updated)
-----

  src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 


Diff: https://reviews.apache.org/r/61573/diff/4/

Changes: https://reviews.apache.org/r/61573/diff/3-4/


Testing
-------

make check


Thanks,

Anand Mazumdar


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Gastón Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/#review182975
-----------------------------------------------------------


Ship it!




Ship It!

- Gastón Kleiman


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/3/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Vinod Kone <vi...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/#review182900
-----------------------------------------------------------




src/launcher/default_executor.cpp
Lines 1000 (patched)
<https://reviews.apache.org/r/61573/#comment258843>

    Can you add a TODO here to use kill policy set on TaskInfo (if present) and override with kill policy set on kill event (if present)?


- Vinod Kone


On Aug. 14, 2017, 5:19 p.m., Anand Mazumdar wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/61573/
> -----------------------------------------------------------
> 
> (Updated Aug. 14, 2017, 5:19 p.m.)
> 
> 
> Review request for mesos and Vinod Kone.
> 
> 
> Bugs: MESOS-7879
>     https://issues.apache.org/jira/browse/MESOS-7879
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> This modifies the default executor to perform signal escalation
> via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
> by a SIGKILL after some grace period. Note that support for kill
> policies still needs to be done instead of using a constant grace
> period.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 
> 
> 
> Diff: https://reviews.apache.org/r/61573/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Anand Mazumdar
> 
>


Re: Review Request 61573: Made the default executor support signal escalation.

Posted by Anand Mazumdar <an...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/61573/
-----------------------------------------------------------

(Updated Aug. 14, 2017, 5:19 p.m.)


Review request for mesos and Vinod Kone.


Changes
-------

Minor changes in code for readability.


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


Repository: mesos


Description
-------

This modifies the default executor to perform signal escalation
via the 'KILL_NESTED_CONTAINER' call i.e., send a SIGTERM followed
by a SIGKILL after some grace period. Note that support for kill
policies still needs to be done instead of using a constant grace
period.


Diffs (updated)
-----

  src/launcher/default_executor.cpp c25cc941eefc0cca998a99d76497bfdd05babe92 


Diff: https://reviews.apache.org/r/61573/diff/2/

Changes: https://reviews.apache.org/r/61573/diff/1-2/


Testing
-------

make check


Thanks,

Anand Mazumdar