Context Data for Error Reporting
Inclusion of Transactions/Spans, Logs and Metrics
The Problem
Sentry supports quite a range of data which is useful and sometimes crucial for understanding bugs, problems and errors, namely: Traces, Logs and Metrics.
But when you want to use error reporting only, that data is not included in error reports.
Please correct me where wrong, but as far as I understand and according to my testing so far, the following seems to be true:
- Traces
In order to have error reports enriched by trace information (transations/spans), it is required
- to send ALL trace data to Sentry
- to set the trace sampling rate to 1.0
- if you set the trace sampling rate to anything lower than 1.0, you will no longer get trace information included in all error reports
(because when using trace sampling, the decision about sending a trace or not is made at the beginning of a new transaction where it isn't known yet, whether an error will occur or not)
- Logs
- log items are associated with a trace, but sent separately
- they are sent before a transaction completes
- also, they are sent, before an error occurs, so when you filter out log items and an error occurs, the log items preceding the error are already gone
- Metrics
Same story like for logs
Assessment
One can get the impression that this might be driven by intent - for maximizing the amount of data that Sentry users are required to transmit in order to get useful data for analyzing errors.
Anyway - whether intentional or not: - this is forcing Sentry customers to send huge amounts of data, even though there's just a fraction of that data which is actually of interest - that's quite unfortunate, to say the least.
Target Use Cases
It seems that large parts of Sentry are tailored for situations where customers are running a range of backend services, serving their users which are accessing those services by a certain client/frontend software.
Unlike others, we are not offering a service, but a software, and our server software can produce a huge amount of transactions as a single instance. We're using Sentry in beta versions only, but that's still above 1k installations. Sending full logs, traces and metrics to Sentry would be totally insane. Not just because of the amounts of data, but also because it's data that we wouldn't ever look at or have use for it in any way.
It would be a stupidity, burning time, money and energy - just for nothing.
Full traces and logs data can be useful at times - but only when investigating specific issues on a specific installation. In those cases, it can still be enabled individually, but that can't be the default setup for the masses.
What's needed?
For Session Replays, the Sentry implementation is recording the required data continuously - but only when an error is going to be reported, the related session replay data from shortly before until shortly after the error occurrence is eventually transmitted to Sentry.
The exact same thing should be possible with the Sentry .NET SDK (and possibly others):
Implement a special reporting mode, where the SDK operates as follows:
- It record transactions/spans, metrics and log data
- It caches the data
- But it doesn't sent it
- Only when an error event is reported, the related transactions/spans, metrics and log data gets transmitted as well
Context Data for Error Reporting
Inclusion of Transactions/Spans, Logs and Metrics
The Problem
Sentry supports quite a range of data which is useful and sometimes crucial for understanding bugs, problems and errors, namely: Traces, Logs and Metrics.
But when you want to use error reporting only, that data is not included in error reports.
Please correct me where wrong, but as far as I understand and according to my testing so far, the following seems to be true:
In order to have error reports enriched by trace information (transations/spans), it is required
(because when using trace sampling, the decision about sending a trace or not is made at the beginning of a new transaction where it isn't known yet, whether an error will occur or not)
Same story like for logs
Assessment
One can get the impression that this might be driven by intent - for maximizing the amount of data that Sentry users are required to transmit in order to get useful data for analyzing errors.
Anyway - whether intentional or not: - this is forcing Sentry customers to send huge amounts of data, even though there's just a fraction of that data which is actually of interest - that's quite unfortunate, to say the least.
Target Use Cases
It seems that large parts of Sentry are tailored for situations where customers are running a range of backend services, serving their users which are accessing those services by a certain client/frontend software.
Unlike others, we are not offering a service, but a software, and our server software can produce a huge amount of transactions as a single instance. We're using Sentry in beta versions only, but that's still above 1k installations. Sending full logs, traces and metrics to Sentry would be totally insane. Not just because of the amounts of data, but also because it's data that we wouldn't ever look at or have use for it in any way.
It would be a stupidity, burning time, money and energy - just for nothing.
Full traces and logs data can be useful at times - but only when investigating specific issues on a specific installation. In those cases, it can still be enabled individually, but that can't be the default setup for the masses.
What's needed?
For Session Replays, the Sentry implementation is recording the required data continuously - but only when an error is going to be reported, the related session replay data from shortly before until shortly after the error occurrence is eventually transmitted to Sentry.
The exact same thing should be possible with the Sentry .NET SDK (and possibly others):
Implement a special reporting mode, where the SDK operates as follows: