ambari-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeff Sposetti <>
Subject Re: Ambari Views Client-Server Interaction Preference
Date Tue, 17 Feb 2015 13:47:22 GMT

Take a look at this example. In this case, it builds the path in the index.html page (doesn't
use dot-dots but uses absolute paths)

Best not to hardcode the instance name.


From: "John.Bork" <<>>
Reply-To: "<>" <<>>
Date: Monday, February 16, 2015 at 5:13 PM
To: "<>" <<>>
Subject: Ambari Views Client-Server Interaction Preference

Hi I was wondering if is it preferred for an index.html of an Ambari View to make dynamic
calls to an Ambari View Instance via a hard coded relative path, or to generate the relative
path for the index? For example, an Ambari View I am working on loads a index.html for the
view and the user can instantiate AJAX calls to the Ambari View API from the index.html. Currently
the AJAX call uses a relative path that consists of "../<more dot dot slashes>/api/v1/rest/of/path"
embedded in the index.html. Would it be better to build this path from the Java class method
in the Ambari View Server instead of having it embedded in the index.html?

John Bork

View raw message