Skip to content

Commit f86d575

Browse files
committed
Merge branch 'main' of github.com:splitio/go-client into dependabot/github_actions/SonarSource/sonarcloud-github-action-2.3
2 parents 69eb4ed + 9fbfad3 commit f86d575

26 files changed

+1037
-742
lines changed

CHANGES.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1+
6.8.0 (Sep 26, 2025)
2+
- Added support for rule-based segments. These segments determine membership at runtime by evaluating their configured rules against the user attributes provided to the SDK.
3+
- Added support for feature flag prerequisites. This allows customers to define dependency conditions between flags, which are evaluated before any allowlists or targeting rules.
4+
- Added support for retries
5+
- Fixed evaluation of large segments to return control properly.
6+
17
6.7.0 (Jan 17, 2025)
28
- Added support for the new impressions tracking toggle available on feature flags, both respecting the setting and including the new field being returned on SplitView type objects. Read more in our docs.
39

go.mod

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,9 @@ module github.com/splitio/go-client/v6
33
go 1.18
44

55
require (
6-
github.com/splitio/go-split-commons/v6 v6.1.0
7-
github.com/splitio/go-toolkit/v5 v5.4.0
6+
github.com/splitio/go-split-commons/v7 v7.0.1-0.20250930213118-b0b22c397fc4
7+
github.com/splitio/go-toolkit/v5 v5.4.1-0.20250930172659-38274b802d99
8+
github.com/stretchr/testify v1.11.1
89
)
910

