You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@mesos.apache.org by Yongqiao Wang <yq...@cn.ibm.com> on 2016/02/01 11:05:46 UTC

Review Request 43041: Update Master to send revocable resources in separate offers.

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

Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.


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


Repository: mesos


Description
-------

Split regular and revocable resources into separate offers,
so that rescinding offers with revocable resources does not
affect offers with regular resources.


Diffs
-----

  src/master/master.hpp 3a7e18232323a1c051bcc97915484b1195fffe58 
  src/master/master.cpp 98441a543611d4083b2495ee103f0ab5e2187e83 
  src/tests/oversubscription_tests.cpp 6f43103e81303015fb614653e3bfece55009d1bf 

Diff: https://reviews.apache.org/r/43041/diff/


Testing
-------

Make && Make check
 
(TODO) I will append the related test cases in another patch later.


Thanks,

Yongqiao Wang


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

Posted by Jian Qiu <qi...@cn.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43041/#review119273
-----------------------------------------------------------




src/master/master.cpp (line 5281)
<https://reviews.apache.org/r/43041/#comment180585>

    How about
    
    if (revocableResource != offered) {
      Offer offer = createOffer(framework, slave, offered - revocableResource)
      ...
    }
    
    if (!revocableResource.empty()) {
      Offer offer = createOffer(framework, slave, revocableResource)
    }


- Jian Qiu


