-
FEATURED COMPONENTS
First time here? Check out the FAQ!
Hello everyone,
I suddenly have a problem trying to publish my ZK project to Tomcat 6 from within ZK Studio.
Til yesterday everything worked fine but suddenly today when I click "Run As->Run on server" the attempt fails with the following error message:
Publishing to "Tomcat 6.0 at localhost" has encountered a problem.
Could not publish to server.
An internal error occurred during: "Updating status for Tomcat v6.0 Server at localhost...".
java.lang.NullPointerException
This also happens if I press CMD+B (Ctrl+B) for a full rebuild after cleaning the whole project.
Does anyone know how to solve or at least debug this?
This starts to get really frustrating...
I tried to create a plain new ZK project - no change.
Uninstalled Tomcat 6.0 and installed Tomcat 7.0. - no change.
Damn, what's wrong with this?
Try to clean the Tomcat Work Directory like in this pic.
@ashishd Yes, starting Tomcat from outside eclipse works perfectly.
@terrytornado I did that already.
The funny thing is: After doing that, I get a 404 every time I try to load my web app in the browser (through http://localhost:8080/myapp).
Before that, the website showed at least the version of the last successful build (which is already days old).
I think eclipse seems to have a problem deploying the new build files to a directory where Tomcat can access them.
I believe, it tries to publish to the following directory but fails (for some reason):
/Users/USERNAME/Documents/workspaces/zk/.metadata/.plugins/org.eclipse.wst.server.core/tmp0
I have sometimes problems with eclipse plugins too, mostly the maven plugins.
In your case it can helps, if you delete the files from your mentioned directory of the eclipse Tomcat plugin.
Make a reboot. :-)
I did that already too :-)
The funny thing: If I manually remove these files, reboot and re-publish, the first build and deployment works. After that: Same old problem.
This is really weird. Everything worked perfectly but since a few days this problem occurs.
Maybe I should try a full reinstall of tomcat, zk studio and the zk sdk...
I removed that directory tmp0 again and now when I start Tomcat from within ZK Studio, I get this error message:
Publishing failed
Could not publish to the server.
java.lang.NullPointerException
Could not publish server configuration: /Users/valmar/Documents/workspaces/zk/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/conf/server.xml (No such file or directory).
/Users/valmar/Documents/workspaces/zk/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/conf/server.xml (No such file or directory)
How can I reinitialize this directory?
Ok, I found the problem.
There was a corrupt project in my workspace associated with Tomcat.
So, whenever I wanted to publish a project to the same server, the attempt failed.
After deleting the corrupt project, everything works fine.
:-) Great
Thanks for the help btw :-)
Asked: 2010-11-06 09:48:10 +0800
Seen: 3,571 times
Last updated: Nov 11 '10