java.lang.NoClassDefFoundError is one of the most common problem while developing Java Enterprise applications. Sometimes debugging a NoClassDefFoundError can be very tedious as you might have to look for missing class dependencies in jar files and may even have to decompile sometimes.
A NoClassDefFoundError is thrown if the Java Virtual Machine or a ClassLoader instance tries to load in the definition of a class (as part of a normal method call or as part of creating a new instance using the new expression) and no definition of the class could be found. The searched-for class definition existed when the currently executing class was compiled, but the definition can no longer be found. In simple words, the class was available at compile time but missing during runtime.