Skip to content

Provides a Middleware to integration Tideways into Symfony Messenger Processing

License

Notifications You must be signed in to change notification settings

tideways/symfony-messenger-middleware

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tideways Middleware for Symfony Messenger

This middleware for Symfony Messenger starts a Tideways trace for every processed message, names the trace after the message class and implements integration with Tideways exception tracking.

If you want to see traces for processed messages, then the INI setting tideways.enable_cli=1 must be set.

Tideways is a monitoring, profiling and exception tracking combo for PHP.

Installation

composer require tideways/symfony-messenger-middleware

Configuration for Symfony

framework:
  messenger:
    buses:
      default:
        middleware:
          - "Tideways\\SymfonyMessenger\\TidewaysOnlyConsumedByWorkerMiddleware"

services:
  "Tideways\\SymfonyMessenger\\TidewaysOnlyConsumedByWorkerMiddleware": ~

Configuration for Shopware 6.5

Shopware uses the Symfony Messenger under the hood and using this middleware requires just a slightly different configuration:

# config/packages/messenger.yaml
framework:
  messenger:
    # here are other sections "transport", "routing" already configured by Shopware.

    buses:
      messenger.bus.default:
        middleware:
          - "Tideways\\SymfonyMessenger\\TidewaysOnlyConsumedByWorkerMiddleware"

services:
  "Tideways\\SymfonyMessenger\\TidewaysOnlyConsumedByWorkerMiddleware": ~

Configuration for Shopware 6.4

Shopware uses the Symfony Messenger under the hood and using this middleware requires just a slightly different configuration:

# config/packages/messenger.yaml
framework:
  messenger:
    # here might be other config values already "transports" and "routing".

    buses:
      messenger.bus.shopware:
        middleware:
          - "Shopware\\Core\\Framework\\MessageQueue\\Middleware\\RetryMiddleware"
          - "Tideways\\SymfonyMessenger\\TidewaysOnlyConsumedByWorkerMiddleware"

services:
  "Tideways\\SymfonyMessenger\\TidewaysOnlyConsumedByWorkerMiddleware": ~

Configuration for TYPO3

TYPO3 uses the Symfony Messenger under the hood and using this middleware requires just a slightly different configuration:

# YOUR_EXTENSION/Configuration/Services.yaml
services:
  Tideways\SymfonyMessenger\TidewaysOnlyConsumedByWorkerMiddleware:
    tags:
      - name: 'messenger.middleware'
        before: 'Symfony\Component\Messenger\Middleware\SendMessageMiddleware'

About

Provides a Middleware to integration Tideways into Symfony Messenger Processing

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages