Skip to content

The easy-to-use open source Business Intelligence and Embedded Analytics tool that lets everyone work with data :bar_chart:

Add Add-Opens to the jar manifest (#85226)

Ethan McCue306d9787a5fe
diff --git a/bin/build/src/build/uberjar.clj b/bin/build/src/build/uberjar.clj
index 0a6a4725c0e..1dd9f5ed3de 100644
--- a/bin/build/src/build/uberjar.clj
+++ b/bin/build/src/build/uberjar.clj
@@ -220,7 +220,15 @@
"Multi-Release" "true"
"Created-By" "Metabase build.clj"
"Build-Jdk-Spec" (System/getProperty "java.specification.version")
- "Main-Class" "metabase.core.bootstrap"})
+ "Main-Class" "metabase.core.bootstrap"
+ ;; Needed for Apache Arrow, which is used by the Snowflake driver.
+ ;; When we update that driver, check if this is still needed.
+ ;; (https://github.com/apache/arrow-java/pull/1334)
+ ;;
+ ;; This is equivalent to --add-opens java.base/java.nio=ALL-UNNAMED
+ ;; The caveat being it only works when the jar is launched directly
+ ;; like `java -jar metabase.jar`
+ "Add-Opens" "java.base/java.nio"})
(defn- manifest ^Manifest []
(doto (Manifest.)