You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
IMO the behavior should be changed. If that's not possible due to the breaking change, it should be documented with a warning to avoid unexpected namespace pollution.
Some might argue that finding all active sessions (cross namespaces) using a single key is a feature. But I think that's a corner case.
Environment Information
Operating System: MacOS 10.15.5
Micronaut Version: 1.3.7
JDK Version: OpenJDK 11.0.7
Example Application
TODO: link to github repository with example that reproduces the issue
The text was updated successfully, but these errors were encountered:
Task List
Steps to Reproduce
Change the default namespace for session keys in Redis:
Sessions are stored in Redis with the namespace prefix, but the key holding active sessions still uses the default prefix
micronaut.session:
If you want active sessions to be under the same namespace you must also change
active-sessions-key
to include your namespace prefix, like this:Expected Behaviour
I expected active sessions to be stored with the namespace prefix when I configured namespace.
Actual Behaviour
Active sessions uses the default prefix "micronaut.session:' unless you explicitly configure
micronaut.session.http.redis.active-sessions-key
.The key is prefixed with namespace when the class is instantiated but it is not changed when namespace is changed.
https://github.com/micronaut-projects/micronaut-redis/blob/master/redis-lettuce/src/main/java/io/micronaut/configuration/lettuce/session/RedisHttpSessionConfiguration.java#L42
IMO the behavior should be changed. If that's not possible due to the breaking change, it should be documented with a warning to avoid unexpected namespace pollution.
Some might argue that finding all active sessions (cross namespaces) using a single key is a feature. But I think that's a corner case.
Environment Information
Example Application
The text was updated successfully, but these errors were encountered: