You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Benjamin Bannier <bb...@apache.org> on 2017/11/15 17:31:07 UTC

Review Request 63842: Allowed removing non-terminal offer operations.

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

Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs
-----

  src/master/master.hpp a309fc78ee2613762f3d5d22ac7559afc7aac4a3 
  src/master/master.cpp 59a533940736f5cfd5ec31e0ed924f0b2ab13f9c 
  src/slave/slave.cpp d8bacebc74790e955490a158c37ac0d9e75fd6b5 


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


Testing
-------

`make check`


Thanks,

Benjamin Bannier


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Benjamin Bannier <bb...@apache.org>.

> On Nov. 15, 2017, 10:05 p.m., Jie Yu wrote:
> > src/master/master.cpp
> > Lines 9816-9817 (original)
> > <https://reviews.apache.org/r/63842/diff/1/?file=1893482#file1893482line9816>
> >
> >     If you remove this CHECK, i'd like to see the resoures used by the operation being released. For instance, if a new operation is in non terminal status, you want to release the resources that it currently uses when removing the operation. That ensures that we don't leak any resources.

I added cleanup code for `usedResources` matching what is done in `Slave::addOfferOperation`.


- Benjamin


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


On Nov. 17, 2017, 6:24 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 17, 2017, 6:24 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp a309fc78ee2613762f3d5d22ac7559afc7aac4a3 
>   src/master/master.cpp 2ddd67ada3731803b00883b6a1f32b20c1bb238f 
>   src/slave/slave.cpp d8edc5e6bbfa265bca4d19bbaa7db3063949dbc0 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/2/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63842/#review191104
-----------------------------------------------------------




src/master/master.cpp
Lines 9816-9817 (original)
<https://reviews.apache.org/r/63842/#comment268690>

    If you remove this CHECK, i'd like to see the resoures used by the operation being released. For instance, if a new operation is in non terminal status, you want to release the resources that it currently uses when removing the operation. That ensures that we don't leak any resources.


- Jie Yu


On Nov. 15, 2017, 5:31 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 15, 2017, 5:31 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp a309fc78ee2613762f3d5d22ac7559afc7aac4a3 
>   src/master/master.cpp 59a533940736f5cfd5ec31e0ed924f0b2ab13f9c 
>   src/slave/slave.cpp d8bacebc74790e955490a158c37ac0d9e75fd6b5 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/1/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Benjamin Bannier <be...@mesosphere.io>.

> On Nov. 21, 2017, 7:59 p.m., Greg Mann wrote:
> > src/master/master.cpp
> > Line 10925 (original), 10922 (patched)
> > <https://reviews.apache.org/r/63842/diff/2/?file=1896903#file1896903line10925>
> >
> >     Especially now that we have code in this function which switches on operation type, could we add a comment to the method's declaration briefly explaining its use? For example, it's not clear from reading the header that this method should not be called on LAUNCH or LAUNCH_GROUP operations.

Dropping this issue as this code is now much less concerned about particular operation types.


> On Nov. 21, 2017, 7:59 p.m., Greg Mann wrote:
> > src/master/master.cpp
> > Lines 10936-10939 (patched)
> > <https://reviews.apache.org/r/63842/diff/2/?file=1896903#file1896903line10939>
> >
> >     Nit: could we put this case at the end? I think we tend to place the UNKNOWN case last.

Dropping this issue as this code is now simplified by using a helper.


- Benjamin


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


On Nov. 24, 2017, 3:52 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 24, 2017, 3:52 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
>   src/master/master.cpp 53263e499d88b906b6406c24c0dfb737e589e813 
>   src/slave/slave.cpp f93ff7b20815c3ccb274ce6990ee66a17b6ac51c 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/6/
> 
> 
> Testing
> -------
> 
> `make check`, tested as part of https://reviews.apache.org/r/63843/.
> 
> This patch requires `protobuf::isSpeculativeOperation` from https://reviews.apache.org/r/63751/ which is _not_ part of this review chain (to avoid multiple dependent RRs).
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

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




src/master/master.cpp
Line 10925 (original), 10922 (patched)
<https://reviews.apache.org/r/63842/#comment269466>

    Especially now that we have code in this function which switches on operation type, could we add a comment to the method's declaration briefly explaining its use? For example, it's not clear from reading the header that this method should not be called on LAUNCH or LAUNCH_GROUP operations.



src/master/master.cpp
Lines 10936-10939 (patched)
<https://reviews.apache.org/r/63842/#comment269461>

    Nit: could we put this case at the end? I think we tend to place the UNKNOWN case last.



src/master/master.cpp
Lines 10940-10946 (patched)
<https://reviews.apache.org/r/63842/#comment269459>

    Just leaving a note here for posterity: in recent discussions, we've converged on the idea that we should avoid operation speculation for all operations when feedback is requested. We'll need to update this code to reflect that once the framework-facing side of offer operation feedback is implemented.


- Greg Mann


On Nov. 17, 2017, 5:24 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 17, 2017, 5:24 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp a309fc78ee2613762f3d5d22ac7559afc7aac4a3 
>   src/master/master.cpp 2ddd67ada3731803b00883b6a1f32b20c1bb238f 
>   src/slave/slave.cpp d8edc5e6bbfa265bca4d19bbaa7db3063949dbc0 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/2/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Benjamin Bannier <bb...@apache.org>.

> On Nov. 18, 2017, 1:47 a.m., Jie Yu wrote:
> > src/master/master.hpp
> > Lines 2913-2915 (original)
> > <https://reviews.apache.org/r/63842/diff/2/?file=1896902#file1896902line2913>
> >
> >     Do you need to do the same as that in `Slave::removeOfferOperation`?

Of course.


- Benjamin


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


On Nov. 21, 2017, 10:08 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 21, 2017, 10:08 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
>   src/master/master.cpp 7417b5d641fd4bb6d91cb0e6456c60201bbc8206 
>   src/slave/slave.cpp 6e9adc60f593faf1b0e56caeea04882f67af7080 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/3/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63842/#review191424
-----------------------------------------------------------




src/master/master.hpp
Lines 2913-2915 (original)
<https://reviews.apache.org/r/63842/#comment269239>

    Do you need to do the same as that in `Slave::removeOfferOperation`?


- Jie Yu


On Nov. 17, 2017, 5:24 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 17, 2017, 5:24 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp a309fc78ee2613762f3d5d22ac7559afc7aac4a3 
>   src/master/master.cpp 2ddd67ada3731803b00883b6a1f32b20c1bb238f 
>   src/slave/slave.cpp d8edc5e6bbfa265bca4d19bbaa7db3063949dbc0 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/2/
> 
> 
> Testing
> -------
> 
> `make check`
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63842/#review192211
-----------------------------------------------------------




src/master/master.cpp
Lines 10952-10961 (patched)
<https://reviews.apache.org/r/63842/#comment270248>

    this is `Slave::recoverResources`?


- Jie Yu


On Nov. 29, 2017, 4:27 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 29, 2017, 4:27 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
>   src/master/master.cpp 700e12433b0b66efc3f5dd296711c0f203a13144 
>   src/slave/slave.cpp e1566832f90cca372ad2f1cc13d1e7f76fa53285 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/8/
> 
> 
> Testing
> -------
> 
> `make check`, tested as part of https://reviews.apache.org/r/63843/.
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

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

(Updated Nov. 30, 2017, 5 p.m.)


Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Changes
-------

Addressed comments from Jie.


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs (updated)
-----

  src/master/master.hpp 0f8a2ac72c3484f911853c2994fc71a488d66d96 
  src/master/master.cpp fadc78b2ca5d46b8cc12a794b428753aa79ac095 
  src/slave/slave.cpp 554a2da6b8e8d0ca8efa0752388f82e48021abce 


Diff: https://reviews.apache.org/r/63842/diff/9/

Changes: https://reviews.apache.org/r/63842/diff/8-9/


Testing
-------

`make check`, tested as part of https://reviews.apache.org/r/63843/.


Thanks,

Benjamin Bannier


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Benjamin Bannier <be...@mesosphere.io>.

> On Nov. 30, 2017, 1:33 a.m., Jie Yu wrote:
> > src/slave/slave.cpp
> > Line 7044 (original)
> > <https://reviews.apache.org/r/63842/diff/8/?file=1903708#file1903708line7044>
> >
> >     Can you add a TODO here to update `Framework::allocatedResources()` to include those used by non speculative operations?
> >     
> >     This currently only affects endpoints. We should create a ticket to track and address that.

I created a ticket, https://issues.apache.org/jira/browse/MESOS-8282. Let's track this ticket instead of adding a `TODO` here where it does not really fit anyway.


- Benjamin


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


On Nov. 30, 2017, 5 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 30, 2017, 5 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 0f8a2ac72c3484f911853c2994fc71a488d66d96 
>   src/master/master.cpp fadc78b2ca5d46b8cc12a794b428753aa79ac095 
>   src/slave/slave.cpp 554a2da6b8e8d0ca8efa0752388f82e48021abce 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/9/
> 
> 
> Testing
> -------
> 
> `make check`, tested as part of https://reviews.apache.org/r/63843/.
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63842/#review192204
-----------------------------------------------------------


Fix it, then Ship it!





src/master/master.cpp
Lines 10953 (patched)
<https://reviews.apache.org/r/63842/#comment270244>

    kill this line?



src/slave/slave.cpp
Line 7044 (original)
<https://reviews.apache.org/r/63842/#comment270245>

    Can you add a TODO here to update `Framework::allocatedResources()` to include those used by non speculative operations?
    
    This currently only affects endpoints. We should create a ticket to track and address that.


- Jie Yu


On Nov. 29, 2017, 4:27 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 29, 2017, 4:27 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
>   src/master/master.cpp 700e12433b0b66efc3f5dd296711c0f203a13144 
>   src/slave/slave.cpp e1566832f90cca372ad2f1cc13d1e7f76fa53285 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/8/
> 
> 
> Testing
> -------
> 
> `make check`, tested as part of https://reviews.apache.org/r/63843/.
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

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

(Updated Nov. 29, 2017, 5:27 p.m.)


Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Changes
-------

Addressed comment from Jie (update used resoures when removing an offer).


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs (updated)
-----

  src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
  src/master/master.cpp 700e12433b0b66efc3f5dd296711c0f203a13144 
  src/slave/slave.cpp e1566832f90cca372ad2f1cc13d1e7f76fa53285 


Diff: https://reviews.apache.org/r/63842/diff/8/

Changes: https://reviews.apache.org/r/63842/diff/7-8/


Testing
-------

`make check`, tested as part of https://reviews.apache.org/r/63843/.


Thanks,

Benjamin Bannier


Re: Review Request 63842: Allowed removing non-terminal offer operations.

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

(Updated Nov. 28, 2017, 10:32 p.m.)


Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Changes
-------

Rebased.


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs (updated)
-----

  src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
  src/master/master.cpp 700e12433b0b66efc3f5dd296711c0f203a13144 
  src/slave/slave.cpp cd716476dfad619dc6cf7449a32a27842efbe7fb 


Diff: https://reviews.apache.org/r/63842/diff/7/

Changes: https://reviews.apache.org/r/63842/diff/6-7/


Testing
-------

`make check`, tested as part of https://reviews.apache.org/r/63843/.


Thanks,

Benjamin Bannier


Re: Review Request 63842: Allowed removing non-terminal offer operations.

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

(Updated Nov. 27, 2017, 4 p.m.)


Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs
-----

  src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
  src/master/master.cpp 53263e499d88b906b6406c24c0dfb737e589e813 
  src/slave/slave.cpp f93ff7b20815c3ccb274ce6990ee66a17b6ac51c 


Diff: https://reviews.apache.org/r/63842/diff/6/


Testing
-------

`make check`, tested as part of https://reviews.apache.org/r/63843/.

This patch requires `protobuf::isSpeculativeOperation` from https://reviews.apache.org/r/63751/ which is _not_ part of this review chain (to avoid multiple dependent RRs).


Thanks,

Benjamin Bannier


Re: Review Request 63842: Allowed removing non-terminal offer operations.

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

(Updated Nov. 24, 2017, 3:52 p.m.)


Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Changes
-------

Rebased.


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs (updated)
-----

  src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
  src/master/master.cpp 53263e499d88b906b6406c24c0dfb737e589e813 
  src/slave/slave.cpp f93ff7b20815c3ccb274ce6990ee66a17b6ac51c 


Diff: https://reviews.apache.org/r/63842/diff/6/

Changes: https://reviews.apache.org/r/63842/diff/5-6/


Testing
-------

`make check`, tested as part of https://reviews.apache.org/r/63843/.

This patch requires `protobuf::isSpeculativeOperation` from https://reviews.apache.org/r/63751/ which is _not_ part of this review chain (to avoid multiple dependent RRs).


Thanks,

Benjamin Bannier


Re: Review Request 63842: Allowed removing non-terminal offer operations.

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

(Updated Nov. 24, 2017, 3:08 p.m.)


Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Changes
-------

Rebased.


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs (updated)
-----

  src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
  src/master/master.cpp 53263e499d88b906b6406c24c0dfb737e589e813 
  src/slave/slave.cpp f93ff7b20815c3ccb274ce6990ee66a17b6ac51c 


Diff: https://reviews.apache.org/r/63842/diff/5/

Changes: https://reviews.apache.org/r/63842/diff/4-5/


Testing
-------

`make check`, tested as part of https://reviews.apache.org/r/63843/.

This patch requires `protobuf::isSpeculativeOperation` from https://reviews.apache.org/r/63751/ which is _not_ part of this review chain (to avoid multiple dependent RRs).


Thanks,

Benjamin Bannier


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Jie Yu <yu...@gmail.com>.

> On Nov. 21, 2017, 10:22 p.m., Jie Yu wrote:
> > src/master/master.hpp
> > Lines 2919 (patched)
> > <https://reviews.apache.org/r/63842/diff/4/?file=1898995#file1898995line2919>
> >
> >     `removeOfferOperation` might be used for old operations too. This will throw a CHECK failure.
> 
> Benjamin Bannier wrote:
>     Dropping this as the code was removed. Now that `addOfferOperation` does not modify resources anymore, neither should `removeOfferOperation`.

`addOfferOperation` does not convert `total`. It'll still be responsible for tracking 'used' resources. The reason we don't update `total` in `addOfferOperation` is because we want to support setting total to a snapshot when receiving update slave message. However, tracking 'used' should be orthogonal, and we should still rely on `addOfferOperation` to track used resources.


- Jie


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


On Nov. 24, 2017, 2:52 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 24, 2017, 2:52 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
>   src/master/master.cpp 53263e499d88b906b6406c24c0dfb737e589e813 
>   src/slave/slave.cpp f93ff7b20815c3ccb274ce6990ee66a17b6ac51c 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/6/
> 
> 
> Testing
> -------
> 
> `make check`, tested as part of https://reviews.apache.org/r/63843/.
> 
> This patch requires `protobuf::isSpeculativeOperation` from https://reviews.apache.org/r/63751/ which is _not_ part of this review chain (to avoid multiple dependent RRs).
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Benjamin Bannier <be...@mesosphere.io>.

> On Nov. 21, 2017, 11:22 p.m., Jie Yu wrote:
> > src/master/master.hpp
> > Lines 2919 (patched)
> > <https://reviews.apache.org/r/63842/diff/4/?file=1898995#file1898995line2919>
> >
> >     `removeOfferOperation` might be used for old operations too. This will throw a CHECK failure.

Dropping this as the code was removed. Now that `addOfferOperation` does not modify resources anymore, neither should `removeOfferOperation`.


- Benjamin


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


On Nov. 24, 2017, 3:52 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 24, 2017, 3:52 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
>   src/master/master.cpp 53263e499d88b906b6406c24c0dfb737e589e813 
>   src/slave/slave.cpp f93ff7b20815c3ccb274ce6990ee66a17b6ac51c 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/6/
> 
> 
> Testing
> -------
> 
> `make check`, tested as part of https://reviews.apache.org/r/63843/.
> 
> This patch requires `protobuf::isSpeculativeOperation` from https://reviews.apache.org/r/63751/ which is _not_ part of this review chain (to avoid multiple dependent RRs).
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Jie Yu <yu...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63842/#review191664
-----------------------------------------------------------




src/master/master.hpp
Lines 2919 (patched)
<https://reviews.apache.org/r/63842/#comment269505>

    `removeOfferOperation` might be used for old operations too. This will throw a CHECK failure.


- Jie Yu


On Nov. 21, 2017, 10:11 p.m., Benjamin Bannier wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/63842/
> -----------------------------------------------------------
> 
> (Updated Nov. 21, 2017, 10:11 p.m.)
> 
> 
> Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> During reconcilation we might be required to remove non-terminal offer
> operations from bookkeeping.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
>   src/master/master.cpp 7417b5d641fd4bb6d91cb0e6456c60201bbc8206 
>   src/slave/slave.cpp 6e9adc60f593faf1b0e56caeea04882f67af7080 
> 
> 
> Diff: https://reviews.apache.org/r/63842/diff/4/
> 
> 
> Testing
> -------
> 
> `make check`, tested as part of https://reviews.apache.org/r/63843/.
> 
> This patch requires `protobuf::isSpeculativeOperation` from https://reviews.apache.org/r/63751/ which is _not_ part of this review chain (to avoid multiple dependent RRs).
> 
> 
> Thanks,
> 
> Benjamin Bannier
> 
>


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Benjamin Bannier <bb...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63842/
-----------------------------------------------------------

(Updated Nov. 21, 2017, 11:11 p.m.)


Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Changes
-------

Did not count speculative operations as `used`.


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs (updated)
-----

  src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
  src/master/master.cpp 7417b5d641fd4bb6d91cb0e6456c60201bbc8206 
  src/slave/slave.cpp 6e9adc60f593faf1b0e56caeea04882f67af7080 


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

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


Testing (updated)
-------

`make check`, tested as part of https://reviews.apache.org/r/63843/.

This patch requires `protobuf::isSpeculativeOperation` from https://reviews.apache.org/r/63751/ which is _not_ part of this review chain (to avoid multiple dependent RRs).


Thanks,

Benjamin Bannier


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Benjamin Bannier <bb...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63842/
-----------------------------------------------------------

(Updated Nov. 21, 2017, 10:08 p.m.)


Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Changes
-------

Addressed comment from Jie; made use of helper added as dependency in previous patch.


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs (updated)
-----

  src/master/master.hpp 2a2e830354db4a2191fb8321beb8174b80f7ba7d 
  src/master/master.cpp 7417b5d641fd4bb6d91cb0e6456c60201bbc8206 
  src/slave/slave.cpp 6e9adc60f593faf1b0e56caeea04882f67af7080 


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

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


Testing
-------

`make check`


Thanks,

Benjamin Bannier


Re: Review Request 63842: Allowed removing non-terminal offer operations.

Posted by Benjamin Bannier <bb...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/63842/
-----------------------------------------------------------

(Updated Nov. 17, 2017, 6:24 p.m.)


Review request for mesos, Greg Mann, Jie Yu, and Jan Schlicht.


Changes
-------

Updated used resources when removing a non-terminal offer operation.


Repository: mesos


Description
-------

During reconcilation we might be required to remove non-terminal offer
operations from bookkeeping.


Diffs (updated)
-----

  src/master/master.hpp a309fc78ee2613762f3d5d22ac7559afc7aac4a3 
  src/master/master.cpp 2ddd67ada3731803b00883b6a1f32b20c1bb238f 
  src/slave/slave.cpp d8edc5e6bbfa265bca4d19bbaa7db3063949dbc0 


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

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


Testing
-------

`make check`


Thanks,

Benjamin Bannier