Skip to content

Commit 96347bf

Browse files
authored
Merge branch 'main' into dependabot/github_actions/codecov/codecov-action-5.1.1
2 parents c05a101 + 00c8eeb commit 96347bf

File tree

60 files changed

+1830
-806
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

60 files changed

+1830
-806
lines changed

.github/workflows/agp-matrix.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ jobs:
7070
arch: x86
7171
channel: canary # Necessary for ATDs
7272
disk-size: 4096M
73-
script: ./gradlew sentry-android-integration-tests:sentry-uitest-android:connectedReleaseAndroidTest -DtestBuildType=release --daemon
73+
script: ./gradlew sentry-android-integration-tests:sentry-uitest-android:connectedReleaseAndroidTest -DtestBuildType=release -Denvironment=github --daemon
7474

7575
- name: Upload test results
7676
if: always()

.github/workflows/release.yml

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,22 @@ jobs:
1717
runs-on: ubuntu-latest
1818
name: "Release a new version"
1919
steps:
20+
- name: Get auth token
21+
id: token
22+
uses: actions/create-github-app-token@5d869da34e18e7287c1daad50e0b8ea0f506ce69 # v1.11.0
23+
with:
24+
app-id: ${{ vars.SENTRY_RELEASE_BOT_CLIENT_ID }}
25+
private-key: ${{ secrets.SENTRY_RELEASE_BOT_PRIVATE_KEY }}
2026
- uses: actions/checkout@v4
2127
with:
22-
token: ${{ secrets.GH_RELEASE_PAT }}
28+
token: ${{ steps.token.outputs.token }}
2329
# Needs to be set, otherwise git describe --tags will fail with: No names found, cannot describe anything
2430
fetch-depth: 0
2531
submodules: 'recursive'
2632
- name: Prepare release
2733
uses: getsentry/action-prepare-release@v1
2834
env:
29-
GITHUB_TOKEN: ${{ secrets.GH_RELEASE_PAT }}
35+
GITHUB_TOKEN: ${{ steps.token.outputs.token }}
3036
with:
3137
version: ${{ github.event.inputs.version }}
3238
force: ${{ github.event.inputs.force }}

CHANGELOG.md

Lines changed: 54 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,63 @@
11
# Changelog
22

