Summary | Can't change app-level access perms without disabling or manually clearing cache |
Queue | Horde Base |
Queue Version | 5.1.1 |
Type | Bug |
State | Resolved |
Priority | 1. Low |
Owners | slusarz (at) horde (dot) org |
Requester | simon (at) simonandkate (dot) net |
Created | 06/28/2013 (4400 days ago) |
Due | |
Updated | 07/18/2013 (4380 days ago) |
Assigned | 07/02/2013 (4396 days ago) |
Resolved | 07/15/2013 (4383 days ago) |
Github Issue Link | |
Github Pull Request | |
Milestone | |
Patch | No |
presented from running horde-clear-cache.
It has also resolved the original issue - changes to permissions are
applied immediately.
Thanks.
the git changes a try and see what they do. :)
started with app defaults.
keys() should not work (and I can't reproduce).
using memcache-like caching mechanisms and expect to clear the
cache. This is not how those backends were designed. If you have a
redis backend that doesn't support keys(), you will have to manually
purge the backend yourself through some other mechanism.
1. A google search for memcache horde clear cache came back with
nothing that I could see as relevant. Could you please point me in the
direction of the discussion, or summarise?
2. Can you clarify your statement that I can't "expect to clear the
cache". I have no issues at all clearing the cache, as I stated
earlier: "...if I run "redis-cli flushall" after making the
permissions change it works." That runs without error, and clears the
redis cache, as I would expect. The issue is that I am having to do
that manually when I make a change in Horde, rather than Horde doing
it automatically when I make a change that results in stale cache.
3. If Horde is configured to use redis, does running horde-clear-cache
call a redis-cli flushall? What redis mechanism is called to clear the
cache?
4. Does making a change in Horde that is likely to be impacted by
stale cache (e.g. a permissions change such as that described here)
automatically attempt to clear the cache? In other words, if redis
cache was working correctly (i.e. supports keys()), would a change in
permissions such as I have done in this ticket automatically clear the
cache, thus not requiring me to "manually purge the backend..."?
If a newer version of redis will result in automatic cache clearing,
then I will happily upgrade it. If not, then my reasoning behind this
ticket still stands -
"If it is too complex to automate a cache-clear with permissions
changes, perhaps an Apply button that does a cache-clear? Or at the
very least commentary on the permissions page that changes may not
take effect until cache is cleared."
State ⇒ Resolved
Assigned to Michael Slusarz
then started with app defaults.
is no reason keys() should not work (and I can't reproduce).
Regardless, as has been said multiple times before - you can't be
using memcache-like caching mechanisms and expect to clear the cache.
This is not how those backends were designed. If you have a redis
backend that doesn't support keys(), you will have to manually purge
the backend yourself through some other mechanism.
commit f47d1533998d3c270f2d4beb1de266e423a0411f
Author: Michael M Slusarz <slusarz@horde.org>
Date: Mon Jul 15 14:06:32 2013 -0600
[mms] Workaround broken redis installations that don't support
the keys() command (
Bug #12416).framework/HashTable/lib/Horde/HashTable/Predis.php | 14 ++++++++------
framework/HashTable/package.xml | 4 ++--
2 files changed, 10 insertions(+), 8 deletions(-)
http://git.horde.org/horde-git/-/commit/f47d1533998d3c270f2d4beb1de266e423a0411f
started with app defaults.
Re Jan's question, I have not had time to test with other caching
backends at this stage.
Cannot use KEYS with a cluster of connections
In /usr/share/pear/Predis/Connection/PredisCluster.php on line 135
uncommon use case and most likely indicates your configuration is
incorrect. (Not to mention this limitation is mentioned nowhere in
the API).
Even so, it looks like we will have to keep a list of Horde related
cache keys in order to clear them.
State ⇒ Feedback
Milestone ⇒
State ⇒ Unconfirmed
Patch ⇒ No
Queue ⇒ Horde Base
Summary ⇒ Can't change app-level access perms without disabling or manually clearing cache
Type ⇒ Bug
Priority ⇒ 1. Low
If I change application level access permissions, the changes are not visible
If I disable Horde Cache, any changes to permissions apply
immediately. Also if I run "redis-cli flushall" after making the
permissions change it works.
It would appear that caching is not being notified of the changes.
If it is too complex to automate a cache-clear with permissions
changes, perhaps an Apply button that does a cache-clear? Or at the
very least commentary on the permissions page that changes may not
take effect until cache is cleared.
I found this issue applied while setting / unsetting Guest permissions
to Ansel and also to Wicked.
Whilst chasing down this one I also came on this:
horde-clear-cache
Are you sure you want to expire all cached data?
(y) Yes
(n) No
Type your choice [n]: y
====================
Fatal Error:
Cannot use KEYS with a cluster of connections
In /usr/share/pear/Predis/Connection/PredisCluster.php on line 135
1. Horde_Cache->clear() /usr/bin/horde-clear-cache:50
2. Horde_Cache_Storage_Hashtable->clear() /usr/share/pear/Horde/Cache.php:164
3. Horde_HashTable_Predis->clear()
/usr/share/pear/Horde/Cache/Storage/Hashtabl
4. Predis\Client->keys() /usr/share/pear/Horde/HashTable/Predis.php:142
5. Predis\Client->__call() /usr/share/pear/Horde/HashTable/Predis.php:142
6. Predis\Connection\PredisCluster->executeCommand()
/usr/share/pear/Predis/Cli
7. Predis\Connection\PredisCluster->getConnection()
/usr/share/pear/Predis/Conn
====================