You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Jan Schlicht <ja...@mesosphere.io> on 2017/04/05 09:24:15 UTC

Re: Review Request 58072: Added resource support for new offer operations.

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

(Updated April 5, 2017, 11:24 a.m.)


Review request for mesos, Benjamin Bannier and Jie Yu.


Changes
-------

Removed "WIP", addressed issues.


Summary (updated)
-----------------

Added resource support for new offer operations.


Repository: mesos


Description (updated)
-------

When applying offer operations to resources, one has to account for
changing resources depending on the operation. For resource-related
operations, disk resources will be converted from a type to another.
So, by applying such an operation, we will substract the resource
of the source type and add the resource of the target type of that
operation.


Diffs (updated)
-----

  src/common/resources.cpp c26e0f995006dc6b2e70a491cea58fa90347e42a 
  src/tests/resources_tests.cpp 343cab2af225a05e32c5a8bd4a5d9ddfbf76536d 
  src/v1/resources.cpp a53deafbea399a1bcf729d1c151bc46e9da04e11 


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

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


Testing
-------

make check


Thanks,

Jan Schlicht


Re: Review Request 58072: Added resource support for new offer operations.

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



Patch looks great!

Reviews applied: [57911, 57997, 57998, 57999, 58048, 58047, 58021, 58071, 58072]

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

- Mesos Reviewbot


On April 5, 2017, 9:26 a.m., Jan Schlicht wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/58072/
> -----------------------------------------------------------
> 
> (Updated April 5, 2017, 9:26 a.m.)
> 
> 
> Review request for mesos, Benjamin Bannier and Jie Yu.
> 
> 
> Bugs: MESOS-7314
>     https://issues.apache.org/jira/browse/MESOS-7314
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> When applying offer operations to resources, one has to account for
> changing resources depending on the operation. For resource-related
> operations, disk resources will be converted from a type to another.
> So, by applying such an operation, we will substract the resource
> of the source type and add the resource of the target type of that
> operation.
> 
> 
> Diffs
> -----
> 
>   src/common/resources.cpp c26e0f995006dc6b2e70a491cea58fa90347e42a 
>   src/tests/resources_tests.cpp 343cab2af225a05e32c5a8bd4a5d9ddfbf76536d 
>   src/v1/resources.cpp a53deafbea399a1bcf729d1c151bc46e9da04e11 
> 
> 
> Diff: https://reviews.apache.org/r/58072/diff/7/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Jan Schlicht
> 
>


Re: Review Request 58072: Added resource support for new offer operations.

Posted by Qian Zhang <zh...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/58072/#review175345
-----------------------------------------------------------




src/common/resources.cpp
Lines 1463-1464 (patched)
<https://reviews.apache.org/r/58072/#comment248797>

    We may need to validate `source` is a RAW disk resource.



src/common/resources.cpp
Lines 1466-1467 (patched)
<https://reviews.apache.org/r/58072/#comment248798>

    We may need to validate `target_type` is either `MOUNT` or `PATH` but not others.


- Qian Zhang


On April 5, 2017, 5:26 p.m., Jan Schlicht wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/58072/
> -----------------------------------------------------------
> 
> (Updated April 5, 2017, 5:26 p.m.)
> 
> 
> Review request for mesos, Benjamin Bannier and Jie Yu.
> 
> 
> Bugs: MESOS-7314
>     https://issues.apache.org/jira/browse/MESOS-7314
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> When applying offer operations to resources, one has to account for
> changing resources depending on the operation. For resource-related
> operations, disk resources will be converted from a type to another.
> So, by applying such an operation, we will substract the resource
> of the source type and add the resource of the target type of that
> operation.
> 
> 
> Diffs
> -----
> 
>   src/common/resources.cpp c26e0f995006dc6b2e70a491cea58fa90347e42a 
>   src/tests/resources_tests.cpp 343cab2af225a05e32c5a8bd4a5d9ddfbf76536d 
>   src/v1/resources.cpp a53deafbea399a1bcf729d1c151bc46e9da04e11 
> 
> 
> Diff: https://reviews.apache.org/r/58072/diff/7/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Jan Schlicht
> 
>


Re: Review Request 58072: Added resource support for new offer operations.

Posted by Jan Schlicht <ja...@mesosphere.io>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/58072/
-----------------------------------------------------------

(Updated April 5, 2017, 11:26 a.m.)


Review request for mesos, Benjamin Bannier and Jie Yu.


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


Repository: mesos


Description
-------

When applying offer operations to resources, one has to account for
changing resources depending on the operation. For resource-related
operations, disk resources will be converted from a type to another.
So, by applying such an operation, we will substract the resource
of the source type and add the resource of the target type of that
operation.


Diffs
-----

  src/common/resources.cpp c26e0f995006dc6b2e70a491cea58fa90347e42a 
  src/tests/resources_tests.cpp 343cab2af225a05e32c5a8bd4a5d9ddfbf76536d 
  src/v1/resources.cpp a53deafbea399a1bcf729d1c151bc46e9da04e11 


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


Testing
-------

make check


Thanks,

Jan Schlicht