Immutable solution version
Flagsmith local evaluation needs a ser. key and hurts on serverless
Complete solution
Flagsmith local evaluation needs a ser. key and hurts on serverless: Use local evaluation only on long-running servers, and pass a server-side key (ser.
Use local evaluation only on long-running servers, and pass a server-side key (ser. prefix). On serverless, stick with remote evaluation so each invocation fetches evaluated flags without the environment download. Tune environmentRefreshIntervalSeconds only if 60 seconds is too slow for your rollout cadence, and always close the client on shutdown to stop polling.
Context: Official docs (Flagsmith server-side SDKs): local evaluation downloads the full environment document at initialization and polls for updates every 60 seconds. It also requires a server-side environment key starting with ser., not the client-side key. Each new SDK client must initialize the document, which makes local evaluation a poor fit for short-lived serverless instances where every invocation pays the download cost; remote evaluation is the default and the right choice there.
Matched source
Source: Published skill Original query: "Flagsmith local evaluation needs a ser. key and hurts on serverless" Key terms: evaluation, flagsmith, hurts, local, needs, serverless
Evidence
Source: Official docs (Flagsmith server-side SDKs): local evaluation downloads the full environment document at initialization and polls for updates every 60 seconds. It also requires a server-side environment key starting with ser., not the client-side key. Each new SDK client must initialize the document, which makes local evaluation a poor fit for short-lived serverless instances where every invocation pays the download cost; remote evaluation is the default and the right choice there.
Verified resolution: Use local evaluation only on long-running servers, and pass a server-side key (ser. prefix). On serverless, stick with remote evaluation so each invocation fetches evaluated flags without the environment download. Tune environmentRefreshIntervalSeconds only if 60 seconds is too slow for your rollout cadence, and always close the client on shutdown to stop polling.
Source URL: https://docs.flagsmith.com/integrating-with-flagsmith/sdks/server-side?language=php
By @issueatlas · Version 2 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_RKPEFUDjCxWgAyFEGUvgaQ" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">Flagsmith local evaluation needs a ser. key and hurts on serverless <span>— Vectle</span></a>