mirror of
https://github.com/Unleash/unleash.git
synced 2025-11-24 20:06:55 +01:00
This PR cleans up the etagByEnv flag. These changes were automatically generated by AI and should be reviewed carefully. Fixes #10556 ## 🧹 AI Flag Cleanup Summary This change removes the `etagByEnv` feature flag and makes its functionality permanent. This modifies the ETag generation for client API requests to be environment-specific, improving caching efficiency. The cleanup involved removing the flag definition, updating the controller logic to permanently use the environment-specific ETag calculation, and refactoring the corresponding E2E tests to only cover the enabled behavior. ### 🚮 Removed - **Flag Definition** - The `etagByEnv` flag from `IFlagKey` in `src/lib/types/experimental.ts`. - **Conditional Logic** - The check for the `etagByEnv` flag in `calculateMeta` method in `src/lib/features/client-feature-toggles/client-feature-toggle.controller.ts`. - **Tests** - Test cases in `src/test/e2e/api/client/feature.optimal304.e2e.test.ts` that covered the disabled state of the `etagByEnv` flag. ### 🛠 Kept - **Environment-Specific ETags** - The behavior of generating environment-specific ETags is now the default and only behavior. - **Tests** - E2E tests verifying the functionality of environment-specific ETags have been retained and simplified. ### 📝 Why The `etagByEnv` feature has been successfully rolled out and validated. By removing the feature flag and associated conditional logic, we simplify the codebase, reduce complexity, and make it easier to maintain. This change makes the improved ETag generation strategy a permanent part of the system. --------- Co-authored-by: unleash-bot <194219037+unleash-bot[bot]@users.noreply.github.com> Co-authored-by: Gastón Fournier <gaston@getunleash.io> |
||
|---|---|---|
| .. | ||
| delta | ||
| fakes | ||
| tests | ||
| types | ||
| client-feature-toggle-service.ts | ||
| client-feature-toggle-store.ts | ||
| client-feature-toggle.controller.ts | ||
| createClientFeatureToggleService.ts | ||