No Code Attached Yet
avatar yossibeck
yossibeck
29 Jun 2024

in this file
libraries/src/Cache/Storage/RedisStorage.php

Steps to reproduce the issue

  1. setup a redis server
  2. define that server as a cache_handler + session_handler
  3. use the same server for redis_server_host + session_redis_server_host
  4. start caching stuff - and login
    on the first delete of a non group cache - you'll lose all of your sessions
    the easiest way to do that is to connect to redis with
redis-cli -h <host name>
HOST-NAME:PORT>monitor

and you'll see after a while these commands:

HOST-NAME:PORT>KEYS "*"
HOST-NAME:PORT>DEL <session-id 1>
HOST-NAME:PORT>DEL <session-id 2>
HOST-NAME:PORT>DEL <session-id 3>
....

Expected result

only -cache- keys should be deleted

Actual result

all keys are deleted from the server

System information (as much as possible)

Additional comments

if we set TTL - why do we even need the code going and deleting the keys ?

avatar yossibeck yossibeck - open - 29 Jun 2024
avatar joomla-cms-bot joomla-cms-bot - change - 29 Jun 2024
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 29 Jun 2024
avatar yossibeck yossibeck - change - 29 Jun 2024
The description was changed
avatar yossibeck yossibeck - edited - 29 Jun 2024
avatar richard67 richard67 - change - 29 Jun 2024
Status New Closed
Closed_Date 0000-00-00 00:00:00 2024-06-29 18:00:11
Closed_By richard67
avatar richard67 richard67 - close - 29 Jun 2024
avatar richard67
richard67 - comment - 29 Jun 2024

Closing as having a pull request. See #43719 .

@yossibeck In case if you are not familiar yet with our practice: We close an issue when there is a PR to solve it. That's different to how some other repositories handle it. And if you want to open an issue and already know you will solve it with a PR, it does not even need the issue. Just the PR is sufficient in that case.

Thanks for reporting the issue and creating this PR.

avatar yossibeck
yossibeck - comment - 29 Jun 2024

@richard67 - thanks for clarifying
the only reason I see for this issue is this question:
if we set TTL - why do we even need the code going and deleting the keys ?

avatar richard67
richard67 - comment - 29 Jun 2024

@richard67 - thanks for clarifying the only reason I see for this issue is this question: if we set TTL - why do we even need the code going and deleting the keys ?

@yossibeck Well, if it is just a question then the right place would be in discussions.

Add a Comment

Login with GitHub to post a comment