无序Uuid
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package com.czg.config;
|
||||
|
||||
import cn.hutool.core.util.IdUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import jakarta.servlet.*;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
@@ -28,7 +29,7 @@ public class CorsFilter implements Filter {
|
||||
if(copyOfContextMap == null){
|
||||
copyOfContextMap = new HashMap<>();
|
||||
}
|
||||
copyOfContextMap.put("traceId",applicationName + IdUtil.getSnowflakeNextId());
|
||||
copyOfContextMap.put("traceId",applicationName + IdUtil.fastSimpleUUID());
|
||||
MDC.setContextMap(copyOfContextMap);
|
||||
HttpServletResponse response = (HttpServletResponse) resp;
|
||||
HttpServletRequest reqs = (HttpServletRequest) req;
|
||||
|
||||
Reference in New Issue
Block a user