Databricks Java - Create Jar in Java 11
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
09-15-2023 07:54 AM
I am trying to a run simple print java program which is not working and getting compilation version issues though i changed the environment variable points to java 11. Can you please help me ? Can we create java with spark session and execute as a jar in databricks? Because most of the examples are in scala.
Error:
UnsupportedClassVersionError: JarTesting has been compiled by a more recent version of the Java Runtime (class file version 55.0), this version of the Java Runtime only recognizes class file versions up to 52.0.
Attached env variable fYR
- Labels:
-
databricks
-
env
-
Spark
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2024 10:22 PM
@Databricks_Java You can run command like this: spark-submit --class com.test.Main example.jar
and make sure to check the java version and match with the DBR compatibility

