https://www.growthbook.io/ logo
m

many-kilobyte-13948

11/21/2022, 12:48 PM
Hello, How do you deal with getting updates of feature flags in Cloud Functions (e.g. AWS lambda). ā€¢ Just fetching the features on every feature check? ā€¢ Using the webhook is not an option in this scenario because the lambda function/docker container is behind a load balancer šŸ¤” is that correct or do i have a mistake in my understanding?
f

future-teacher-7046

11/21/2022, 2:51 PM
Hi Valentin. There are a few ways to do it. 1. Fetch the features in your lambda outside of the event handler (so they are shared between invocations). Add logic to re-fetch if more than X seconds old. 2. Add a webhook that persists the feature JSON in something like Redis or DynamoDB. Read from there in your functions.
šŸ™ 1
9 Views