-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[DependencyInjection] replace DefinitionDecorator by ChildDefinition #20663
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
12ad265
to
36207b4
Compare
@@ -54,6 +54,9 @@ protected function tearDown() | |||
$this->deleteTmpDir('Acl'); | |||
} | |||
|
|||
/** | |||
* @group legacy |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is necessary until DoctrineBundle is compatible with the changes done in this PR.
It reflects service that decorates another one, doesn't it? |
@unkind no. The decorates feature uses normal definition to configure the composition (as the service definition for the decorator does not need to reuse anything from the original service as it gets it as a dependency instead). |
DerivedDefinition? ChildDefinition? |
I like |
👍 for |
cb93449
to
a7c7477
Compare
I renamed |
I'm tempted to vote +1, but then I also considered the burden that we'll put on bundles & co. Not sure it's worth it... |
Given the confusion this class name caused in the past and still causes, I think we should dare to make this deprecation now and get rid of it in 4.0. |
👍 There are some conflicts to be resolved. |
377687f
to
2ddb0e9
Compare
The DefinitionDecorator class does not deal with decorated services. It reflects a parent-child-relationship between definitions instead. To avoid confusion, this commit deprecates the existing DefinitionDecorator class and introduces a new ChildDefinition class as replacement.
2ddb0e9
to
184f7ff
Compare
conflicts are resolved |
Thank you @xabbuh. |
…hildDefinition (xabbuh) This PR was merged into the 3.3-dev branch. Discussion ---------- [DependencyInjection] replace DefinitionDecorator by ChildDefinition | Q | A | ------------- | --- | Branch? | master | Bug fix? | no | New feature? | yes | BC breaks? | no | Deprecations? | yes | Tests pass? | yes | Fixed tickets | n/a | License | MIT | Doc PR | TODO The DefinitionDecorator class does not deal with decorated services. It reflects a parent-child-relationship between definitions instead. To avoid confusion, this commit deprecates the existing DefinitionDecorator class and introduces a new DefinitionExtension class as replacement. Commits ------- 184f7ff replace DefinitionDecorator with ChildDefinition
The DefinitionDecorator class does not deal with decorated services. It reflects a parent-child-relationship between definitions instead. To avoid confusion, this commit deprecates the existing DefinitionDecorator class and introduces a new DefinitionExtension class as replacement.