ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From aonis...@apache.org
Subject [2/2] ambari git commit: AMBARI-15460. Download client configurations does not work (aonishuk)
Date Thu, 17 Mar 2016 12:45:01 GMT
AMBARI-15460. Download client configurations does not work (aonishuk)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/8b150c51
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/8b150c51
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/8b150c51

Branch: refs/heads/branch-2.2
Commit: 8b150c51f34cc46498a31c86dd334b52f15e24df
Parents: 9d3fd9e
Author: Andrew Onishuk <aonishuk@hortonworks.com>
Authored: Thu Mar 17 14:44:51 2016 +0200
Committer: Andrew Onishuk <aonishuk@hortonworks.com>
Committed: Thu Mar 17 14:44:51 2016 +0200

----------------------------------------------------------------------
 .../server/controller/internal/ClientConfigResourceProvider.java | 4 ++++
 .../controller/internal/ClientConfigResourceProviderTest.java    | 4 ++++
 2 files changed, 8 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/8b150c51/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
index 2d26e4b..fb6b63e 100644
--- a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
+++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProvider.java
@@ -75,6 +75,8 @@ import java.util.TreeMap;
 import java.util.concurrent.ExecutionException;
 import java.util.concurrent.TimeoutException;
 
+import static org.apache.ambari.server.agent.ExecutionCommand.KeyNames.AGENT_STACK_RETRY_COUNT;
+import static org.apache.ambari.server.agent.ExecutionCommand.KeyNames.AGENT_STACK_RETRY_ON_UNAVAILABILITY;
 import static org.apache.ambari.server.agent.ExecutionCommand.KeyNames.DB_NAME;
 import static org.apache.ambari.server.agent.ExecutionCommand.KeyNames.GROUP_LIST;
 import static org.apache.ambari.server.agent.ExecutionCommand.KeyNames.JAVA_HOME;
@@ -310,6 +312,8 @@ public class ClientConfigResourceProvider extends AbstractControllerResourceProv
       hostLevelParams.put(HOST_SYS_PREPPED, configs.areHostsSysPrepped());
       hostLevelParams.putAll(managementController.getRcaParameters());
       hostLevelParams.putAll(managementController.getRcaParameters());
+      hostLevelParams.put(AGENT_STACK_RETRY_ON_UNAVAILABILITY, configs.isAgentStackRetryOnInstallEnabled());
+      hostLevelParams.put(AGENT_STACK_RETRY_COUNT, configs.getAgentStackRetryOnInstallCount());
 
       // Write down os specific info for the service
       ServiceOsSpecific anyOs = null;

http://git-wip-us.apache.org/repos/asf/ambari/blob/8b150c51/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProviderTest.java
----------------------------------------------------------------------
diff --git a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProviderTest.java
b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProviderTest.java
index 3d44224..76032bd 100644
--- a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProviderTest.java
+++ b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/ClientConfigResourceProviderTest.java
@@ -240,6 +240,8 @@ public class ClientConfigResourceProviderTest {
     expect(configuration.getResourceDirPath()).andReturn("/tmp/stacks/S1/V1");
     expect(configuration.getJavaVersion()).andReturn(8);
     expect(configuration.areHostsSysPrepped()).andReturn("false");
+    expect(configuration.isAgentStackRetryOnInstallEnabled()).andReturn("false");
+    expect(configuration.getAgentStackRetryOnInstallCount()).andReturn("5");
     expect(configuration.getExternalScriptTimeout()).andReturn(Integer.parseInt(Configuration.EXTERNAL_SCRIPT_TIMEOUT_DEFAULT));
     Map<String,String> props = new HashMap<String, String>();
     props.put(Configuration.HIVE_METASTORE_PASSWORD_PROPERTY, "pass");
@@ -442,6 +444,8 @@ public class ClientConfigResourceProviderTest {
     expect(configuration.getResourceDirPath()).andReturn("/var/lib/ambari-server/src/main/resources");
     expect(configuration.getJavaVersion()).andReturn(8);
     expect(configuration.areHostsSysPrepped()).andReturn("false");
+    expect(configuration.isAgentStackRetryOnInstallEnabled()).andReturn("false");
+    expect(configuration.getAgentStackRetryOnInstallCount()).andReturn("5");
     expect(configuration.getExternalScriptTimeout()).andReturn(Integer.parseInt(Configuration.EXTERNAL_SCRIPT_TIMEOUT_DEFAULT));
 
     Map<String,String> props = new HashMap<String, String>();


Mime
View raw message