Aggarwal-Raghav commented on code in PR #6985:
URL: https://github.com/apache/hive/pull/6985#discussion_r4767065588


##########
standalone-metastore/pom.xml:
##########
@@ -68,7 +68,7 @@
     <maven.versions.plugin.version>2.16.0</maven.versions.plugin.version>
     <maven.surefire.plugin.version>3.5.3</maven.surefire.plugin.version>
     <!-- Dependency versions -->
-    <antlr.version>4.9.3</antlr.version>
+    <antlr.version>4.13.1</antlr.version>

Review Comment:
   we can't remove `antlr4-runtime` completely from `metastore-server/pom.xml` 
because `PartFilterParser, PartFilterVisitor` and generated code compile 
against the `org.antlr.v4.runtime.*` during compile phase and shading relocates 
them in package phase.
   
   ```
   [ERROR] Failed to execute goal 
org.apache.maven.plugins:maven-compiler-plugin:3.14.0:compile (default-compile) 
on project hive-standalone-metastore-server: Compilation failure: Compilation 
failure:
   [ERROR] 
/Users/raghav/Desktop/apache/hive/master/standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/parser/PartFilterParser.java:[22,33]
 package org.antlr.v4.runtime.misc does not exist
   [ERROR] 
/Users/raghav/Desktop/apache/hive/master/standalone-metastore/metastore-server/src/main/java/org/apache/hadoop/hive/metastore/parser/PartFilterParser.java:[23,33]
 package org.antlr.v4.runtime.misc does not exist
   ```
   
   Better to make it `<optional>true</optional>`, since generating 
`dependency-reduced-pom.xml` under `target/` shifts `${basedir}` and breaks 
`apache-rat:check` 
https://ci.hive.apache.org/job/hive-precommit/job/PR-6985/4/stages/
   
   **NOTE:** 
   1. Full Hive packaging (`apache-hive-*-bin/lib/`): still ships both ANTLR 3 
(antlr-runtime-3.5.2.jar) and ANTLR 4 (antlr4-runtime-4.13.1.jar) because 
hive-hplsql requires it and can't be easily shaded. 
   2. standalone-metastore packaging (`apache-hive-metastore-*-bin/lib/`): will 
only ships ANTLR 3 (antlr-runtime-3.5.2.jar) with optional = true



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to