----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/36843/#review93106 -----------------------------------------------------------
Ship it! Ship It! - Andrew Onischuk On July 27, 2015, 7:28 a.m., Vitalyi Brodetskyi wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/36843/ > ----------------------------------------------------------- > > (Updated July 27, 2015, 7:28 a.m.) > > > Review request for Ambari and Andrew Onischuk. > > > Bugs: AMBARI-12547 > https://issues.apache.org/jira/browse/AMBARI-12547 > > > Repository: ambari > > > Description > ------- > > While issuing the API to try to start all host components on c6401: > {code} > curl --user admin:admin -H "X-Requested-By: ambari" -i -X PUT -d > '{"HostRoles":{"state":"STARTED"}}' http://`hostname > -f`:8080/api/v1/clusters/c1/hosts/c6401.ambari.apache.org/host_components > {code} > *Response* > {code} > { > "status" : 400, > "message" : "java.lang.IllegalArgumentException: Invalid desired state for > a client component" > } > {code} > > *Note:* There was no serviceComponent name specified but the API treats this > scenario as start request has been made on client component > > Currently, you have to explicitly specify all the host components that you > wish to start. This is very cumbersome and not user friendly. > We also cannot do something like > /api/v1/clusters/c1/hosts/c6401.ambari.apache.org/host_components?HostRoles/is_client!=true > > > Diffs > ----- > > > ambari-server/src/main/java/org/apache/ambari/server/controller/internal/HostComponentResourceProvider.java > d7fc33b > > ambari-server/src/test/java/org/apache/ambari/server/controller/AmbariManagementControllerTest.java > 46dbb8e > > ambari-server/src/test/java/org/apache/ambari/server/controller/internal/HostComponentResourceProviderTest.java > c38b142 > > Diff: https://reviews.apache.org/r/36843/diff/ > > > Testing > ------- > > mvn clean test > > > Thanks, > > Vitalyi Brodetskyi > >
