We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
spring-boot-dependencies: 2.6.13 jetcache-starter-redi: 2.7.4
jetcache.remote.default.type=redis jetcache.remote.default.broadcastChannel=projectA
broadcastChannel 不起作用 ,一个节点修改 local+remote 然后立刻获取 显示生效, 但一个节点 local 还是之前的数据
The text was updated successfully, but these errors were encountered:
那是个总开关,不能所有的缓存更新都广播。注解上还需要打开syncLocal,才会生效
Sorry, something went wrong.
@cached(name = "user", key = "#username", expire = 3600, localExpire = 180, syncLocal = true, cacheType = CacheType.BOTH) 也是不起作用
同一个问题
@cached(name = "user", key = "#username", expire = 3600, localExpire = 180, syncLocal = true, cacheType = CacheType.BOTH) 也是不起作用 我刚开始也是不生效,找了还就才发现我是自己写了个Configuration(Spring Boot)显式的初始化全局一次性初始化cache的导致未初始化时的syncLocal没有指定导致的。 推荐检查思路: 1、首先检查redis是否开启的事件通知,配置文件(通常是redis.conf)中notify-keyspace-events我设置值是Egx 2、检查你的代码中@cached中是否开启syncLocal = true(我看你已经开启了) 3、如果你是显式的初始化cache,查看你的代码中是否使用QuickConfig同CacheManager的getOrCreateCache(QuickConfig config)来初始化cache,初始化时的QuickConfig.builder中有个参数是syncLocal需要显示指定为true(默认未指定就是false,此处不指定你注解中如何设置没用)。
No branches or pull requests
spring-boot-dependencies: 2.6.13
jetcache-starter-redi: 2.7.4
jetcache.remote.default.type=redis
jetcache.remote.default.broadcastChannel=projectA
broadcastChannel 不起作用 ,一个节点修改 local+remote 然后立刻获取 显示生效, 但一个节点 local 还是之前的数据
The text was updated successfully, but these errors were encountered: