How pagopa/pn-delivery-push works
Main Components
a. Core Service Components:
• Delivery Push Service (Main Application)
• Action Handlers
• Timeline Service
• Notification Service
• Webhook Service
• Legal Facts Service
b. External Integrations:
• Address Manager Client
• Data Vault Client
• External Channel Client
• Paper Channel Client
• Safe Storage Client
• National Registries Client
• Mandate Client
• F24 Client
c. Data Stores:
• DynamoDB Tables (for actions, timeline, documents, webhooks)
• Safe Storage (for documents/attachments)
d. Message Queues:
• SQS Queues (for actions and webhooks)
• Event Bridge
• Kinesis Streams
Architecture Layers
a. API Layer:
• REST Controllers (PnCancellationController, PnDocumentsController, etc.)
• Webhook Controllers
• API Versioning Support
b. Service Layer:
• Business Logic Services
• Workflow Handlers
• Event Handlers
c. Data Access Layer:
• DAO Implementations
• External Client Integrations
Key Workflows to Highlight
a. Notification Processing:
• Digital Workflow
• Analog Workflow
• Mixed Workflow
b. Document Management:
• Legal Facts Generation
• Document Creation
• Attachment Handling
Implementation Details
Create sections showing:
• AWS Infrastructure components
• Spring Boot application structure
• External service integration points
• Data persistence layer
• Event processing flow
Specific Recommendations
• Main service entry points (REST APIs)
• Core business logic components
• External service integrations
• Storage solutions
• Message queues
• Notification workflow processing
• Document handling flow
• Webhook event processing
• Timeline management
Cross-cutting concerns
• Security
• Logging
• Monitoring
• Error handling
• The event-driven nature of the system
• The separation between synchronous and asynchronous operations
• The integration points with external services
• The data flow between components
• The scalability aspects of the system
• Core services (blue)
• External integrations (green)
• Storage components (yellow)
• Message queues (purple)
• API endpoints (orange)