REQ-2453: 优化统计

This commit is contained in:
yanglin 2024-07-10 13:34:59 +08:00
parent 936b24eaab
commit 53e199872d
2 changed files with 3 additions and 3 deletions

View File

@ -28,7 +28,7 @@ public class TemplateCache {
LOCAL.set(new TemplateCache());
}
public static void clear() {
public static void disableCache() {
LOCAL.remove();
}

View File

@ -234,7 +234,7 @@ public class TodoRangeQueryService {
nodes = groupTemplateService.getTodoGroups(request.getAppTerminalType());
return groupTemplateService.collectTemplateCodes(nodes);
} finally {
TemplateCache.clear();
TemplateCache.disableCache();
}
}
@ -287,7 +287,7 @@ public class TodoRangeQueryService {
log.warn("分类统计异常, request={}", request, e);
throw new ServiceException("分类统计, 请稍后重试");
} finally {
TemplateCache.clear();
TemplateCache.disableCache();
}
}