feat: add @env-var tag to env-var config scenarios#359
Conversation
Tag all scenario outlines that mutate System environment variables so the Cucumber exclusive-resources mechanism can serialise them during parallel execution (ENV_VARS resource lock in junit-platform.properties). Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: Simon Schrottner <simon.schrottner@dynatrace.com>
There was a problem hiding this comment.
Code Review
This pull request updates the gherkin/config.feature file by adding the @env-var tag to several scenarios that manipulate environment variables. This is likely intended to facilitate resource locking or isolation during test execution. A review comment suggests extending this tag to scenarios that read default environment values to prevent potential race conditions and state leakage when tests are run concurrently.
|
Thanks for the review! The In the Java SDK (the companion PR), we handle the config suite differently: Tagging reader-only scenarios like "Default Config" with |
Add active TCP health checks (interval=1s) and reduce connect_timeout from the default 5s to 0.25s on both flagd clusters (RPC port 8013, sync port 8015). This ensures envoy detects and recovers from upstream flagd restarts within one health-check cycle rather than waiting for a client-triggered connection attempt. Combined with the shorter connect_timeout, failed connections are detected and retried quickly rather than blocking for up to 5 seconds. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Signed-off-by: Simon Schrottner <simon.schrottner@dynatrace.com>
Summary
Adds the
@env-vartag to all config scenarios that mutate system environment variables viaGiven an environment variable ... with value ....Motivation
SDKs that run Cucumber scenarios in parallel need a way to serialise scenarios that mutate global process state (environment variables). Cucumber's exclusive resource mechanism can lock on a tag, but only if the feature files actually carry that tag.
Without
@env-var, parallel runners either:FLAGD_PORT=3456leaking into a scenario expecting8015).Tagged scenarios
@env-var@env-var(appended to existing)@env-var(appended to existing)@env-var@env-var(appended to existing)Companion to: open-feature/java-sdk-contrib#1752