getsentry / getsentry/sentry-java
Add support for Firebase Remote Config Feature Flags
- 主要言語
- Kotlin
- スター
- 1.4k
- フォーク
- 478
- 平均マージ
- 2日 23時間
- マージ済み PR(30日)
- 67
説明
### Problem Statement
Add a hook for Firebase Remote Config that tracks Feature Flag evaluations in Sentry.
### Solution Brainstorm
Something like:
```java
public class SentryFirebaseRemoteConfigListener implements ConfigUpdateListener {
private final IScopes scopes;
private final FirebaseRemoteConfig remoteConfig;
@Override
public void onUpdate(ConfigUpdate configUpdate) {
// Track all boolean flags that were updated
Set updatedKeys = configUpdate.getUpdatedKeys();
for (String key : updatedKeys) {
try {
boolean value = remoteConfig.getBoolean(key);
scopes.addFeatureFlag(key, value);
} catch (Exception e) {
// Log error, don't break
}
}
}
@Override
public void onError(ConfigUpdateException error) {
// Log error but don't track as feature flag
}
}
```
Also look at what Flutter SDK is doing: https://github.com/getsentry/sentry-dart/blob/main/packages/firebase_remote_config/lib/src/sentry_firebase_remote_config_integration.dart
Please 👍 if you would like us to implement this.
コントリビューションガイド
評価
この issue はまだ評価されていません。