java.lang.NoClassDefFoundError

org/springframework/context/ApplicationContextInitializer

Samebug tips4

This might be an issue with the file location in the Spark submit command. Try it with "spark-submit --master spark://master:7077 hello_world_from_pyspark.py {file location}"

Needs to add netty-transport-native-epoll with a OS classifier to the classpath, it's not included in netty-all

Don't give up yet. Our experts can help. Paste your full stack trace to get a solution.

Solutions on the web19008

  • org/springframework/context/ApplicationContextInitializer
  • org/springframework/context/ApplicationContextInitializer
  • org/springframework/context/ApplicationContextInitializer
  • Stack trace

    • java.lang.NoClassDefFoundError: org/springframework/context/ApplicationContextInitializer at java.lang.ClassLoader.defineClass1(Native Method) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:467) at java.net.URLClassLoader.access$100(URLClassLoader.java:73) at java.net.URLClassLoader$1.run(URLClassLoader.java:368) at java.net.URLClassLoader$1.run(URLClassLoader.java:362) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:361) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) at java.lang.ClassLoader.loadClass(ClassLoader.java:411) at org.springframework.boot.loader.LaunchedURLClassLoader.loadClass(LaunchedURLClassLoader.java:89) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at org.springframework.util.ClassUtils.forName(ClassUtils.java:250) at org.springframework.boot.SpringApplication.createSpringFactoriesInstances(SpringApplication.java:414) Caused by: java.lang.ClassNotFoundException: org.springframework.context.ApplicationContextInitializer at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ... 15 more Caused by: java.lang.NoClassDefFoundError: org/springframework/context/ApplicationContextInitializer at java.lang.ClassLoader.defineClass1(Native Method) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:467) at java.net.URLClassLoader.access$100(URLClassLoader.java:73) at java.net.URLClassLoader$1.run(URLClassLoader.java:368) at java.net.URLClassLoader$1.run(URLClassLoader.java:362) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:361) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) at java.lang.ClassLoader.loadClass(ClassLoader.java:411) at org.springframework.boot.loader.LaunchedURLClassLoader.loadClass(LaunchedURLClassLoader.java:89) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at org.springframework.util.ClassUtils.forName(ClassUtils.java:250) at org.springframework.boot.SpringApplication.createSpringFactoriesInstances(SpringApplication.java:414) ... 15 more Caused by: java.lang.ClassNotFoundException: org.springframework.context.ApplicationContextInitializer at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:331) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ... 30 more

    Write tip

    You have a different solution? A short tip here would help you and many other users who saw this issue last week.

    Users with the same issue

    Unknown user
    Once, 11 months ago
    Unknown user
    Once, 11 months ago
    Unknown user
    Once, 3 weeks ago
    Unknown user
    Once, 3 weeks ago
    Unknown user
    Once, 3 weeks ago
    1587 more bugmates