Home
Docs
GitHub
Pricing
Blog
Log In

Run Sandworm Audit for your App

Get started
Hold on, we're currently generating a fresh version of this report
Generated on May 3, 2024 via composer

symfony/doctrine-messenger v7.0.2

Symfony Doctrine Messenger Bridge
Package summary
Share
0
issues
1
license
13
MIT
Package created
28 Jan 2020
Version published
27 Dec 2023
Maintainers
1
Total deps
13
Direct deps
3
License
MIT

Issues

0
This package has no issues

Licenses

MIT License

Permissive
OSI Approved
This is a human-readable summary of (and not a substitute for) the license. Disclaimer.
Can
commercial-use
modify
distribute
sublicense
private-use
Cannot
hold-liable
Must
include-copyright
include-license
13 Packages, Including:
doctrine/dbal@4.0.2
doctrine/deprecations@1.1.3
psr/cache@3.0.0
psr/clock@1.0.0
psr/container@2.0.2
psr/log@3.0.0
symfony/clock@v7.0.7
symfony/deprecation-contracts@v3.5.0
symfony/doctrine-messenger@v7.0.2
symfony/messenger@v7.0.7
symfony/polyfill-php80@v1.29.0
symfony/polyfill-php83@v1.29.0
symfony/service-contracts@v3.5.0
Disclaimer

This deed highlights only some of the key features and terms of the actual license. It is not a license and has no legal value. You should carefully review all of the terms and conditions of the actual license before using the licensed material.

Sandworm is not a law firm and does not provide legal services. Distributing, displaying, or linking to this deed or the license that it summarizes does not create a lawyer-client or any other relationship.

Direct Dependencies

3
All Dependencies CSV
β“˜ This is a list of symfony/doctrine-messenger 's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
NameVersionSizeLicenseTypeVulnerabilities
doctrine/dbal4.0.2-MIT
prod
symfony/messengerv7.0.7-MIT
prod
symfony/service-contractsv3.5.0-MIT
prod dev

Visualizations

Frequently Asked Questions

What does symfony/doctrine-messenger do?

The Symfony Doctrine Messenger is a powerful tool that allows seamless integration between Symfony Messenger and Doctrine. Symfony Messenger is a potent component of Symfony that aids in sending and receiving messages between applications, while Doctrine is a set of PHP libraries intended to manage databases. Thus, by enabling a smooth interface between the two, Symfony Doctrine Messenger works as a bridge, thus improving the scalability of your Symfony applications and enhancing the potential of your database handling and application messaging.

How do you use symfony/doctrine-messenger?

Working with Symfony Doctrine Messenger isn't overly complex if you're familiar with Symfony and Doctrine. To start with, you need to have the Messenger and Doctrine bundles set up in your Symfony application.

composer require symfony/messenger doctrine

Once you have them installed, you can configure your messenger transport to use the doctrine transport like this:

# config/packages/messenger.yaml
framework:
    messenger:
        transports:
            async_priority_high:
                dsn: '%env(MESSENGER_TRANSPORT_DSN)%'
                options:
                    queue_name: high
            async_priority_low:
                dsn: '%env(MESSENGER_TRANSPORT_DSN)%'
                options:
                    queue_name: low
        routing:
            'App\Message\YourMessage':  async_priority_high

In your MessageHandler, use the Entity Manager to persist your entities. When dispatching the message, the Symfony Messenger automatically determines the correct MessageHandler.

class YourMessageHandler implements MessageHandlerInterface
{
    private $entityManager;

    public function __construct(EntityManagerInterface $entityManager)
    {
        $this->entityManager = $entityManager;
    }

    public function __invoke(YourMessage $message)
    {
        // use the entity manager to persist your entities
    }
}

Where are the symfony/doctrine-messenger docs?

The Symfony Doctrine Messenger documentation can be found within Symfony's comprehensive online docs. More specifically, you can access Symfony Doctrine Messenger's dedicated resources by visiting Symfony's official documentation. You can also find relevant contribution guidelines, report any issues, and propose pull requests on the main Symfony repository on GitHub.