You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Greg Mann <gr...@mesosphere.io> on 2018/05/03 22:07:25 UTC

Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

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

Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.


Repository: mesos


Description
-------

Since the 'SchedulerDriver' does not support operation status updates,
this patch adds a CHECK to the driver which will abort the scheduler
if the 'id' field is set in an offer operation.

This patch also removes the test
'SchedulerTest.OperationFeedbackValidationSchedulerDriverFramework'
because with these new changes, it causes the test harness to abort.


Diffs
-----

  src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
  src/tests/scheduler_tests.cpp 749420a23bc1a3873bd4d5aee56e78cff79bb1af 


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


Testing
-------

make check


Thanks,

Greg Mann


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Greg Mann <gr...@mesosphere.io>.

> On May 4, 2018, 2:45 p.m., Benjamin Bannier wrote:
> > src/sched/sched.cpp
> > Lines 1349 (patched)
> > <https://reviews.apache.org/r/66938/diff/2/?file=2016633#file2016633line1349>
> >
> >     Do we really need to `return` here? It seems just dropping this particular operation would be enough (in addition to calling `error` with all its side-effects). I am especially wondering about the tracking of operations.
> >     
> >     (With a `CHECK` the expected behavior would be simpler, not saying we should prefer it).

I switched back to aborting the process directly rather than calling error() - while this means we must eliminate the relevant test, it seems to make a bit more sense for the framework developer I think. It also matches what we do in a similar case, where the framework attempts to acknowledge a status update explicitly after implicit acknowledgement has been enabled.


- Greg


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


On May 4, 2018, 11:20 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 4, 2018, 11:20 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a check to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
>   src/tests/scheduler_tests.cpp 749420a23bc1a3873bd4d5aee56e78cff79bb1af 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/3/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Benjamin Bannier <be...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/#review202446
-----------------------------------------------------------




src/sched/sched.cpp
Lines 1349 (patched)
<https://reviews.apache.org/r/66938/#comment284269>

    Do we really need to `return` here? It seems just dropping this particular operation would be enough (in addition to calling `error` with all its side-effects). I am especially wondering about the tracking of operations.
    
    (With a `CHECK` the expected behavior would be simpler, not saying we should prefer it).


- Benjamin Bannier


On May 4, 2018, 1:14 a.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 4, 2018, 1:14 a.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a check to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Gaston Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/#review202413
-----------------------------------------------------------


Ship it!




Ship It!

- Gaston Kleiman


On May 3, 2018, 4:14 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 3, 2018, 4:14 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a check to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Mesos Reviewbot <re...@mesos.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/#review202412
-----------------------------------------------------------



Patch looks great!

Reviews applied: [66938]

Passed command: export OS='ubuntu:14.04' BUILDTOOL='autotools' COMPILER='gcc' CONFIGURATION='--verbose --disable-libtool-wrappers' ENVIRONMENT='GLOG_v=1 MESOS_VERBOSE=1'; ./support/docker-build.sh

- Mesos Reviewbot


On May 3, 2018, 11:14 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 3, 2018, 11:14 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a check to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Mesos Reviewbot Windows <re...@mesos.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/#review202394
-----------------------------------------------------------



PASS: Mesos patch 66938 was successfully built and tested.

Reviews applied: `['66938']`

All the build artifacts available at: http://dcos-win.westus.cloudapp.azure.com/mesos-build/review/66938

- Mesos Reviewbot Windows


On May 3, 2018, 11:14 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 3, 2018, 11:14 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a check to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Mesos Reviewbot Windows <re...@mesos.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/#review202516
-----------------------------------------------------------



PASS: Mesos patch 66938 was successfully built and tested.

Reviews applied: `['66938']`

All the build artifacts available at: http://dcos-win.westus.cloudapp.azure.com/mesos-build/review/66938

- Mesos Reviewbot Windows


On May 4, 2018, 11:20 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 4, 2018, 11:20 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a check to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
>   src/tests/scheduler_tests.cpp 749420a23bc1a3873bd4d5aee56e78cff79bb1af 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/3/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Mesos Reviewbot <re...@mesos.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/#review202517
-----------------------------------------------------------



Patch looks great!

Reviews applied: [66938]

Passed command: export OS='ubuntu:14.04' BUILDTOOL='autotools' COMPILER='gcc' CONFIGURATION='--verbose --disable-libtool-wrappers' ENVIRONMENT='GLOG_v=1 MESOS_VERBOSE=1'; ./support/docker-build.sh

- Mesos Reviewbot


On May 4, 2018, 4:20 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 4, 2018, 4:20 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a check to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
>   src/tests/scheduler_tests.cpp 749420a23bc1a3873bd4d5aee56e78cff79bb1af 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/3/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Benjamin Bannier <be...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/#review202604
-----------------------------------------------------------


Ship it!




- Benjamin Bannier


On May 5, 2018, 1:20 a.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 5, 2018, 1:20 a.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a check to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
>   src/tests/scheduler_tests.cpp 749420a23bc1a3873bd4d5aee56e78cff79bb1af 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/3/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/
-----------------------------------------------------------

(Updated May 4, 2018, 11:20 p.m.)


Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.


Repository: mesos


Description
-------

Since the 'SchedulerDriver' does not support operation status updates,
this patch adds a check to the driver which will abort the scheduler
if the 'id' field is set in an offer operation.


Diffs (updated)
-----

  src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
  src/tests/scheduler_tests.cpp 749420a23bc1a3873bd4d5aee56e78cff79bb1af 


Diff: https://reviews.apache.org/r/66938/diff/3/

Changes: https://reviews.apache.org/r/66938/diff/2-3/


Testing
-------

make check


Thanks,

Greg Mann


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Greg Mann <gr...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/
-----------------------------------------------------------

(Updated May 3, 2018, 11:14 p.m.)


Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.


Repository: mesos


Description (updated)
-------

Since the 'SchedulerDriver' does not support operation status updates,
this patch adds a check to the driver which will abort the scheduler
if the 'id' field is set in an offer operation.


Diffs (updated)
-----

  src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 


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

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


Testing
-------

make check


Thanks,

Greg Mann


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Greg Mann <gr...@mesosphere.io>.

> On May 3, 2018, 10:25 p.m., Gaston Kleiman wrote:
> > src/sched/sched.cpp
> > Lines 1349-1352 (patched)
> > <https://reviews.apache.org/r/66938/diff/1/?file=2016592#file2016592line1349>
> >
> >     We should call `error()` here so that the framework is gracefully teared down instead of triggering a segfault.

Good call, thanks! This also allows us to keep the existing test.


- Greg


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


On May 3, 2018, 11:14 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 3, 2018, 11:14 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a check to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/2/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>


Re: Review Request 66938: Made the 'SchedulerDriver' abort when operation's 'id' field is set.

Posted by Gaston Kleiman <ga...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/66938/#review202388
-----------------------------------------------------------




src/sched/sched.cpp
Lines 1349-1352 (patched)
<https://reviews.apache.org/r/66938/#comment284199>

    We should call `error()` here so that the framework is gracefully teared down instead of triggering a segfault.


- Gaston Kleiman


On May 3, 2018, 3:07 p.m., Greg Mann wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/66938/
> -----------------------------------------------------------
> 
> (Updated May 3, 2018, 3:07 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier, Gaston Kleiman, Jan Schlicht, and Vinod Kone.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Since the 'SchedulerDriver' does not support operation status updates,
> this patch adds a CHECK to the driver which will abort the scheduler
> if the 'id' field is set in an offer operation.
> 
> This patch also removes the test
> 'SchedulerTest.OperationFeedbackValidationSchedulerDriverFramework'
> because with these new changes, it causes the test harness to abort.
> 
> 
> Diffs
> -----
> 
>   src/sched/sched.cpp 620a3b26d8bf3487b6ce922b2280be7da291df06 
>   src/tests/scheduler_tests.cpp 749420a23bc1a3873bd4d5aee56e78cff79bb1af 
> 
> 
> Diff: https://reviews.apache.org/r/66938/diff/1/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Greg Mann
> 
>