Rodrigo Verdiani d398ac8f06 feat(catalog): implement custom circuit breaker for external APIs
Replace Spring Retry CircuitBreakerRetryPolicy with lightweight custom
implementation using ConcurrentHashMap and AtomicReference<Instant>.
Avoids classpath conflict between spring-retry and spring-aspects
RetryTemplate, and eliminates stacked retries with Feign @Retryable.

Behavior: circuit opens for 30s after first failure, returns
fallback immediately without hitting external APIs. Transitions
through CLOSED -> OPEN -> HALF_OPEN -> CLOSED automatically.

Applied to AniListService and MyAnimeListService for all
searchMangaByTitle, getMangasByTitle, and getMangaDataById calls.
2026-07-14 14:12:01 -03:00
..