[jetty-user] web app context stops serving static content

ChadDavis <[email protected]>
Newsgroups gmane.comp.java.jetty.support
Message-ID <[email protected]>
I recently migrated to Jetty 6.1.22 from 4.x.  Everything is good,
except my web application quits serving static content from it's
default mapping after an indeterminate period of time.  I'm guessing
about two weeks.  Here's the set up:

WebAppContext ctx = new WebAppContext("mywar.war", "/");
ctx.setParentLoaderPriority(true);
ctx.setMimeTypes(getMimeTypeMappings());
addContextHandlerToServer(server, ctx);

My web.xml contains several servlet mappings, such as:

<servlet-mapping>
  <servlet-name>MyServlet</servlet-name>
  <url-pattern>*.page</url-pattern>
</servlet-mapping>
<servlet-mapping>
  <servlet-name>MyServlet</servlet-name>
  <url-pattern>/page/*</url-pattern>
</servlet-mapping>

And my static resources are in war file top level directories like:

/images/myImage.gif

To sum up:

1) the servlet mappings still work
2) static files like myImage.gif no longer work
3) if i hit the host name without any path info, such as
www.myhost.com, I no longer go to my servlet ( default behavour? );
rather I get a directory browsing view showing some, but not all, of
the directories in the top level of my war.  The servlet was being
hit, in this instance, by way of a welcome file mapping that appended
"index.page", which was not a real file, to my host name which then
hit my servlet mapping above.


I found one item on the jetty docs page regarding temp files (
/tmp/Jetty_*) deleted by cron jobs.  Is this perhaps related?

http://docs.codehaus.org/display/JETTY/Webapp+suddenly+stopped+working

Thanks!
Chad

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.