Reusable approach to enhanced proxy generation
Goal:
- some bundles want to define their own code enhancement rules
- if two bundles enhance the same class - there would be no risk of conflicts
- couple of bundles won't overwrite changes of each other, as they'll define their own generators
How:
- added proxy enhancer repository
- supported code with tests
- fixed single failing test with outdated class name
- now tests run normally on 2.1 composer based install
Regards, Serge
Hey, thanks for the patch.
There are a few CS issues, but I don't want to comment on them for now. Maybe you could show an example of how you would use these changes in your code?
Usage should be like https://github.com/nfx/AsyncBundle/blob/master/DependencyInjection/Compiler/CollectAsyncTasksPass.php#L72
so, what should i change?
sry, did not have time yet to look into this.
On Mon, Jun 25, 2012 at 4:18 PM, Serge Smertin < [email protected]
wrote:
so, what should i change?
Reply to this email directly or view it on GitHub: https://github.com/schmittjoh/JMSAopBundle/pull/8#issuecomment-6548417
ping
This is not really related to AOP; could we add this to another bundle, maybe even Symfony itself?
hm, actually Symfony itself would even be a better solution, as it is directly related to class proxy generation. Where do you think we need to put it?
Before you start writing code, I'd first start a discussion about it either on Github (symfony/symfony), or the symfony-dev mailing list.
This could not only be used for AOP, but also to implement lazy-loading for services (@lsmith and others might be interested in this).
On Wed, Sep 19, 2012 at 8:51 PM, Serge Smertin [email protected]:
hm, actually Symfony itself would even be a better solution, as it is directly related to class proxy generation. Where do you think we need to put it?
— Reply to this email directly or view it on GitHubhttps://github.com/schmittjoh/JMSAopBundle/pull/8#issuecomment-8702062.
So, what are we going to do? Me doing better implementation to be included in CG-lib or finishing up with this commit? Either option works.