问题
I'm using Grails -2.0.1 and when trying to run an app, I find a NoClassDefFoundError :
Error 2012-10-16 15:24:25,301 [http-bio-8080-exec-9] ERROR errors.GrailsExceptionResolver - NoClassDefFoundError occurred when processing request: [GET] /workstation/track/computerName/login/MacOSX/true/username
Could not initialize class workstation.server.TrackController. Stacktrace follows: Message: Error creating bean with name 'workstation.server.TrackController': Instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError: Could not initialize class workstation.server.TrackController Line | Method ->> 886 | runTask in java.util.concurrent.ThreadPoolExecutor$Worker
| 908 | run in '' ^ 680 | run . . in java.lang.Thread
I couldn't figure out this error do I tried doing a grails -clean( in the hope of running again). Turns out the clean does not work
Error: plugin-list-grailsCentral.xml:29227:22: XML document structures must start and end within the same entity. Also, did not find this XML in the grails directory.
Any clues anyone? Could anyone help me as to why the clean won't work?
回答1:
Try deleting .grails dir after the clean. This can fix a lot of problems, especially when it comes to plugins.
来源:https://stackoverflow.com/questions/12922215/grails-clean-doesnt-work