osdir.com
mailing list archive

Subject: Re: http headers for expiring pages - msg#00179

List: java.jetty.support

Date: Prev Next Index Thread: Prev Next Index
Thanks for your help. Actually I am using JBoss-2.4.4_Jetty-3.1.7-1.
We use a lot of audio files (.wav files) with our Voicexml
applications. These files are cached by the Voicexml interpreter
based on the http headers. Periodically we have a need for updating
these audio files such as when we make changes to the dialog or when
we have a better recording. Hence, the reason for setting the
expiration for these audio files to a week or so.

Our dynamic pages are done through a servlet serving up jsp pages and
we set the http headers on these. It is the audio files that I am
concerned about. Microsoft's IIS has the functionality where you can
set the expiration headers for pages served from a particular
directory. This would be the ideal solution with Jetty, if I could do
it that way.

Thanks

Arthur

--- In jetty-support@xxxx, Brett Sealey <bretts@xxxx> wrote:
> Arthur,
>
> can you please provide a more information on what you are trying to
do
> and version of Jetty etc...
>
> i.e. static pages/images/servlet/jsp... etc..
>
> You may end up needing a custom Handler, or a Filter if you prefer.
>
> Brett
>
> It may help us give you a better answer!
>
> On Sat, 20 Jul 2002, Chris Haynes wrote:
>
> > Hi, Arthur,
> >
> > The lead Jetty developer is away at the moment, and it doesn't
look
> > like the others are around, either. I'm just a user whose picked
up
> > bits of knowledge.
> >
> > As you've asked twice, you may be in a hurry.
> >
> > This is not something I've tried from the basic server - I use
> > Servlets, and set the expiry header directly in the response.
> >
> > I had a quick look through the HttpContext APIs (listed in the
> > website) to see if your answer is there. I can't see it, but I may
> > have missed it. It's worth you looking more closely. If you do
find it
> > there, you'll be able to configure it using XML.
> >
> > However I suspect there isn't an existing configuration API for
it in
> > Jetty - its an unusual requirement (when serving 'static'
content).
> >
> > If you want a 'standard' server with as little change as
necessary, I
> > suspect you may have to implement your own ResourceHandler (by
> > subclassing the Jetty-provided class) and get it to add the HTTP
> > header you need.
> >
> > Anyone else know anything more elegant?
> >
> > Alternatively, wait 'till Tuesday for Greg to get back - he may
know
> > immediately how to do it!
> >
> > Chris Haynes
> >
> > P.S.: I presume using 'meta-equiv' in the HTML itself is
unacceptable?
> >
> >
> >
> > ----- Original Message -----
> > From: "arthur_james_95148" <arthur@xxxx>
> > To: <jetty-support@xxxx>
> > Sent: Saturday, July 20, 2002 2:57 PM
> > Subject: [jetty-support] http headers for expiring pages
> >
> >
> > >
> > > Hi,
> > >
> > > I would like to set default http headers for pages served from
jetty
> > > so that the pages expire in a week (some configurable period).
How
> > do
> > > I set this ?
> > >
> > > Thanks
> > >
> > > Arthur
> > >
> > >
> > >
> > >
> > > ------------------------ Yahoo! Groups
> > Sponsor ---------------------~-->
> > > Will You Find True Love?
> > > Will You Meet the One?
> > > Free Love Reading by phone!
> > > http://us.click.yahoo.com/O3jeVD/R_ZEAA/Ey.GAA/CefplB/TM
> > > ----------------------------------------------------------------
----
> > -~->
> > >
> > > For the latest information about Jetty, please see
> > http://jetty.mortbay.org
> > >
> > >
> > >
> > > Your use of Yahoo! Groups is subject to
> > http://docs.yahoo.com/info/terms/
> > >
> > >
> > >
> > >
> >
> >
> >
> > For the latest information about Jetty, please see
http://jetty.mortbay.org
> >
> >
> >
> > Your use of Yahoo! Groups is subject to
http://docs.yahoo.com/info/terms/
> >
> >




Was this page helpful?
Yes No
Thread at a glance:

Previous Message by Date: click to view message preview

web-app open only to a certain ip address.

hi all . can i configure a web-app to accept request from certain ip address. when someone like 127.0.0.1 types http://server:port/myWebApp he will be answered and all other address will not.. my system is jetty4.0.4 bundled with jboss-2.4.7 . thanks all, Yoni.

