----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/51851/ -----------------------------------------------------------
Review request for Ambari, Robert Nettleton and Sumit Mohanty. Bugs: AMBARI-18332 https://issues.apache.org/jira/browse/AMBARI-18332 Repository: ambari Description ------- AMBARI-18332: Blueprints: API should make available "setting" property from blueprint ** Issue: ** A new section *setting* was added to blueprints to support auto-start. However, when querying the blueprint that used to deploy a cluster, the *setting* section is absent. ** Fix: ** Add the *setting* section to the blueprint response that is returned during a http://<server_name>:<port>/api/v1/blueprints/<blueprint_name> Diffs ----- ambari-server/src/main/java/org/apache/ambari/server/controller/internal/BlueprintResourceProvider.java 775827b4425a6668fd11d435ca7e4175d1f75d16 ambari-server/src/test/java/org/apache/ambari/server/controller/internal/BlueprintResourceProviderTest.java 75eff7e1d1d5b8db232f109eb08b6cb57ce0a105 Diff: https://reviews.apache.org/r/51851/diff/ Testing ------- ** 1. mvn clean install ** [INFO] ------------------------------------------------------------------------ [INFO] Reactor Summary: [INFO] [INFO] Ambari Main ....................................... SUCCESS [11.486s] [INFO] Apache Ambari Project POM ......................... SUCCESS [0.041s] [INFO] Ambari Web ........................................ SUCCESS [1:11.461s] [INFO] Ambari Views ...................................... SUCCESS [1.161s] [INFO] Ambari Admin View ................................. SUCCESS [8.439s] [INFO] ambari-metrics .................................... SUCCESS [0.681s] [INFO] Ambari Metrics Common ............................. SUCCESS [4.584s] [INFO] Ambari Metrics Hadoop Sink ........................ SUCCESS [2.078s] [INFO] Ambari Metrics Flume Sink ......................... SUCCESS [1.289s] [INFO] Ambari Metrics Kafka Sink ......................... SUCCESS [1.410s] [INFO] Ambari Metrics Storm Sink ......................... SUCCESS [4.003s] [INFO] Ambari Metrics Storm Sink (Legacy) ................ SUCCESS [1.559s] [INFO] Ambari Metrics Collector .......................... SUCCESS [10.463s] [INFO] Ambari Metrics Monitor ............................ SUCCESS [1.870s] [INFO] Ambari Metrics Grafana ............................ SUCCESS [1.009s] [INFO] Ambari Metrics Assembly ........................... SUCCESS [1:19.907s] [INFO] Ambari Server ..................................... SUCCESS [3:03.887s] [INFO] Ambari Functional Tests ........................... SUCCESS [2.286s] [INFO] Ambari Agent ...................................... SUCCESS [26.876s] [INFO] Ambari Client ..................................... SUCCESS [0.048s] [INFO] Ambari Python Client .............................. SUCCESS [0.940s] [INFO] Ambari Groovy Client .............................. SUCCESS [2.030s] [INFO] Ambari Shell ...................................... SUCCESS [0.047s] [INFO] Ambari Python Shell ............................... SUCCESS [0.672s] [INFO] Ambari Groovy Shell ............................... SUCCESS [0.994s] [INFO] ambari-logsearch .................................. SUCCESS [0.302s] [INFO] Ambari Logsearch Appender ......................... SUCCESS [0.225s] [INFO] Ambari Logsearch Solr Client ...................... SUCCESS [1.219s] [INFO] Ambari Logsearch Portal ........................... SUCCESS [6.735s] [INFO] Ambari Logsearch Log Feeder ....................... SUCCESS [3.926s] [INFO] Ambari Logsearch Assembly ......................... SUCCESS [0.074s] [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 7:13.702s [INFO] Finished at: Tue Sep 13 11:00:07 PDT 2016 [INFO] Final Memory: 302M/1191M [INFO] ------------------------------------------------------------------------ ** 2. mvn test -DskipPythonTests -Dtest=Blueprint*Test ** ** Added a new test BlueprintResourceProviderTest::testPopulateSettingList() ** * This test creates the setting JSON and adds it to the blueprint response * Results : Tests run: 247, Failures: 0, Errors: 0, Skipped: 0 [INFO] ------------------------------------------------------------------------ [INFO] BUILD SUCCESS [INFO] ------------------------------------------------------------------------ [INFO] Total time: 28.790s [INFO] Finished at: Tue Sep 13 11:13:16 PDT 2016 [INFO] Final Memory: 51M/786M [INFO] ------------------------------------------------------------------------ ** 3. Manual Tests ** * Set up a VM with the latest trunk build patched with ambari-server JAR from the local build. * Applied a blueprint: curl -u admin:admin -H "X-Requested-By: ambari" -X POST -d @./bp1.json http://c6401.ambari.apache.org:8080/api/v1/blueprints/bp1 * Ran curl -u admin:admin -H "X-Requested-By: ambari" -X GET http://c6401.ambari.apache.org:8080/api/v1/blueprints/bp1 * Visually verified that the returned JSON response contained the following snippet: "settings" : [ { "service_settings" : [ { "recovery_enabled" : "true", "name" : "HDFS" }, { "recovery_enabled" : "false", "name" : "TEZ" } ] }, { "component_settings" : [ { "recovery_enabled" : "true", "name" : "DATANODE" } ] }, { "recovery_settings" : [ { "recovery_enabled" : "true" } ] } ], "Blueprints" : { "blueprint_name" : "bp1", "stack_name" : "HDP", "stack_version" : "2.5", "security" : { "type" : "NONE" } Thanks, Nahappan Somasundaram