Dmitry Bogomolov
Dmitry Bogomolov

Reputation: 426

dotnet-trace in ASP.NET Core doesn't show any methods of controllers

I made a little ASP.NET Core applications to check out the dotnet-trace tool. It's an API with a single controller, returning some data from memory, nothing special.

The command I run is:

dotnet-trace collect --process-id 1 --format Speedscope --duration 00:00:01:00

While doing this I run a script sending requests to my controller during all the period of trace collecting. But after dotnet-trace finishes I can't see any useful information in the file I get. That's what I see: enter image description here So it doesn't show anything related to a controller or any of my other class, but instead of this I can see Program.Main and something called UNMANAGED_CODE_TIME.

Could you please help me understand what I did wrong and how can I get more detailed profile.

Thanks in advance!

Upvotes: 1

Views: 1040

Answers (1)

Dmitry Bogomolov
Dmitry Bogomolov

Reputation: 426

Ok, it seems like I need a big blackboard to write "I will always read a documentation before asking a question"...

If you're struggling with the same, try to use n and p keys to navigate between threads (n means next, and p means previous).

And on one of .NET ThreadPool threads I've found my methods: enter image description here

I thought about removing the question, but now I think I'd better keep it here in case of anybody facing with the same situation.

Upvotes: 4

Related Questions