@@ -2,22 +2,15 @@ resilience4j:
22 circuitbreaker :
33 configs :
44 default :
5- # Sliding Window 설정
6- slidingWindowType : COUNT_BASED
7- slidingWindowSize : 10 # 최근 10개 호출을 기준으로 판단
8- minimumNumberOfCalls : 5 # 최소 5번 호출 후 Circuit Breaker 작동
9-
10- # 실패율 임계값
11- failureRateThreshold : 50 # 실패율 50% 이상이면 OPEN
12- slowCallRateThreshold : 50 # 느린 호출 50% 이상이면 OPEN
13- slowCallDurationThreshold : 2s # 2초 이상 걸리면 느린 호출로 간주
14-
15- # Circuit Breaker 상태 전환
16- waitDurationInOpenState : 10s # OPEN 상태에서 10초 후 HALF_OPEN으로 전환
17- permittedNumberOfCallsInHalfOpenState : 3 # HALF_OPEN에서 3번 테스트
5+ slidingWindowType : TIME_BASED
6+ slidingWindowSize : 30
7+ minimumNumberOfCalls : 5
8+ failureRateThreshold : 50
9+ slowCallRateThreshold : 50
10+ slowCallDurationThreshold : 2s
11+ waitDurationInOpenState : 10s
12+ permittedNumberOfCallsInHalfOpenState : 3
1813 automaticTransitionFromOpenToHalfOpenEnabled : true
19-
20- # 예외 설정
2114 registerHealthIndicator : true
2215 recordExceptions :
2316 - java.util.concurrent.TimeoutException
@@ -28,17 +21,19 @@ resilience4j:
2821 instances :
2922 pgSimulator :
3023 baseConfig : default
31- failureRateThreshold : 60 # PG는 60% 실패율까지 허용 (40% 실패율 고려)
32- slowCallDurationThreshold : 1s # PG는 1초 이상이면 느린 호출
33- waitDurationInOpenState : 15s # OPEN 시 15초 대기
24+ slidingWindowSize : 20
25+ minimumNumberOfCalls : 3
26+ failureRateThreshold : 60
27+ slowCallDurationThreshold : 1s
28+ waitDurationInOpenState : 15s
3429
3530 retry :
3631 configs :
3732 default :
38- maxAttempts : 3 # 최대 3번 재시도
39- waitDuration : 500ms # 재시도 간격 500ms
40- enableExponentialBackoff : true # 지수 백오프 활성화
41- exponentialBackoffMultiplier : 2 # 2배씩 증가
33+ maxAttempts : 3
34+ waitDuration : 500ms
35+ enableExponentialBackoff : true
36+ exponentialBackoffMultiplier : 2
4237 retryExceptions :
4338 - java.util.concurrent.TimeoutException
4439 - org.springframework.web.client.ResourceAccessException
@@ -48,15 +43,14 @@ resilience4j:
4843 instances :
4944 pgSimulator :
5045 baseConfig : default
51- maxAttempts : 1 # PG는 재시도 안 함 (멱등성 보장 어려움)
52- # Payment 엔티티 저장 후 requiresRetry 플래그로 수동 재시도 처리
46+ maxAttempts : 1
5347 waitDuration : 300ms
5448
5549 timelimiter :
5650 configs :
5751 default :
58- timeoutDuration : 3s # 기본 타임아웃 3초
52+ timeoutDuration : 3s
5953 cancelRunningFuture : true
6054 instances :
6155 pgSimulator :
62- timeoutDuration : 2s # PG 호출은 2초 타임아웃 (요청 지연 100-500ms 고려)
56+ timeoutDuration : 2s
0 commit comments