Enhance ComboHandler and orchestrator functionality with access control and error handling improvements
- Added AccessControl to ComboHandler for role-based access management. - Implemented gas estimation for plan execution and improved gas limit checks. - Updated execution and preparation methods to enforce step count limits and role restrictions. - Enhanced error handling in orchestrator API endpoints with AppError for better validation feedback. - Integrated request timeout middleware for improved request management. - Updated Swagger documentation to reflect new API structure and parameters.
This commit is contained in:
55
docs/ADRs/ADR-001-Architecture-Decisions.md
Normal file
55
docs/ADRs/ADR-001-Architecture-Decisions.md
Normal file
@@ -0,0 +1,55 @@
|
||||
# ADR-001: Architecture Decisions
|
||||
|
||||
## Status
|
||||
Accepted
|
||||
|
||||
## Context
|
||||
ISO-20022 Combo Flow system requires decisions on architecture patterns, technology choices, and design principles.
|
||||
|
||||
## Decisions
|
||||
|
||||
### 1. Two-Phase Commit (2PC) Pattern
|
||||
**Decision**: Use 2PC for atomic execution across DLT and banking rails.
|
||||
|
||||
**Rationale**:
|
||||
- Ensures atomicity across heterogeneous systems
|
||||
- Provides rollback capability
|
||||
- Industry standard for distributed transactions
|
||||
|
||||
### 2. PostgreSQL for Persistence
|
||||
**Decision**: Use PostgreSQL as primary database.
|
||||
|
||||
**Rationale**:
|
||||
- ACID compliance required for financial transactions
|
||||
- JSONB support for flexible plan storage
|
||||
- Strong ecosystem and tooling
|
||||
|
||||
### 3. Redis for Caching
|
||||
**Decision**: Use Redis for caching and session management.
|
||||
|
||||
**Rationale**:
|
||||
- High performance
|
||||
- Pub/sub support for real-time updates
|
||||
- Widely supported
|
||||
|
||||
### 4. Smart Contract Architecture
|
||||
**Decision**: Separate handler, registry, and adapter contracts.
|
||||
|
||||
**Rationale**:
|
||||
- Modularity and upgradeability
|
||||
- Security isolation
|
||||
- Easier testing and auditing
|
||||
|
||||
### 5. Next.js for Frontend
|
||||
**Decision**: Use Next.js 14 with App Router.
|
||||
|
||||
**Rationale**:
|
||||
- Server-side rendering for performance
|
||||
- Built-in API routes
|
||||
- Excellent developer experience
|
||||
|
||||
---
|
||||
|
||||
**Date**: 2025-01-15
|
||||
**Author**: Engineering Team
|
||||
|
||||
Reference in New Issue
Block a user