1
0
mirror of https://github.com/apache/httpd.git synced 2025-11-06 16:49:32 +03:00
Commit Graph

13 Commits

Author SHA1 Message Date
Graham Leggett
ca9d2ae938 mod_cache: Add a discrete commit_entity() provider function within the
mod_cache provider interface which is called to indicate to the
provider that caching is complete, giving the provider the opportunity
to commit temporary files permanently to the cache in an atomic
fashion. Move all "rename" functionality of temporary files to permanent
files within mod_disk_cache from ad hoc locations in the code to the
commit_entity() function. Instead of reusing the same variables for
temporary file handling in mod_disk_cache, introduce separate discrete
structures for each of the three cache file types, the headers file,
vary file and data file, so that the atomic rename of all three file
types within commit_entity() becomes possible. Replace the inconsistent
use of error cleanups with a formal set of pool cleanups attached to
a subpool, which is destroyed on error.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@997545 13f79535-47bb-0310-9956-ffa450edef68
2010-09-16 00:05:14 +00:00
Graham Leggett
721d19a58b Handle the case where a brigade might have buckets following the eos
bucket. In this case the cache provider passes all buckets through as
is once the cached entry is marked as done.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@996713 13f79535-47bb-0310-9956-ffa450edef68
2010-09-13 22:35:51 +00:00
Graham Leggett
665426645e mod_cache: Change the signature of the store_body() provider function
within the mod_cache provider interface to support an "in" brigade
and an "out" brigade instead of just a single input brigade. This
gives a cache provider the option to consume only part of the brigade
passed to it, rather than the whole brigade as was required before.
This fixes an out of memory and a request timeout condition that would
occur when the original document was a large file. Update the
mod_disk_cache provider implementation to take into account the new API.
Introduce CacheReadSize and CacheReadTime directives to mod_disk_cache
to control the amount of data to attempt to cache before sending the
data on to the client in the "out" brigade.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@996395 13f79535-47bb-0310-9956-ffa450edef68
2010-09-12 23:16:49 +00:00
Graham Leggett
a9f530e317 This time from the top, with three part harmony AND feeling...
Revert the read-while-caching and large-file-crash fixes for mod_disk_cache,
ready to start again.

Reverted: r450105 r450188 r462571 r462601 r462696 r467655 r467684 r468044
r468373 r468409 r470455



git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@502365 13f79535-47bb-0310-9956-ffa450edef68
2007-02-01 21:28:34 +00:00
Paul Querna
832c80e502 Change the default depth and length of directories for mod_disk_cache to a depth of 2, and a length of 2.
Suggested By: noirin


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@491364 13f79535-47bb-0310-9956-ffa450edef68
2006-12-31 02:17:39 +00:00
Graham Leggett
66d027d551 mod_cache: Pass the output filter stack through the store_body()
hook, giving each cache backend the ability to make a better
decision as to how it will allocate the tasks of writing to the
cache and writing to the network. Previously the write to the
cache task needed to be complete before the same brigade was
written to the network, and this caused timing and memory issues
on large cached files. This fix replaces the previous fix for
PR39380.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@468373 13f79535-47bb-0310-9956-ffa450edef68
2006-10-27 13:28:56 +00:00
Graham Leggett
f53558c769 mod_disk_cache: Implement read-while-caching.
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@462696 13f79535-47bb-0310-9956-ffa450edef68
2006-10-11 04:31:18 +00:00
Graham Leggett
a0207d2ff9 mod_disk_cache: Do away with the write-to-file-then-move-in-place
mentality.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@462571 13f79535-47bb-0310-9956-ffa450edef68
2006-10-10 21:17:47 +00:00
Graham Leggett
4116db0d19 mod_disk_cache: Make caching of large files possible on 32bit machines
by determining whether the cached file should be copied on disk rather
than loaded into RAM. PR39380


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@450105 13f79535-47bb-0310-9956-ffa450edef68
2006-09-26 16:26:56 +00:00
Graham Leggett
cbf599cfd7 mod_disk_cache: Make sure that only positive integers are accepted
for the CacheMaxFileSize and CacheMinFileSize parameters in the
config file. PR39380 [Niklas Edmundsson <nikke acc.umu.se>]


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@450042 13f79535-47bb-0310-9956-ffa450edef68
2006-09-26 13:29:09 +00:00
Roy T. Fielding
de659cbed0 update license header text
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@420983 13f79535-47bb-0310-9956-ffa450edef68
2006-07-11 20:33:53 +00:00
Colm MacCarthaigh
dd95d7c37c Update the copyright year in all .c, .h and .xml files
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@395228 13f79535-47bb-0310-9956-ffa450edef68
2006-04-19 12:11:27 +00:00
Andreas Steinmetz
59a68232cc Split mod_disk_cache.c into mod_disk_cache.c and mod_disk_cache.h
to allow inclusion of mod_disk_cache.h in htcacheclean.c.


git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@239406 13f79535-47bb-0310-9956-ffa450edef68
2005-08-23 13:35:00 +00:00