Please take our Survey
logo       

Choosing A Webhost:
A web hosting service is a type of Internet hosting service that allows individuals and organizations to provide their own website accessible via the World Wide Web. Web hosts are companies that provide space on a server they own for use by their clients as well as providing Internet connectivity, typically in a data center. Web hosts can also provide data center space and connectivity to the Internet for servers they do not own to be located in their data center, called colocation. more...

Re: Why isn't Cache-Control removed with remove_content_headers?: msg#00021

lang.perl.modules.lwp

Subject: Re: Why isn't Cache-Control removed with remove_content_headers?

On Wed, Jan 25, 2006 at 01:49:16AM -0800, Gisle Aas wrote:
> Bill Moseley <moseley@xxxxxxxx> writes:
>
> > I've been setting both Cache-Control max-age and Expires. But I
> > noticed that remove_content_headers() only removes the
> > @entity_headers which only includes Expires.
> >
> > Should remove_content_headers remove both?
>
> I'm not sure. RFC 2616 section 4.5 starts out saying "There are a few
> header fields which have general applicability for both request and
> response messages, but which do not apply to the entity being
> transferred." and Cache-Control is one of these. This implies that
> remove_content_headers shouldn't touch it.

I'm not sure either. Expires and Cache-Control have somewhat similar
function (section 14.9.3 discusses what happens when both are
present) so I thought it odd that one would be removed and not the
other.

Like Expires, Cache-Control does describe what to do with the content
in a response, so would seem reasonable to consider it a content
header. On there other hand, I believe it's possible to include
Expires and Cache-Control on a 304 response that contains no content.

I'm not sure why Cache-Control isn't listed in 7.1 Entity Header
Fields, as Cache-Control can override Expires as noted in 14.21.

So, ya, I'm not sure.

> Does the current behaviour create a problem in your application?

Not really a problem. I have a response that includes Last-Modified,
Content-Length, Cache-Control max-age, and Expires. In some cases that
content is further processed and becomes non-cacheable. So I need to
remove all headers except Last-Modified (and even leaving
last-modified is questionable).

So I was trying to use remove_content_headers for a different
purpose, I suppose.


--
Bill Moseley
moseley@xxxxxxxx




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

Recently Viewed:
qnx.openqnx.dev...    gcc.libstdc++.c...    solaris.opensol...    information-ret...    misc.misterhous...    web.catalyst.ge...    apache.webservi...    redhat.release....    hardware.lirc/2...    kernel.autofs/2...    technology.sust...    linux.vdr/2003-...    editors.lyx.gen...    org.user-groups...    netbsd.devel.pk...    xdg.devel/2004-...    version-control...    jakarta.slide.d...    debian.packages...    creativecommons...    ports.ppc.embed...    bug-tracking.bu...   
Home | blog view | USPTO Patent Archive | advertise | OSDir is an inevitable website. super tiny logo

Free Magazines

Cisco News
Receive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business.
subscribe

Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field.
subscribe

The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business.
subscribe

Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company.
subscribe

Total Telecom Total Telecom is "The Economist of the communications industry".
subscribe