This is an automated email from the ASF dual-hosted git repository.

sorabh pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/drill.git


The following commit(s) were added to refs/heads/master by this push:
     new f971c1f  DRILL-7186: Add back storage.json REST endpoint (regression 
after DRILL-6562)
f971c1f is described below

commit f971c1f0b2ec5c744535791c2476981e406591e3
Author: Arina Ielchiieva <[email protected]>
AuthorDate: Fri Apr 19 15:00:43 2019 +0300

    DRILL-7186: Add back storage.json REST endpoint (regression after 
DRILL-6562)
---
 .../java/org/apache/drill/exec/server/rest/StorageResources.java | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git 
a/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/StorageResources.java
 
b/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/StorageResources.java
index 5dee285..7219a0d 100644
--- 
a/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/StorageResources.java
+++ 
b/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/StorageResources.java
@@ -93,10 +93,17 @@ public class StorageResources {
   }
 
   @GET
+  @Path("/storage.json")
+  @Produces(MediaType.APPLICATION_JSON)
+  public List<PluginConfigWrapper> getPluginsJSON() {
+    return getConfigsFor(ALL_PLUGINS);
+  }
+
+  @GET
   @Path("/storage")
   @Produces(MediaType.TEXT_HTML)
   public Viewable getPlugins() {
-    List<PluginConfigWrapper> list = getConfigsFor(ALL_PLUGINS);
+    List<PluginConfigWrapper> list = getPluginsJSON();
     return ViewableWithPermissions.create(authEnabled.get(), 
"/rest/storage/list.ftl", sc, list);
   }
 

Reply via email to