Replies: 5 comments
-
You can bind a new client to the current scope: sentry-dotnet/src/Sentry/SentrySdk.cs Line 294 in c19fb14 Mind if I ask what's the use case? You can also keep a reference of the Client and call directly to it to capture errors and stuff but some functionality go to the client bound to the scope |
Beta Was this translation helpful? Give feedback.
-
@bruno-garcia thanks, it works fine. We use several sentry projects for different purposes. One project (per app) - for internal bugs, warnings, etc... Another project - for collecting users feedback, and this project is shared across our apps to have all feedbacks in one place. So, from single app we need possibility to capture events into different sentry projects. One note, it seems there is no way to Unbind client when we don't need it anymore? Here the sample if someone will be needed in similar functionality:
|
Beta Was this translation helpful? Give feedback.
-
If I get your intention correctly you're looking for something like this
The client gets bound to the current scope. Pushing a scope gives you an |
Beta Was this translation helpful? Give feedback.
-
@bitsandfoxes not obvious solution since we don't use explicitly result from
|
Beta Was this translation helpful? Give feedback.
-
Yes, |
Beta Was this translation helpful? Give feedback.
-
Hi, could you say what's the correct way to use several independent sentry clients with different settings (dsn) inside one app? Didn't find anything similar inside your samples... you are using static
SentrySdk.Capture()
everywhere.Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions