修改了幂等性异常提示
This commit is contained in:
@ -64,7 +64,6 @@ public class IdempotentAspect {
|
||||
}
|
||||
Idempotent idempotent = method.getAnnotation(Idempotent.class);
|
||||
|
||||
|
||||
/* key : url + 参数列表作为区分 */
|
||||
String url = request.getRequestURL().toString();
|
||||
String argString = JsonUtils.objectToJson(Arrays.asList(joinPoint.getArgs()));
|
||||
@ -87,9 +86,8 @@ public class IdempotentAspect {
|
||||
synchronized (this) {
|
||||
boolean submitAble = redisTemplate.opsForValue().setIfAbsent(key, value, expireTime, timeUnit);
|
||||
if (!submitAble) {
|
||||
CommonExceptionEnum.FRAME_EXCEPTION_COMMON_DATA_OTHER_ERROR.customValidName("[idempotent]:" + info,true);
|
||||
}
|
||||
else {
|
||||
CommonExceptionEnum.FRAME_EXCEPTION_COMMON_DATA_OTHER_ERROR.customValidName(info, true);
|
||||
} else {
|
||||
log.info("[idempotent]:has stored key={},value={},expireTime={}{},now={}", key, value, expireTime,
|
||||
timeUnit, LocalDateTime.now().toString());
|
||||
}
|
||||
|
Reference in New Issue
Block a user