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

(Updated Nov. 25, 2015, 8:30 a.m.)


Review request for mesos and Adam B.


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


Repository: mesos


Description
-------

Enhance endpoint /roles for adding a new role


Diffs
-----

  src/master/http.cpp 6c647808a48879cbc176ffe7586c7e9b41bcf4c8 
  src/master/master.hpp e5e0ed01a56d869cc535687c8dbb6b99f6295b66 
  src/master/role_handler.cpp PRE-CREATION 

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


Testing
-------

$ curl -d role="{\"name\":\"role1\",\"weight\":2}" -X POST 
http://127.0.0.1:5050/roles

$ curl -d role="{\"name\":\"role1\",\"weight\":2}" -X POST 
http://127.0.0.1:5050/roles
Failed to validate set role request string: 
('role={"name":"role1","weight":2}')': This role already exist!

$ curl -X GET http://127.0.0.1:5050/roles/role1
{"status":[{"infos":{"name":"role1","weight":2.0}}]}


Thanks,

Yong Qiao Wang

Reply via email to