Re: [dancer-users] dancer-users Digest, plugins
On Mon, 20 Apr 2015, Yanick Champoux wrote:
On 2015-04-19 07:59 AM, Sawyer X wrote:
Yanick Champoux and Russell Jenkins have both produces two different implementations that resolve our current problems in different ways. They are available online.
Mine is at https://github.com/PerlDancer/Dancer2/compare/master...yanick:plugins-yanick
And Russell's is at https://github.com/PerlDancer/Dancer2/compare/master...veryrusty:playground/...
What are the pro's and con's of these ways? (and what are the current problems?) Thanks Rick
On 2015-08-26 03:37 PM, Rick Leir wrote:
Mine is at https://github.com/PerlDancer/Dancer2/compare/master...yanick:plugins-yanick
And Russell's is at https://github.com/PerlDancer/Dancer2/compare/master...veryrusty:playground/...
What are the pro's and con's of these ways? (and what are the current problems?)
In a very tight nutshell: the main problem are plugins not being able to use the other plugins (a plugin might want, for example, to be able to build atop the database connection provided by the DBIC plugin). Another goal of at least my work was to come up with a simpler plugin system, because the current one makes me go cross-eyed. :-) As for the pros and cons of my solution: it's simple, doesn't require a lot of changes, seem to work, buuuut it's taking a fairly different approach than the previous plugin system, code-wise. This being said, it's been so long that most of my memory of the details is gone. Let's see if I can juggle some recollections by rebasing that work atop the current master branch... Joy, `/anick
On 2015-08-27 06:32 PM, Yanick Champoux wrote:
This being said, it's been so long that most of my memory of the details is gone. Let's see if I can juggle some recollections by rebasing that work atop the current master branch...
Memory jogged, and documented: https://github.com/yanick/Dancer2/blob/plugins-yanick/lib/Dancer2/Plugin2.pm Doing that, I remembered that one of the things I was aiming for with the P2 system is to differentiate a little bit more between the app as the object, versus the app as the class, and to have the plugins injected into the former, and to have it done in a way that can be observed, retrieved and manipulated afterwards too (via the $app->plugins attribute). Joy, `/anick
participants (2)
-
Rick Leir -
Yanick Champoux