Repository navigation
feat(all): tag OpenFeature exposures with $openfeature_provider (SDK-448) - #107
Open
ketanmixpanel wants to merge 1 commit into
Open
ketanmixpanel wants to merge 1 commit into
ketanmixpanel wants to merge 1 commit into
Conversation
Exposures fired through the Mixpanel OpenFeature provider now include "$openfeature_provider": true so they can be told apart from direct SDK flag calls. Direct SDK calls are unchanged. No public API change: the provider signals the SDK through an argument it already passes on every evaluation. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
[Medium impact] The PR appears safe to merge; no actionable issues were found. Reviews (1) · Last reviewed commit: "feat: tag OpenFeature exposures with $op..." · Reviewed by Greptile |
ketanmixpanel
marked this pull request as ready for review
November 13, 2026 08:55
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
SDK-448:
$experiment_startedexposures fired through the Mixpanel OpenFeature provider now include"$openfeature_provider": true, so OpenFeature usage can be told apart from direct SDK flag calls. Direct SDK calls are unchanged (no property).No public API change: no new public methods, parameters or fields. The provider signals the SDK through an argument it already passes on every evaluation.
How
"$openfeature_provider": trueto the evaluation context it already passes togetVariant, set after the customer attributes so a same-named attribute cannot override it.distinct_id) copies the marker onto$experiment_startedwhen the context value is exactlytrue. Covers local and remote evaluation.distinct_idandcustom_properties.Testing
trackExposuresignature is unchanged.getVariant, cannot be overridden by a customer attribute, and is set for a null context.mvn test(SDK): 396, 0 failures.cd openfeature-provider && mvn test: 38, 0 failures.~/.m2, removed afterwards), including an end-to-end test with a realRemoteFlagsProvider: 39/39.Note: marker is sent to the server on remote evaluation
Because the marker lives in the evaluation context, remote evaluation sends it to
/flagswith the rest of the context. The flags API accepts and ignores it (checked inanalytics/go/src/mixpanel.com/flags/api/handlers/evaluatefeatureflags.go):distinct_idanddevice_id;distinct_id/device_id,custom_propertiesand hierarchical group IDs;logRequestdoes not log it.So it has no effect on targeting, rollout or variant assignment; it is only visible in the GET
contextquery parameter.Release order
Older SDKs ignore the marker, so the provider change is safe on its own (no errors; the property just does not appear). The property appears once customers run an SDK release containing this change; the provider minimum SDK version was intentionally not bumped here and should be raised after the SDK release. No version or changelog edits.
🤖 Generated with Claude Code