1011
require (
@@ -13,10 +14,10 @@ require (
1314
github.com/cespare/xxhash/v2 v2.2.0 // indirect
1415
github.com/davecgh/go-spew v1.1.1 // indirect
1516
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f // indirect
17+
github.com/kr/text v0.2.0 // indirect
1618
github.com/pmezard/go-difflib v1.0.0 // indirect
1719
github.com/redis/go-redis/v9 v9.0.4 // indirect
1820
github.com/stretchr/objx v0.5.2 // indirect
19-
github.com/stretchr/testify v1.9.0 // indirect
2021
golang.org/x/exp v0.0.0-20231006140011-7918f672742d // indirect
2122
golang.org/x/sync v0.3.0 // indirect
2223
gopkg.in/yaml.v3 v3.0.1 // indirect

go.sum

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,29 +6,33 @@ github.com/bsm/ginkgo/v2 v2.7.0 h1:ItPMPH90RbmZJt5GtkcNvIRuGEdwlBItdNVoyzaNQao=
66
github.com/bsm/gomega v1.26.0 h1:LhQm+AFcgV2M0WyKroMASzAzCAJVpAxQXv4SaI9a69Y=
77
github.com/cespare/xxhash/v2 v2.2.0 h1:DC2CZ1Ep5Y4k3ZQ899DldepgrayRUGE6BBZ/cd9Cj44=
88
github.com/cespare/xxhash/v2 v2.2.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs=
9+
github.com/creack/pty v1.1.9/go.mod h1:oKZEueFk5CKHvIhNR5MUki03XCEU+Q6VDXinZuGJ33E=
910
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
1011
github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38=
1112
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f h1:lO4WD4F/rVNCu3HqELle0jiPLLBs70cWOduZpkS1E78=
1213
github.com/dgryski/go-rendezvous v0.0.0-20200823014737-9f7001d12a5f/go.mod h1:cuUVRXasLTGF7a8hSLbxyZXjz+1KgoB3wDUb6vlszIc=
14+
github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI=
15+
github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY=
16+
github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE=
1317
github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM=
1418
github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4=
1519
github.com/redis/go-redis/v9 v9.0.4 h1:FC82T+CHJ/Q/PdyLW++GeCO+Ol59Y4T7R4jbgjvktgc=
1620
github.com/redis/go-redis/v9 v9.0.4/go.mod h1:WqMKv5vnQbRuZstUwxQI195wHy+t4PuXDOjzMvcuQHk=
17-
github.com/splitio/go-split-commons/v6 v6.1.0 h1:k3mwr12DF6gbEaV8XXU/tSAQlPkIEuzIgTEneYhGg2I=
18-
github.com/splitio/go-split-commons/v6 v6.1.0/go.mod h1:D/XIY/9Hmfk9ivWsRsJVp439kEdmHbzUi3PKzQQDOXY=
19-
github.com/splitio/go-toolkit/v5 v5.4.0 h1:g5WFpRhQomnXCmvfsNOWV4s5AuUrWIZ+amM68G8NBKM=
20-
github.com/splitio/go-toolkit/v5 v5.4.0/go.mod h1:xYhUvV1gga9/1029Wbp5pjnR6Cy8nvBpjw99wAbsMko=
21+
github.com/splitio/go-split-commons/v7 v7.0.1-0.20250930213118-b0b22c397fc4 h1:OK9LLRmEpLghXM5paCrR9zFXTuYTdoiP2P2apwW3C9E=
22+
github.com/splitio/go-split-commons/v7 v7.0.1-0.20250930213118-b0b22c397fc4/go.mod h1:Lsj2n1zm88laFRu+JhlNeXW0x1ndtjQ1H21rLhRFfOs=
23+
github.com/splitio/go-toolkit/v5 v5.4.1-0.20250930172659-38274b802d99 h1:rQo355F9JbdyTMz2X5MU+FeRvkT6rvD1n+GnXdJr33A=
24+
github.com/splitio/go-toolkit/v5 v5.4.1-0.20250930172659-38274b802d99/go.mod h1:SifzysrOVDbzMcOE8zjX02+FG5az4FrR3Us/i5SeStw=
2125
github.com/stretchr/objx v0.5.2 h1:xuMeJ0Sdp5ZMRXx/aWO6RZxdr3beISkG5/G/aIRr3pY=
2226
github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA=
23-
github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg=
24-
github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
27+
github.com/stretchr/testify v1.11.1 h1:7s2iGBzp5EwR7/aIZr8ao5+dra3wiQyKjjFuvgVKu7U=
28+
github.com/stretchr/testify v1.11.1/go.mod h1:wZwfW3scLgRK+23gO65QZefKpKQRnfz6sD981Nm4B6U=
2529
github.com/twmb/murmur3 v1.1.6 h1:mqrRot1BRxm+Yct+vavLMou2/iJt0tNVTTC0QoIjaZg=
2630
github.com/twmb/murmur3 v1.1.6/go.mod h1:Qq/R7NUyOfr65zD+6Q5IHKsJLwP7exErjN6lyyq3OSQ=
2731
golang.org/x/exp v0.0.0-20231006140011-7918f672742d h1:jtJma62tbqLibJ5sFQz8bKtEM8rJBtfilJ2qTU199MI=
2832
golang.org/x/exp v0.0.0-20231006140011-7918f672742d/go.mod h1:ldy0pHrwJyGW56pPQzzkH36rKxoZW1tw7ZJpeKx+hdo=
2933
golang.org/x/sync v0.3.0 h1:ftCYgMx6zT/asHUrPw8BLLscYtGznsLAnjq5RH9P66E=
3034
golang.org/x/sync v0.3.0/go.mod h1:FU7BRWz2tNW+3quACPkgCx/L+uEAv1htQ0V83Z9Rj+Y=
31-
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM=
3235
gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0=
36+
gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo=
3337
gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA=
3438
gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM=

splitio/client/client.go

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,19 +4,20 @@ import (
44
"errors"
55
"fmt"
66
"runtime/debug"
7+
"sort"
78
"strings"
89
"time"
910

1011
"github.com/splitio/go-client/v6/splitio/conf"
1112
impressionlistener "github.com/splitio/go-client/v6/splitio/impressionListener"
1213

13-
"github.com/splitio/go-split-commons/v6/dtos"
14-
"github.com/splitio/go-split-commons/v6/engine/evaluator"
15-
"github.com/splitio/go-split-commons/v6/engine/evaluator/impressionlabels"
16-
"github.com/splitio/go-split-commons/v6/flagsets"
17-
"github.com/splitio/go-split-commons/v6/provisional"
18-
"github.com/splitio/go-split-commons/v6/storage"
19-
"github.com/splitio/go-split-commons/v6/telemetry"
14+
"github.com/splitio/go-split-commons/v7/dtos"
15+
"github.com/splitio/go-split-commons/v7/engine/evaluator"
16+
"github.com/splitio/go-split-commons/v7/engine/evaluator/impressionlabels"
17+
"github.com/splitio/go-split-commons/v7/flagsets"
18+
"github.com/splitio/go-split-commons/v7/provisional"
19+
"github.com/splitio/go-split-commons/v7/storage"
20+
"github.com/splitio/go-split-commons/v7/telemetry"
2021
"github.com/splitio/go-toolkit/v5/logging"
2122
)
2223

@@ -74,6 +75,7 @@ func (c *SplitClient) getEvaluationsResult(matchingKey string, bucketingKey *str
7475
if c.isReady() {
7576
return c.evaluator.EvaluateFeatures(matchingKey, bucketingKey, featureFlags, attributes)
7677
}
78+
sort.Strings(featureFlags)
7779
featureFlagsToPrint := strings.Join(featureFlags, ", ")
7880
c.logger.Warning(fmt.Sprintf("%s: the SDK is not ready, results may be incorrect for feature flags %s. Make sure to wait for SDK readiness before using this method", operation, featureFlagsToPrint))
7981
c.initTelemetry.RecordNonReadyUsage()

0 commit comments

Comments
 (0)