RE: [PHP-DEV] [RFC] Extension Prepend Files
| From: | Derick Rethans | Date: | Thu, 08 Jan 2015 11:39:35 +0000 |
| Subject: | RE: [PHP-DEV] [RFC] Extension Prepend Files | ||
| References: | 1 2 3 4 5 6 7 8 9 | Groups: | php.internals |
| Request: | Send a blank email to internals+get-80269@lists.php.net to get a copy of this message | ||
On Wed, 7 Jan 2015, François Laupretre wrote:
> > De : Pierre Joye [mailto:pierre.php@gmail.com]
> >
> > ... here,
> > it is proposed to bundle scripts that will be executed at runtime like any
> > other script, except that nothing can be done with them, not even disable
> > them if not required (like using its own glue codes).
>
> I agree. Bundling scripts in extensions to execute them at each RINIT
> is, IMO, not a good idea (mostly for performance reasons and lack of
> control, as you note), but I keep thinking that a mechanism to embed
> PHP scripts in extensions and make them available via a common stream
> wrapper can be useful.
It should really be in MINIT... but I guess that doesn't work well.
> What I don't like is the fact to execute them automatically at every
> RINIT. I prefer to let the extension free to load its PHP code when
> its logic decides it is needed.
I really don't see the problem if the PHP code is really part of the
extension. It just defines extra classes!
cheers,
Derick