3-
### Unreleased
3+
## Unreleased
4+
5+
### Internal
6+
7+
- Warm starts cleanup ([#3954](https://github.com/getsentry/sentry-java/pull/3954))
8+
9+
## 7.20.0
10+
11+
### Features
12+
13+
- Session Replay GA ([#4017](https://github.com/getsentry/sentry-java/pull/4017))
14+
15+
To enable Replay use the `sessionReplay.sessionSampleRate` or `sessionReplay.onErrorSampleRate` options.
16+
17+
```kotlin
18+
import io.sentry.SentryReplayOptions
19+
import io.sentry.android.core.SentryAndroid
20+
21+
SentryAndroid.init(context) { options ->
22+
23+
options.sessionReplay.sessionSampleRate = 1.0
24+
options.sessionReplay.onErrorSampleRate = 1.0
25+
26+
// To change default redaction behavior (defaults to true)
27+
options.sessionReplay.redactAllImages = true
28+
options.sessionReplay.redactAllText = true
29+
30+
// To change quality of the recording (defaults to MEDIUM)
31+
options.sessionReplay.quality = SentryReplayOptions.SentryReplayQuality.MEDIUM // (LOW|MEDIUM|HIGH)
32+
}
33+
```
34+
35+
### Fixes
36+
37+
- Fix warm start detection ([#3937](https://github.com/getsentry/sentry-java/pull/3937))
38+
- Session Replay: Reduce memory allocations, disk space consumption, and payload size ([#4016](https://github.com/getsentry/sentry-java/pull/4016))
39+
- Session Replay: Do not try to encode corrupted frames multiple times ([#4016](https://github.com/getsentry/sentry-java/pull/4016))
40+
41+
### Internal
42+
43+
- Session Replay: Allow overriding `SdkVersion` for replay events ([#4014](https://github.com/getsentry/sentry-java/pull/4014))
44+
- Session Replay: Send replay options as tags ([#4015](https://github.com/getsentry/sentry-java/pull/4015))
45+
46+
### Breaking changes
47+
48+
- Session Replay options were moved from under `experimental` to the main `options` object ([#4017](https://github.com/getsentry/sentry-java/pull/4017))
49+
50+
## 7.19.1
451

552
### Fixes
653

754
- Change TTFD timeout to 25 seconds ([#3984](https://github.com/getsentry/sentry-java/pull/3984))
55+
- Session Replay: Fix memory leak when masking Compose screens ([#3985](https://github.com/getsentry/sentry-java/pull/3985))
56+
- Session Replay: Fix potential ANRs in `GestureRecorder` ([#4001](https://github.com/getsentry/sentry-java/pull/4001))
57+
58+
### Internal
59+
60+
- Session Replay: Flutter improvements ([#4007](https://github.com/getsentry/sentry-java/pull/4007))
861

962
## 7.19.0
1063

buildSrc/src/main/java/Config.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -194,6 +194,7 @@ object Config {
194194
val mockitoKotlin = "org.mockito.kotlin:mockito-kotlin:4.1.0"
195195
val mockitoInline = "org.mockito:mockito-inline:4.8.0"
196196
val awaitility = "org.awaitility:awaitility-kotlin:4.1.1"
197+
val awaitility3 = "org.awaitility:awaitility-kotlin:3.1.6" // need this due to a conflict of awaitility4+ and espresso on hamcrest
197198
val mockWebserver = "com.squareup.okhttp3:mockwebserver:${Libs.okHttpVersion}"
198199
val jsonUnit = "net.javacrumbs.json-unit:json-unit:2.32.0"
199200
val hsqldb = "org.hsqldb:hsqldb:2.6.1"

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ android.useAndroidX=true
1313
android.defaults.buildfeatures.buildconfig=true
1414

1515
# Release information
16-
versionName=7.19.0
16+
versionName=7.20.0
1717

1818
# Override the SDK name on native crashes on Android
1919
sentryAndroidSdkName=sentry.native.android

sentry-android-core/api/sentry-android-core.api

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,12 @@ public final class io/sentry/android/core/ActivityLifecycleIntegration : android
2727
public fun onActivityCreated (Landroid/app/Activity;Landroid/os/Bundle;)V
2828
public fun onActivityDestroyed (Landroid/app/Activity;)V
2929
public fun onActivityPaused (Landroid/app/Activity;)V
30+
public fun onActivityPostCreated (Landroid/app/Activity;Landroid/os/Bundle;)V
3031
public fun onActivityPostResumed (Landroid/app/Activity;)V
32+
public fun onActivityPostStarted (Landroid/app/Activity;)V
33+
public fun onActivityPreCreated (Landroid/app/Activity;Landroid/os/Bundle;)V
3134
public fun onActivityPrePaused (Landroid/app/Activity;)V
35+
public fun onActivityPreStarted (Landroid/app/Activity;)V
3236
public fun onActivityResumed (Landroid/app/Activity;)V
3337
public fun onActivitySaveInstanceState (Landroid/app/Activity;Landroid/os/Bundle;)V
3438
public fun onActivityStarted (Landroid/app/Activity;)V
@@ -430,6 +434,20 @@ public class io/sentry/android/core/performance/ActivityLifecycleCallbacksAdapte
430434
public fun onActivityStopped (Landroid/app/Activity;)V
431435
}
432436

437+
public class io/sentry/android/core/performance/ActivityLifecycleSpanHelper {
438+
public fun <init> (Ljava/lang/String;)V
439+
public fun clear ()V
440+
public fun createAndStopOnCreateSpan (Lio/sentry/ISpan;)V
441+
public fun createAndStopOnStartSpan (Lio/sentry/ISpan;)V
442+
public fun getOnCreateSpan ()Lio/sentry/ISpan;
443+
public fun getOnCreateStartTimestamp ()Lio/sentry/SentryDate;
444+
public fun getOnStartSpan ()Lio/sentry/ISpan;
445+
public fun getOnStartStartTimestamp ()Lio/sentry/SentryDate;
446+
public fun saveSpanToAppStartMetrics ()V
447+
public fun setOnCreateStartTimestamp (Lio/sentry/SentryDate;)V
448+
public fun setOnStartStartTimestamp (Lio/sentry/SentryDate;)V
449+
}
450+
433451
public class io/sentry/android/core/performance/ActivityLifecycleTimeSpan : java/lang/Comparable {
434452
public fun <init> ()V
435453
public fun compareTo (Lio/sentry/android/core/performance/ActivityLifecycleTimeSpan;)I
@@ -442,6 +460,7 @@ public class io/sentry/android/core/performance/AppStartMetrics : io/sentry/andr
442460
public fun <init> ()V
443461
public fun addActivityLifecycleTimeSpans (Lio/sentry/android/core/performance/ActivityLifecycleTimeSpan;)V
444462
public fun clear ()V
463+
public fun createProcessInitSpan ()Lio/sentry/android/core/performance/TimeSpan;
445464
public fun getActivityLifecycleTimeSpans ()Ljava/util/List;
446465
public fun getAppStartProfiler ()Lio/sentry/ITransactionProfiler;
447466
public fun getAppStartSamplingDecision ()Lio/sentry/TracesSamplingDecision;
@@ -454,17 +473,21 @@ public class io/sentry/android/core/performance/AppStartMetrics : io/sentry/andr
454473
public static fun getInstance ()Lio/sentry/android/core/performance/AppStartMetrics;
455474
public fun getSdkInitTimeSpan ()Lio/sentry/android/core/performance/TimeSpan;
456475
public fun isAppLaunchedInForeground ()Z
476+
public fun isColdStartValid ()Z
457477
public fun onActivityCreated (Landroid/app/Activity;Landroid/os/Bundle;)V
478+
public fun onAppStartSpansSent ()V
458479
public static fun onApplicationCreate (Landroid/app/Application;)V
459480
public static fun onApplicationPostCreate (Landroid/app/Application;)V
460481
public static fun onContentProviderCreate (Landroid/content/ContentProvider;)V
461482
public static fun onContentProviderPostCreate (Landroid/content/ContentProvider;)V
462483
public fun registerApplicationForegroundCheck (Landroid/app/Application;)V
484+
public fun restartAppStart (J)V
463485
public fun setAppLaunchedInForeground (Z)V
464486
public fun setAppStartProfiler (Lio/sentry/ITransactionProfiler;)V
465487
public fun setAppStartSamplingDecision (Lio/sentry/TracesSamplingDecision;)V
466488
public fun setAppStartType (Lio/sentry/android/core/performance/AppStartMetrics$AppStartType;)V
467489
public fun setClassLoadedUptimeMs (J)V
490+
public fun shouldSendStartMeasurements ()Z
468491
}
469492

470493
public final class io/sentry/android/core/performance/AppStartMetrics$AppStartType : java/lang/Enum {
@@ -497,6 +520,7 @@ public class io/sentry/android/core/performance/TimeSpan : java/lang/Comparable
497520
public fun setStartUnixTimeMs (J)V
498521
public fun setStartedAt (J)V
499522
public fun setStoppedAt (J)V
523+
public fun setup (Ljava/lang/String;JJJ)V
500524
public fun start ()V
501525
public fun stop ()V
502526
}

0 commit comments

Comments
 (0)