ambari-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sid Wagle" <swa...@hortonworks.com>
Subject Review Request 41471: Add ability to restart all host components with stale_configs=true with one API request
Date Wed, 16 Dec 2015 22:14:57 GMT

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

Review request for Ambari, Alejandro Fernandez, Aravindan Vijayan, Dmytro Sen, and Sumit Mohanty.


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


Repository: ambari


Description
-------

Provide ability to filter host components using a predicate that allows bulk ops like RESTART
of stale configs with a simple API call.

Example:
{code}
{
  "RequestInfo": {
    "context": "Restart stale",
    "operational_level": "host_component",
    "command": "RESTART"
  },
  "Requests/resource_filters": [
    {
      "hosts_predicate": "HostRoles/stale_configs=true"
    }
  ]
}
{code}

This API call should allow user to perform custom command restart on all host components with
stale configurations.


Diffs
-----

  ambari-server/src/main/java/org/apache/ambari/server/controller/internal/HostComponentResourceProvider.java
44b9a15 
  ambari-server/src/main/java/org/apache/ambari/server/controller/internal/RequestResourceProvider.java
d79fed4 
  ambari-server/src/main/java/org/apache/ambari/server/controller/utilities/PredicateBuilder.java
ccadc43 
  ambari-server/src/main/java/org/apache/ambari/server/state/cluster/ClusterImpl.java b2a8485

  ambari-server/src/test/java/org/apache/ambari/server/api/predicate/QueryLexerTest.java 8caa821

  ambari-server/src/test/java/org/apache/ambari/server/controller/internal/RequestResourceProviderTest.java
9377493 
  ambari-server/src/test/java/org/apache/ambari/server/controller/metrics/timeline/AMSPropertyProviderTest.java
3c72dbf 

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


Testing
-------

Manual testing done.
Unit test passes.


Thanks,

Sid Wagle


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message