rubenada commented on code in PR #6523:
URL: https://github.com/apache/hive/pull/6523#discussion_r3553534131


##########
druid-handler/pom.xml:
##########
@@ -353,10 +353,15 @@
                       <pattern>io.netty</pattern>
                       
<shadedPattern>org.apache.hive.druid.io.netty</shadedPattern>
                     </relocation>
+                    <!-- Calcite is intentionally NOT included or relocated 
here. Druid 0.17.1 uses Calcite APIs
+                    that are compatible with Hive's Calcite 1.42+. Including 
calcite-core in the shade caused
+                    SqlFunctions.class to exceed the JVM 64KB method limit 
after relocation. If Druid is upgraded
+                    to a version with an incompatible Calcite, this relocation 
must be restored (excluding SqlFunctions,
+                    or splitting the class via a source-level patch to 
Calcite).

Review Comment:
   I think you should be able to reproduce it by undoing this changes in this 
file and the running `mvn install -DskipTests -pl druid-handler -am` and/or 
`mvn install javadoc:javadoc javadoc:aggregate -DskipTests` :
   ```
   ...
   [INFO] Hive Druid Handler ................................. FAILURE [  3.089 
s]
   [INFO] 
------------------------------------------------------------------------
   [INFO] BUILD FAILURE
   [INFO] 
------------------------------------------------------------------------
   [INFO] Total time:  45.700 s
   [INFO] Finished at: 2026-07-09T17:15:12+01:00
   [INFO] 
------------------------------------------------------------------------
   [INFO] 356 goals, 352 executed, 4 from cache
   [ERROR] Failed to execute goal 
org.apache.maven.plugins:maven-shade-plugin:3.6.0:shade (default) on project 
hive-druid-handler: Error creating shaded jar: Problem shading JAR 
/.../hive/druid-handler/target/hive-druid-handler-4.3.0-SNAPSHOT.jar entry 
org/apache/hive/druid/org/apache/calcite/runtime/SqlFunctions.class: 
org.apache.maven.plugin.MojoExecutionException: Error in ASM processing class 
org/apache/hive/druid/org/apache/calcite/runtime/SqlFunctions.class: Index 
65536 out of bounds for length 334 -> [Help 1]
   [ERROR] 
   ```
   
   However, I just realized that the explanation in this comment is not 
accurate. I'll update it.
   



-- 
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