httpd-bugs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject DO NOT REPLY [Bug 44696] mod_cache sometimes serves old content despite having fetched new content
Date Wed, 13 Aug 2008 15:52:24 GMT

--- Comment #7 from Ruediger Pluem <>  2008-08-13 08:52:23 PST ---
(In reply to comment #6)
> Created an attachment (id=22441)
 --> ( [details]
> iterate over buckets in a brigade to find eos


> For the second race condition, Using remove_url the first time in
> cache_store_content should work, but I am concerned that remove_url is not
> light weight enough. (It deletes the headerfile, datafile and the directories
> if empty, while what I require is to just remove headers before the caching is
> started.)
> What would you suggest? Is there a better way? or would it be better to add a
> 'remove_headers' method to the cache provider interface?

I guess I was partly wrong with this race condition. It is not that large as I
anticipated first, because during opening the entity in open_entity where the
headers are read the fd for the datafile is also opened.
As we do a move later on to move the new body from the temporary file to
the new datafile location this should not harm. The open fd still references
to the old body datafile and the old body datafile should be gone after all fds
to it should be closed.
But of course there is still a possibility that the body file switches when the
old headers are read in open_entity and before opening the old datafile.
I currently have no good idea how to avoid this race.
Calling remove_url the first time in cache_store_content is IMHO a bad idea as
this can have severe performance implication if the delivery of the new content
takes a long time for whatever reason (slow client, slow backend). So this is
no way to go.

Configure bugmail:
------- You are receiving this mail because: -------
You are the assignee for the bug.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message