Jetty as file server

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Jetty as file server

Tobia Loschiavo
I have to use jetty as a file server. I need to put in a context only a
file and not the entire directory but i can't do it! Is it possible? How
do i have to proceed?

Yours faithfully
John Slave


-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
Jetty-support mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jetty-support
Reply | Threaded
Open this post in threaded view
|

Re: Jetty as file server

Eric Rizzo
On 10/7/05, Tobia Loschiavo <[hidden email]> wrote:
> I have to use jetty as a file server. I need to put in a context only a
> file and not the entire directory but i can't do it! Is it possible? How
> do i have to proceed?

One way would be to implement a servlet filter and attach it to the
default servlet that serves static content.
I suppose you could sub-class the default servlet
(org.mortbay.jetty.servlet.Default) and override part of the
implementation to only return resources you want to, but I think the
ServletFilter option will be more straightforward.

HTH,
Eric


-------------------------------------------------------
This SF.Net email is sponsored by:
Power Architecture Resource Center: Free content, downloads, discussions,
and more. http://solutions.newsforge.com/ibmarch.tmpl
_______________________________________________
Jetty-support mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/jetty-support