Atitit. troubleshooting series --- NoClassDefFoundError ClassNotFoundException, dllnotfoundexception
Atitit. troubleshooting series --- NoClassDefFoundError ClassNotFoundException
1. The class exception cannot be found in java. lang. ClassNotFoundException. This exception is thrown when the application tries to construct a class based on the class name in the string format and cannot find the class file with the corresponding name after traversing the CLASSPAH. 1
2. Check whether the class exists... 1
3. Add the class "eclipse" to the class "sysoout", ", and" re-compile "to the class" hanging... 3 ". Go to" OK "... 2
4. Try to use web servers that support complete hot deployment. We recommend glassfish and resin .. Tomcat and jboss only support hot deployment in rare cases to add a new line of out print, so eclipse has re-compiled the class .. usually it's OK... 90% this solution can be used to view the updated version information of the tracking class. If the manual synchronization version is for remote debugging, it is usually better to interrupt the connection... if not, restart the web server .. If not, restart ide... 2
5. Class Library conflict 2
1. Java. lang. ClassNotFoundException cannot find the class exception. This exception is thrown when the application tries to construct a class based on the class name in the string format and cannot find the class file with the corresponding name after traversing the CLASSPAH.
There is also a NoClassDefFoundError, which means that classload will not be able to load the class ..
2. Check whether the class exists...
Author: old wow's paw Attilax iron, EMAIL: 1466519819@qq.com
Reprinted please indicate Source: http://www.cnblogs.com/attilax/
3. Add a sysoout class named eclipse, and re-compile it to the class... 3. Go to OK...
Cause: myeclipse bug (local debugging), eclipse or web server bug (remote debugging)
Scenario :::
Occasionally, inconsistency between. java and. class occurs ..
Solution :::
4.
Try to use web servers that support complete hot deployment. We recommend glassfish and resin .. Tomcat and jboss only support hot deployment in rare cases
A new line of out print is added, so eclipse has already re-compiled the class .. It is usually OK... 90%. This solution can be used.
You can use bcompare to view the updated version information of the tracking class and manually synchronize the version.
For remote debugging, it is usually better to interrupt the connection... if not, restart the web server ..
If not, restart ide...
5. Class Library conflict
For example, the jar package contains a class .. The class directory has a class with the same name .. Attilax is called. Clousre .. But this clousre does not exist in the jar package.
The class in jar is started and loaded. As a result, classload cannot find the class under the sub-path ....
Solution: Delete the startup class with the same name in the jar package .. Use the class file under the class directory to start. In this way, you can ..