ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nc...@apache.org
Subject [33/50] ambari git commit: Revert "AMBARI-14058. "Application Tracking URL" in Tez View broken due to RM HA changes in Ambari views framework. (Dipayan Bhowmick)"
Date Tue, 01 Dec 2015 18:20:23 GMT
Revert "AMBARI-14058. "Application Tracking URL" in Tez View broken due to RM HA changes in
Ambari views framework. (Dipayan Bhowmick)"

This reverts commit 89c6f26286540651ee46bcb50f618014863c5e79.


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

Branch: refs/heads/branch-dev-patch-upgrade
Commit: 1f1c661a100f4136d24c9526a18c3d920a5bff8f
Parents: 006f0fe
Author: Yusaku Sako <yusaku@hortonworks.com>
Authored: Mon Nov 30 16:11:55 2015 -0800
Committer: Yusaku Sako <yusaku@hortonworks.com>
Committed: Mon Nov 30 16:11:55 2015 -0800

----------------------------------------------------------------------
 .../ambari/view/tez/rest/BaseProxyResource.java | 21 +-------------------
 .../resources/ui/scripts/init-ambari-view.js    |  3 ---
 2 files changed, 1 insertion(+), 23 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/1f1c661a/contrib/views/tez/src/main/java/org/apache/ambari/view/tez/rest/BaseProxyResource.java
----------------------------------------------------------------------
diff --git a/contrib/views/tez/src/main/java/org/apache/ambari/view/tez/rest/BaseProxyResource.java
b/contrib/views/tez/src/main/java/org/apache/ambari/view/tez/rest/BaseProxyResource.java
index 5f8fb91..3670a40 100644
--- a/contrib/views/tez/src/main/java/org/apache/ambari/view/tez/rest/BaseProxyResource.java
+++ b/contrib/views/tez/src/main/java/org/apache/ambari/view/tez/rest/BaseProxyResource.java
@@ -19,7 +19,6 @@
 package org.apache.ambari.view.tez.rest;
 
 import com.google.inject.Inject;
-import org.apache.ambari.view.tez.exceptions.ProxyException;
 import org.apache.ambari.view.tez.utils.ProxyHelper;
 import org.json.simple.JSONObject;
 import org.json.simple.JSONValue;
@@ -28,13 +27,7 @@ import javax.ws.rs.GET;
 import javax.ws.rs.Path;
 import javax.ws.rs.PathParam;
 import javax.ws.rs.Produces;
-import javax.ws.rs.core.Context;
-import javax.ws.rs.core.MediaType;
-import javax.ws.rs.core.MultivaluedMap;
-import javax.ws.rs.core.Response;
-import javax.ws.rs.core.UriInfo;
-import java.net.URI;
-import java.net.URISyntaxException;
+import javax.ws.rs.core.*;
 import java.util.HashMap;
 
 /**
@@ -57,18 +50,6 @@ public abstract class BaseProxyResource {
     String response = proxyHelper.getResponse(url, new HashMap<String, String>());
 
     JSONObject jsonObject = (JSONObject) JSONValue.parse(response);
-
-    // If the endpoint returns some other format apart from JSON,
-    // we will only redirect the request. This is required because UI may call
-    // the proxy endpoint to directly point to any URL of RM/ATS.
-    if (jsonObject == null) {
-      try {
-        return Response.temporaryRedirect(new URI(url)).build();
-      } catch (URISyntaxException e) {
-        throw new ProxyException("Failed to set the redirection url to : " + url + ".Internal
Error.",
-          Response.Status.INTERNAL_SERVER_ERROR.getStatusCode(), e.getMessage());
-      }
-    }
     return Response.ok(jsonObject).type(MediaType.APPLICATION_JSON).build();
   }
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/1f1c661a/contrib/views/tez/src/main/resources/ui/scripts/init-ambari-view.js
----------------------------------------------------------------------
diff --git a/contrib/views/tez/src/main/resources/ui/scripts/init-ambari-view.js b/contrib/views/tez/src/main/resources/ui/scripts/init-ambari-view.js
index c443726..5152fb9 100644
--- a/contrib/views/tez/src/main/resources/ui/scripts/init-ambari-view.js
+++ b/contrib/views/tez/src/main/resources/ui/scripts/init-ambari-view.js
@@ -164,9 +164,6 @@ function setConfigs() {
       aminfo: '%@rmproxy/proxy/__app_id__/ws/v1/tez'.fmt(resourcesPrefix),
       aminfoV2: '%@rmproxy/proxy/__app_id__/ws/v2/tez'.fmt(resourcesPrefix),
       cluster: '%@rmproxy/ws/v1/cluster'.fmt(resourcesPrefix)
-    },
-    otherNamespace: {
-      cluster: '%@rmproxy/cluster'.fmt(resourcesPrefix)
     }
   });
 


Mime
View raw message