10000 [Messenger] remove send_and_handle which can be achieved with SyncTransport by Tobion · Pull Request #31454 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content

[Messenger] remove send_and_handle which can be achieved with SyncTransport #31454

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 11, 2019

Conversation

Tobion
Copy link
Contributor
@Tobion Tobion commented May 10, 2019
Q A
Branch? 4.3
Bug fix? no
New feature? yes/no
BC breaks? yes
Deprecations? no
Tests pass? yes
Fixed tickets
License MIT
Doc PR symfony/symfony-docs#11236

The send_and_handle option is pretty awkward and we don't need it anymore because the same thing can be achieved with the SyncTransport from #30759

So the following example from the doc in https://symfony.com/doc/current/messenger.html#routing

framework:
    messenger:
        routing:
            'My\Message\ThatIsGoingToBeSentAndHandledLocally':
                 senders: [amqp]
                 send_and_handle: true

is the same as

framework:
    messenger:
        routing:
            'My\Message\ThatIsGoingToBeSentAndHandledLocally':
                 senders: [amqp, sync]

#31401 (review)

Copy link
Member
@weaverryan weaverryan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Need an entry for the BC break in the CHANGELOG.

The send_and_handle solved a real problem, but it was messy. With the SyncTransport, we can remove this. It's also much more clear how the transport-based handler config (from_transport) will work when using the sync transport vs this send_and_handle.

@Tobion Tobion force-pushed the messenger-remove-send-handle branch from 82736bd to 4552b7f Compare May 11, 2019 06:47
@Tobion Tobion requested a review from sroze as a code owner May 11, 2019 06:47
@Tobion
Copy link
Contributor Author
Tobion commented May 11, 2019

Added the changelogs.

@fabpot
Copy link
Member
fabpot commented May 11, 2019

Thank you @Tobion.

@fabpot fabpot merged commit 4552b7f into symfony:4.3 May 11, 2019
fabpot added a commit that referenced this pull request May 11, 2019
…ed with SyncTransport (Tobion)

This PR was merged into the 4.3 branch.

Discussion
----------

[Messenger] remove send_and_handle which can be achieved with SyncTransport

| Q             | A
| ------------- | ---
| Branch?       | 4.3
| Bug fix?      | no
| New feature?  | yes/no <!-- please update src/**/CHANGELOG.md files -->
| BC breaks?    | yes     <!-- see https://symfony.com/bc -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| Tests pass?   | yes    <!-- please add some, will be required by reviewers -->
| Fixed tickets |
| License       | MIT
| Doc PR        | symfony/symfony-docs#11236

The send_and_handle option is pretty awkward and we don't need it anymore because the same thing can be achieved with the SyncTransport from #30759

So the following example from the doc in https://symfony.com/doc/current/messenger.html#routing
```yaml
framework:
    messenger:
        routing:
            'My\Message\ThatIsGoingToBeSentAndHandledLocally':
                 senders: [amqp]
                 send_and_handle: true
```
is the same as
```yaml
framework:
    messenger:
        routing:
            'My\Message\ThatIsGoingToBeSentAndHandledLocally':
                 senders: [amqp, sync]
```

#31401 (review)

Commits
-------

4552b7f [Messenger] remove send_and_handle option which can be achieved with SyncTransport
@Tobion Tobion deleted the messenger-remove-send-handle branch May 11, 2019 07:14
@sroze
Copy link
Contributor
sroze commented May 12, 2019

Fab', thank you @Tobion!

@fabpot fabpot mentioned this pull request May 22, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants
0