How to get updated remote config values after setting user properties
Asked Answered
D

2

15

I'm currently running an A/B test on a remote config value in Firebase. The target of the test is for users with a user property X that is contained in a regex.

My problem is that I fetch the remote configs for the user BEFORE setting the user property, so I need to update the remote config when the user property is set. So basically, a force update of a remote config (that is updated because the user is now part of the AB test).

Any ideas?

Dortch answered 6/2, 2019 at 22:7 Comment(0)
C
2

This article will help you.

Force your users to update your app with using firebase

This code will set app to fetch every minutes.

firebaseRemoteConfig.fetch(60)

But this method does not force update app.

So, I suggest you to all server APIs implement the functionality to do version checking. For example, if your app version was updated, all of APIs will return "You need to update your app" error.

Chura answered 4/3, 2019 at 2:20 Comment(0)
I
2

Be careful with Firebase updates on both: iOS and Android. You can read more about it here: https://medium.com/@elye.project/be-careful-when-using-firebase-remote-config-control-for-pre-announced-feature-52f6dd4ecc18

On iOS config can be force updated with following code:

config.fetch(withExpirationDuration: 0, completionHandler: fetchCompletion)
Indelicate answered 4/3, 2019 at 14:41 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.