From fd83ac85641cec0e2e4fa861d0a9ec10e44d9aa7 Mon Sep 17 00:00:00 2001 From: kgy1008 Date: Mon, 2 Dec 2024 06:38:17 +0900 Subject: [PATCH] [refac] change retry properties --- .../hankkiserver/api/store/service/HeartCommandService.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/org/hankki/hankkiserver/api/store/service/HeartCommandService.java b/src/main/java/org/hankki/hankkiserver/api/store/service/HeartCommandService.java index 1929e92a..a84dd000 100644 --- a/src/main/java/org/hankki/hankkiserver/api/store/service/HeartCommandService.java +++ b/src/main/java/org/hankki/hankkiserver/api/store/service/HeartCommandService.java @@ -30,7 +30,7 @@ public class HeartCommandService { private final StoreFinder storeFinder; @Retryable( - retryFor = ObjectOptimisticLockingFailureException.class, + noRetryFor = {ConflictException.class, NotFoundException.class}, notRecoverable = {ConflictException.class, NotFoundException.class}, backoff = @Backoff(delay = 100)) @Transactional @@ -44,7 +44,7 @@ public HeartResponse createHeart(final HeartCommand heartCommand) { } @Retryable( - retryFor = ObjectOptimisticLockingFailureException.class, + noRetryFor = {NotFoundException.class, ConflictException.class, BadRequestException.class}, notRecoverable = {NotFoundException.class, ConflictException.class, BadRequestException.class}, backoff = @Backoff(delay = 100)) @Transactional