----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/44512/#review122584 -----------------------------------------------------------
Patch looks great! Reviews applied: [41681, 43863, 44512] 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 March 8, 2016, 2:52 p.m., Yongqiao Wang wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/44512/ > ----------------------------------------------------------- > > (Updated March 8, 2016, 2:52 p.m.) > > > Review request for mesos and Adam B. > > > Bugs: MESOS-4316 > https://issues.apache.org/jira/browse/MESOS-4316 > > > Repository: mesos > > > Description > ------- > > Support to get weights info by /weights. > > > Diffs > ----- > > include/mesos/mesos.proto 3d22ec32655dca741169e1f0e382303e061c38b7 > src/master/http.cpp a3ad57a1c3f8a01aa609b28c12825670bb243387 > src/master/master.hpp ea26670e6c6c67314406fded510e8fdd46053dc8 > src/master/weights_handler.cpp PRE-CREATION > > Diff: https://reviews.apache.org/r/44512/diff/ > > > Testing > ------- > > make && make check. > > $ (./mesos-master.sh --ip=127.0.0.1 --work_dir=/tmp/mesos-master > --authenticate_http --credentials=/opt/credentials.json >> > /tmp/mesos-master.log 2>&1 &) > > $ curl --user framework1:secret_string1 http://localhost:5050/weights | > python -mjson.tool > {} > > $ curl --user framework1:secret_string1 --data > "[{\"weight\":1.8,\"role\":\"role1\"},{\"weight\":1.0,\"role\":\"role2\"},{\"weight\":3.4,\"role\":\"role3\"}]" > -X PUT http://127.0.0.1:5050/weights > > $ curl --user framework1:secret_string1 http://localhost:5050/weights | > python -mjson.tool > { > "infos": [ > { > "role": "role3", > "weight": 3.4 > }, > { > "role": "role2", > "weight": 1.0 > }, > { > "role": "role1", > "weight": 1.8 > } > ] > } > > (TODO) Add couple of tests in another patch. > > > Thanks, > > Yongqiao Wang > >