How dbos-inc/dbos-transact-py works
Main Components
a) Core Components:
• Workflow Engine (Central Component)
• Step Executor
• Transaction Manager
• State Management System
• Database Connector (PostgreSQL)
b) Supporting Systems:
• FastAPI/Flask Integration Layer
• Kafka Integration
• Scheduler System
• Admin Server
• OpenTelemetry Tracer
Component Relationships
a) Primary Flow:
User Application -> DBOS Decorator Layer -> Workflow Engine -> Step Executor -> Database
b) Secondary Systems:
• Scheduler System -> Workflow Engine (for timed executions)
• Kafka Integration -> Workflow Engine (for event processing)
• Admin Server <- Database (for monitoring)
• OpenTelemetry Tracer (connected to all components)
Specific Implementation Details
• Blue rectangles: Core components
• Green rectangles: Integration layers (FastAPI/Flask)
• Yellow diamonds: External systems (PostgreSQL, Kafka)
• Purple rectangles: Monitoring components (Admin Server, OpenTelemetry)
Key Architectural Elements
Specific architectural patterns:
• Decorator Pattern (@DBOS.step(), @DBOS.workflow())
• Transaction Management System
• Event Processing System
• State Machine for Workflow Management
Component Details
Annotations for:
• Database Schema (from _schemas folder)
• Migration System (from _migrations folder)
• Configuration Management (dbos-config.yaml)
• Role-based Access Control (_roles.py)
Additional Notes
Callouts for:
• Configuration requirements
• Security boundaries
• Scaling points
• Failure recovery paths