产生新的批次的时候,重新计算
This commit is contained in:
parent
d003bb14e5
commit
0954cb5738
|
|
@ -67,7 +67,7 @@ namespace LY.App.Service
|
|||
await _db.CopyNew().Insertable(entity).SplitTable().ExecuteReturnSnowflakeIdListAsync();
|
||||
//推送报警信息
|
||||
await _pushService.SendMessageToAll(new { msgType = "event", data = entity });
|
||||
await _redisService.DeleteAsync(RedisKeyList.index_data());
|
||||
|
||||
}
|
||||
return new ApiResult();
|
||||
}
|
||||
|
|
@ -141,6 +141,7 @@ namespace LY.App.Service
|
|||
if (batchId == 0)
|
||||
{
|
||||
batchId = SnowFlakeSingle.Instance.NextId();
|
||||
await _redisService.DeleteAsync(RedisKeyList.index_data());
|
||||
}
|
||||
await _redisService.SetAsync(key, batchId, TimeSpan.FromSeconds(timeSpan));
|
||||
return batchId;
|
||||
|
|
|
|||
Loading…
Reference in New Issue