open-feature / go-sdk

Go SDK for OpenFeature
https://openfeature.dev
Apache License 2.0
144 stars 33 forks source link

feat: run event handlers immediately, add STALE (0.7.0 compliance) #221

Closed craigpastro closed 1 year ago

craigpastro commented 1 year ago

This PR

Add a stale state and ensure event handlers run immediately if the associated provider and the state associated with the handle are compatible.

Related Issues

Resolves #220.

Notes

Follow-up Tasks

How to test

codecov[bot] commented 1 year ago

Codecov Report

Merging #221 (617ef2b) into main (d850ebc) will increase coverage by 0.12%. The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main     #221      +/-   ##
==========================================
+ Coverage   78.63%   78.76%   +0.12%     
==========================================
  Files          10       10              
  Lines        1203     1210       +7     
==========================================
+ Hits          946      953       +7     
  Misses        230      230              
  Partials       27       27              
Files Changed Coverage Δ
pkg/openfeature/provider.go 65.38% <ø> (ø)
pkg/openfeature/event_executor.go 98.75% <100.00%> (+0.03%) :arrow_up:

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

toddbaert commented 1 year ago

I'll give this a review later today!