Skip to content

IAV-691/Enhance exception handling with centralized error codes

salaheddine zidani a demandé de fusionner feature/IAV-691 vers develop

Summary

This MR introduces a centralized business error code system for the iavia-agent-service-customer-care microservice, improving traceability, consistency, and maintainability of exception handling.

Changes

New Components

Component Description
BusinessErrorCode enum Centralized error codes following CUSTOMER-CARE-SERVICE-NNN pattern
BusinessErrorCodeTest Unit tests ensuring code uniqueness, range compliance, and message quality

Refactored Layers

  • Helpers: AgentCreationHelper, AgentValidationHelper, UserHelper, WebhookHelper
  • Inter-service communication: FileManagerServiceImpl, N8nServiceImpl, UserServiceImpl
  • Business services: All service implementations updated

Alignment

This implementation aligns with the exception management improvements made in mc-starter.

Testing

  • All error codes validated for uniqueness
  • Code format validated against pattern CUSTOMER-CARE-SERVICE-\d{3}$
  • Code numbers validated within assigned category ranges
  • Messages validated for quality (uniqueness, formatting, minimum length)

Related

Closes IAV-691

Modification effectuée par salaheddine zidani

Rapports de requête de fusion