• 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
  • Tim Cooke
  • paul wheaton
  • Liutauras Vilda
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Devaka Cooray
  • Paul Clapham
Saloon Keepers:
  • Scott Selikoff
  • Tim Holloway
  • Piet Souris
  • Mikalai Zaikin
  • Frits Walraven
Bartenders:
  • Stephan van Hulst
  • Carey Brown

WSAD 5 Web Project Testing

 
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I have a web project (jsp ver. 1.2) and have it associated with a WAS4 test
server in WSAD5
I have a servlet in the web project that is set to run at startup that is
running fine on the test server when I start the test server.
My problem is this: I cannot seem to get any of the jsp files in the web
project to run on the WAS4 test server... when I have the jsp I want to run
selected and right click the 'Run on Server' selection is greyed out...
furthermore if I type the URL in explicitly in a browser and try to run it
that way I get the following error (WebGroup X Servlet Error: File not
found: WEB-INF/SessionSetter.jsp: javax.servlet.ServletException: File not
found: WEB-INF/SessionSetter.jsp).
The file is where I am referencing it but I have no idea why this is not
working (it worked just fine in WSAD 4.0.3)
Any help would be GREATLY appreciated!
Doug
 
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You have your JSPs in the web-inf directory?
Servlet containers are not allowed to serve JSPs from this directory. THis is probably why you can't 'run on server' and the other error is shown.
But, depending on the server and version, it is sometimes possible to forward or include a JSP in the web-inf directory. It's not something I do myself since its support is too flakey. It may work in one server version but not the next, forcing you to rewrite everything.
Dave
 
Douglas Vanderpool
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dave,
That was exactly the problem... indeed my JSP files were in the WEB-INF directory. After much experimentation I actually figured this out yesterday. This worked fine on in WSAD4 and on WAS4. What structure do you typically use for JSP's, included js files, and images etc. within a project? I looked through the J2EE spec but did not see anything specified or recommended...
Thanks,
Doug
 
Politics n. Poly "many" + ticks "blood sucking insects". Tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic