Skip to content

Commit

Permalink
feat(debugmeta): Add getProguardUuid (#3054)
Browse files Browse the repository at this point in the history
  • Loading branch information
krystofwoldrich authored Nov 20, 2023
1 parent 8838e01 commit 8d1b70a
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
- (Internal) Extract Android Profiler and Measurements for Hybrid SDKs ([#3016](https://github.com/getsentry/sentry-java/pull/3016))
- (Internal) Remove SentryOptions dependency from AndroidProfiler ([#3051](https://github.com/getsentry/sentry-java/pull/3051))
- (Internal) Add `readBytesFromFile` for use in Hybrid SDKs ([#3052](https://github.com/getsentry/sentry-java/pull/3052))
- (Internal) Add `getProguardUuid` for use in Hybrid SDKs ([#3054](https://github.com/getsentry/sentry-java/pull/3054))

### Fixes

Expand Down
1 change: 1 addition & 0 deletions sentry/api/sentry.api
Original file line number Diff line number Diff line change
Expand Up @@ -4365,6 +4365,7 @@ public final class io/sentry/util/DebugMetaPropertiesApplier {
public static field DEBUG_META_PROPERTIES_FILENAME Ljava/lang/String;
public fun <init> ()V
public static fun applyToOptions (Lio/sentry/SentryOptions;Ljava/util/Properties;)V
public static fun getProguardUuid (Ljava/util/Properties;)Ljava/lang/String;
}

public final class io/sentry/util/ExceptionUtils {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,13 @@ private static void applyBundleIds(
private static void applyProguardUuid(
final @NotNull SentryOptions options, final @NotNull Properties debugMetaProperties) {
if (options.getProguardUuid() == null) {
final @Nullable String proguardUuid =
debugMetaProperties.getProperty("io.sentry.ProguardUuids");
final @Nullable String proguardUuid = getProguardUuid(debugMetaProperties);
options.getLogger().log(SentryLevel.DEBUG, "Proguard UUID found: %s", proguardUuid);
options.setProguardUuid(proguardUuid);
}
}

public static @Nullable String getProguardUuid(final @NotNull Properties debugMetaProperties) {
return debugMetaProperties.getProperty("io.sentry.ProguardUuids");
}
}

0 comments on commit 8d1b70a

Please sign in to comment.