Hi, 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)
https://github.com/apache/ambari/blob/trunk/ambari-views/examples/simple-view/src/main/resources/ui/index.html Best not to hardcode the instance name. Jeff From: "John.Bork" <[email protected]<mailto:[email protected]>> Reply-To: "[email protected]<mailto:[email protected]>" <[email protected]<mailto:[email protected]>> Date: Monday, February 16, 2015 at 5:13 PM To: "[email protected]<mailto:[email protected]>" <[email protected]<mailto:[email protected]>> 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
