You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ambari.apache.org by Vitalyi Brodetskyi <vb...@hortonworks.com> on 2014/07/21 13:58:57 UTC

Review Request 23731: API call for hosts filtered by host_components/HostRoles/component_name returns 400 error

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

Review request for Ambari, Dmytro Sen and Nate Cole.


Bugs: AMBARI-6546
    https://issues.apache.org/jira/browse/AMBARI-6546


Repository: ambari


Description
-------


When I try to get hosts filtered by host_components/HostRoles/component_name with != clause:

http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name!=HBASE_MASTER

API returns
{ "status": 400, "message": "The properties [host_components/HostRoles/component_name] specified in the request or predicate are not supported for the resource type Host." }

When I try to get hosts filtered by component with '=' clause:
http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name=HBASE_MASTER


Diffs
-----

  ambari-server/src/main/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitor.java a9cd46c 
  ambari-server/src/main/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitor.java 5ec2f10 
  ambari-server/src/test/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitorTest.java 393d5f5 
  ambari-server/src/test/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitorTest.java f6dbdd7 

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


Testing
-------

Results :

Tests run: 1793, Failures: 0, Errors: 0, Skipped: 13


Thanks,

Vitalyi Brodetskyi


Re: Review Request 23731: API call for hosts filtered by host_components/HostRoles/component_name returns 400 error

Posted by Vitalyi Brodetskyi <vb...@hortonworks.com>.

> On July 21, 2014, 3:13 p.m., Tom Beerbower wrote:
> > Will this patch work for a predicate like ... ?
> > 
> >     !(host_components/HostRoles/property1=FOO|host_components/HostRoles/property2=BAR)
> >

Yes, your predicate works correctly.


- Vitalyi


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


On July 21, 2014, 2:42 p.m., Vitalyi Brodetskyi wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/23731/
> -----------------------------------------------------------
> 
> (Updated July 21, 2014, 2:42 p.m.)
> 
> 
> Review request for Ambari, Dmytro Sen, Nate Cole, and Tom Beerbower.
> 
> 
> Bugs: AMBARI-6546
>     https://issues.apache.org/jira/browse/AMBARI-6546
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> 
> When I try to get hosts filtered by host_components/HostRoles/component_name with != clause:
> 
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name!=HBASE_MASTER
> 
> API returns
> { "status": 400, "message": "The properties [host_components/HostRoles/component_name] specified in the request or predicate are not supported for the resource type Host." }
> 
> When I try to get hosts filtered by component with '=' clause:
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name=HBASE_MASTER
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitor.java a9cd46c 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitor.java 5ec2f10 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitorTest.java 393d5f5 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitorTest.java f6dbdd7 
> 
> Diff: https://reviews.apache.org/r/23731/diff/
> 
> 
> Testing
> -------
> 
> Results :
> 
> Tests run: 1793, Failures: 0, Errors: 0, Skipped: 13
> 
> 
> Thanks,
> 
> Vitalyi Brodetskyi
> 
>


Re: Review Request 23731: API call for hosts filtered by host_components/HostRoles/component_name returns 400 error

Posted by Tom Beerbower <tb...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/23731/#review48231
-----------------------------------------------------------


Will this patch work for a predicate like ... ?

    !(host_components/HostRoles/property1=FOO|host_components/HostRoles/property2=BAR)


- Tom Beerbower


On July 21, 2014, 2:42 p.m., Vitalyi Brodetskyi wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/23731/
> -----------------------------------------------------------
> 
> (Updated July 21, 2014, 2:42 p.m.)
> 
> 
> Review request for Ambari, Dmytro Sen, Nate Cole, and Tom Beerbower.
> 
> 
> Bugs: AMBARI-6546
>     https://issues.apache.org/jira/browse/AMBARI-6546
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> 
> When I try to get hosts filtered by host_components/HostRoles/component_name with != clause:
> 
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name!=HBASE_MASTER
> 
> API returns
> { "status": 400, "message": "The properties [host_components/HostRoles/component_name] specified in the request or predicate are not supported for the resource type Host." }
> 
> When I try to get hosts filtered by component with '=' clause:
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name=HBASE_MASTER
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitor.java a9cd46c 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitor.java 5ec2f10 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitorTest.java 393d5f5 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitorTest.java f6dbdd7 
> 
> Diff: https://reviews.apache.org/r/23731/diff/
> 
> 
> Testing
> -------
> 
> Results :
> 
> Tests run: 1793, Failures: 0, Errors: 0, Skipped: 13
> 
> 
> Thanks,
> 
> Vitalyi Brodetskyi
> 
>


Re: Review Request 23731: API call for hosts filtered by host_components/HostRoles/component_name returns 400 error

Posted by Nate Cole <nc...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/23731/#review48226
-----------------------------------------------------------

Ship it!


Ship It!

- Nate Cole


On July 21, 2014, 10:42 a.m., Vitalyi Brodetskyi wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/23731/
> -----------------------------------------------------------
> 
> (Updated July 21, 2014, 10:42 a.m.)
> 
> 
> Review request for Ambari, Dmytro Sen, Nate Cole, and Tom Beerbower.
> 
> 
> Bugs: AMBARI-6546
>     https://issues.apache.org/jira/browse/AMBARI-6546
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> 
> When I try to get hosts filtered by host_components/HostRoles/component_name with != clause:
> 
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name!=HBASE_MASTER
> 
> API returns
> { "status": 400, "message": "The properties [host_components/HostRoles/component_name] specified in the request or predicate are not supported for the resource type Host." }
> 
> When I try to get hosts filtered by component with '=' clause:
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name=HBASE_MASTER
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitor.java a9cd46c 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitor.java 5ec2f10 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitorTest.java 393d5f5 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitorTest.java f6dbdd7 
> 
> Diff: https://reviews.apache.org/r/23731/diff/
> 
> 
> Testing
> -------
> 
> Results :
> 
> Tests run: 1793, Failures: 0, Errors: 0, Skipped: 13
> 
> 
> Thanks,
> 
> Vitalyi Brodetskyi
> 
>


Re: Review Request 23731: API call for hosts filtered by host_components/HostRoles/component_name returns 400 error

Posted by Tom Beerbower <tb...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/23731/#review48238
-----------------------------------------------------------

Ship it!


Ship It!

- Tom Beerbower


On July 21, 2014, 2:42 p.m., Vitalyi Brodetskyi wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/23731/
> -----------------------------------------------------------
> 
> (Updated July 21, 2014, 2:42 p.m.)
> 
> 
> Review request for Ambari, Dmytro Sen, Nate Cole, and Tom Beerbower.
> 
> 
> Bugs: AMBARI-6546
>     https://issues.apache.org/jira/browse/AMBARI-6546
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> 
> When I try to get hosts filtered by host_components/HostRoles/component_name with != clause:
> 
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name!=HBASE_MASTER
> 
> API returns
> { "status": 400, "message": "The properties [host_components/HostRoles/component_name] specified in the request or predicate are not supported for the resource type Host." }
> 
> When I try to get hosts filtered by component with '=' clause:
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name=HBASE_MASTER
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitor.java a9cd46c 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitor.java 5ec2f10 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitorTest.java 393d5f5 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitorTest.java f6dbdd7 
> 
> Diff: https://reviews.apache.org/r/23731/diff/
> 
> 
> Testing
> -------
> 
> Results :
> 
> Tests run: 1793, Failures: 0, Errors: 0, Skipped: 13
> 
> 
> Thanks,
> 
> Vitalyi Brodetskyi
> 
>


Re: Review Request 23731: API call for hosts filtered by host_components/HostRoles/component_name returns 400 error

Posted by Vitalyi Brodetskyi <vb...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/23731/
-----------------------------------------------------------

(Updated July 21, 2014, 2:42 p.m.)


Review request for Ambari, Dmytro Sen, Nate Cole, and Tom Beerbower.


Bugs: AMBARI-6546
    https://issues.apache.org/jira/browse/AMBARI-6546


Repository: ambari


Description
-------


When I try to get hosts filtered by host_components/HostRoles/component_name with != clause:

http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name!=HBASE_MASTER

API returns
{ "status": 400, "message": "The properties [host_components/HostRoles/component_name] specified in the request or predicate are not supported for the resource type Host." }

When I try to get hosts filtered by component with '=' clause:
http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name=HBASE_MASTER


Diffs
-----

  ambari-server/src/main/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitor.java a9cd46c 
  ambari-server/src/main/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitor.java 5ec2f10 
  ambari-server/src/test/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitorTest.java 393d5f5 
  ambari-server/src/test/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitorTest.java f6dbdd7 

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


Testing
-------

Results :

Tests run: 1793, Failures: 0, Errors: 0, Skipped: 13


Thanks,

Vitalyi Brodetskyi


Re: Review Request 23731: API call for hosts filtered by host_components/HostRoles/component_name returns 400 error

Posted by Dmytro Sen <ds...@hortonworks.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/23731/#review48213
-----------------------------------------------------------

Ship it!


Ship It!

- Dmytro Sen


On July 21, 2014, 11:58 a.m., Vitalyi Brodetskyi wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/23731/
> -----------------------------------------------------------
> 
> (Updated July 21, 2014, 11:58 a.m.)
> 
> 
> Review request for Ambari, Dmytro Sen and Nate Cole.
> 
> 
> Bugs: AMBARI-6546
>     https://issues.apache.org/jira/browse/AMBARI-6546
> 
> 
> Repository: ambari
> 
> 
> Description
> -------
> 
> 
> When I try to get hosts filtered by host_components/HostRoles/component_name with != clause:
> 
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name!=HBASE_MASTER
> 
> API returns
> { "status": 400, "message": "The properties [host_components/HostRoles/component_name] specified in the request or predicate are not supported for the resource type Host." }
> 
> When I try to get hosts filtered by component with '=' clause:
> http://host:8080/api/v1/clusters/my_cluster/hosts?host_components/HostRoles/component_name=HBASE_MASTER
> 
> 
> Diffs
> -----
> 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitor.java a9cd46c 
>   ambari-server/src/main/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitor.java 5ec2f10 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/ProcessingPredicateVisitorTest.java 393d5f5 
>   ambari-server/src/test/java/org/apache/ambari/server/api/query/SubResourcePredicateVisitorTest.java f6dbdd7 
> 
> Diff: https://reviews.apache.org/r/23731/diff/
> 
> 
> Testing
> -------
> 
> Results :
> 
> Tests run: 1793, Failures: 0, Errors: 0, Skipped: 13
> 
> 
> Thanks,
> 
> Vitalyi Brodetskyi
> 
>