Next Message by Date: click to view message preview

Re: Re: http headers for expiring pages

Forgive me if I'm missing something obvious... As I understand it, Jetty, along with all other decent web servers, puts the write-date of the file into the 'Last-Modified:' header, and also uses this date to respond intelligently to 'If-Modified-Since:' conditional requests. Browsers are encouraged to only use their cached copies if they know they are up-to-date (although there are user settings which can modify this behaviour). I happened to do some tests last week - using MSIE and Jetty, to check that this was working OK on image files which I was updating - no problems. Is there some special problem with how your Voicexml handles the caching of .wav files? Can it not use the 'Last-Modified' information (which *is* provided by Jetty)? Chris Haynes ----- Original Message ----- From: "arthur_james_95148" <arthur@xxxxxxxxxxxx> To: <jetty-support@xxxxxxxxxxxxxxx> Sent: Sunday, July 21, 2002 1:36 PM Subject: [jetty-support] Re: http headers for expiring pages > Thanks for your help. Actually I am using JBoss-2.4.4_Jetty-3.1.7-1. > We use a lot of audio files (.wav files) with our Voicexml > applications. These files are cached by the Voicexml interpreter > based on the http headers. Periodically we have a need for updating > these audio files such as when we make changes to the dialog or when > we have a better recording. Hence, the reason for setting the > expiration for these audio files to a week or so. > > Our dynamic pages are done through a servlet serving up jsp pages and > we set the http headers on these. It is the audio files that I am > concerned about. Microsoft's IIS has the functionality where you can > set the expiration headers for pages served from a particular > directory. This would be the ideal solution with Jetty, if I could do > it that way. > > Thanks > > Arthur > > --- In jetty-support@xxxx, Brett Sealey <bretts@xxxx> wrote: > > Arthur, > > > > can you please provide a more information on what you are trying to > do > > and version of Jetty etc... > > > > i.e. static pages/images/servlet/jsp... etc.. > > > > You may end up needing a custom Handler, or a Filter if you prefer. > > > > Brett > > > > It may help us give you a better answer! > > > > On Sat, 20 Jul 2002, Chris Haynes wrote: > > > > > Hi, Arthur, > > > > > > The lead Jetty developer is away at the moment, and it doesn't > look > > > like the others are around, either. I'm just a user whose picked > up > > > bits of knowledge. > > > > > > As you've asked twice, you may be in a hurry. > > > > > > This is not something I've tried from the basic server - I use > > > Servlets, and set the expiry header directly in the response. > > > > > > I had a quick look through the HttpContext APIs (listed in the > > > website) to see if your answer is there. I can't see it, but I may > > > have missed it. It's worth you looking more closely. If you do > find it > > > there, you'll be able to configure it using XML. > > > > > > However I suspect there isn't an existing configuration API for > it in > > > Jetty - its an unusual requirement (when serving 'static' > content). > > > > > > If you want a 'standard' server with as little change as > necessary, I > > > suspect you may have to implement your own ResourceHandler (by > > > subclassing the Jetty-provided class) and get it to add the HTTP > > > header you need. > > > > > > Anyone else know anything more elegant? > > > > > > Alternatively, wait 'till Tuesday for Greg to get back - he may > know > > > immediately how to do it! > > > > > > Chris Haynes > > > > > > P.S.: I presume using 'meta-equiv' in the HTML itself is > unacceptable? > > > > > > > > > > > > ----- Original Message ----- > > > From: "arthur_james_95148" <arthur@xxxx> > > > To: <jetty-support@xxxx> > > > Sent: Saturday, July 20, 2002 2:57 PM > > > Subject: [jetty-support] http headers for expiring pages > > > > > > > > > > > > > > Hi, > > > > > > > > I would like to set default http headers for pages served from > jetty > > > > so that the pages expire in a week (some configurable period). > How > > > do > > > > I set this ? > > > > > > > > Thanks > > > > > > > > Arthur > > > > > > > > > > > > > > > > > > > > ------------------------ Yahoo! Groups > > > Sponsor ---------------------~--> > > > > Will You Find True Love? > > > > Will You Meet the One? > > > > Free Love Reading by phone! > > > > http://us.click.yahoo.com/O3jeVD/R_ZEAA/Ey.GAA/CefplB/TM > > > > ---------------------------------------------------------------- > ---- > > > -~-> > > > > > > > > For the latest information about Jetty, please see > > > http://jetty.mortbay.org > > > > > > > > > > > > > > > > Your use of Yahoo! Groups is subject to > > > http://docs.yahoo.com/info/terms/ > > > > > > > > > > > > > > > > > > > > > > > > > > > > For the latest information about Jetty, please see > http://jetty.mortbay.org > > > > > > > > > > > > Your use of Yahoo! Groups is subject to > http://docs.yahoo.com/info/terms/ > > > > > > > > > ------------------------ Yahoo! Groups Sponsor ---------------------~--> > Discover Remote PC Acess Now > http://us.click.yahoo.com/p5uw2C/1ncEAA/Ey.GAA/CefplB/TM > -------------------------------------------------------------------- -~-> > > For the latest information about Jetty, please see http://jetty.mortbay.org > > > > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ > > > >

Previous Message by Thread: click to view message preview

Re: http headers for expiring pages

Arthur, can you please provide a more information on what you are trying to do and version of Jetty etc... i.e. static pages/images/servlet/jsp... etc.. You may end up needing a custom Handler, or a Filter if you prefer. Brett It may help us give you a better answer! On Sat, 20 Jul 2002, Chris Haynes wrote: > Hi, Arthur, > > The lead Jetty developer is away at the moment, and it doesn't look > like the others are around, either. I'm just a user whose picked up > bits of knowledge. > > As you've asked twice, you may be in a hurry. > > This is not something I've tried from the basic server - I use > Servlets, and set the expiry header directly in the response. > > I had a quick look through the HttpContext APIs (listed in the > website) to see if your answer is there. I can't see it, but I may > have missed it. It's worth you looking more closely. If you do find it > there, you'll be able to configure it using XML. > > However I suspect there isn't an existing configuration API for it in > Jetty - its an unusual requirement (when serving 'static' content). > > If you want a 'standard' server with as little change as necessary, I > suspect you may have to implement your own ResourceHandler (by > subclassing the Jetty-provided class) and get it to add the HTTP > header you need. > > Anyone else know anything more elegant? > > Alternatively, wait 'till Tuesday for Greg to get back - he may know > immediately how to do it! > > Chris Haynes > > P.S.: I presume using 'meta-equiv' in the HTML itself is unacceptable? > > > > ----- Original Message ----- > From: "arthur_james_95148" <arthur@xxxxxxxxxxxx> > To: <jetty-support@xxxxxxxxxxxxxxx> > Sent: Saturday, July 20, 2002 2:57 PM > Subject: [jetty-support] http headers for expiring pages > > > > > > Hi, > > > > I would like to set default http headers for pages served from jetty > > so that the pages expire in a week (some configurable period). How > do > > I set this ? > > > > Thanks > > > > Arthur > > > > > > > > > > ------------------------ Yahoo! Groups > Sponsor ---------------------~--> > > Will You Find True Love? > > Will You Meet the One? > > Free Love Reading by phone! > > http://us.click.yahoo.com/O3jeVD/R_ZEAA/Ey.GAA/CefplB/TM > > -------------------------------------------------------------------- > -~-> > > > > For the latest information about Jetty, please see > http://jetty.mortbay.org > > > > > > > > Your use of Yahoo! Groups is subject to > http://docs.yahoo.com/info/terms/ > > > > > > > > > > > > For the latest information about Jetty, please see http://jetty.mortbay.org > > > > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ > >

Next Message by Thread: click to view message preview

Re: Re: http headers for expiring pages