On 二月 16, 2016, 8:21 a.m., Yongqiao Wang wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43041/
> -----------------------------------------------------------
> 
> (Updated 二月 16, 2016, 8:21 a.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.
> 
> 
> Bugs: MESOS-2646
>     https://issues.apache.org/jira/browse/MESOS-2646
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Update Master to send revocable resources in separate offers.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2f2ad2ada508e1923bf995ab124367a3b082b572 
>   src/master/master.cpp e1ca81dab85a7ab1391eca0d6bd995548bf79c22 
>   src/tests/oversubscription_tests.cpp d4ae81972fd218c58a413d1968a4e9acbee52fd3 
> 
> Diff: https://reviews.apache.org/r/43041/diff/
> 
> 
> Testing
> -------
> 
> Make && Make check
>  
> Test: https://reviews.apache.org/r/43593/
> 
> 
> Thanks,
> 
> Yongqiao Wang
> 
>


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

Posted by Yongqiao Wang <yq...@cn.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43041/
-----------------------------------------------------------

(Updated Feb. 17, 2016, 3 a.m.)


Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.


Changes
-------

Rebase.


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


Repository: mesos


Description
-------

Update Master to send revocable resources in separate offers.


Diffs (updated)
-----

  src/master/master.hpp 2f2ad2ada508e1923bf995ab124367a3b082b572 
  src/master/master.cpp e1ca81dab85a7ab1391eca0d6bd995548bf79c22 
  src/tests/oversubscription_tests.cpp d4ae81972fd218c58a413d1968a4e9acbee52fd3 

Diff: https://reviews.apache.org/r/43041/diff/


Testing
-------

Make && Make check
 
Test: https://reviews.apache.org/r/43593/


Thanks,

Yongqiao Wang


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

Posted by Yongqiao Wang <yq...@cn.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43041/
-----------------------------------------------------------

(Updated Feb. 16, 2016, 11:57 a.m.)


Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.


Changes
-------

Addressed DA's comments.


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


Repository: mesos


Description
-------

Update Master to send revocable resources in separate offers.


Diffs (updated)
-----

  src/master/master.hpp 2f2ad2ada508e1923bf995ab124367a3b082b572 
  src/master/master.cpp e1ca81dab85a7ab1391eca0d6bd995548bf79c22 
  src/tests/oversubscription_tests.cpp d4ae81972fd218c58a413d1968a4e9acbee52fd3 

Diff: https://reviews.apache.org/r/43041/diff/


Testing
-------

Make && Make check
 
Test: https://reviews.apache.org/r/43593/


Thanks,

Yongqiao Wang


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

Posted by Yongqiao Wang <yq...@cn.ibm.com>.

> On Feb. 16, 2016, 10:08 a.m., Klaus Ma wrote:
> > src/master/master.cpp, line 5285
> > <https://reviews.apache.org/r/43041/diff/4/?file=1241830#file1241830line5285>
> >
> >     Use `Resources::nonRevocable()`
> >     
> >     Maybe use `Try<Offer> createOffer(...)` is better; so we can check the parameters in `createOffer()`.

Use 'Try<offer>' except some error happened in createOffer function, in this patch use 'Offer' is enough due to no any error happened.


- Yongqiao


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


On Feb. 16, 2016, 8:52 a.m., Yongqiao Wang wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43041/
> -----------------------------------------------------------
> 
> (Updated Feb. 16, 2016, 8:52 a.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.
> 
> 
> Bugs: MESOS-2646
>     https://issues.apache.org/jira/browse/MESOS-2646
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Update Master to send revocable resources in separate offers.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2f2ad2ada508e1923bf995ab124367a3b082b572 
>   src/master/master.cpp e1ca81dab85a7ab1391eca0d6bd995548bf79c22 
>   src/tests/oversubscription_tests.cpp d4ae81972fd218c58a413d1968a4e9acbee52fd3 
> 
> Diff: https://reviews.apache.org/r/43041/diff/
> 
> 
> Testing
> -------
> 
> Make && Make check
>  
> Test: https://reviews.apache.org/r/43593/
> 
> 
> Thanks,
> 
> Yongqiao Wang
> 
>


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

Posted by Klaus Ma <kl...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43041/#review119279
-----------------------------------------------------------




src/master/master.cpp (line 5283)
<https://reviews.apache.org/r/43041/#comment180596>

    s/Create add add/Create and add/
    
    Maybe "Create offer with regular resources only."



src/master/master.cpp (line 5284)
<https://reviews.apache.org/r/43041/#comment180592>

    Use `Resources::nonRevocable()`
    
    Maybe use `Try<Offer> createOffer(...)` is better; so we can check the parameters in `createOffer()`.



src/master/master.cpp (line 5285)
<https://reviews.apache.org/r/43041/#comment180600>

    Remove empty line.



src/master/master.cpp (line 5292)
<https://reviews.apache.org/r/43041/#comment180599>

    ditto



src/tests/oversubscription_tests.cpp (line 588)
<https://reviews.apache.org/r/43041/#comment180595>

    `EXPECT_EQ(offer1.slaveID(), offer2.slaveID())`


- Klaus Ma


On Feb. 16, 2016, 4:52 p.m., Yongqiao Wang wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43041/
> -----------------------------------------------------------
> 
> (Updated Feb. 16, 2016, 4:52 p.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.
> 
> 
> Bugs: MESOS-2646
>     https://issues.apache.org/jira/browse/MESOS-2646
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Update Master to send revocable resources in separate offers.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 2f2ad2ada508e1923bf995ab124367a3b082b572 
>   src/master/master.cpp e1ca81dab85a7ab1391eca0d6bd995548bf79c22 
>   src/tests/oversubscription_tests.cpp d4ae81972fd218c58a413d1968a4e9acbee52fd3 
> 
> Diff: https://reviews.apache.org/r/43041/diff/
> 
> 
> Testing
> -------
> 
> Make && Make check
>  
> Test: https://reviews.apache.org/r/43593/
> 
> 
> Thanks,
> 
> Yongqiao Wang
> 
>


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

Posted by Yongqiao Wang <yq...@cn.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43041/
-----------------------------------------------------------

(Updated Feb. 16, 2016, 8:52 a.m.)


Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.


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


Repository: mesos


Description
-------

Update Master to send revocable resources in separate offers.


Diffs (updated)
-----

  src/master/master.hpp 2f2ad2ada508e1923bf995ab124367a3b082b572 
  src/master/master.cpp e1ca81dab85a7ab1391eca0d6bd995548bf79c22 
  src/tests/oversubscription_tests.cpp d4ae81972fd218c58a413d1968a4e9acbee52fd3 

Diff: https://reviews.apache.org/r/43041/diff/


Testing
-------

Make && Make check
 
Test: https://reviews.apache.org/r/43593/


Thanks,

Yongqiao Wang


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

Posted by Yongqiao Wang <yq...@cn.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43041/
-----------------------------------------------------------

(Updated Feb. 16, 2016, 8:45 a.m.)


Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.


Changes
-------

Addressed comments of Jian.


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


Repository: mesos


Description
-------

Update Master to send revocable resources in separate offers.


Diffs (updated)
-----

  src/master/master.hpp 2f2ad2ada508e1923bf995ab124367a3b082b572 
  src/master/master.cpp e1ca81dab85a7ab1391eca0d6bd995548bf79c22 
  src/tests/oversubscription_tests.cpp d4ae81972fd218c58a413d1968a4e9acbee52fd3 

Diff: https://reviews.apache.org/r/43041/diff/


Testing
-------

Make && Make check
 
Test: https://reviews.apache.org/r/43593/


Thanks,

Yongqiao Wang


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

Posted by Yongqiao Wang <yq...@cn.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43041/
-----------------------------------------------------------

(Updated Feb. 16, 2016, 8:21 a.m.)


Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.


Changes
-------

Update the offer seqence.


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


Repository: mesos


Description (updated)
-------

Update Master to send revocable resources in separate offers.


Diffs (updated)
-----

  src/master/master.hpp 2f2ad2ada508e1923bf995ab124367a3b082b572 
  src/master/master.cpp e1ca81dab85a7ab1391eca0d6bd995548bf79c22 
  src/tests/oversubscription_tests.cpp d4ae81972fd218c58a413d1968a4e9acbee52fd3 

Diff: https://reviews.apache.org/r/43041/diff/


Testing
-------

Make && Make check
 
Test: https://reviews.apache.org/r/43593/


Thanks,

Yongqiao Wang


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

Posted by Yongqiao Wang <yq...@cn.ibm.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/43041/
-----------------------------------------------------------

(Updated Feb. 16, 2016, 8:09 a.m.)


Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.


Changes
-------

Add test.


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


Repository: mesos


Description
-------

Split regular and revocable resources into separate offers,
so that rescinding offers with revocable resources does not
affect offers with regular resources.


Diffs
-----

  src/master/master.hpp 3a7e18232323a1c051bcc97915484b1195fffe58 
  src/master/master.cpp 98441a543611d4083b2495ee103f0ab5e2187e83 
  src/tests/oversubscription_tests.cpp 6f43103e81303015fb614653e3bfece55009d1bf 

Diff: https://reviews.apache.org/r/43041/diff/


Testing (updated)
-------

Make && Make check
 
Test: https://reviews.apache.org/r/43593/


Thanks,

Yongqiao Wang


Re: Review Request 43041: Update Master to send revocable resources in separate offers.

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



Patch looks great!

Reviews applied: [43041]

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

- Mesos ReviewBot


On Feb. 1, 2016, 10:05 a.m., Yongqiao Wang wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/43041/
> -----------------------------------------------------------
> 
> (Updated Feb. 1, 2016, 10:05 a.m.)
> 
> 
> Review request for mesos, Guangya Liu, Klaus Ma, Niklas Nielsen, Qian Zhang, Jian Qiu, and Vinod Kone.
> 
> 
> Bugs: MESOS-2646
>     https://issues.apache.org/jira/browse/MESOS-2646
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Split regular and revocable resources into separate offers,
> so that rescinding offers with revocable resources does not
> affect offers with regular resources.
> 
> 
> Diffs
> -----
> 
>   src/master/master.hpp 3a7e18232323a1c051bcc97915484b1195fffe58 
>   src/master/master.cpp 98441a543611d4083b2495ee103f0ab5e2187e83 
>   src/tests/oversubscription_tests.cpp 6f43103e81303015fb614653e3bfece55009d1bf 
> 
> Diff: https://reviews.apache.org/r/43041/diff/
> 
> 
> Testing
> -------
> 
> Make && Make check
>  
> (TODO) I will append the related test cases in another patch later.
> 
> 
> Thanks,
> 
> Yongqiao Wang
> 
>