jonwagner / EventSourceProxy

EventSourceProxy (ESP) is the easiest way to add scalable Event Tracing for Windows (ETW) logging to your .NET program
Other
97 stars 20 forks source link

NuGet and "... EventProvider class in .NET is actually broken" #29

Closed Mike-E-angelo closed 9 years ago

Mike-E-angelo commented 9 years ago

On this page: https://github.com/jonwagner/EventSourceProxy/wiki/Managing-Activity-&-Correlation-IDs

There is this reference to the mention in the title. Has this been addressed in 4.5.1?

Also, is there a benefit to using the NuGet version as opposed to the .NET version?

Thank you!

jonwagner commented 9 years ago

IMO, Microsoft has done an awful job with the built-in E2E tracing. I don't think it's fixed in 4.5.1. However, I'm pretty sure that ESP properly hooks up with the framework activities. I fixed a lot of small edge cases since I wrote that wiki page.

I think the difference between NuGet and Framework versions is that the NuGet ones are more recent and have some new features. The MS P&P team released those outside the framework because they didn't want to have to wait for another release.

Mike-E-angelo commented 9 years ago

OK... sounds good. Yeah, I've been digging around the framework code today and it definitely shows its age. :P

Mike-E-angelo commented 9 years ago

FYI, here's a very valuable feature in the NuGet that is not yet available in .NET: http://blogs.msdn.com/b/dotnet/archive/2013/08/09/announcing-the-eventsource-nuget-package-write-to-the-windows-event-log.aspx

Mike-E-angelo commented 9 years ago

Revisiting this topic (I have been doing a LOT of research into ETW this past week or so), I am curious if there is a unit test I can look into that helps reproduce/demonstrate broken functionality in 4.5. From what I am reading, it looks like a lot has been fixed/addressed in the 4.5.1/MDT (Microsoft.Diagnostics.Tracing) combination:

https://slab.codeplex.com/wikipage?title=ActivityTracingAndSampling

If this is the case, I am eyeballing at simplifying the NuGet/Futures package by removing EventActivityScope, but wanted to gauge the feasibility/desirability before doing such a thing.

Also, there appears to be a WriteEventWithRelatedActivityId method that is used to create new "scopes" (if you want to call them that). I would be interested in providing functionality to allow this in the NuGet/Futures project as well.

Mike-E-angelo commented 9 years ago

Actually... scratch that. You're right. ETW is a terrible E2E solution. :P I'm not sure why I'm even bothering with any of this, outside of the challenge/knowledge of it all. EventActivityScope is still necessary. I will need the generated ID from EAS with the call to WriteEventWithRelatedActivityId.