Skip to content
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

[DI] ignore extra tags added by autoconfiguration in PriorityTaggedServiceTrait #35957

Merged
merged 1 commit into from Mar 5, 2020

Conversation

nicolas-grekas
Copy link
Member

@nicolas-grekas nicolas-grekas commented Mar 4, 2020

Q A
Branch? 4.4
Bug fix? yes
New feature? no
Deprecations? no
Tickets Fix #35916, Fix #35953
License MIT
Doc PR -

@alex-dev
Copy link
Contributor

alex-dev commented Mar 4, 2020

Seems to work but...

  • There are no TypedReference anymore. It may or may not matter.
  • Reflection are reloaded everytime rather than at first time needed. Worst case is two calls to $container->getReflectionClass(), $container->getParameterBag()->resolveValue(). It should not matter much.
  • $index will always have a value: line 89 - 91 are redundant. This will cause all service iterables to have service id as key (assuming they don't have a better key). Most of the complexity behind last implementation was to keep behavior the same as far as key goes.

@nicolas-grekas
Copy link
Member Author

Thanks for the review

There are no TypedReference anymore. It may or may not matter.

Yep, doesn't matter.

Reflection are reloaded everytime

$container->getReflectionClass() already has a cache

$index will always have a value: line 89 - 91 are redundant

nope, see line 70

@alex-dev
Copy link
Contributor

alex-dev commented Mar 4, 2020

nope, see line 70

Doh! Everything seems good.

@Jamesking56
Copy link

Can we expect a release of this soon? We've had to hold upgrading to 4.4.5 due to this

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.

None yet

5 participants