You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Benno Evers <be...@mesosphere.com> on 2019/10/29 18:14:37 UTC
Review Request 71690: Added function to compute a common reservation
ancestor.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/71690/
-----------------------------------------------------------
Review request for mesos and Benjamin Bannier.
Bugs: MESOS-9984
https://issues.apache.org/jira/browse/MESOS-9984
Repository: mesos
Description
-------
Added a new function `Resources::getReservationAncestor()` to compute
a common reservation ancestor between two `Resources`.
Diffs
-----
include/mesos/resources.hpp b8aef28e08f85c87bb78f25a64b0d7318f2727cc
src/common/resources.cpp bfa9f3ea7e8c3e2dc9b4c4f7c86ad29b0de81f24
src/tests/resources_tests.cpp b5854656b7e9ce7af9e1d8ecad708066512d814f
Diff: https://reviews.apache.org/r/71690/diff/1/
Testing
-------
Thanks,
Benno Evers
Re: Review Request 71690: Added function to compute a common
reservation ancestor.
Posted by Benno Evers <be...@mesosphere.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/71690/
-----------------------------------------------------------
(Updated Nov. 6, 2019, 3:52 p.m.)
Review request for mesos and Benjamin Bannier.
Changes
-------
Addressed comments.
Bugs: MESOS-9984
https://issues.apache.org/jira/browse/MESOS-9984
Repository: mesos
Description
-------
Added a new function `Resources::getReservationAncestor()` to compute
a common reservation ancestor between two `Resources`.
Diffs (updated)
-----
include/mesos/resources.hpp b8aef28e08f85c87bb78f25a64b0d7318f2727cc
src/common/resources.cpp bfa9f3ea7e8c3e2dc9b4c4f7c86ad29b0de81f24
src/tests/resources_tests.cpp b5854656b7e9ce7af9e1d8ecad708066512d814f
Diff: https://reviews.apache.org/r/71690/diff/4/
Changes: https://reviews.apache.org/r/71690/diff/3-4/
Testing
-------
Thanks,
Benno Evers
Re: Review Request 71690: Added function to compute a common
reservation ancestor.
Posted by Benjamin Bannier <bb...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/71690/#review218533
-----------------------------------------------------------
src/common/resources.cpp
Line 612 (original)
<https://reviews.apache.org/r/71690/#comment306269>
Let's keep this line.
src/common/resources.cpp
Lines 1339 (patched)
<https://reviews.apache.org/r/71690/#comment306270>
This function has an implicit precondition on `r1` and `r2` referring to identical resource quantities. Let's at least add this to the declarations's documentation.
- Benjamin Bannier
On Nov. 5, 2019, 6:12 p.m., Benno Evers wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/71690/
> -----------------------------------------------------------
>
> (Updated Nov. 5, 2019, 6:12 p.m.)
>
>
> Review request for mesos and Benjamin Bannier.
>
>
> Bugs: MESOS-9984
> https://issues.apache.org/jira/browse/MESOS-9984
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Added a new function `Resources::getReservationAncestor()` to compute
> a common reservation ancestor between two `Resources`.
>
>
> Diffs
> -----
>
> include/mesos/resources.hpp b8aef28e08f85c87bb78f25a64b0d7318f2727cc
> src/common/resources.cpp bfa9f3ea7e8c3e2dc9b4c4f7c86ad29b0de81f24
> src/tests/resources_tests.cpp b5854656b7e9ce7af9e1d8ecad708066512d814f
>
>
> Diff: https://reviews.apache.org/r/71690/diff/3/
>
>
> Testing
> -------
>
>
> Thanks,
>
> Benno Evers
>
>
Re: Review Request 71690: Added function to compute a common
reservation ancestor.
Posted by Benno Evers <be...@mesosphere.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/71690/
-----------------------------------------------------------
(Updated Nov. 5, 2019, 5:12 p.m.)
Review request for mesos and Benjamin Bannier.
Changes
-------
Fixed a bug where the reservation ancestor was not properly computed.
Bugs: MESOS-9984
https://issues.apache.org/jira/browse/MESOS-9984
Repository: mesos
Description
-------
Added a new function `Resources::getReservationAncestor()` to compute
a common reservation ancestor between two `Resources`.
Diffs (updated)
-----
include/mesos/resources.hpp b8aef28e08f85c87bb78f25a64b0d7318f2727cc
src/common/resources.cpp bfa9f3ea7e8c3e2dc9b4c4f7c86ad29b0de81f24
src/tests/resources_tests.cpp b5854656b7e9ce7af9e1d8ecad708066512d814f
Diff: https://reviews.apache.org/r/71690/diff/3/
Changes: https://reviews.apache.org/r/71690/diff/2-3/
Testing
-------
Thanks,
Benno Evers
Re: Review Request 71690: Added function to compute a common
reservation ancestor.
Posted by Benno Evers <be...@mesosphere.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/71690/
-----------------------------------------------------------
(Updated Nov. 5, 2019, 1:24 p.m.)
Review request for mesos and Benjamin Bannier.
Changes
-------
Incorporated changes by @bbannier
Bugs: MESOS-9984
https://issues.apache.org/jira/browse/MESOS-9984
Repository: mesos
Description
-------
Added a new function `Resources::getReservationAncestor()` to compute
a common reservation ancestor between two `Resources`.
Diffs (updated)
-----
include/mesos/resources.hpp b8aef28e08f85c87bb78f25a64b0d7318f2727cc
src/common/resources.cpp bfa9f3ea7e8c3e2dc9b4c4f7c86ad29b0de81f24
src/tests/resources_tests.cpp b5854656b7e9ce7af9e1d8ecad708066512d814f
Diff: https://reviews.apache.org/r/71690/diff/2/
Changes: https://reviews.apache.org/r/71690/diff/1-2/
Testing
-------
Thanks,
Benno Evers
Re: Review Request 71690: Added function to compute a common
reservation ancestor.
Posted by Benjamin Bannier <bb...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/71690/#review218481
-----------------------------------------------------------
I think this patch does what we need. We want a function which when given two `Resources` (where all of each `Resources`' `Resource`s have identical `ReservationInfo`s, and where, but for the reservation state the two `Resources` are identical) will return the first `Resources` which can be reached by removing `ReservationInfo`s from the two `Resources`. This `Resources` always exists (bottom case: completely unreserved `Resources`).
One practical algorithm to find this `Resources` is to start with the bottom case, and push `reservations[0..]` onto it which are present in both the input resources.
- Benjamin Bannier
On Oct. 29, 2019, 7:14 p.m., Benno Evers wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/71690/
> -----------------------------------------------------------
>
> (Updated Oct. 29, 2019, 7:14 p.m.)
>
>
> Review request for mesos and Benjamin Bannier.
>
>
> Bugs: MESOS-9984
> https://issues.apache.org/jira/browse/MESOS-9984
>
>
> Repository: mesos
>
>
> Description
> -------
>
> Added a new function `Resources::getReservationAncestor()` to compute
> a common reservation ancestor between two `Resources`.
>
>
> Diffs
> -----
>
> include/mesos/resources.hpp b8aef28e08f85c87bb78f25a64b0d7318f2727cc
> src/common/resources.cpp bfa9f3ea7e8c3e2dc9b4c4f7c86ad29b0de81f24
> src/tests/resources_tests.cpp b5854656b7e9ce7af9e1d8ecad708066512d814f
>
>
> Diff: https://reviews.apache.org/r/71690/diff/1/
>
>
> Testing
> -------
>
>
> Thanks,
>
> Benno Evers
>
>