3.9K Star 18.4K Fork 5.3K

卓源软件 / JeeSite 4.x and 5.x

 / 详情

在CacheUtils.put()中timeToLiveInSeconds 非3600 报错

已完成
创建于  
2019-09-16 17:45

该问题是怎么引起的?

在CacheUtils.put()中timeToLiveInSeconds 非3600 就会报错

重现步骤


CacheUtils.put(loginUserToken, token,user.getLoginCode(),7200);

报错信息

"Region [loginUserToken] TTL 3600 not match with 7200"

评论 (3)

harbor 创建了任务

缓存最多存1小时吗?

我也遇到该问题望解决

缓存名称只能初次设置超期时间才有效。建议在 j2cache.properties 文件里设置更容易管理,如下:

#########################################
# Caffeine configuration
# caffeine.region.[name] = size, xxxx[s|m|h|d]
#########################################

#caffeine.properties = /config/caffeine.properties
caffeine.region.default = 10000, 1h
caffeine.region.sessionCache = 100000, 12h

caffeine.region.你的缓存名字= 对象数, 超期时间
卓源软件 任务状态待办的 修改为已完成

登录 后才可以发表评论

状态
负责人
里程碑
Pull Requests
关联的 Pull Requests 被合并后可能会关闭此 issue
分支
开始日期   -   截止日期
-
置顶选项
优先级
参与者(3)
6732 thinkgem 1651893329
Java
1
https://gitee.com/thinkgem/jeesite4.git
git@gitee.com:thinkgem/jeesite4.git
thinkgem
jeesite4
JeeSite 4.x and 5.x

搜索帮助