Skip to content
This repository has been archived by the owner on Dec 8, 2018. It is now read-only.

Support middleware (or Elm option) to log errors to the Windows Event Log #72

Closed
JesperTreetop opened this issue Dec 15, 2014 · 4 comments

Comments

@JesperTreetop
Copy link

ASP.NET 4 and older logs escaped exceptions to the Windows Event Log with the event ID 1309. This seems like a good middleware to have in Diagnostics to also make it hosting-independent (although maybe not platform-independent; Mono seems to do wildly different things depending on configuration). Unsure if this is best implemented as a standalone middleware or as an option to the Elm infrastructure (maybe because Elm isn't really detailed anywhere; it seems like an exception VCR and the name hints at ELMAH).

@davidfowl
Copy link
Member

This wouldn't be middleware, it would be a logger provider. The middleware just calls into whatever log providers are registered.

@JesperTreetop
Copy link
Author

I didn't notice that the logging interfaces took Exception objects. That makes sense, as long as the hosting environment catches and logs these exceptions (or otherwise there would need to be middleware at least to do that).

@JesperTreetop
Copy link
Author

And that middleware was this middleware, ErrorHandlerMiddleware, of course.

Is an event log logger provider planned or are you accepting pull requests for this?

@Eilon
Copy link
Member

Eilon commented Dec 16, 2014

@JesperTreetop I'm closing this issue because it isn't a Diagnostics issue. Can you re-start the discussion in the https://github.com/aspnet/Logging/ repo?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants