用自带的缓存,使用memcache等存储,命中旧数据的问题 #341

Closed
opened 2016-01-30 06:25:12 +00:00 by hsyan2008 · 1 comment
hsyan2008 commented 2016-01-30 06:25:12 +00:00 (Migrated from github.com)

说下应用场景:
有个定时任务,获取表里未处理的数据(状态是N),然后标记为待处理R,处理完毕后标记为Y
当标记为R的时候,服务重启了,就需要把所有为R的标记为N,然后执行定时任务
重现:
第一次启动服务,修改状态R为N,然后读取状态N的数据,标记为R,异步处理,这时缓存map和memcache都为空,执行正常
重启服务,修改状态R为N,然后读取状态N的数据,发现读不到从状态R改回N的那部分数据,我猜测是读取列表的SQL命中缓存了
后面不断重启服务,都会重现这个问题

说下应用场景: 有个定时任务,获取表里未处理的数据(状态是N),然后标记为待处理R,处理完毕后标记为Y 当标记为R的时候,服务重启了,就需要把所有为R的标记为N,然后执行定时任务 重现: 第一次启动服务,修改状态R为N,然后读取状态N的数据,标记为R,异步处理,这时缓存map和memcache都为空,执行正常 重启服务,修改状态R为N,然后读取状态N的数据,发现读不到从状态R改回N的那部分数据,我猜测是读取列表的SQL命中缓存了 后面不断重启服务,都会重现这个问题
lunny removed this from the 1.1.1 milestone 2020-03-24 01:45:18 +00:00

This cannot be reproduced so I close this one. Please feel free to reopen it.

This cannot be reproduced so I close this one. Please feel free to reopen it.
lunny closed this issue 2020-03-24 01:45:38 +00:00
lunny removed the
kind
bug
need
test
labels 2020-03-24 01:45:45 +00:00
Sign in to join this conversation.
No Milestone
No Assignees
1 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: xorm/xorm#341
No description provided.