ReleaseDateStrategy

@Serializable
@SerialName(value = "releaseDate")
data class ReleaseDateStrategy(val releaseDate: Instant, clock: Clock = Clock.System) : FlippingStrategy(source)

A strategy that enables a feature after a specified release date.

The feature is disabled before the release date and enabled once the current time reaches or passes the release date.

This strategy is useful for scheduling feature launches at a specific point in time without requiring a deployment or manual toggle.

See also

for enabling a feature within a specific time window

Constructors

Link copied to clipboard
constructor(releaseDate: Instant, clock: Clock = Clock.System)

Properties

Link copied to clipboard
val releaseDate: Instant

The instant after which the feature becomes enabled.

Functions

Link copied to clipboard

Combines this strategy with other using logical AND.

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open suspend override fun evaluate(featureId: String, store: FeatureStore?, context: FlippingExecutionContext): Boolean

Evaluates whether the feature should be enabled based on the execution context.

Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard

Negates this strategy.

Link copied to clipboard

Combines this strategy with other using logical OR.