logo       

Re: 404 servlet: msg#00001

text.xml.resin.user

Subject: Re: 404 servlet

Hi.

This works perfectly for for found files that are handled by resin.
For what I need to do, I must define a 404 error within apache (and
within resin ...)

ErrorDocument 404 /servlets/notfound

.jsp, servlets, .do, ... not found will have the attribute.
but .gif, .js, .css, ... and all static files have null instead.

Finaly, I'm begining to think it's simply impossible. To know really, I
would look at how 404 documents are ahndled by Apache, but I'm not sure
I will understand anything ...

Anyway, thanks for you response.

Mike

Le 058éme jour de l'an 2004, Dalen-van.Andre à écrit :
>
> Hi,
>
> Have a look at the following attributes in your 404 servlet
>
> private static final String[] ERROR_ATTRIBUTES = {
> "javax.servlet.error.status_code",
> "javax.servlet.error.exception_type",
> "javax.servlet.error.message",
> "javax.servlet.error.exception",
> "javax.servlet.error.request_uri",
> "com.ibm.websphere.request_url" // IBM
> WebSphere 4.x specific...
> };
>
> you can get the original request from the request_ur[il] attribues.
>
> hope this helps, Andre
>
> > -----Original Message-----
> > From: mbaroukh@xxxxxxxxxxxx [mailto:mbaroukh@xxxxxxxxxxxx]
> > Sent: Thursday, February 26, 2004 17:25
> > To: resin-interest@xxxxxxxxxx
> > Subject: 404 servlet
> >
> >
> >
> > Hi.
> >
> > I thought about the following but don't see how to do. I know
> > it's not a
> > resin specifc question but if somebody can help ...
> >
> > Suppose I have some static content in database and I wan't to
> > have them
> > served by apache. For this, it would be nice to :
> > - An url like /static/image.gif is called
> > - Apache do not found it, so he call error document. It could be a
> > servlet.
> > - This servlet see if it is something it can generate. If no,
> > it returns
> > a true 404. Else, it generate it and forward the request to
> > the generated content.
> > - Subsequent calls to the content will return the content directly
> > because it exists ...
> >
> > My problem is that the 404 servlet knows nothing about the initial uri
> > of the object that was requested. At least, I can't see where this
> > information is.
> >
> > Does anybody have any idea ?
> >
> > Thanks in advance.
> >
> > --
> >
> > Mike Baroukh
> >
> > Cardiweb - 31 Rue de Mogador Paris IXeme
> > 06 63 57 27 22 - 01 53 21 82 63 - ICQ: 105910677
> > http://www.cardiweb.com
> > --
> >
>

--

Mike Baroukh

Cardiweb - 31 Rue de Mogador Paris IXeme
06 63 57 27 22 - 01 53 21 82 63 - ICQ: 105910677
http://www.cardiweb.com
--
Léon, le télémanipulateur, bat ta bru et a lu pi, n'a mêlé tel Noël.
-- Graner, Nicolas
--



<Prev in Thread] Current Thread [Next in Thread>
Google Custom Search

News | FAQ | advertise