Feature flag

Feature Flag Attributes

This document defines attributes for Feature Flags.

Attributes:

KeyStabilityValue TypeDescriptionExample Values
feature_flag.context.idRelease CandidatestringThe unique identifier for the flag evaluation context. For example, the targeting key.5157782b-2203-4c80-a857-dbbd5e7761db
feature_flag.keyRelease CandidatestringThe lookup key of the feature flag.logo-color
feature_flag.provider.nameRelease CandidatestringIdentifies the feature flag provider.Flag Manager
feature_flag.result.reasonRelease CandidatestringThe reason code which shows how a feature flag value was determined.static; targeting_match; error; default
feature_flag.result.valueRelease CandidateanyThe evaluated value of the feature flag. [1]#ff0000; true; 3
feature_flag.result.variantRelease CandidatestringA semantic identifier for an evaluated flag value. [2]red; true; on
feature_flag.set.idRelease CandidatestringThe identifier of the flag set to which the feature flag belongs.proj-1; ab98sgs; service1/dev
feature_flag.versionRelease CandidatestringThe version of the ruleset used during the evaluation. This may be any stable value which uniquely identifies the ruleset.1; 01ABCDEF

[1] feature_flag.result.value: With some feature flag providers, feature flag results can be quite large or contain private or sensitive details. Because of this, feature_flag.result.variant is often the preferred attribute if it is available.

It may be desirable to redact or otherwise limit the size and scope of feature_flag.result.value if possible. Because the evaluated flag value is unstructured and may be any type, it is left to the instrumentation author to determine how best to achieve this.

[2] feature_flag.result.variant: A semantic identifier, commonly referred to as a variant, provides a means for referring to a value without including the value itself. This can provide additional context for understanding the meaning behind a value. For example, the variant red maybe be used for the value #c05543.


feature_flag.result.reason has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
cachedThe resolved value was retrieved from cache.Release Candidate
defaultThe resolved value fell back to a pre-configured value (no dynamic evaluation occurred or dynamic evaluation yielded no result).Release Candidate
disabledThe resolved value was the result of the flag being disabled in the management system.Release Candidate
errorThe resolved value was the result of an error.Release Candidate
splitThe resolved value was the result of pseudorandom assignment.Release Candidate
staleThe resolved value is non-authoritative or possibly out of dateRelease Candidate
staticThe resolved value is static (no dynamic evaluation).Release Candidate
targeting_matchThe resolved value was the result of a dynamic evaluation, such as a rule or specific user-targeting.Release Candidate
unknownThe reason for the resolved value could not be determined.Release Candidate

Deprecated Feature Flag Attributes

Describes deprecated feature flag attributes.

Attributes:

KeyStabilityValue TypeDescriptionExample Values
feature_flag.evaluation.error.messageDeprecated
Replaced by error.message.
stringDeprecated, use error.message instead.Flag header-colorexpected typestringbut found typenumber``
feature_flag.evaluation.reasonDeprecated
Replaced by feature_flag.result.reason.
stringDeprecated, use feature_flag.result.reason instead.static; targeting_match; error; default
feature_flag.provider_nameDeprecated
Replaced by feature_flag.provider.name.
stringDeprecated, use feature_flag.provider.name instead.Flag Manager
feature_flag.variantDeprecated
Replaced by feature_flag.result.variant.
stringDeprecated, use feature_flag.result.variant instead.red; true; on

feature_flag.evaluation.reason has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
cachedThe resolved value was retrieved from cache.Development
defaultThe resolved value fell back to a pre-configured value (no dynamic evaluation occurred or dynamic evaluation yielded no result).Development
disabledThe resolved value was the result of the flag being disabled in the management system.Development
errorThe resolved value was the result of an error.Development
splitThe resolved value was the result of pseudorandom assignment.Development
staleThe resolved value is non-authoritative or possibly out of dateDevelopment
staticThe resolved value is static (no dynamic evaluation).Development
targeting_matchThe resolved value was the result of a dynamic evaluation, such as a rule or specific user-targeting.Development
unknownThe reason for the resolved value could not be determined.Development