AshCommanded.Commanded.Middleware.LoggingMiddleware (AshCommanded v0.1.0)
View SourceMiddleware that logs command dispatch and results.
This middleware logs information about commands being dispatched and their results. It's useful for debugging and auditing.
Configuration
The logging level can be configured with the :level
option:
middleware AshCommanded.Commanded.Middleware.LoggingMiddleware, level: :debug
Available levels: :debug
, :info
, :warn
, :error
Log Format
The middleware logs the following information:
- Before dispatch: Command type, command ID, and fields
- After successful dispatch: Command type, command ID, and result
- After failed dispatch: Command type, command ID, and error reason