Azure ServiceFabric samples not logging to ETW

我只是一个虾纸丫 提交于 2019-11-30 19:28:28

To see events from your EventSource you need to add its name to the list of providers in the Diagnostics window. Look at the ServiceEventSource definition, it will have an [EventSource(Name="xxx")] attribute on it. That is the name ('xxx') you need to be on the list of providers.

Visual Studio will usually take care of automatically detecting EventSources in your solution when Diagnostics Windows is launched; not sure why it is not working for you, but adding it manually should do the trick.

I encountered this issue after I reorganized my solution. I moved my service projects into a solution folder. And that is when the Diagnostics Events Viewer stopped having messages from my services.

After moving the projects back to the root level of the solution Visual Studio would automatically add the event source names to the list of ETW providers.

This bug now appears to be fixed with VS 2017 and/or Azure Service Fabric SDK 2.5.216.0.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!