Event Logging Source Registration .NET 2.0 vs .NET 4.0

Topics: Logging Application Block
Aug 11, 2010 at 8:45 PM
Edited Aug 11, 2010 at 8:48 PM

We are starting our migration from ASP.NET 2.0/3.5 to ASP.NET 4.0.  In our ASP.NET environment we have a tool that registers the event source so that Enterprise Library Logging can write to the Application event log (we have a different source for each application we host).  Currently, after the event is registered by the tool, the registry key for the source has a value EventMessageFile set to C:\WINNT\Microsoft.NET\Framework\v2.0.50727\EventLogMessages.dll.  As we migrate our applications to .NET 4.0 will we need to re-register them so that the EventMessageFile points to C:\WINNT\Microsoft.NET\Framework\v4.0.30319\EventLogMessages.dll?

All of our ASP.NET 4.0 applications will be using Enterprise Library 5.0.

Aug 12, 2010 at 8:25 AM

Hi,

Were there any encountered entlib related problem using the EventMessageFile of .NET Framework 2.0 while trying it with your ASP App created in .NET Framework 4? Seems like your inquiry is more on to ASP.NET 2.0 to 4.0 migration.

Even though entlib uses the Event Log, for what I know registering an event source is still part of environment configuration and not particular to entlib only. What I can only suggest for now is to try out and test your app's logging functionality and see if you may encounter any problem. Btw, I tried it myself in a simple console app but haven't encountered any issue logging.

Gino Terrado
Global Technology and Solutions
Avanade, Inc.
entlib.support@avanade.com

 

 

 

 

 

 

Aug 12, 2010 at 8:09 PM

After doing some further research it does not appear to matter which version of the EventLogMessages.dll is used because every message id is set to %1.