Module unleash_api_client::strategy
source · Expand description
Traits§
- Apply memoised state to a context.
Functions§
- This function is a strategy decorator which compiles to nothing when there are no constraints, or to a constraint evaluating test if there are.
- https://docs.getunleash.io/user_guide/activation_strategy#gradual-rollout stickiness: [default|userId|sessionId|random] groupId: hash key rollout: percentage
- Get the group and rollout parameters for gradual rollouts.
- https://docs.getunleash.io/user_guide/activation_strategy#hostnames hostNames: names,of,hosts
- Calculates a hash in the standard way expected for Unleash clients. Not required for extension strategies, but reusing this is probably a good idea for consistency across implementations.
- Calculates a hash for variant distribution in the standard way expected for Unleash clients. This differs from the
normalised_hash
function in that it uses a different seed to ensure a fair distribution. - Implement partial rollout given a group a variable part and a rollout amount
- https://docs.getunleash.io/user_guide/activation_strategy#ips IPs: 1.2.3.4,AB::CD::::EF,1.2/8
- https://docs.getunleash.io/user_guide/activation_strategy#gradualrolloutsessionid-deprecated-from-v4---use-gradual-rollout-instead percentage: 0-100 groupId: hash key
- https://docs.getunleash.io/user_guide/activation_strategy#gradualrolloutuserid-deprecated-from-v4---use-gradual-rollout-instead percentage: 0-100 groupId: hash key
- https://docs.getunleash.io/user_guide/activation_strategy#userids userIds: user,ids,to,match
Type Aliases§
- Memoise feature state for a strategy.