firebase / firebase-cpp-sdk

Firebase C++ SDK
http://firebase.google.com
Apache License 2.0
271 stars 111 forks source link

[Bug] Users % targettig does not seem to work as one could think is does #1038

Open pawel-gener8 opened 1 year ago

pawel-gener8 commented 1 year ago

[REQUIRED] Please fill in the following fields:

[REQUIRED] Please describe the issue here:

Users % targettig does not seem to work as it should. It rolls a dice every fetch so it does not have any notion of a user or client thus single client can get various configs every fetch

Steps to reproduce:

Configure remote config so it has a user % based condition and serve one config (config A) for 50% of users and the other (config B) for the rest. Fetch the config multiple times. Expected: A user who got config A keeps getting config A and the one who got config B always gets config B. Actual: The user who got config A gets config B on subsequent fetch.

Relevant Code:

chkuang-g commented 1 year ago

Hi @pawel-gener8

If you are using Remote Config on desktop, ex. Windows and macOS, users % targeting won't work because it relies Firebase Installation (to make sure the same installation always get the same config). And we do not have Firebase Installation implementation for desktop yet. :( Therefore, this random behavior is expected.

Currently, such feature only works on mobile devices like Android and iOS.

Please confirm if this is the case. If so, we can turn this into a feature request.

As a feature, this requires two components:

  1. Firebase Installation desktop implementation
  2. Firebase Remote Config API sends request with FIS id.
pawel-gener8 commented 1 year ago

Hi @chkuang-g,

That's exactly my case i.e. using remote config on desktop so please convert this into a feature request. Thanks in advance.