Problem/Motivation
When creating the plugin through FocalPointEffectBase::create it needs the manager injected as well. In the creation method the manager is constructed every time, so there as many manager as there are instances. The plugin pattern in D8 core follows 1 manager instance for all plugin instances managed by it.
Proposed resolution
Define a service for the manager and inject that directly, so it can skip the creation step on every instance.
Remaining tasks
Patch, etc...
User interface changes
None.
API changes
None - implementation detail.
Data model changes
None.
Release notes snippet
None.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | 3021400-3.patch | 655 bytes | ndobromirov |
Comments
Comment #2
ndobromirov commentedComment #3
ndobromirov commentedHere is a patch that implements the issue description.
Comment #5
bleen commentedYes, of course!