Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

It would be nice to have api to explore thread logical call context #36

Closed
gusev-p opened this issue Dec 6, 2015 · 1 comment
Closed

Comments

@gusev-p
Copy link

gusev-p commented Dec 6, 2015

Scenario: in our generic diagnostics code for http service we want to dump thread stacks with corresponding http urls/ports. We save url/port via CallContext.LogicalSetData for incoming http requests and dispatch them to Task.Factory.StartNew. Request processing code can use async/await, so there can be more than one thread for each request. In the current version of this diagnostic we use some TaskScheduer-s magic to remember (url, managed thread id) pairs in static field. It would be much simpler to just dump all ClrRuntime.Threads having http url on ther LogicalCallContext.

kant added a commit to kant/clrmd that referenced this issue Dec 17, 2018
leculver pushed a commit that referenced this issue Dec 17, 2018
@leculver
Copy link
Contributor

Sorry for the very long delay in responding. I think this is more of something that should be done by the consumer of ClrMD. I try to keep ClrMD down to just "building blocks", giving you the functionality to implement something like what you are describing, instead of having every small algorithm like that in ClrMD itself.

(Though if this is something you find impossible to implement on top of ClrMD, please let me know.)

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

No branches or pull requests

2 participants