Forgive me if I'm missing something obvious... As I understand it, Jetty, along with all other decent web servers, puts the write-date of the file into the 'Last-Modified:' header, and also uses this date to respond intelligently to 'If-Modified-Since:' conditional requests. Browsers are encouraged to only use their cached copies if they know they are up-to-date (although there are user settings which can modify this behaviour). I happened to do some tests last week - using MSIE and Jetty, to check that this was working OK on image files which I was updating - no problems. Is there some special problem with how your Voicexml handles the caching of .wav files? Can it not use the 'Last-Modified' information (which *is* provided by Jetty)? Chris Haynes ----- Original Message ----- From: "arthur_james_95148" <arthur@xxxxxxxxxxxx> To: <jetty-support@xxxxxxxxxxxxxxx> Sent: Sunday, July 21, 2002 1:36 PM Subject: [jetty-support] Re: http headers for expiring pages > Thanks for your help. Actually I am using JBoss-2.4.4_Jetty-3.1.7-1. > We use a lot of audio files (.wav files) with our Voicexml > applications. These files are cached by the Voicexml interpreter > based on the http headers. Periodically we have a need for updating > these audio files such as when we make changes to the dialog or when > we have a better recording. Hence, the reason for setting the > expiration for these audio files to a week or so. > > Our dynamic pages are done through a servlet serving up jsp pages and > we set the http headers on these. It is the audio files that I am > concerned about. Microsoft's IIS has the functionality where you can > set the expiration headers for pages served from a particular > directory. This would be the ideal solution with Jetty, if I could do > it that way. > > Thanks > > Arthur > > --- In jetty-support@xxxx, Brett Sealey <bretts@xxxx> wrote: > > Arthur, > > > > can you please provide a more information on what you are trying to > do > > and version of Jetty etc... > > > > i.e. static pages/images/servlet/jsp... etc.. > > > > You may end up needing a custom Handler, or a Filter if you prefer. > > > > Brett > > > > It may help us give you a better answer! > > > > On Sat, 20 Jul 2002, Chris Haynes wrote: > > > > > Hi, Arthur, > > > > > > The lead Jetty developer is away at the moment, and it doesn't > look > > > like the others are around, either. I'm just a user whose picked > up > > > bits of knowledge. > > > > > > As you've asked twice, you may be in a hurry. > > > > > > This is not something I've tried from the basic server - I use > > > Servlets, and set the expiry header directly in the response. > > > > > > I had a quick look through the HttpContext APIs (listed in the > > > website) to see if your answer is there. I can't see it, but I may > > > have missed it. It's worth you looking more closely. If you do > find it > > > there, you'll be able to configure it using XML. > > > > > > However I suspect there isn't an existing configuration API for > it in > > > Jetty - its an unusual requirement (when serving 'static' > content). > > > > > > If you want a 'standard' server with as little change as > necessary, I > > > suspect you may have to implement your own ResourceHandler (by > > > subclassing the Jetty-provided class) and get it to add the HTTP > > > header you need. > > > > > > Anyone else know anything more elegant? > > > > > > Alternatively, wait 'till Tuesday for Greg to get back - he may > know > > > immediately how to do it! > > > > > > Chris Haynes > > > > > > P.S.: I presume using 'meta-equiv' in the HTML itself is > unacceptable? > > > > > > > > > > > > ----- Original Message ----- > > > From: "arthur_james_95148" <arthur@xxxx> > > > To: <jetty-support@xxxx> > > > Sent: Saturday, July 20, 2002 2:57 PM > > > Subject: [jetty-support] http headers for expiring pages > > > > > > > > > > > > > > Hi, > > > > > > > > I would like to set default http headers for pages served from > jetty > > > > so that the pages expire in a week (some configurable period). > How > > > do > > > > I set this ? > > > > > > > > Thanks > > > > > > > > Arthur > > > > > > > > > > > > > > > > > > > > ------------------------ Yahoo! Groups > > > Sponsor ---------------------~--> > > > > Will You Find True Love? > > > > Will You Meet the One? > > > > Free Love Reading by phone! > > > > http://us.click.yahoo.com/O3jeVD/R_ZEAA/Ey.GAA/CefplB/TM > > > > ---------------------------------------------------------------- > ---- > > > -~-> > > > > > > > > For the latest information about Jetty, please see > > > http://jetty.mortbay.org > > > > > > > > > > > > > > > > Your use of Yahoo! Groups is subject to > > > http://docs.yahoo.com/info/terms/ > > > > > > > > > > > > > > > > > > > > > > > > > > > > For the latest information about Jetty, please see > http://jetty.mortbay.org > > > > > > > > > > > > Your use of Yahoo! Groups is subject to > http://docs.yahoo.com/info/terms/ > > > > > > > > > ------------------------ Yahoo! Groups Sponsor ---------------------~--> > Discover Remote PC Acess Now > http://us.click.yahoo.com/p5uw2C/1ncEAA/Ey.GAA/CefplB/TM > -------------------------------------------------------------------- -~-> > > For the latest information about Jetty, please see http://jetty.mortbay.org > > > > Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/ > > > >
Sign up for updates to this mailing list. email:
Loading Comments...
Home | News | Patents | Sitemap | FAQ | advertise

Advertising by