You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@drill.apache.org by pr...@apache.org on 2017/09/25 17:22:15 UTC

[1/4] drill git commit: DRILL-5745: Corrected 'location' information in Drill web server

Repository: drill
Updated Branches:
  refs/heads/master 9620e3482 -> 44d5cc8eb


DRILL-5745: Corrected 'location' information in Drill web server

closes #948


Project: http://git-wip-us.apache.org/repos/asf/drill/repo
Commit: http://git-wip-us.apache.org/repos/asf/drill/commit/61c48a9c
Tree: http://git-wip-us.apache.org/repos/asf/drill/tree/61c48a9c
Diff: http://git-wip-us.apache.org/repos/asf/drill/diff/61c48a9c

Branch: refs/heads/master
Commit: 61c48a9cf935c43de4cfca28fe11fbe6fdb1a36f
Parents: 9620e34
Author: Prasad Subramanya <pr...@psubram-1010.local>
Authored: Tue Sep 19 18:32:49 2017 -0700
Committer: Paul Rogers <pr...@maprtech.com>
Committed: Mon Sep 25 09:35:34 2017 -0700

----------------------------------------------------------------------
 .../server/rest/profile/ProfileResources.java   | 42 ++++++++++++++++----
 1 file changed, 34 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/drill/blob/61c48a9c/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/ProfileResources.java
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/ProfileResources.java b/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/ProfileResources.java
index 468ec56..af47ee1 100644
--- a/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/ProfileResources.java
+++ b/exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/profile/ProfileResources.java
@@ -37,6 +37,7 @@ import javax.ws.rs.core.SecurityContext;
 import javax.ws.rs.core.UriInfo;
 import javax.xml.bind.annotation.XmlRootElement;
 
+import org.apache.drill.common.config.DrillConfig;
 import org.apache.drill.common.exceptions.DrillRuntimeException;
 import org.apache.drill.common.exceptions.UserException;
 import org.apache.drill.exec.ExecConstants;
@@ -55,7 +56,6 @@ import org.apache.drill.exec.store.sys.PersistentStore;
 import org.apache.drill.exec.store.sys.PersistentStoreProvider;
 import org.apache.drill.exec.work.WorkManager;
 import org.apache.drill.exec.work.foreman.Foreman;
-import org.apache.drill.exec.work.foreman.QueryManager;
 import org.glassfish.jersey.server.mvc.Viewable;
 
 import com.google.common.collect.Lists;
