Le 2003-10-09 21:36:17, guest a écrit :
Show quoted text> In POE::Component::Logger, there seems to be no way to shot down the
> logger properly - as such, the only way to break out of the kernel
> is to post a '_stop' event to it.
This is not a feature request: this is a bug.
The '_stop' event is reserved to the POE system and should not have to
be called directly by user code.
Show quoted text> However, this can cause recently-
> sent messages to be lost. I'd appreciate a 'shutdown' event, which
> would safely shut down the logger session without losing any not-
> yet-written messages.
I don't think that it is a problem: messages are handled by POE in the
order they are submitted to a session queue. If the messages are
submitted before posting '_stop', they will be correctly sent to the log.
Anyway, I'm currently working on the implementation of a 'shutdown'
event and a 'shutdown' method.
I'll deprecate the usage of posting '_stop' directly by sending a log
message at 'notice' level if such a situation is detected.
The code is hosted on Github:
http://github.com/dolmen/POE-Component-Logger
(however my RT4062-shutdown branch is not yet there)
--
Olivier Mengué -
http://search.cpan.org/~dolmen/ http://github.com/dolmen/