<?xml version="1.0" encoding="UTF-8"?> 
<?xml-stylesheet href="https://dev.horde.org/themes/horde//default/feed-rss.xsl" type="text/xsl"?> 
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"> 
 <channel> 
  <title>Can&#039;t change app-level access perms without disabling or manually clearing cache</title> 
  <pubDate>Fri, 10 Apr 2026 13:36:22 +0000</pubDate> 
  <link>https://bugs.horde.org/ticket/12416</link> 
  <atom:link rel="self" type="application/rss+xml" title="Can&#039;t change app-level access perms without disabling or manually clearing cache" href="https://bugs.horde.org/ticket/12416/rss" /> 
  <description>Can&#039;t change app-level access perms without disabling or manually clearing cache</description> 
 
   
   
  <item> 
   <title>I have Horde setup to use hash table and Redis. 

If I cha</title> 
   <description>I have Horde setup to use hash table and Redis. 

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 &quot;redis-cli flushall&quot; 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-&gt;clear() /usr/bin/horde-clear-cache:50
2. Horde_Cache_Storage_Hashtable-&gt;clear() /usr/share/pear/Horde/Cache.php:164
3. Horde_HashTable_Predis-&gt;clear() /usr/share/pear/Horde/Cache/Storage/Hashtabl
4. Predis\Client-&gt;keys() /usr/share/pear/Horde/HashTable/Predis.php:142
5. Predis\Client-&gt;__call() /usr/share/pear/Horde/HashTable/Predis.php:142
6. Predis\Connection\PredisCluster-&gt;executeCommand() /usr/share/pear/Predis/Cli
7. Predis\Connection\PredisCluster-&gt;getConnection() /usr/share/pear/Predis/Conn

====================


</description> 
   <pubDate>Fri, 28 Jun 2013 04:12:06 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79069</link> 
  </item> 
   
  <item> 
   <title>Do you see this with other caching backends too?</title> 
   <description>Do you see this with other caching backends too?</description> 
   <pubDate>Tue, 02 Jul 2013 22:28:36 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79110</link> 
  </item> 
   
  <item> 
   <title>&gt; Fatal Error:
&gt; Cannot use KEYS with a cluster of connecti</title> 
   <description>&gt; Fatal Error:
&gt; Cannot use KEYS with a cluster of connections
&gt; In /usr/share/pear/Predis/Connection/PredisCluster.php on line 135

For some reason are you using a Redis cluster?  That&#039;s a fairly 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.</description> 
   <pubDate>Tue, 09 Jul 2013 23:04:28 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79205</link> 
  </item> 
   
  <item> 
   <title>Probably need http://redis.io/topics/data-types#sets</title> 
   <description>Probably need http://redis.io/topics/data-types#sets</description> 
   <pubDate>Tue, 09 Jul 2013 23:04:57 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79206</link> 
  </item> 
   
  <item> 
   <title>&gt;&gt; Fatal Error:
&gt;&gt; Cannot use KEYS with a cluster of connec</title> 
   <description>&gt;&gt; Fatal Error:
&gt;&gt; Cannot use KEYS with a cluster of connections
&gt;&gt; In /usr/share/pear/Predis/Connection/PredisCluster.php on line 135
&gt;
&gt; For some reason are you using a Redis cluster?  That&#039;s a fairly 
&gt; uncommon use case and most likely indicates your configuration is 
&gt; incorrect.  (Not to mention this limitation is mentioned nowhere in 
&gt; the API).
&gt;
&gt; Even so, it looks like we will have to keep a list of Horde related 
&gt; cache keys in order to clear them.

No, not using a Redis cluster. Just a very simple Redis install, then started with app defaults. 

Re Jan&#039;s question, I have not had time to test with other caching backends at this stage. </description> 
   <pubDate>Tue, 09 Jul 2013 23:28:59 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79207</link> 
  </item> 
   
  <item> 
   <title>Changes have been made in Git (master):

commit f47d1533998d</title> 
   <description>Changes have been made in Git (master):

commit f47d1533998d3c270f2d4beb1de266e423a0411f
Author: Michael M Slusarz &lt;slusarz@horde.org&gt;
Date:   Mon Jul 15 14:06:32 2013 -0600

    [mms] Workaround broken redis installations that don&#039;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</description> 
   <pubDate>Mon, 15 Jul 2013 20:17:37 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79316</link> 
  </item> 
   
  <item> 
   <title>&gt; No, not using a Redis cluster. Just a very simple Redis in</title> 
   <description>&gt; No, not using a Redis cluster. Just a very simple Redis install, then 
&gt; started with app defaults.

You are SOL then.  Your version of redis is probably too old.  There is no reason keys() should not work (and I can&#039;t reproduce).

Regardless, as has been said multiple times before - you can&#039;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&#039;t support keys(), you will have to manually purge the backend yourself through some other mechanism.</description> 
   <pubDate>Mon, 15 Jul 2013 20:17:47 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79317</link> 
  </item> 
   
  <item> 
   <title>&gt;&gt; No, not using a Redis cluster. Just a very simple Redis i</title> 
   <description>&gt;&gt; No, not using a Redis cluster. Just a very simple Redis install, then
&gt;&gt; started with app defaults.
&gt;
&gt; You are SOL then.

?? Huh?

&gt; Your version of redis is probably too old.  There 
&gt; is no reason keys() should not work (and I can&#039;t reproduce).

2.4.10, released March 2012, so not very old. Pear redis is up to date. 

&gt;
&gt; Regardless, as has been said multiple times before - you can&#039;t be 
&gt; using memcache-like caching mechanisms and expect to clear the cache. 
&gt;  This is not how those backends were designed.  If you have a redis 
&gt; backend that doesn&#039;t support keys(), you will have to manually purge 
&gt; the backend yourself through some other mechanism.

So, some questions please:

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&#039;t &quot;expect to clear the cache&quot;. I have no issues at all clearing the cache, as I stated earlier: &quot;...if I run &quot;redis-cli flushall&quot; after making the permissions change it works.&quot; 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 &quot;manually purge the backend...&quot;?

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 - 

&quot;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.&quot;</description> 
   <pubDate>Mon, 15 Jul 2013 23:17:45 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79322</link> 
  </item> 
   
  <item> 
   <title>&gt; Changes have been made in Git (master):
&gt;
&gt; commit f47d1</title> 
   <description>&gt; Changes have been made in Git (master):
&gt;
&gt; commit f47d1533998d3c270f2d4beb1de266e423a0411f
&gt; Author: Michael M Slusarz &lt;slusarz@horde.org&gt;
&gt; Date:   Mon Jul 15 14:06:32 2013 -0600
&gt;
&gt;     [mms] Workaround broken redis installations that don&#039;t support 
&gt; the keys() command (Bug #12416).
&gt;
&gt;  framework/HashTable/lib/Horde/HashTable/Predis.php |   14 ++++++++------
&gt;  framework/HashTable/package.xml                    |    4 ++--
&gt;  2 files changed, 10 insertions(+), 8 deletions(-)
&gt;
&gt; http://git.horde.org/horde-git/-/commit/f47d1533998d3c270f2d4beb1de266e423a0411f

And what I should have said already - thank you Michael, I will give the git changes a try and see what they do. :)</description> 
   <pubDate>Mon, 15 Jul 2013 23:19:06 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79323</link> 
  </item> 
   
  <item> 
   <title>The changes as released in the latest HashTable have removed</title> 
   <description>The changes as released in the latest HashTable have removed the error presented from running horde-clear-cache. 

It has also resolved the original issue - changes to permissions are applied immediately.

Thanks.

</description> 
   <pubDate>Thu, 18 Jul 2013 11:09:28 +0000</pubDate> 
   <link>https://bugs.horde.org/ticket/12416#t79415</link> 
  </item> 
   
   
 
 </channel> 
</rss> 
