-
Notifications
You must be signed in to change notification settings - Fork 10
feat(go-feature-flag): Support exporter metadata #45
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: Thomas Poignant <thomas.poignant@gofeatureflag.org>
4543a8d to
c58f3ab
Compare
|
|
||
| # enrich the evaluation context with the exporter_metadata | ||
| @options.exporter_metadata ||= {} | ||
| @options.exporter_metadata.merge!({"openfeature" => true, "provider" => "ruby"}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Those are default exporter_metadata values that are added for every evaluation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Because I need them in the GO Feature Flag server, and since I am using the OFREP API and I have no other fields than the context to add those extra informations.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I could have put it as a header, but the problem is the limit in header size that we may reach.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, I see. That's a clever workaround 😄
beeme1mr
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why are you adding exporter metadata to the context?
|
Will give this a review today when I have a chance |
maxveldink
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🦑 Just a few small comments, but nothing blocking from me!
providers/openfeature-go-feature-flag-provider/lib/openfeature/go-feature-flag/options.rb
Outdated
Show resolved
Hide resolved
...feature-go-feature-flag-provider/lib/openfeature/go-feature-flag/go_feature_flag_provider.rb
Outdated
Show resolved
Hide resolved
providers/openfeature-go-feature-flag-provider/spec/openfeature/gofeatureflag/provider_spec.rb
Show resolved
Hide resolved
providers/openfeature-go-feature-flag-provider/spec/openfeature/gofeatureflag/provider_spec.rb
Show resolved
Hide resolved
Signed-off-by: Thomas Poignant <thomas.poignant@gofeatureflag.org>
🤖 I have created a release *beep* *boop* --- ## [0.1.3](openfeature-go-feature-flag-provider/v0.1.2...openfeature-go-feature-flag-provider/v0.1.3) (2025-01-25) ### ✨ New Features * **go-feature-flag:** Support exporter metadata ([#45](#45)) ([04754fd](04754fd)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Signed-off-by: OpenFeature Bot <109696520+openfeaturebot@users.noreply.github.com>
This PR
In this PR we support
exporterMetadatathat will allow to add static information that will be added to your feature event sent to the GO Feature Flag exporter.In this PR we add those exporter metadata to the evaluation context in order to pass them to GO Feature Flag relay-proxy.
Related Issues
thomaspoignant/go-feature-flag#2983