diff --git a/gherkin/config.feature b/gherkin/config.feature index f246229..c3944a0 100644 --- a/gherkin/config.feature +++ b/gherkin/config.feature @@ -14,7 +14,7 @@ Feature: Configuration Test | streamDeadlineMs | FLAGD_STREAM_DEADLINE_MS | deadline for streaming calls, useful as an application-layer keepalive | int | 600000 | rpc & in-process | | retryBackoffMs | FLAGD_RETRY_BACKOFF_MS | initial backoff for stream retry | int | 1000 | rpc & in-process | | retryBackoffMaxMs | FLAGD_RETRY_BACKOFF_MAX_MS | maximum backoff for stream retry | int | 120000 | rpc & in-process | - | retryGraceAttempts | FLAGD_RETRY_GRACE_ATTEMPTS | amount of stream retry attempts before provider moves from STALE to ERROR state | int | 5 | rpc & in-process | + | retryGracePeriod | FLAGD_RETRY_GRACE_PERIOD | amount of stream retry attempts before provider moves from STALE to ERROR state | int | 5 | rpc & in-process | | keepAliveTime | FLAGD_KEEP_ALIVE_TIME_MS | http 2 keepalive | long | 0 | rpc & in-process | | cache | FLAGD_CACHE | enable cache of static flags | String - `lru`, `disabled` | lru | rpc | | maxCacheSize | FLAGD_MAX_CACHE_SIZE | max size of static flag cache | int | 1000 | rpc | @@ -49,21 +49,21 @@ Feature: Configuration Test | socketPath | String | null | @events Examples: Events - | option | type | default | - | streamDeadlineMs | Integer | 600000 | - | keepAliveTime | Long | 0 | - | retryBackoffMs | Integer | 1000 | - | retryBackoffMaxMs | Integer | 120000 | - | retryGraceAttempts | Integer | 5 | + | option | type | default | + | streamDeadlineMs | Integer | 600000 | + | keepAliveTime | Long | 0 | + | retryBackoffMs | Integer | 1000 | + | retryBackoffMaxMs | Integer | 120000 | + | retryGracePeriod | Integer | 5 | @sync Examples: Sync - | option | type | default | - | streamDeadlineMs | Integer | 600000 | - | keepAliveTime | Long | 0 | - | retryBackoffMs | Integer | 1000 | - | retryBackoffMaxMs | Integer | 120000 | - | retryGraceAttempts | Integer | 5 | - | selector | String | null | + | option | type | default | + | streamDeadlineMs | Integer | 600000 | + | keepAliveTime | Long | 0 | + | retryBackoffMs | Integer | 1000 | + | retryBackoffMaxMs | Integer | 120000 | + | retryGracePeriod | Integer | 5 | + | selector | String | null | @caching Examples: caching | option | type | default | @@ -119,21 +119,21 @@ Feature: Configuration Test | socketPath | String | path | @events Examples: - | option | type | value | - | streamDeadlineMs | Integer | 500000 | - | keepAliveTime | Long | 5 | - | retryBackoffMs | Integer | 5000 | - | retryBackoffMaxMs | Integer | 12000 | - | retryGraceAttempts | Integer | 10 | + | option | type | value | + | streamDeadlineMs | Integer | 500000 | + | keepAliveTime | Long | 5 | + | retryBackoffMs | Integer | 5000 | + | retryBackoffMaxMs | Integer | 12000 | + | retryGracePeriod | Integer | 10 | @sync Examples: - | option | type | value | - | streamDeadlineMs | Integer | 500000 | - | keepAliveTime | Long | 5 | - | retryBackoffMs | Integer | 5000 | - | retryBackoffMaxMs | Integer | 12000 | - | retryGraceAttempts | Integer | 10 | - | selector | String | selector | + | option | type | value | + | streamDeadlineMs | Integer | 500000 | + | keepAliveTime | Long | 5 | + | retryBackoffMs | Integer | 5000 | + | retryBackoffMaxMs | Integer | 12000 | + | retryGracePeriod | Integer | 10 | + | selector | String | selector | @caching Examples: | option | type | value | @@ -174,21 +174,21 @@ Feature: Configuration Test | socketPath | FLAGD_SOCKET_PATH | String | path | @events Examples: - | option | env | type | value | - | streamDeadlineMs | FLAGD_STREAM_DEADLINE_MS | Integer | 500000 | - | keepAliveTime | FLAGD_KEEP_ALIVE_TIME_MS | Long | 5 | - | retryBackoffMs | FLAGD_RETRY_BACKOFF_MS | Integer | 5000 | - | retryBackoffMaxMs | FLAGD_RETRY_BACKOFF_MAX_MS | Integer | 12000 | - | retryGraceAttempts | FLAGD_RETRY_GRACE_ATTEMPTS | Integer | 10 | + | option | env | type | value | + | streamDeadlineMs | FLAGD_STREAM_DEADLINE_MS | Integer | 500000 | + | keepAliveTime | FLAGD_KEEP_ALIVE_TIME_MS | Long | 5 | + | retryBackoffMs | FLAGD_RETRY_BACKOFF_MS | Integer | 5000 | + | retryBackoffMaxMs | FLAGD_RETRY_BACKOFF_MAX_MS | Integer | 12000 | + | retryGracePeriod | FLAGD_RETRY_GRACE_PERIOD | Integer | 10 | @sync Examples: - | option | env | type | value | - | streamDeadlineMs | FLAGD_STREAM_DEADLINE_MS | Integer | 500000 | - | keepAliveTime | FLAGD_KEEP_ALIVE_TIME_MS | Long | 5 | - | retryBackoffMs | FLAGD_RETRY_BACKOFF_MS | Integer | 5000 | - | retryBackoffMaxMs | FLAGD_RETRY_BACKOFF_MAX_MS | Integer | 12000 | - | retryGraceAttempts | FLAGD_RETRY_GRACE_ATTEMPTS | Integer | 10 | - | selector | FLAGD_SOURCE_SELECTOR | String | selector | + | option | env | type | value | + | streamDeadlineMs | FLAGD_STREAM_DEADLINE_MS | Integer | 500000 | + | keepAliveTime | FLAGD_KEEP_ALIVE_TIME_MS | Long | 5 | + | retryBackoffMs | FLAGD_RETRY_BACKOFF_MS | Integer | 5000 | + | retryBackoffMaxMs | FLAGD_RETRY_BACKOFF_MAX_MS | Integer | 12000 | + | retryGracePeriod | FLAGD_RETRY_GRACE_PERIOD | Integer | 10 | + | selector | FLAGD_SOURCE_SELECTOR | String | selector | @caching Examples: | option | env | type | value | @@ -227,21 +227,21 @@ Feature: Configuration Test | socketPath | FLAGD_SOCKET_PATH | String | path | rpc | @events Examples: - | option | env | type | value | env-value | - | streamDeadlineMs | FLAGD_STREAM_DEADLINE_MS | Integer | 500000 | 400 | - | keepAliveTime | FLAGD_KEEP_ALIVE_TIME_MS | Long | 5 | 4 | - | retryBackoffMs | FLAGD_RETRY_BACKOFF_MS | Integer | 5000 | 4 | - | retryBackoffMaxMs | FLAGD_RETRY_BACKOFF_MAX_MS | Integer | 12000 | 4 | - | retryGraceAttempts | FLAGD_RETRY_GRACE_ATTEMPTS | Integer | 10 | 4 | + | option | env | type | value | env-value | + | streamDeadlineMs | FLAGD_STREAM_DEADLINE_MS | Integer | 500000 | 400 | + | keepAliveTime | FLAGD_KEEP_ALIVE_TIME_MS | Long | 5 | 4 | + | retryBackoffMs | FLAGD_RETRY_BACKOFF_MS | Integer | 5000 | 4 | + | retryBackoffMaxMs | FLAGD_RETRY_BACKOFF_MAX_MS | Integer | 12000 | 4 | + | retryGracePeriod | FLAGD_RETRY_GRACE_PERIOD | Integer | 10 | 4 | @sync Examples: - | option | env | type | value | env-value | - | streamDeadlineMs | FLAGD_STREAM_DEADLINE_MS | Integer | 500000 | 400 | - | keepAliveTime | FLAGD_KEEP_ALIVE_TIME_MS | Long | 5 | 4 | - | retryBackoffMs | FLAGD_RETRY_BACKOFF_MS | Integer | 5000 | 4 | - | retryBackoffMaxMs | FLAGD_RETRY_BACKOFF_MAX_MS | Integer | 12000 | 4 | - | retryGraceAttempts | FLAGD_RETRY_GRACE_ATTEMPTS | Integer | 10 | 4 | - | selector | FLAGD_SOURCE_SELECTOR | String | selector | sele | + | option | env | type | value | env-value | + | streamDeadlineMs | FLAGD_STREAM_DEADLINE_MS | Integer | 500000 | 400 | + | keepAliveTime | FLAGD_KEEP_ALIVE_TIME_MS | Long | 5 | 4 | + | retryBackoffMs | FLAGD_RETRY_BACKOFF_MS | Integer | 5000 | 4 | + | retryBackoffMaxMs | FLAGD_RETRY_BACKOFF_MAX_MS | Integer | 12000 | 4 | + | retryGracePeriod | FLAGD_RETRY_GRACE_PERIOD | Integer | 10 | 4 | + | selector | FLAGD_SOURCE_SELECTOR | String | selector | sele | @caching Examples: | option | env | type | value | env-value | diff --git a/gherkin/events.feature b/gherkin/events.feature index 8956022..652dc18 100644 --- a/gherkin/events.feature +++ b/gherkin/events.feature @@ -2,10 +2,11 @@ Feature: Flagd Provider State Changes Background: - Given a unstable flagd provider + Given a stable flagd provider Scenario Outline: Provider events Given a event handler + When the connection is lost for 6s Then the event handler should have been executed Examples: | event | @@ -17,11 +18,8 @@ Feature: Flagd Provider State Changes Given a ready event handler And a error event handler And a stale event handler - When a ready event was fired Then the ready event handler should have been executed - When a stale event was fired + When the connection is lost for 6s Then the stale event handler should have been executed - When a error event was fired Then the error event handler should have been executed - When a ready event was fired Then the ready event handler should have been executed diff --git a/gherkin/flagd-reconnect.feature b/gherkin/flagd-reconnect.feature index 434c3bf..31c88e5 100644 --- a/gherkin/flagd-reconnect.feature +++ b/gherkin/flagd-reconnect.feature @@ -3,13 +3,14 @@ Feature: flagd provider disconnect and reconnect functionality # This test suite tests the reconnection functionality of flagd providers Scenario: Provider reconnection - Given a unstable flagd provider + Given a stable flagd provider And a ready event handler And a error event handler When a ready event was fired Then the ready event handler should have been executed - When a error event was fired + When the connection is lost for 6s Then the error event handler should have been executed + Then the ready event handler should have been executed Scenario: Provider unavailable Given an option "deadlineMs" of type "Integer" with value "1000" diff --git a/gherkin/flagd-rpc-caching.feature b/gherkin/flagd-rpc-caching.feature index f124072..8d86a47 100644 --- a/gherkin/flagd-rpc-caching.feature +++ b/gherkin/flagd-rpc-caching.feature @@ -42,9 +42,7 @@ Feature: Flag evaluation with Caching Then the reason should be "CACHED" Scenario: Stale and Error stage - Given an option "cache" of type "CacheType" with value "lru" - And a unstable flagd provider - And a ready event handler + Given a ready event handler And a stale event handler And a error event handler And a String-flag with key "changing-flag" and a default value "false" @@ -52,7 +50,8 @@ Feature: Flag evaluation with Caching Then the reason should be "STATIC" When the flag was evaluated with details Then the reason should be "CACHED" - When a stale event was fired + When the connection is lost for 6s + And a stale event was fired And the flag was evaluated with details Then the reason should be "CACHED" When a error event was fired diff --git a/gherkin/flagd.feature b/gherkin/flagd.feature index 0ceb06f..ab0fa51 100644 --- a/gherkin/flagd.feature +++ b/gherkin/flagd.feature @@ -1,4 +1,3 @@ -@rpc @in-process @evaluation Feature: flagd providers # This test suite contains scenarios to test flagd providers.