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

[Rollouts] Implement insert and load logic for rollout metadata in RC #12262

Merged
merged 9 commits into from
Jan 18, 2024

Conversation

ddnan
Copy link
Contributor

@ddnan ddnan commented Jan 10, 2024

Add insertOrUpdate method to persist rollout metadata in sqlite db
Add load method to load rollout metadata from sqlite db

Note: this change will merge to our feature branch not master
#no-changelog

@ddnan ddnan self-assigned this Jan 10, 2024
@ddnan ddnan marked this pull request as ready for review January 10, 2024 20:37
Copy link
Contributor

@danasilver danasilver left a comment

Choose a reason for hiding this comment

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

A couple minor things and questions. Nice work; this is a really tricky codebase

FirebaseRemoteConfig/Sources/RCNConfigContent.m Outdated Show resolved Hide resolved
FirebaseRemoteConfig/Sources/RCNConfigDBManager.h Outdated Show resolved Hide resolved
@@ -134,6 +140,14 @@ - (void)loadConfigFromMainTable {
self->_activePersonalization = [activePersonalization copy];
dispatch_group_leave(self->_dispatch_group);
}];

dispatch_group_enter(_dispatch_group);
Copy link
Contributor

Choose a reason for hiding this comment

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

Is it possible to do this in loadMainWithBundleIdentifier? It looks like there's an existing todo above to do that for personalization, so it'd be nice if we can avoid it here

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Moved rollout metadata loading to loadMain.

FirebaseRemoteConfig/Sources/RCNConfigDBManager.h Outdated Show resolved Hide resolved
FirebaseRemoteConfig/Sources/RCNConfigDBManager.h Outdated Show resolved Hide resolved
FirebaseRemoteConfig/Sources/RCNConfigDBManager.m Outdated Show resolved Hide resolved
FirebaseRemoteConfig/Sources/RCNConfigDBManager.m Outdated Show resolved Hide resolved
Copy link
Contributor

@themiswang themiswang left a comment

Choose a reason for hiding this comment

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

Two more minor comment and overall LGTM! Another nit I just realized in RC for all NSArray and NSDictionary there is no type declaration for the element. In Crash we do Array<NSString *>* something like this to improve readability. Might be good to start this change from your PR and it will def help the folks outside your team to review PRs!

@ddnan ddnan changed the title [Rollout] Implement insert and load logic for rollout metadata [Rollouts] Implement insert and load logic for rollout metadata in RC Jan 18, 2024
@ddnan ddnan merged commit 822fcdf into featureRollouts Jan 18, 2024
68 of 69 checks passed
@ddnan ddnan deleted the ddn-rc branch January 18, 2024 18:43
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants