java.lang.NoClassDefFoundError

If you like a tip written by other Samebug users, mark is as helpful! Marks help our algorithm provide you better solutions and also help other users.
tip

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

tip

You might've forgot to add a dependency or it's written wrong. Also, you might be using incompatible versions of Java and Hibernate. More on this here: https://goo.gl/SjSlRA

tip

If you're using Hibernate, this indicates you're missing FasterXML Classmate dependency, which you can add to your dependencies. To add it, the groupId is com.fasterxml and artifactId is Classmate.

tip

Check if you didn't forget to instantiate your topic in the kafka broker.

tip

NoClassDefFoundError means java has failed to find a class you're trying to instantiate, look if you've added the class you're trying to instantiate to the dependencies.

tip

This error means there's a class missing in your classpath during runtime. You need to create a jar with all your dependencies and have it in your classpath. Check Maven Assembly Plugin and how to add your dependencies to a jar: https://goo.gl/U2zr8k

tip

jsp-api and servlet-api jars must NOT be deployed by your web app. They should be marked as provided but not deployed by your app.

tip

You need to add httpcore to your dependencies. Try adding version 4.3 or further.

tip

The server rejects all jars that already belong to the server runtime (such as tomcat-**.jar, servlet**.jar). Consider substituting the CORS filter you're using for this one: https://goo.gl/ctQ7Fs

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

  • Plugin loads but not working
    via GitHub by Devilsphere007
    ,
  • SQLlite Error with MC 1.11
    via GitHub by EnderSandman
    ,
  • sqlite JDBC jdk1.8 incompatibility
    via by George Eilers,
  • How to use JDBC jar in Eclipse on Mac OSX
    via by Jeff Bullock,
  • GitHub comment 182#291005565
    via GitHub by ItsPueh
    ,
    • java.lang.NoClassDefFoundError: org/sqlite/NativeDB at java.lang.ClassLoader$NativeLibrary.load(Native Method) at java.lang.ClassLoader.loadLibrary0(ClassLoader.java:1833) at java.lang.ClassLoader.loadLibrary(ClassLoader.java:1709) at java.lang.Runtime.load0(Runtime.java:770) at java.lang.System.load(System.java:1019) at org.sqlite.SQLiteJDBCLoader.loadNativeLibrary(SQLiteJDBCLoader.java:200) at org.sqlite.SQLiteJDBCLoader.extractAndLoadLibraryFile(SQLiteJDBCLoader.java:148) at org.sqlite.SQLiteJDBCLoader.loadSQLiteNativeLibrary(SQLiteJDBCLoader.java:249) at org.sqlite.SQLiteJDBCLoader.initialize(SQLiteJDBCLoader.java:65) at org.sqlite.core.NativeDB.load(NativeDB.java:53) at org.sqlite.core.CoreConnection.open(CoreConnection.java:136) at org.sqlite.core.CoreConnection.<init>(CoreConnection.java:66) at org.sqlite.jdbc3.JDBC3Connection.<init>(JDBC3Connection.java:21) at org.sqlite.jdbc4.JDBC4Connection.<init>(JDBC4Connection.java:23) at org.sqlite.SQLiteConnection.<init>(SQLiteConnection.java:44) at org.sqlite.JDBC.createConnection(JDBC.java:113) at org.sqlite.JDBC.connect(JDBC.java:87) at java.sql.DriverManager.getConnection(DriverManager.java:582) at java.sql.DriverManager.getConnection(DriverManager.java:207) at edu.ucsd.cse.cse132a.SQLiteJDBCTest.main(SQLiteJDBCTest.java:15) Caused by: java.lang.ClassNotFoundException: org.sqlite.NativeDB at java.net.URLClassLoader$1.run(URLClassLoader.java:202) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:190) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301) at java.lang.ClassLoader.loadClass(ClassLoader.java:247) ... 20 more

    Users with the same issue

    joserobjr
    1 times, last one,
    Unknown visitor1 times, last one,
    Casper
    4 times, last one,
    Handemelindo
    1 times, last one,
    Unknown visitor1 times, last one,
    1190 more bugmates