You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@livy.apache.org by "Gabor Roczei (Jira)" <ji...@apache.org> on 2026/08/12 11:44:00 UTC

[jira] [Created] (LIVY-1069) Build fails with NoClassDefFoundError without explicit -Pspark3 and -Pscala-2.12 profiles

Gabor Roczei created LIVY-1069:
----------------------------------

             Summary: Build fails with NoClassDefFoundError without explicit -Pspark3 and -Pscala-2.12 profiles
                 Key: LIVY-1069
                 URL: https://issues.apache.org/jira/browse/LIVY-1069
             Project: Livy
          Issue Type: Bug
    Affects Versions: 1.0.0
            Reporter: Gabor Roczei


Currently if we don't specify the -Pspark3 -Pscala-2.12 profiles (which are used by Livy's unit and integration tests in GitHub Actions) it fails with the following error:
{code:java}
$ mvn -Pthriftserver verify
...

SQLInterpreterSpec:
*** RUN ABORTED *** (2 seconds, 570 milliseconds)
  java.lang.NoClassDefFoundError: org/json4s/JsonAssoc$
  at org.apache.spark.sql.types.StructType.jsonValue(StructType.scala)
  at org.apache.spark.sql.types.StructType.jsonValue(StructType.scala:102)
  at org.apache.spark.sql.types.DataType.json(DataType.scala:78)
  at org.apache.livy.repl.SQLInterpreter.execute(SQLInterpreter.scala:94)
  at org.apache.livy.repl.SQLInterpreterSpec.$anonfun$new$2(SQLInterpreterSpec.scala:58)
  at org.apache.livy.repl.BaseInterpreterSpec.withInterpreter(BaseInterpreterSpec.scala:32)
  at org.apache.livy.repl.SQLInterpreterSpec.$anonfun$new$1(SQLInterpreterSpec.scala:49)
  at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23)
  at org.scalatest.OutcomeOf.outcomeOf(OutcomeOf.scala:85)
  at org.scalatest.OutcomeOf.outcomeOf$(OutcomeOf.scala:83)
  ...
  Cause: java.lang.ClassNotFoundException: org.json4s.JsonAssoc$
  at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:641)
  at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:188)
  at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:525)
  at org.apache.spark.sql.types.StructType.jsonValue(StructType.scala)
  at org.apache.spark.sql.types.StructType.jsonValue(StructType.scala:102)
  at org.apache.spark.sql.types.DataType.json(DataType.scala:78)
  at org.apache.livy.repl.SQLInterpreter.execute(SQLInterpreter.scala:94)
  at org.apache.livy.repl.SQLInterpreterSpec.$anonfun$new$2(SQLInterpreterSpec.scala:58)
  at org.apache.livy.repl.BaseInterpreterSpec.withInterpreter(BaseInterpreterSpec.scala:32)
  at org.apache.livy.repl.SQLInterpreterSpec.$anonfun$new$1(SQLInterpreterSpec.scala:49)
  ...
{code}

We need to find a solution for this, for example making the 3.5.4 parameters set by the spark3 profile the default values under <properties> in the parent pom.xml.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)