Hi Team, We have integrated Growthbook using the ...
# ask-questions
n
Hi Team, We have integrated Growthbook using the React SDK and realized that live updates are not necessary for our specific use case. Therefore, we have configured the GrowthBook instance as shown below:
Copy code
const gb = new GrowthBook({
  apiHost: GROWTH_BOOK_API_HOST,
  clientKey: GROWTH_BOOK_CLIENT_KEY,
  // Enable easier debugging during development
  enableDevMode: true,
  // Disable background streaming connection
  backgroundSync: false,
  subscribeToChanges: false,
  trackingCallback: (experiment, result) => {
    // analytics tracking
  }
});
However, despite these settings, we still observe that the streaming API requests are being made every 5 minutes. Additionally, the GrowthBook dashboard indicates that streaming updates are enabled in the SDK connection. Please advise on how to disable the streaming updates.
f
Does this still happen after you clear localStorage cache? Wondering if it's caching the previous default backgroundSync setting and not updating properly
n
yes, it's still the same even after clearing the localStorage cache. Tried in private window as well, but no luck.
f
Ok. I'll take a look and see if I'm able to reproduce. Setting
backgroundSync
to false should in theory stop those streaming requests from happening.
👍 1
n
Is there any way we can see the usage of the API in our account?
f
I am able to look that up for you if you share your clientKey (can be in a DM if you don't want to share publicly). I can also disable streaming for your account on our end in the meantime
n
Ok sure.
f
One thing I forgot to ask. What version of the React SDK are you using? The
backgroundSync
option was added in version
0.18.0
, so if you are using an earlier version it won't work.
n
Oh, Okay. I using 0.17.0 and that might be the reason. I will update it to latest.
Thanks