Thanks to visit codestin.com
Credit goes to github.com

Skip to content

[Messenger][FrameworkBundle] Move commands-specifics to a compiler pass in FWB #28328

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

Conversation

sroze
Copy link
Contributor

@sroze sroze commented Aug 31, 2018

Q A
Branch? master
Bug fix? no
New feature? no
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #28271 (comment)
License MIT
Doc PR ø

We very recently broke the tests by adding a legitimate BC-break in one of Messenger's command. The failure is on FrameworkBundle (on the 4.1 branch) when using the "latest" dependencies (so messenger on master): the XML configuration does not match anymore the class.

Even though it makes sense to have most the compiler pass in the components, it does not make much sense to have things into them that are very coupled to what we defined in FWB' XML. This pull-request moves what is related to this command to the FWB directly.

@sroze sroze force-pushed the move-console-specifics-to-pass-in-messenger branch 4 times, most recently from 407f913 to e973373 Compare September 1, 2018 15:11
@sroze sroze changed the base branch from master to 4.1 September 1, 2018 15:11
@sroze sroze force-pushed the move-console-specifics-to-pass-in-messenger branch from e973373 to ee36550 Compare September 1, 2018 15:12

$container
->getDefinition('console.command.messenger_consume_messages')
->replaceArgument(0, ServiceLocatorTagPass::register($container, $buses))
Copy link
Contributor Author

Choose a reason for hiding this comment

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

These changes should not be merged into 4.1; I'll revert them.

@sroze sroze force-pushed the move-console-specifics-to-pass-in-messenger branch 2 times, most recently from 37272af to 7a8c171 Compare September 1, 2018 16:15
Copy link
Member

@nicolas-grekas nicolas-grekas left a comment

Choose a reason for hiding this comment

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

Looks legit to me.
deps=low failures are hinting framework-bundle should require 4.1.5 as minimum version of messenger.

@@ -312,4 +289,26 @@ private function registerBusMiddleware(ContainerBuilder $container, string $busI

$container->getDefinition($busId)->replaceArgument(0, $middlewareReferences);
}

public static function findReceivers(ContainerBuilder $container, string $receiverTag)
Copy link
Member

Choose a reason for hiding this comment

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

should be @internal I suppose

@sroze sroze force-pushed the move-console-specifics-to-pass-in-messenger branch 2 times, most recently from 67b8b00 to aefce11 Compare September 1, 2018 17:38
@sroze sroze force-pushed the move-console-specifics-to-pass-in-messenger branch from aefce11 to b5415ea Compare September 1, 2018 17:39
@nicolas-grekas
Copy link
Member

Thank you @sroze.

@nicolas-grekas nicolas-grekas merged commit b5415ea into symfony:4.1 Sep 1, 2018
nicolas-grekas added a commit that referenced this pull request Sep 1, 2018
…compiler pass in FWB (sroze)

This PR was merged into the 4.1 branch.

Discussion
----------

[Messenger][FrameworkBundle] Move commands-specifics to a compiler pass in FWB

| Q             | A
| ------------- | ---
| Branch?       | master
| Bug fix?      | no
| New feature?  | no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #28271 (comment)
| License       | MIT
| Doc PR        | ø

We very recently [broke the tests](#28271 (comment)) by adding a legitimate BC-break in one of Messenger's command. The failure is on FrameworkBundle (on the 4.1 branch) when using the "latest" dependencies (so messenger on master): the XML configuration does not match anymore the class.

Even though it makes sense to have most the compiler pass in the components, it does not make much sense to have things into them that are very coupled to what we defined in FWB' XML. This pull-request moves what is related to this command to the FWB directly.

Commits
-------

b5415ea Move commands-specifics to a compiler pass in FWB
@nicolas-grekas nicolas-grekas added this to the 4.1 milestone Sep 1, 2018
nicolas-grekas added a commit that referenced this pull request Sep 2, 2018
…iler pass in FWB" (sroze)

This PR was merged into the 4.1 branch.

Discussion
----------

[FWB][Messenger] Revert "Move commands-specifics to a compiler pass in FWB"

| Q             | A
| ------------- | ---
| Branch?       | 4.1
| Bug fix?      | yes
| New feature?  |no
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | ø
| License       | MIT
| Doc PR        | ø

This reverts #28328.

Commits
-------

fb3f729 Revert "Move commands-specifics to a compiler pass in FWB"
@fabpot fabpot mentioned this pull request Sep 30, 2018
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.

3 participants