[Tickets #13085] Re: Use memcache instead of distributed hashtable in $conf[cache][driver]
noreply at bugs.horde.org
noreply at bugs.horde.org
Mon Mar 31 14:36:05 UTC 2014
DO NOT REPLY TO THIS MESSAGE. THIS EMAIL ADDRESS IS NOT MONITORED.
Ticket URL: http://bugs.horde.org/ticket/13085
------------------------------------------------------------------------------
Ticket | 13085
Updated By | Michael Rubinsky <mrubinsk at horde.org>
Summary | Use memcache instead of distributed hashtable in
| $conf[cache][driver]
Queue | Horde Framework Packages
Version | Git master
Type | Bug
State | Feedback
Priority | 1. Low
Milestone |
Patch |
Owners | Michael Slusarz
------------------------------------------------------------------------------
Michael Rubinsky <mrubinsk at horde.org> (2014-03-31 14:36) wrote:
>>> It is probably due to my limited command of the PHP language, but I
>>> assumed that the below function would set $lifetime to '0' if the
>>> parameter is not passed (similar to C++):
>>
>> No, you are correct in your logic, but this class is ONLY for
>> memcache, not other cache drivers. As already stated, memcache
>> doesn't use/need the lifetime parameter here so the default value of
>> zero is irrelevant.
>
> This is how *every* cache driver is defined:
>
> /usr/share/php5/PEAR/Horde/Cache/Storage/Apc.php: public function
No, this is how every Horde_Cache_Storage_* driver is defined. Client
code uses Horde_Cache, which delegates the storage to the configured
storage driver. Horde_Cache::set() defaults to $lifetime == null,
which if you read the code you can see will lead to the storage driver
being sent the configured default value for $lifetime.
More information about the bugs
mailing list