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

Deprecate: metrics api #2312

Merged
merged 11 commits into from
Oct 1, 2024
Merged
Show file tree
Hide file tree
Changes from 9 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
### Features

- Emit `transaction.data` inside `contexts.trace.data` ([#2284](https://github.com/getsentry/sentry-dart/pull/2284))
- Blocking app starts if "appLaunchedInForeground" is false. (Android only) ([#2291](https://github.com/getsentry/sentry-dart/pull/2291)
- Blocking app starts if "appLaunchedInForeground" is false. (Android only) ([#2291](https://github.com/getsentry/sentry-dart/pull/2291))

### Enhancements

Expand All @@ -21,6 +21,11 @@
- Rounding error used on frames.total and reject frame measurements if frames.total is less than frames.slow or frames.frozen ([#2308](https://github.com/getsentry/sentry-dart/pull/2308))
- iOS replay integration when only `onErrorSampleRate` is specified ([#2306](https://github.com/getsentry/sentry-dart/pull/2306))

### Deprecate

- Metrics API ([#2312](https://github.com/getsentry/sentry-dart/pull/2312))
- Learn more: https://sentry.zendesk.com/hc/en-us/articles/26369339769883-Metrics-Beta-Coming-to-an-End

## 8.9.0

### Features
Expand Down
2 changes: 2 additions & 0 deletions dart/lib/src/sentry.dart
Original file line number Diff line number Diff line change
Expand Up @@ -316,6 +316,8 @@ class Sentry {
static ISentrySpan? getSpan() => _hub.getSpan();

/// Gets access to the metrics API for the current hub.
@Deprecated(
'Metrics will be deprecated and removed in the next major release. Sentry will reject all metrics sent after October 7, 2024. Learn more: https://sentry.zendesk.com/hc/en-us/articles/26369339769883-Upcoming-API-Changes-to-Metrics')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

m: Aren't metrics experimental? If yes, we can also remove them in a nonmajor update. I don't think it makes sense to keep the code if, anyways, we are going to reject all metrics after October 7th.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, I don't have any strong opinion on that.

@kahest what do you think?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'd deprecate now and leave some time to remove - not because it needs to be a major (can be a minor in a few weeks), but to give app maintainers at least a bit of time to learn about the deprecation and remove the code before we break their builds. even if it's likely a very small change they need to do, we don't need to force them to do it right now

Copy link
Contributor Author

@buenaflor buenaflor Sep 30, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sounds good, I guess we can approve this PR

I'd like to include that in the release

static MetricsApi metrics() => _hub.metricsApi;

@internal
Expand Down
40 changes: 0 additions & 40 deletions dart/test/metrics/local_metrics_aggregator_test.dart

This file was deleted.

315 changes: 0 additions & 315 deletions dart/test/metrics/metric_test.dart

This file was deleted.

Loading
Loading