You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@slider.apache.org by el...@apache.org on 2015/01/29 18:23:45 UTC

[22/28] incubator-slider git commit: SLIDER-765 TestStandaloneYarnRegistryAM failing

SLIDER-765 TestStandaloneYarnRegistryAM failing


Project: http://git-wip-us.apache.org/repos/asf/incubator-slider/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-slider/commit/192fb49f
Tree: http://git-wip-us.apache.org/repos/asf/incubator-slider/tree/192fb49f
Diff: http://git-wip-us.apache.org/repos/asf/incubator-slider/diff/192fb49f

Branch: refs/heads/develop
Commit: 192fb49f878422d48a81534617681034dd65221e
Parents: 6bd7165
Author: Steve Loughran <st...@apache.org>
Authored: Sun Jan 25 17:18:53 2015 +0000
Committer: Steve Loughran <st...@apache.org>
Committed: Sun Jan 25 17:18:53 2015 +0000

----------------------------------------------------------------------
 .../registry/retrieve/RegistryRetriever.java    | 21 +++++++++++++-------
 .../TestStandaloneYarnRegistryAM.groovy         |  1 +
 2 files changed, 15 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-slider/blob/192fb49f/slider-core/src/main/java/org/apache/slider/core/registry/retrieve/RegistryRetriever.java
----------------------------------------------------------------------
diff --git a/slider-core/src/main/java/org/apache/slider/core/registry/retrieve/RegistryRetriever.java b/slider-core/src/main/java/org/apache/slider/core/registry/retrieve/RegistryRetriever.java
index 3ed7cc6..364c661 100644
--- a/slider-core/src/main/java/org/apache/slider/core/registry/retrieve/RegistryRetriever.java
+++ b/slider-core/src/main/java/org/apache/slider/core/registry/retrieve/RegistryRetriever.java
@@ -67,9 +67,9 @@ public class RegistryRetriever extends AMWebClient {
    * not match that expected (i.e. not a list of URLs), missing endpoint...
    */
   public RegistryRetriever(ServiceRecord record) throws RegistryIOException {
-    internalConfigurationURL = lookupRestAPI(record,
-        PUBLISHER_CONFIGURATIONS_API, true);
     externalConfigurationURL = lookupRestAPI(record,
+        PUBLISHER_CONFIGURATIONS_API, true);
+    internalConfigurationURL = lookupRestAPI(record,
         PUBLISHER_CONFIGURATIONS_API, false);
     externalExportsURL = lookupRestAPI(record,
         PUBLISHER_EXPORTS_API, true);
@@ -196,10 +196,17 @@ public class RegistryRetriever extends AMWebClient {
 
   @Override
   public String toString() {
-    return super.toString() 
-           + ":  internal URL: \"" + internalConfigurationURL
-           + "\";  external \"" + externalConfigurationURL +"\"";
+    final StringBuilder sb =
+        new StringBuilder("RegistryRetriever{");
+    sb.append("externalConfigurationURL='")
+      .append(externalConfigurationURL)
+      .append('\'');
+    sb.append(", internalConfigurationURL='")
+      .append(internalConfigurationURL)
+      .append('\'');
+    sb.append(", externalExportsURL='").append(externalExportsURL).append('\'');
+    sb.append(", internalExportsURL='").append(internalExportsURL).append('\'');
+    sb.append('}');
+    return sb.toString();
   }
-  
-  
 }

http://git-wip-us.apache.org/repos/asf/incubator-slider/blob/192fb49f/slider-core/src/test/groovy/org/apache/slider/agent/standalone/TestStandaloneYarnRegistryAM.groovy
----------------------------------------------------------------------
diff --git a/slider-core/src/test/groovy/org/apache/slider/agent/standalone/TestStandaloneYarnRegistryAM.groovy b/slider-core/src/test/groovy/org/apache/slider/agent/standalone/TestStandaloneYarnRegistryAM.groovy
index 705430f..62a8c40 100644
--- a/slider-core/src/test/groovy/org/apache/slider/agent/standalone/TestStandaloneYarnRegistryAM.groovy
+++ b/slider-core/src/test/groovy/org/apache/slider/agent/standalone/TestStandaloneYarnRegistryAM.groovy
@@ -158,6 +158,7 @@ class TestStandaloneYarnRegistryAM extends AgentMiniClusterTestBase {
     assert serviceRecords.size() == 1
 
     def serviceRecord = serviceRecords[0]
+    describe "service record"
     log.info(serviceRecord.toString())
 
     assert serviceRecord[YarnRegistryAttributes.YARN_ID] != null