How zalando/riptide works
Main Components Overview
The system should be represented as a layered architecture with the following main components:
a. Core Layer:
• HTTP Client Core (riptide-core)
• Request/Response Handling
• Plugin System
• Thread Pool Management
b. Integration Layer:
• Spring Boot Integration (riptide-spring-boot-starter)
• Authentication (riptide-auth)
• Monitoring/Metrics (riptide-micrometer, riptide-opentelemetry, riptide-opentracing)
• Resilience Features (riptide-failsafe, riptide-faults)
c. Extension Layer:
• Streaming Support (riptide-stream)
• Problem Handling (riptide-problem)
• SOAP Support (riptide-soap)
• Compression (riptide-compression)
Component Relationships
a. Core Flow:
Client Application -> Riptide Core -> HTTP Client (Apache/OkHttp) -> External Services
b. Plugin Chain:
Request -> Authorization -> Failsafe -> Metrics -> Tracing -> Core Processing
Detailed Elements
Specific components with appropriate symbols:
a. Infrastructure Components:
• Thread Pools (bounded/unbounded queues)
• Connection Pools
• Request Factory
b. Processing Components:
• Message Converters
• Route Handlers
• Response Dispatchers
• Plugin Chain
c. Resilience Components:
• Circuit Breaker
• Retry Mechanism
• Backup Requests
• Timeout Handling
Key Interactions to Highlight
a. Request Flow:
Client -> Thread Pool -> Plugin Chain -> HTTP Client -> External Service
b. Response Flow:
External Service -> HTTP Client -> Response Router -> Callback Handler
c. Resilience Pattern:
Request -> Failsafe Plugin -> [Retry/Circuit Breaker] -> Actual Request