• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Tomcat Netbeans Deployment Problem

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
I'm trying to deploy a web application that I developed using Netbeans (5.5/6)

Everything was working fine with the bundled Tomcat. Netbeans has written a web.xml that works fine with netbeans and the bundled Tomcat. Unfortunately, when I tried to copy everything to my Java Server there seems to be something different with the expected directory structure.

The system doesn't find my servlets and my JSPs are found only when I change the URL. Example: Under the bundled Tomcat a JSP uses this URL: Application/index.jsp
On the Tomcat on the server it requires this URL to be found: Application/web/index.jsp

The latter resembles the physical directory hierarchy, because the JSP ist actually under web. But when I try to put the JSP one step higher up on the production server, i.e. when I put it physically under Application/index.jsp the server doesn't find the file. What's wrong in the setup of my production server? Again: JSPs work after when I use a different URL with the /web/ directory in between, but servlets don't work and I don't even know whether the production server even finds my web.xml generated by netbeans.

Thanks a lot

Peter
 
Ranch Hand
Posts: 387
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
hi Peter,

Netbeans (aka Ant) builds a .war file (it's in the dist folder of your webapplication).
Have a look in there, that's the real structure of you webapplication.

The "web" folder is on the developer's PC only, and could have any name.

Herman
[ November 25, 2007: Message edited by: Herman Scheltinga ]
 
Peter Jansen
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks for your quick reply. I had been looking for this .war file on my laptop. It seems netbeans didn't generate it. Fortunately I had it on my second computer that has the same project checked in. It was in the dist directory that doesn't exist on my laptop. Apparently this did the trick although I'm now getting an error (UnsupportedClassVersionError) which is probably due to the fact that I'm using Tomcat 6/Java 1.6 on my local systems and Tomcat 5.5 with Java 1.5 on the production server.

I'll have to upgrade.

Thanks again for your answer!!

Peter
[ November 25, 2007: Message edited by: Peter Jansen ]
reply
    Bookmark Topic Watch Topic
  • New Topic