michallkanak/symfony-message-flow-visualizer
Visualize Symfony Messenger message flow in your app: inspect dispatched messages, handlers, middleware and transport routing on a clear diagram. Debug async jobs, find bottlenecks and trace how each message travels through the bus in real time—without digging through logs.
Install the package in a Symfony application (or a Laravel app that already runs Symfony Messenger) with Composer:
composer require michallkanak/symfony-message-flow-visualizer
The 0.1.3 release only adds Symfony 8 compatibility, so existing Symfony 6/7 setups should continue to work. Since this is a Symfony bundle rather than a Laravel package, there is no Laravel auto-discovery or php artisan command. In a Laravel codebase you will typically use it only if you have deliberately integrated Symfony Messenger; otherwise treat it as a reference tool for Symfony services.
First steps:
composer.json for the supported Symfony/PHP constraint matrix.config/bundles.php if it is not auto-registered.bin/console list and look for the package’s command namespace (likely messenger or flow).The best first use case is documenting an existing Messenger setup: dispatch a single message through its bus and confirm the generated diagram shows the expected middleware, handler, and transport path. That validates both the package and your mental model of the flow.
CI documentation artifact. Add a Composer script or Makefile target that runs the visualizer and writes Mermaid or Graphviz output to docs/. Upload the result as a CI artifact so message-flow changes are reviewable in pull requests.
Local debugging aid. When a message is handled by an unexpected handler, or middleware ordering is unclear, generate the flow for the relevant bus and compare it with config/packages/messenger.yaml. This is faster than tracing HandleMessageMiddleware by hand.
Architecture reviews. Generate one diagram per bounded context or transport. Commit the output alongside the Messenger configuration so reviewers can see routing changes without running the application.
Laravel integration. If you use Symfony Messenger inside Laravel through a bridge or standalone container, register the bundle/service manually and invoke the Symfony console command from a custom Artisan command. Do not assume Laravel’s queue system is represented; the package models Messenger buses, middleware, handlers, and transports, not Laravel jobs and events.
Incremental adoption. Start with a single bus and a small set of messages. Once the output is trusted, expand to all buses and add the generation step to CI. This keeps early-version noise and false positives contained.
composer.json and read the changelog before upgrading.composer why-not if installation fails.FlowVisualizerServiceProvider or Artisan command unless the package explicitly ships one. In Laravel, you must wire it into the container yourself.messenger.yaml..dot files, install Graphviz in CI and locally; Mermaid output avoids that dependency.-vvv and check Symfony logs if no diagram or an empty diagram is produced. Confirm the command is reading the expected bus name.How can I help you explore Laravel packages today?