[Mono-list] Nothing happens with mono-service and EventLog.WriteEntry

Jonathan Pryor jonpryor at vt.edu
Fri Feb 16 07:24:29 EST 2007


On Fri, 2007-02-16 at 12:53 +0100, Gert Driesen wrote:
> We *could* add the syslog event log implementation to Mono.Unix, and add
> support for event log implementations in external (GAC'ed) assemblies to
> MONO_EVENTLOG_TYPE.
> 
> However, to do this we'd have to mark the EventLogImpl class public and this
> is a no-go since it would break the public API ...

Not necessarily.  We could add a method to Mono.Unix which could be
added to the public System.Diagnostics.EventLog.EntryWritten event.  So
MONO_EVENTLOG_TYPE could refer to a static method in addition to a type.

The downside to this is that MONO_EVENTLOG_TYPE would become much
longer; alternatively, we could have a MONO_EVENTLOG_TYPE value of
"syslog", and EventLog would know that "syslog" means "look up this
specific method within Mono.Posix.dll using Reflection."

I'm not sure which is better, adding an internal SyslogEventLog type or
using the EventWritten event.  The one downside to the latter is that
the EventWritten event will contain delegates not explicitly added by
the end user, though this might not matter.

 - Jon




More information about the Mono-list mailing list