A bit off topic but: I would love to see the logger available anywhere from a regular function without having to do anything special to get to it.
It wouldn't be that difficult to get the have the logger class without having it spawn multiple instances. For example: class logger { static private $__handle = NULL; function init( $identifier = 0) { if ( is_null( self::$__handle ) self::$__handle = do_initialize_logger(); } public function log( $logger, $context, $msg ) { self::init(); /// do log stuff } } function log($logger, $context, $msg) { return logger::log($logger, $context, $msg); } This sort of strategy would be great for several other components in Symfony also such as the app kernel, entity manager, and others. When I get through my current project I'll definitely look into forking the code to contribute such logic if it hasn't been added by then so I would love to see some feedback on the idea. Bart On Jun 18, 2011, at 7:53 AM, Christophe COEVOET wrote: > Le 18/06/2011 14:38, Michal_V a écrit : >> >> Hi I tried your idea, but my ajaxAuthenticationListener never gets the >> event. From log it is obvious that previous symfony listener stopped >> onCoreException event propagation. >> >> [2011-06-18 08:27:16] event.DEBUG: Listener "Symfony\Component\Security\ >> Http\Firewall\ExceptionListener" stopped propagation of the event >> "onCoreException". >> [2011-06-18 08:27:16] event.DEBUG: Listener >> "MyUserBundle\Listener\AjaxAuthenticationListener" was not called for event >> "onCoreException". >> >> Did you face the same issue an overcame it somehow? >> Thanks >> > Use a higher priority to execute your own listener before the one from the > Security component > -- > Christophe | Stof > > -- > If you want to report a vulnerability issue on symfony, please send it to > security at symfony-project.com > > You received this message because you are subscribed to the Google > Groups "symfony developers" group. > To post to this group, send email to symfony-devs@googlegroups.com > To unsubscribe from this group, send email to > symfony-devs+unsubscr...@googlegroups.com > For more options, visit this group at > http://groups.google.com/group/symfony-devs?hl=en -- If you want to report a vulnerability issue on symfony, please send it to security at symfony-project.com You received this message because you are subscribed to the Google Groups "symfony developers" group. To post to this group, send email to symfony-devs@googlegroups.com To unsubscribe from this group, send email to symfony-devs+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/symfony-devs?hl=en