refactor(remote-config): Disable in CEC mode + add observability logs#3705
Merged
Conversation
57d60c2 to
9d78258
Compare
5dd1644 to
14a6963
Compare
This was referenced Jul 3, 2026
Contributor
Author
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #3705 +/- ##
==========================================
- Coverage 80.60% 80.56% -0.05%
==========================================
Files 398 398
Lines 16421 16473 +52
Branches 2347 2356 +9
==========================================
+ Hits 13236 13271 +35
- Misses 2249 2265 +16
- Partials 936 937 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
9d78258 to
0932eb0
Compare
14a6963 to
0973813
Compare
1f1434b to
72eede3
Compare
ee90f08 to
3553a9b
Compare
72eede3 to
9110211
Compare
Two related remote-config changes stacked on the read-facade work: - Observability logs: happy-path logging across the sync flow, blob storage/download, and the read facade. Debug-level for lifecycle (refresh start, 204 not-modified, topics + items received, per-sync summary); verbose-level for fine-grained tracing (inline blob stored, blob downloaded/stored, prefetch counts, source failover, and body()/topic() resolution). Uses the existing debugLog/verboseLog helpers and the package's inline-string style; never logs blob bytes. - Disable in custom entitlement computation mode: RemoteConfigManager is no longer constructed when appConfig.customEntitlementComputation is set, gated alongside the existing BuildConfig.ENABLE_REMOTE_CONFIG check in PurchasesFactory. To keep refreshRemoteConfig under detekt's LongMethod limit, the 204 handling and the refresh-start log were extracted into handleNotModified / logRefreshStart helpers (behavior-preserving). Test plan: - ./gradlew detektAll - ./gradlew :purchases:testDefaultsBc8DebugUnitTest --tests "com.revenuecat.purchases.common.remoteconfig.*" Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
9110211 to
8ee1c29
Compare
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, have a team admin enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 8ee1c29. Configure here.
Address Cursor Bugbot review comments on the new remote config logs: - Gate the "Stored inlined remote config blob" success log on write() returning true - Log a warn instead of a misleading "Resolved (0 bytes)" when a downloaded blob reads back null - Use warnLog (not verboseLog) for a failed blob resolution Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.


2 main changes in this one:
Note
Low Risk
Changes are gated CEC wiring plus logging and small read-path optimizations; no new network or entitlement logic for standard SDK builds.
Overview
Remote Config is no longer wired up when the SDK runs in custom entitlement computation (CEC) mode —
RemoteConfigManageris only created when the feature flag is on andappConfig.customEntitlementComputationis false.Observability is expanded across the remote config stack: refresh start, 204 handling, persist/prefetch, cold reads, topic/blob resolution, blob download failover, and prefetch enqueue counts. Most of this is
verboseLog; successful config receipt/persist and unchanged 204 responses usedebugLog, withwarnLogwhen a blob download succeeds but read-back fails.Minor behavior tweaks alongside logging:
topic()only waits for or triggers a sync when the topic is not already cached; inline blob extraction logs success only whenwrite()actually stores the blob.Reviewed by Cursor Bugbot for commit ae39abe. Bugbot is set up for automated code reviews on this repo. Configure here.