-
-
Notifications
You must be signed in to change notification settings - Fork 835
Description
Describe the bug
In Unleash v7.2+, changes to feature flags that are not tied to a specific environment are not propagated to clients using polling mode. As a result, clients (and Edge) keep serving stale feature data until an unrelated environment-scoped change occurs (e.g. toggling a flag on/off).
This happens because some non-environment changes still affect the environment-scoped feature payload, but do not update the revision ID used for cache invalidation / polling. Consequently, polling clients never detect the change.
This regression does not occur in Unleash 7.0 or 7.1.x (tested up to 7.1.2), and was introduced in 7.2.
Restarting Edge or clients does not resolve the issue. Making an unrelated environment change does fix it, which strongly suggests incorrect revision handling.
Steps to reproduce the bug
Example (archiving case):
- Run Unleash v7.2+.
- Create a feature flag enabled in an environment.
- Archive the feature (archive is environment-agnostic).
- Query the
/api/client/featuresendpoint using an environment token. - Observe that the archived feature is still returned.
- Unarchive the feature.
- Check again: The feature is returned but with incorrect state.
- Toggle the feature on/off.
- Poll again: data is now correct.
Similar reproduction applies to:
- Adding/removing a parent flag
- Changing impression data
- Moving the feature to another project
Expected behavior
Any change that affects the environment-scoped feature payload should:
- Update the revision ID for that environment
- Be detected by polling clients
- Result in updated feature data without requiring unrelated changes
Polling clients should always converge to the correct state.
Logs, error output, etc.
Screenshots
No response
Additional context
- Confirmed not to be an Edge-specific issue (same behavior observed directly against the backend).
- Regression introduced in v7.2.
- Root cause identified: revision handling does not account for non-environment changes that still affect environment responses.
- Likely related to PR chore(AI): etagByEnv flag cleanup #10560.
- Proposed fix adjusts revision calculation to correctly account for environment-impacting changes.
Unleash version
7.2.0
Subscription type
None
Hosting type
None
SDK information (language and version)
No response
Metadata
Metadata
Assignees
Labels
Type
Projects
Status