This forum has been moved here:
Helicon Tech Community Forum

Helicon Ape (Forum Locked Forum Locked)
 Helicon Tech : Helicon Ape
Subject Topic: mod_expires vs. mod_headers
Author
Message |
camcima
Newbie


Joined: 22 February 2011
Location: Brazil
Posts: 5
Posted: 22 February 2011 at 5:52am

I'm using mod_expires to set the Expires header. It also sets the Cache-Control max-age directive with the same value, which is nice. I also need to set the s-maxage header so that the reverse proxy will know how long to cache the content. When I do this, it merges the max-age and s-maxage directives in the Cache-Control header separated by a comma, like this:

Cache-Control: s-maxage=900,max-age=900

The problem is that, after the comma, it does not insert a space and IE does not recognize the max-age directive unless there is a space there.

Is there any way to insert a space after the comma so it will work with IE?

 

Thanks,

Carlos Cima

Back to Top
 
Vyacheslav
Admin Group


Joined: 02 July 2008
Location: Ukraine
Posts: 1542
Posted: 22 February 2011 at 8:46am

Hello.
Could you please provide Helicon Ape’s configuration code.
Thank you.

__________________
Slavik Shynkarenko,
Helicon Tech.
Back to Top Visit Vyacheslav's Homepage
 
camcima
Newbie


Joined: 22 February 2011
Location: Brazil
Posts: 5
Posted: 22 February 2011 at 8:54am

    ExpiresActive On
    ExpiresDefault A86400
    Header set Cache-Control "s-maxage=86400"
Back to Top
 
Vyacheslav
Admin Group


Joined: 02 July 2008
Location: Ukraine
Posts: 1542
Posted: 22 February 2011 at 11:28am

Hello.
Please try to replace that code with following:
Code:
Header set Cache-Control "s-maxage=86400, max-age=86400"


__________________
Slavik Shynkarenko,
Helicon Tech.
Back to Top Visit Vyacheslav's Homepage
 
camcima
Newbie


Joined: 22 February 2011
Location: Brazil
Posts: 5
Posted: 22 February 2011 at 5:58pm

That will obviously solve the problem on the Cache-Control header, but what about the Expires header?
Back to Top
 
camcima
Newbie


Joined: 22 February 2011
Location: Brazil
Posts: 5
Posted: 24 February 2011 at 3:59am

Is there a way to edit the Cache-Control header and add a space after the comma after the mod-expires has updated it?

 

Back to Top
 
Vyacheslav
Admin Group


Joined: 02 July 2008
Location: Ukraine
Posts: 1542
Posted: 25 February 2011 at 8:46am

Hello.
This behaviour happens because of .NET internal work. We don’t manually add comma character. We probably should manually parse Cache-Control, but it requires some time to implement this feature. Is there significant reason of using s-maxage= value?

__________________
Slavik Shynkarenko,
Helicon Tech.
Back to Top Visit Vyacheslav's Homepage
 
camcima
Newbie


Joined: 22 February 2011
Location: Brazil
Posts: 5
Posted: 25 February 2011 at 10:32am

Yes. Not only s-maxage, which is the time the proxy should keep this particular content in its store, but also other directives like "must-revalidate" or "public".

I've commented out the mod_expires directive for now because it's more important that IE understands the directive than old browsers that don't understand the Cache-Control header (HTTP 1.1) do it.

It would be nice to have this fixed in the future.

Thanks!

Carlos Cima
Back to Top
 

Sorry, you can NOT post a reply.
This forum has been locked by a forum administrator.

Printable version Printable version