wood burning stoves*
The moose likes JForum and the fly likes Problem deploying War to Tomcat6 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » JForum
Bookmark "Problem deploying War to Tomcat6" Watch "Problem deploying War to Tomcat6" New topic
Author

Problem deploying War to Tomcat6

Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
I downloaded the source and configured everything so that it worked with my eclipse set up. (Compiler 1.5, Class compatibility and Source compatibility 1.4). It was originally exporting at 1.6 but my server is running 1.5. I configured the build path and everything but I still get this error in the logs:



And this error when I go to the directory path:

HTTP Status 503 - This application is not currently available

type Status report

message This application is not currently available

description The requested service (This application is not currently available) is not currently available.
Apache Tomcat/6.0.20

It does not appear in my tomcat manager, but I can see the war file and the directory structure there. Any hints as to what I am doing wrong?

It runs just fine on my local machine with all these settings. But my tomcat is using 1.6.
[originally posted on jforum.net by ajwatkins]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
Ok, I still have not solved this error and No matter where I have looked nobody can help me with this. Why am I not getting ANY responses at all? Has everybody on this died off?

I am compiling with 1.5 to 1.4, my facet is set at 5, and then I changed it to 1.4. My buildpath is set at 5, and my library referenced is 5.

I still get a version offset =6 error. JForum, when I deploy the war works just fine, except when I compile and deploy it!

I even went as far to put it on a computer that doesn't even have java6 and compile it from there. I still get this error.
[originally posted on jforum.net by ajwatkins]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
I thought I should let everybody know I solved this problem.

What was wrong is how I set it up. I compiled it originally using 6. and installed it then, so I believe somewhere something is set to say java6.

Well it appears that the structure that tomcat (when using java6) is different then when using 5, when exported as a war from eclipse. I'm sure many will tell me this is untrue, but, at least with using tomcat as a server within eclipse, this is how it works.

To solve my problem I just build the war file manually (without using eclipse that is, I am currently working on an ANT build to build me a war file). I cannot launch the application within eclipse anymore for debugging purposes. So even though I know this is BAD PRACTICE currently I have two copies, one that works when launching it in eclipse and the other one.

If you are using java6 with tomcat and eclipse, I can tell you how to turn it into a dynamic web project, where to move files and such. It makes debugging things much easier.

I am sorry if my post doesn't make too much sense. I wasn't sure how to present what I found out. :?


[originally posted on jforum.net by ajwatkins]
Migrated From Jforum.net
Ranch Hand

Joined: Apr 22, 2012
Posts: 17424
This may be something to do with the fact that you are using javac as compiler. Eclipse has its own compiler and i believe Tomcat using the same compiler as well. There may be a mismatch somewhere.
[originally posted on jforum.net by jobhits]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Problem deploying War to Tomcat6
 
Similar Threads
UnsupportedClassVersionError while startup.
Change JRE
Error -HTTP status 503 - This application is not currently available
Error The requested resource is not available
Phantom error in Tomcat!