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

Support Spotlight without sending to Sentry #3481

Open
jessetan opened this issue Jul 15, 2024 · 7 comments
Open

Support Spotlight without sending to Sentry #3481

jessetan opened this issue Jul 15, 2024 · 7 comments
Labels
Feature New feature or request

Comments

@jessetan
Copy link

Problem Statement

One of the first lines on the Spotlight about page is

One of the great benefits of this approach is you get the power of Sentry’s telemetry without needing to utilize Sentry’s production monitoring.

The blogpost about the dotnet v4 SDK also says

It’s a tool to help you see all of Sentry’s telemetry data directly in your development environment, without the need to send anything to Sentry itself.

However this does not seem to be possible, since the SDK will not initialise Sentry without a valid DSN and wil not send anything to Spotlight.

Solution Brainstorm

Requested: when EnableSpotlight = true is passed to SentrySdk.Init, Sentry is always initialized even if there is no DSN.
Optional: when Spotlight is enabled, ignore transaction sample rate setting and send everything to Sentry, while still using the configured rate to send to Sentry.

I did not test if the requested behaviour is present in other SDKs, except for the in-browser JS SDK. That one requires a separate Spotlight.init() call outside of Sentry.init and does work without a DSN. For the other SDKs, Spotlight is turned on inside Sentry.init so might also ignore Spotlight if there is no DSN.

@bitsandfoxes
Copy link
Contributor

Thanks for the feedback! I'll have to see what the other SDKs are up to.

It’s a tool to help you see all of Sentry’s telemetry data directly in your development environment, without the need to send anything to Sentry itself.

I can see the being read in a way that you would not expect the events to have to go to Sentry.

@bitsandfoxes bitsandfoxes added the Feature New feature or request label Jul 15, 2024
@bitsandfoxes
Copy link
Contributor

From what it looks like we should update the SDK to check for Is there a DSN || EnableSpotlight before initializing.

@vaind
Copy link
Collaborator

vaind commented Jul 16, 2024

Does spotlight currently work for native events (crashes)? If so, that would also need to be taken into account.

@bitsandfoxes
Copy link
Contributor

AFAIK, it currently does not, no. Oh no, that adds another layer..

@xt0rted
Copy link
Contributor

xt0rted commented Nov 12, 2024

It took me a bit to set Spotlight up in our .net projects due to the different DSN behavior compared to the JS sdk I set up first. It was also a huge surprise today to realize everything our .net code has logged to Spotlight is now also in Sentry 😕

@getsantry getsantry bot moved this to Waiting for: Product Owner in GitHub Issues with 👀 3 Nov 12, 2024
@bruno-garcia
Copy link
Member

@BYK cc

Should we just not send to Sentry if Spotlight is set?

@BYK
Copy link
Member

BYK commented Nov 12, 2024

Should we just not send to Sentry if Spotlight is set?

Definitely not. The solution proposal in the ticket description is spot on:

  1. SDK should be initialized even without a DSN if spotlight=true (or equivalent)
  2. Sample rate should be 100% for Spotlight whereas the SDK should respect the sample rate for the actual DSN/Sentry backend
  3. We also want to enable any optional integrations to be enabled when possible
  4. We want SENTRY_SPOTLIGHT env variable to control the spotlight config variable, which should also allow a custom URL

I'm trying to come up with a final list of requirements here: getsentry/spotlight#545

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature New feature or request
Projects
Status: No status
Status: No status
Development

No branches or pull requests

6 participants