Ian Maxon has uploaded a new change for review.

  https://asterix-gerrit.ics.uci.edu/3197

Change subject: [NO ISSUE] Parallel Build
......................................................................

[NO ISSUE] Parallel Build

Updating the JavaCC plugin to allow paralell builds with mvn -T

Change-Id: I8f9c8bdbd4d1c56f4258efc0c7698e18a81ab15b
---
M asterixdb/asterix-algebra/pom.xml
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ApiServlet.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/QueryServiceServlet.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/RestApiServlet.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ResultUtil.java
M 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/message/ExecuteStatementRequestMessage.java
M asterixdb/asterix-lang-aql/pom.xml
M asterixdb/asterix-lang-aql/src/main/javacc/AQL.jj
M asterixdb/asterix-lang-sqlpp/pom.xml
M asterixdb/asterix-lang-sqlpp/src/main/javacc/SQLPP.jj
M asterixdb/pom.xml
11 files changed, 40 insertions(+), 43 deletions(-)


  git pull ssh://asterix-gerrit.ics.uci.edu:29418/asterixdb 
refs/changes/97/3197/1

diff --git a/asterixdb/asterix-algebra/pom.xml 
b/asterixdb/asterix-algebra/pom.xml
index ee0bb5e..8496d0d 100644
--- a/asterixdb/asterix-algebra/pom.xml
+++ b/asterixdb/asterix-algebra/pom.xml
@@ -62,9 +62,9 @@
         </executions>
       </plugin>
       <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>javacc-maven-plugin</artifactId>
-        <version>2.6</version>
+        <groupId>com.helger.maven</groupId>
+        <artifactId>ph-javacc-maven-plugin</artifactId>
+        <version>4.1.2</version>
         <executions>
           <execution>
             <id>javacc</id>
@@ -108,8 +108,8 @@
               <pluginExecutions>
                 <pluginExecution>
                   <pluginExecutionFilter>
-                    <groupId>org.codehaus.mojo</groupId>
-                    <artifactId>javacc-maven-plugin</artifactId>
+                    <groupId>com.helger.maven</groupId>
+                    <artifactId>ph-javacc-maven-plugin</artifactId>
                     <versionRange>[0.0,)</versionRange>
                     <goals>
                       <goal>javacc</goal>
diff --git 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ApiServlet.java
 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ApiServlet.java
index ea6e616..f5b2fb8 100644
--- 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ApiServlet.java
+++ 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ApiServlet.java
@@ -39,10 +39,10 @@
 import org.apache.asterix.common.dataflow.ICcApplicationContext;
 import org.apache.asterix.common.exceptions.AsterixException;
 import org.apache.asterix.compiler.provider.ILangCompilationProvider;
-import org.apache.asterix.lang.aql.parser.TokenMgrError;
 import org.apache.asterix.lang.common.base.IParser;
 import org.apache.asterix.lang.common.base.IParserFactory;
 import org.apache.asterix.lang.common.base.Statement;
+import org.apache.asterix.lang.sqlpp.parser.TokenMgrException;
 import org.apache.asterix.metadata.MetadataManager;
 import org.apache.asterix.translator.IRequestParameters;
 import org.apache.asterix.translator.IStatementExecutor;
@@ -158,7 +158,7 @@
             duration = (endTime - startTime) / 1000.00;
             out.println(HTML_STATEMENT_SEPARATOR);
             out.println("<PRE>Duration of all jobs: " + duration + " 
sec</PRE>");
-        } catch (AsterixException | TokenMgrError | 
org.apache.asterix.aqlplus.parser.TokenMgrError pe) {
+        } catch (AsterixException | TokenMgrException pe) {
             GlobalConfig.ASTERIX_LOGGER.log(Level.INFO, pe.toString(), pe);
             ResultUtil.webUIParseExceptionHandler(out, pe, query);
         } catch (Exception e) {
diff --git 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/QueryServiceServlet.java
 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/QueryServiceServlet.java
index 31b784f..b6fdf36 100644
--- 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/QueryServiceServlet.java
+++ 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/QueryServiceServlet.java
@@ -52,12 +52,12 @@
 import org.apache.asterix.common.exceptions.ErrorCode;
 import org.apache.asterix.common.exceptions.RuntimeDataException;
 import org.apache.asterix.compiler.provider.ILangCompilationProvider;
-import org.apache.asterix.lang.aql.parser.TokenMgrError;
 import org.apache.asterix.lang.common.base.IParser;
 import org.apache.asterix.lang.common.base.IParserFactory;
 import org.apache.asterix.lang.common.base.Statement;
 import org.apache.asterix.lang.common.expression.VariableExpr;
 import org.apache.asterix.lang.common.statement.Query;
+import org.apache.asterix.lang.sqlpp.parser.TokenMgrException;
 import org.apache.asterix.metadata.MetadataManager;
 import org.apache.asterix.om.base.IAObject;
 import org.apache.asterix.translator.ExecutionPlans;
@@ -564,7 +564,7 @@
                 printWarnings(sessionOutput.out(), warnings);
             }
             errorCount = 0;
-        } catch (Exception | TokenMgrError | 
org.apache.asterix.aqlplus.parser.TokenMgrError e) {
+        } catch (Exception e) {
             handleExecuteStatementException(e, execution, param);
             response.setStatus(execution.getHttpStatus());
             printError(sessionOutput.out(), e);
@@ -629,8 +629,7 @@
 
     protected void handleExecuteStatementException(Throwable t, 
RequestExecutionState state,
             QueryServiceRequestParameters param) {
-        if (t instanceof org.apache.asterix.aqlplus.parser.TokenMgrError || t 
instanceof TokenMgrError
-                || t instanceof AlgebricksException) {
+        if (t instanceof TokenMgrException || t instanceof 
AlgebricksException) {
             if (LOGGER.isDebugEnabled()) {
                 LOGGER.debug("handleException: {}: {}", t.getMessage(), 
LogRedactionUtil.userData(param.toString()), t);
             } else {
diff --git 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/RestApiServlet.java
 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/RestApiServlet.java
index 65fb357..07bd684 100644
--- 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/RestApiServlet.java
+++ 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/RestApiServlet.java
@@ -32,10 +32,10 @@
 import org.apache.asterix.common.dataflow.ICcApplicationContext;
 import org.apache.asterix.common.exceptions.AsterixException;
 import org.apache.asterix.compiler.provider.ILangCompilationProvider;
-import org.apache.asterix.lang.aql.parser.TokenMgrError;
 import org.apache.asterix.lang.common.base.IParser;
 import org.apache.asterix.lang.common.base.IParserFactory;
 import org.apache.asterix.lang.common.base.Statement;
+import org.apache.asterix.lang.sqlpp.parser.TokenMgrException;
 import org.apache.asterix.metadata.MetadataManager;
 import org.apache.asterix.translator.IRequestParameters;
 import org.apache.asterix.translator.IStatementExecutor;
@@ -200,7 +200,7 @@
             final IRequestParameters requestParameters = new 
RequestParameters(requestReference, query, resultSet,
                     new ResultProperties(resultDelivery), new 
IStatementExecutor.Stats(), null, null, null, null, true);
             translator.compileAndExecute(hcc, requestParameters);
-        } catch (AsterixException | TokenMgrError | 
org.apache.asterix.aqlplus.parser.TokenMgrError pe) {
+        } catch (AsterixException | TokenMgrException pe) {
             response.setStatus(HttpResponseStatus.INTERNAL_SERVER_ERROR);
             GlobalConfig.ASTERIX_LOGGER.log(Level.ERROR, pe.getMessage(), pe);
             String errorMessage = ResultUtil.buildParseExceptionMessage(pe, 
query);
diff --git 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ResultUtil.java
 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ResultUtil.java
index fa3c03d..eb85b33 100644
--- 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ResultUtil.java
+++ 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/api/http/server/ResultUtil.java
@@ -36,9 +36,9 @@
 import org.apache.asterix.app.result.ResultPrinter;
 import org.apache.asterix.app.result.ResultReader;
 import org.apache.asterix.common.api.IApplicationContext;
-import org.apache.asterix.lang.aql.parser.TokenMgrError;
 import org.apache.asterix.lang.common.expression.VariableExpr;
 import org.apache.asterix.lang.sqlpp.util.SqlppVariableUtil;
+import org.apache.asterix.lang.aql.parser.TokenMgrException;
 import org.apache.asterix.om.types.ARecordType;
 import org.apache.asterix.translator.IStatementExecutor.Stats;
 import org.apache.asterix.translator.SessionOutput;
@@ -125,8 +125,7 @@
         Throwable rootCause = getRootCause(e);
         String msg = rootCause.getMessage();
         if (!(rootCause instanceof AlgebricksException || rootCause instanceof 
HyracksException
-                || rootCause instanceof TokenMgrError
-                || rootCause instanceof 
org.apache.asterix.aqlplus.parser.TokenMgrError)) {
+                || rootCause instanceof TokenMgrException)) {
             msg = rootCause.getClass().getSimpleName() + (msg == null ? "" : 
": " + msg);
         }
         printError(pw, msg, code, comma);
diff --git 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/app/message/ExecuteStatementRequestMessage.java
 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/app/message/ExecuteStatementRequestMessage.java
index a89728c..aa46800 100644
--- 
a/asterixdb/asterix-app/src/main/java/org/apache/asterix/app/message/ExecuteStatementRequestMessage.java
+++ 
b/asterixdb/asterix-app/src/main/java/org/apache/asterix/app/message/ExecuteStatementRequestMessage.java
@@ -40,9 +40,9 @@
 import org.apache.asterix.common.messaging.api.ICcAddressedMessage;
 import org.apache.asterix.compiler.provider.ILangCompilationProvider;
 import org.apache.asterix.hyracks.bootstrap.CCApplication;
-import org.apache.asterix.lang.aql.parser.TokenMgrError;
 import org.apache.asterix.lang.common.base.IParser;
 import org.apache.asterix.lang.common.base.Statement;
+import org.apache.asterix.lang.sqlpp.parser.TokenMgrException;
 import org.apache.asterix.messaging.CCMessageBroker;
 import org.apache.asterix.metadata.MetadataManager;
 import org.apache.asterix.om.base.IAObject;
@@ -142,8 +142,7 @@
             responseMsg.setMetadata(outMetadata);
             responseMsg.setStats(stats);
             responseMsg.setExecutionPlans(translator.getExecutionPlans());
-        } catch (AlgebricksException | HyracksException | TokenMgrError
-                | org.apache.asterix.aqlplus.parser.TokenMgrError pe) {
+        } catch (AlgebricksException | HyracksException | TokenMgrException 
pe) {
             // we trust that "our" exceptions are serializable and have a 
comprehensible error message
             GlobalConfig.ASTERIX_LOGGER.log(Level.WARN, pe.getMessage(), pe);
             responseMsg.setError(pe);
diff --git a/asterixdb/asterix-lang-aql/pom.xml 
b/asterixdb/asterix-lang-aql/pom.xml
index f202192..86a784b 100644
--- a/asterixdb/asterix-lang-aql/pom.xml
+++ b/asterixdb/asterix-lang-aql/pom.xml
@@ -40,9 +40,9 @@
   <build>
     <plugins>
       <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>javacc-maven-plugin</artifactId>
-        <version>2.6</version>
+        <groupId>com.helger.maven</groupId>
+        <artifactId>ph-javacc-maven-plugin</artifactId>
+        <version>4.1.2</version>
         <executions>
           <execution>
             <id>javacc</id>
@@ -89,13 +89,13 @@
                 <pluginExecution>
                   <pluginExecutionFilter>
                     <groupId>
-                      org.codehaus.mojo
+                      com.helger.maven
                     </groupId>
                     <artifactId>
-                      javacc-maven-plugin
+                      ph-javacc-maven-plugin
                     </artifactId>
                     <versionRange>
-                      [2.6,)
+                      [4.1.2,)
                     </versionRange>
                     <goals>
                       <goal>jjdoc</goal>
@@ -126,8 +126,8 @@
       <build>
         <plugins>
           <plugin>
-            <groupId>org.codehaus.mojo</groupId>
-            <artifactId>javacc-maven-plugin</artifactId>
+            <groupId>com.helger.maven</groupId>
+            <artifactId>ph-javacc-maven-plugin</artifactId>
             <executions>
               <execution>
                 <id>javacc-jjdoc</id>
diff --git a/asterixdb/asterix-lang-aql/src/main/javacc/AQL.jj 
b/asterixdb/asterix-lang-aql/src/main/javacc/AQL.jj
index 35c2ae8..03a4b94 100644
--- a/asterixdb/asterix-lang-aql/src/main/javacc/AQL.jj
+++ b/asterixdb/asterix-lang-aql/src/main/javacc/AQL.jj
@@ -277,7 +277,7 @@
         super.setInput(s);
     }
 
-    public static void main(String args[]) throws ParseException, 
TokenMgrError, IOException, FileNotFoundException, CompilationException {
+    public static void main(String args[]) throws ParseException, 
TokenMgrException, IOException, FileNotFoundException, CompilationException {
         File file = new File(args[0]);
         Reader fis = new BufferedReader(new InputStreamReader(new 
FileInputStream(file), "UTF-8"));
         AQLParser parser = new AQLParser(fis);
@@ -2634,7 +2634,7 @@
          int errorColumn = input_stream.getEndColumn();
          String msg = "Lexical error at line " + errorLine + ", column " + 
errorColumn + ". Encountered \"" + token
              + "\" but state stack is empty.";
-         throw new TokenMgrError(msg, -1);
+         throw new TokenMgrException(msg, -1);
       }
     }
 }
diff --git a/asterixdb/asterix-lang-sqlpp/pom.xml 
b/asterixdb/asterix-lang-sqlpp/pom.xml
index f13c219..112d810 100644
--- a/asterixdb/asterix-lang-sqlpp/pom.xml
+++ b/asterixdb/asterix-lang-sqlpp/pom.xml
@@ -38,9 +38,9 @@
   <build>
     <plugins>
       <plugin>
-        <groupId>org.codehaus.mojo</groupId>
-        <artifactId>javacc-maven-plugin</artifactId>
-        <version>2.6</version>
+        <groupId>com.helger.maven</groupId>
+        <artifactId>ph-javacc-maven-plugin</artifactId>
+        <version>4.1.2</version>
         <executions>
           <execution>
             <id>javacc</id>
@@ -86,8 +86,8 @@
               <pluginExecutions>
                 <pluginExecution>
                   <pluginExecutionFilter>
-                    <groupId>org.codehaus.mojo</groupId>
-                    <artifactId>javacc-maven-plugin</artifactId>
+                    <groupId>com.helger.maven</groupId>
+                    <artifactId>ph-javacc-maven-plugin</artifactId>
                     <versionRange>[0.0,)</versionRange>
                     <goals>
                       <goal>jjdoc</goal>
@@ -118,8 +118,8 @@
       <build>
         <plugins>
           <plugin>
-            <groupId>org.codehaus.mojo</groupId>
-            <artifactId>javacc-maven-plugin</artifactId>
+            <groupId>com.helger.maven</groupId>
+            <artifactId>ph-javacc-maven-plugin</artifactId>
             <executions>
               <execution>
                 <id>javacc-jjdoc</id>
diff --git a/asterixdb/asterix-lang-sqlpp/src/main/javacc/SQLPP.jj 
b/asterixdb/asterix-lang-sqlpp/src/main/javacc/SQLPP.jj
index 19a4da2..4e13260 100644
--- a/asterixdb/asterix-lang-sqlpp/src/main/javacc/SQLPP.jj
+++ b/asterixdb/asterix-lang-sqlpp/src/main/javacc/SQLPP.jj
@@ -317,7 +317,7 @@
         super.setInput(s);
     }
 
-    public static void main(String args[]) throws ParseException, 
TokenMgrError, IOException, FileNotFoundException, CompilationException {
+    public static void main(String args[]) throws ParseException, 
TokenMgrException, IOException, FileNotFoundException, CompilationException {
         File file = new File(args[0]);
         Reader fis = new BufferedReader(new InputStreamReader(new 
FileInputStream(file), "UTF-8"));
         SQLPPParser parser = new SQLPPParser(fis);
@@ -3572,7 +3572,7 @@
          int errorColumn = input_stream.getEndColumn();
          String msg = "Lexical error at line " + errorLine + ", column " + 
errorColumn + ". Encountered \"" + token
              + "\" but state stack is empty.";
-         throw new TokenMgrError(msg, -1);
+         throw new TokenMgrException(msg, -1);
       }
     }
 }
diff --git a/asterixdb/pom.xml b/asterixdb/pom.xml
index 12a6928..cbf3a10 100644
--- a/asterixdb/pom.xml
+++ b/asterixdb/pom.xml
@@ -412,8 +412,8 @@
                 </pluginExecution>
                 <pluginExecution>
                   <pluginExecutionFilter>
-                    <groupId>org.codehaus.mojo</groupId>
-                    <artifactId>javacc-maven-plugin</artifactId>
+                    <groupId>com.helger.maven</groupId>
+                    <artifactId>ph-javacc-maven-plugin</artifactId>
                     <versionRange>[0.0,)</versionRange>
                     <goals>
                       <goal>jjdoc</goal>
@@ -552,9 +552,9 @@
           <version>2.2.3</version>
         </plugin>
         <plugin>
-          <groupId>org.codehaus.mojo</groupId>
-          <artifactId>javacc-maven-plugin</artifactId>
-          <version>2.6</version>
+          <groupId>com.helger.maven</groupId>
+          <artifactId>ph-javacc-maven-plugin</artifactId>
+          <version>4.1.2</version>
         </plugin>
         <plugin>
           <groupId>net.revelc.code.formatter</groupId>

-- 
To view, visit https://asterix-gerrit.ics.uci.edu/3197
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I8f9c8bdbd4d1c56f4258efc0c7698e18a81ab15b
Gerrit-PatchSet: 1
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Ian Maxon <[email protected]>

Reply via email to