[wp-trac] [WordPress Trac] #4179: wp object cache ignores custom
expire time
WordPress Trac
wp-trac at lists.automattic.com
Sun Apr 22 05:34:54 GMT 2007
#4179: wp object cache ignores custom expire time
----------------------------+-----------------------------------------------
Reporter: DD32 | Owner: anonymous
Type: defect | Status: new
Priority: normal | Milestone: 2.3
Component: Administration | Version: 2.2
Severity: normal | Keywords: has-patch, cache, object cache
----------------------------+-----------------------------------------------
The current implementation of the WordPress object cache ignores the
passed $expire value, And instead every object defaults to the hard-coded
value of 900 seconds, unless defined otherwise.
'''Suggested Solution:'''
Set the modification date on the cache files to the time in the future
when we want the object to expire.
'''Implementation:'''
I have included a patch to allow this to happen, any Cache calls which do
not specify an expirary time are given the default expire time still, and
there seem no problems setting file modification timestamps to the future.
Also in this patch i cleaned up the formatting, Changed any remaining '/'
to DIRECTORY_SEPARATOR to keep in line with the rest of the file.
(DIRECTORY_SEPARATOR was added in PHP 4.3.0, I assume thats WP's baseline
as it was allready in use in the file). Should also fix any remaining
issues with Windows not liking the Unix directory structure marker.
Also fixed a </P> nesting error in class->stats()
--
Ticket URL: <http://trac.wordpress.org/ticket/4179>
WordPress Trac <http://trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list