plkumar / elmah

Automatically exported from code.google.com/p/elmah
Apache License 2.0
0 stars 0 forks source link

MemoryErrorLog doesn't use configured applicationName #291

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

1.Configure MemoryErrorLog with applicationName:
<elmah>
    <errorLog type="Elmah.MemoryErrorLog, Elmah" applicationName="Metering2012" size="50" />
...

2.Configure IIS Express to host the web app in VS2010 SP1.
3.Log an error in Application_Start event handler: 
Elmah.ErrorLog.GetDefault(context).Log(error);

What is the expected output? What do you see instead?
There will be an exception in ErrorLog.InferApplicationName() when call 
context.Request, because Request not available when in Application_Start event.

MemoryErrorLog should use the applicatioinName configured in web.cofig to avoid 
inferring application name.

This can be fixed by copying the code from SqlErrorLog constructor.

Original issue reported on code.google.com by Bob.net2...@gmail.com on 18 Apr 2012 at 12:07

GoogleCodeExporter commented 9 years ago
I would like to fix this.

Original comment by thomasar...@gmail.com on 9 Jan 2014 at 12:14

GoogleCodeExporter commented 9 years ago

Original comment by azizatif on 9 Jan 2014 at 8:20

GoogleCodeExporter commented 9 years ago
This issue was closed by revision 598d495f1336.

Original comment by thomasar...@gmail.com on 5 Feb 2014 at 7:26