@@ -77,19 +77,19 @@ public class ProfileResources {
     private long startTime;
     private long endTime;
     private Date time;
-    private String location;
+    private String link;
     private String foreman;
     private String query;
     private String state;
     private String user;
 
-    public ProfileInfo(String queryId, long startTime, long endTime, String foreman, String query, String state, String user) {
+    public ProfileInfo(DrillConfig drillConfig, String queryId, long startTime, long endTime, String foreman, String query, String state, String user) {
       this.queryId = queryId;
       this.startTime = startTime;
       this.endTime = endTime;
       this.time = new Date(startTime);
       this.foreman = foreman;
-      this.location = "http://localhost:8047/profile/" + queryId + ".json";
+      this.link = generateLink(drillConfig, foreman, queryId);
       this.query = query.substring(0,  Math.min(query.length(), 150));
       this.state = state;
       this.user = user;
@@ -127,8 +127,8 @@ public class ProfileResources {
       return state;
     }
 
-    public String getLocation() {
-      return location;
+    public String getLink() {
+      return link;
     }
 
     @Override
@@ -140,6 +140,30 @@ public class ProfileResources {
       return foreman;
     }
 
+    /**
+     * Generates link which will return query profile in json representation.
+     *
+     * @param drillConfig drill configuration
+     * @param foreman foreman hostname
+     * @param queryId query id
+     * @return link
+     */
+    private String generateLink(DrillConfig drillConfig, String foreman, String queryId) {
+      StringBuilder sb = new StringBuilder();
+      if (drillConfig.getBoolean(ExecConstants.HTTP_ENABLE_SSL)) {
+        sb.append("https://");
+      } else {
+        sb.append("http://");
+      }
+      sb.append(foreman);
+      sb.append(":");
+      sb.append(drillConfig.getInt(ExecConstants.HTTP_PORT));
+      sb.append("/profiles/");
+      sb.append(queryId);
+      sb.append(".json");
+      return sb.toString();
+    }
+
   }
 
   protected PersistentStoreProvider getProvider() {
@@ -195,7 +219,8 @@ public class ProfileResources {
           final Map.Entry<String, QueryInfo> runningEntry = runningEntries.next();
           final QueryInfo profile = runningEntry.getValue();
           if (principal.canManageProfileOf(profile.getUser())) {
-            runningQueries.add(new ProfileInfo(runningEntry.getKey(), profile.getStart(), System.currentTimeMillis(), profile.getForeman().getAddress(), profile.getQuery(), profile.getState().name(), profile.getUser()));
+            runningQueries.add(new ProfileInfo(work.getContext().getConfig(), runningEntry.getKey(), profile.getStart(), System.currentTimeMillis(), profile.getForeman()
+              .getAddress(), profile.getQuery(), profile.getState().name(), profile.getUser()));
           }
         } catch (Exception e) {
           errors.add(e.getMessage());
@@ -221,7 +246,8 @@ public class ProfileResources {
           final Map.Entry<String, QueryProfile> profileEntry = range.next();
           final QueryProfile profile = profileEntry.getValue();
           if (principal.canManageProfileOf(profile.getUser())) {
-            finishedQueries.add(new ProfileInfo(profileEntry.getKey(), profile.getStart(), profile.getEnd(), profile.getForeman().getAddress(), profile.getQuery(), profile.getState().name(), profile.getUser()));
+            finishedQueries.add(new ProfileInfo(work.getContext().getConfig(), profileEntry.getKey(), profile.getStart(), profile.getEnd(), profile.getForeman().getAddress(),
+              profile.getQuery(), profile.getState().name(), profile.getUser()));
           }
         } catch (Exception e) {
           errors.add(e.getMessage());


[2/4] drill git commit: DRILL-5727: Update release profile to generate SHA-512 checksum.

Posted by pr...@apache.org.
DRILL-5727: Update release profile to generate SHA-512 checksum.

Also, remove sha1 checksum from release package

closes #951


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

Branch: refs/heads/master
Commit: dde6fb72eca3c89265d41814e8dfea64b26bfb4b
Parents: 61c48a9
Author: Parth Chandra <pa...@apache.org>
Authored: Wed Sep 20 13:42:54 2017 -0700
Committer: Paul Rogers <pr...@maprtech.com>
Committed: Mon Sep 25 09:37:08 2017 -0700

----------------------------------------------------------------------
 pom.xml | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/drill/blob/dde6fb72/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index f22fafa..4f8ec67 100644
--- a/pom.xml
+++ b/pom.xml
@@ -976,7 +976,7 @@
             <configuration>
               <algorithms>
                 <algorithm>MD5</algorithm>
-                <algorithm>SHA-1</algorithm>
+                <algorithm>SHA-512</algorithm>
               </algorithms>
               <failOnError>false</failOnError>
             </configuration>


[4/4] drill git commit: DRILL-5812: Restore the minor fragment Gantt chart canvas

Posted by pr...@apache.org.
DRILL-5812: Restore the minor fragment Gantt chart canvas

Minor update to restore the fragment Gantt chart
https://issues.apache.org/jira/browse/DRILL-5766?focusedCommentId=16176955&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-16176955

closes #956


Project: http://git-wip-us.apache.org/repos/asf/drill/repo
Commit: http://git-wip-us.apache.org/repos/asf/drill/commit/44d5cc8e
Tree: http://git-wip-us.apache.org/repos/asf/drill/tree/44d5cc8e
Diff: http://git-wip-us.apache.org/repos/asf/drill/diff/44d5cc8e

Branch: refs/heads/master
Commit: 44d5cc8eb1cd197d942a8ac52e9d42e282d30c88
Parents: 3d8f699
Author: Kunal Khatua <kk...@maprtech.com>
Authored: Fri Sep 22 12:55:29 2017 -0700
Committer: Paul Rogers <pr...@maprtech.com>
Committed: Mon Sep 25 09:39:35 2017 -0700

----------------------------------------------------------------------
 exec/java-exec/src/main/resources/rest/profile/profile.ftl | 1 +
 1 file changed, 1 insertion(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/drill/blob/44d5cc8e/exec/java-exec/src/main/resources/rest/profile/profile.ftl
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/main/resources/rest/profile/profile.ftl b/exec/java-exec/src/main/resources/rest/profile/profile.ftl
index 5bb7be8..9318afc 100644
--- a/exec/java-exec/src/main/resources/rest/profile/profile.ftl
+++ b/exec/java-exec/src/main/resources/rest/profile/profile.ftl
@@ -226,6 +226,7 @@
       </div>
       <div id="fragment-overview" class="panel-collapse collapse">
         <div class="panel-body">
+          <svg id="fragment-overview-canvas" class="center-block"></svg>
           ${model.getFragmentsOverview()?no_esc}
         </div>
       </div>


[3/4] drill git commit: DRILL-5438: Amazon S3 bucket can't be queried directly at root

Posted by pr...@apache.org.
DRILL-5438: Amazon S3 bucket can't be queried directly at root

closes #952


Project: http://git-wip-us.apache.org/repos/asf/drill/repo
Commit: http://git-wip-us.apache.org/repos/asf/drill/commit/3d8f6993
Tree: http://git-wip-us.apache.org/repos/asf/drill/tree/3d8f6993
Diff: http://git-wip-us.apache.org/repos/asf/drill/diff/3d8f6993

Branch: refs/heads/master
Commit: 3d8f69935458da6eccd324e1add0900209fb2e8a
Parents: dde6fb7
Author: Korn, Uwe <Uw...@blue-yonder.com>
Authored: Thu Sep 21 14:52:58 2017 +0200
Committer: Paul Rogers <pr...@maprtech.com>
Committed: Mon Sep 25 09:38:34 2017 -0700

----------------------------------------------------------------------
 .../main/java/org/apache/drill/exec/store/dfs/FileSelection.java | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/drill/blob/3d8f6993/exec/java-exec/src/main/java/org/apache/drill/exec/store/dfs/FileSelection.java
----------------------------------------------------------------------
diff --git a/exec/java-exec/src/main/java/org/apache/drill/exec/store/dfs/FileSelection.java b/exec/java-exec/src/main/java/org/apache/drill/exec/store/dfs/FileSelection.java
index 7cabee0..81c7ad2 100644
--- a/exec/java-exec/src/main/java/org/apache/drill/exec/store/dfs/FileSelection.java
+++ b/exec/java-exec/src/main/java/org/apache/drill/exec/store/dfs/FileSelection.java
@@ -362,6 +362,10 @@ public class FileSelection {
       int idx = root.indexOf(WILD_CARD); // first wild card in the path
       idx = root.lastIndexOf('/', idx); // file separator right before the first wild card
       final String newRoot = root.substring(0, idx);
+      if (newRoot.length() == 0) {
+          // Ensure that we always return a valid root.
+          return new Path("/");
+      }
       return new Path(newRoot);
     } else {
       return new Path(root);