kkhatua commented on a change in pull request #1608: DRILL-6960: AutoLimit the 
size of ResultSet for a WebUI (or REST) client
URL: https://github.com/apache/drill/pull/1608#discussion_r259683078
 
 

 ##########
 File path: 
exec/java-exec/src/main/java/org/apache/drill/exec/server/rest/QueryResources.java
 ##########
 @@ -83,10 +83,14 @@ public QueryResult submitQueryJSON(QueryWrapper query) 
throws Exception {
   @Consumes(MediaType.APPLICATION_FORM_URLENCODED)
   @Produces(MediaType.TEXT_HTML)
   public Viewable submitQuery(@FormParam("query") String query,
-                              @FormParam("queryType") String queryType) throws 
Exception {
+                              @FormParam("queryType") String queryType,
+                              @FormParam("autoLimit") String autoLimit
+                              ) throws Exception {
     try {
       final String trimmedQueryString = 
CharMatcher.is(';').trimTrailingFrom(query.trim());
-      final QueryResult result = submitQueryJSON(new 
QueryWrapper(trimmedQueryString, queryType));
+      //Extract option of AutoLimit
+      String autoLimitValue = (autoLimit != null && 
autoLimit.matches("[0-9]+")) ? autoLimit : "";
 
 Review comment:
   Done in the latest set of commits

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to