Change log
All notable changes to the LaunchDarkly Go SDK will be documented in this file. This project adheres to Semantic Versioning.
7.23.0 (2026-11-13)
Features
Bug Fixes
- Give FDv1 fallback data no selector (#511) (2006348)
- Reject override entries that are marked as deleted (#510) (8b0e02d)
- Update go-server-sdk-evaluation to v3.2.1 (#508) (733322c)
7.22.0 (2026-11-06)
Features
- Broadcast Off to FDv2 status listeners when the data system stops (#505) (5c5b8ce)
- End an FDv1 fallback after a default TTL of one hour (#499) (1f03a5f)
- Park FDv2 synchronizers instead of retiring them on unexpected failures (#489) (644253a)
Bug Fixes
- Keep data from a store that is not initialized out of override evaluations and AllFlagsState, and report a store failure (#491) (1005a1a)
- Keep the override marking when a migration flag serves an unrecognized stage (#492) (9f9911f)
- Leave StateSince alone when a synchronizer starts (#502) (823b9aa)
- Make TestData ValueForAll return its value when targeting is off (#507) (7300bc1)
- Park a synchronizer that reports Off or closes its results (#500) (f6e9910)
- Poll the override files when they cannot be watched (#495) (170ad3b)
- Prevent a full status listener from hanging Close (#498) (9efd570)
- Say that the data system retries after an unrecoverable HTTP error (#501) (d4066cc)
- Treat a repeated override file path in a different case as a repeat on Windows (#494) (eeb68d3)
- Warn when offline mode skips the override source (#493) (69bbe61)
7.21.2 (2026-10-28)
Bug Fixes
- Prevent a leaked streaming connection after back-to-back malformed events (#490) (e83af25)
- Synchronize access to the environment ID (#486) (83d31ed)
7.21.1 (2026-10-26)
Bug Fixes
- Prevent WaitFor from hanging past its timeout when status updates are queued (#475) (7a2fa47)
- Rewrite the persistent store from the in-memory store after an outage (#480) (218b905)
7.21.0 (2026-10-22)
Features
- Allow the Relay Proxy to change the SDK key of a running client (#457) (605d1ae)
- Re-enable blocked FDv2 synchronizers when the SDK key changes (#466) (2a3ce4c)
Bug Fixes
- Drop a file path listed more than once instead of treating its entries as duplicate keys (#477) (8b5641e)
- Notify overridden flags when the LaunchDarkly data they depend on changes (#479) (ceff41c)
- Stop the polling synchronizer's goroutines when the synchronizer stops (#482) (592d1d3)
- Update go-sdk-events to v3.8.1 (#485) (151ca66)
7.20.0 (2026-10-20)
Features
- Let each file source choose how a value entry expands into a flag (#460) (81146c0)
7.19.2 (2026-10-14)
Bug Fixes
- Prevent client hangs when a flag change listener reads the store during FDv2 data update (#470) (0ce742d)
- Prevent ldtestdatav2.UsePreconfiguredSegment from writing segment updates as flags (#471) (0a78469)
7.19.1 (2026-10-12)
Bug Fixes
- fall back from a silent synchronizer during FDv2 startup (#461) (c66100e)
7.19.0 (2026-10-07)
Features
- Add option to release redundant in-clause value lists (#467) (9ad54c8)
Bug Fixes
- Block permanently failed FDv2 synchronizers instead of removing them (#463) (955ead9)
- Keep the cached full data set when an upsert loses a race (#464) (9eafbac)
7.18.0 (2026-09-24)
Features
- Add file-based flag overrides (#458) (8b5131a)
- internal: add reload orchestration with debouncing and failure retry to file data loading (#406) (778569e)
Bug Fixes
- Do not log the cached-data warning after initialization succeeds (#449) (c14f870)
- Make the file data source's initialized flag safe to read concurrently (#452) (5bf0434)
7.17.1 (2026-09-15)
Bug Fixes
- Accept DescribeConfiguration without a client context (#445) (12d780e)
- Log the cached-data evaluation warning only once per client (#448) (d1b2699)
7.17.0 (2026-09-03)
Features
- Add DuplicateKeysKeepFirst and deprecate DuplicateKeysIgnoreAllButFirst (#437) (27d31a4)
- Complete initialization when initializers return data without a selector (#441) (a8432b7)
- deprecate FDv2 payload filter builder methods (#440) (fac8693)
Bug Fixes
- Report data source Valid status before signaling readiness (#442) (9dd6b4e)
7.16.0 (2026-08-25)
Features
- conform FDv1 streaming and polling to RETRY spec (#429) (f5fc1a3)
7.15.6 (2026-08-17)
Bug Fixes
- Upgrade go-jsonstream to v3.1.2 for faster JSON parsing and serialization (f2ec567)
- Upgrade go-sdk-common to v3.5.1 (f2ec567)
- Upgrade go-sdk-events to v3.6.3 (f2ec567)
- Upgrade go-server-sdk-evaluation to v3.0.2 (f2ec567)
7.15.5 (2026-07-27)
Bug Fixes
- avoid data races in test flag creation (#422) (505bea9)
7.15.4 (2026-06-11)
Bug Fixes
- deps: refresh submodule pins to released v3 tags (#393) (eec0cb6)
7.15.3 (2026-06-11)
Bug Fixes
- deps: revert root module, sub-modules, and testservice to v3 core libraries (#392) (0c0b0e8)
7.15.2 (2026-06-04)
Bug Fixes
7.15.1 (2026-06-03)
Bug Fixes
- bump core deps to v4 and remove EasyJSON support (#381) (35733e1)
7.15.0 (2026-05-28)
Features
- add X-LaunchDarkly-Instance-Id header (SDK-2350) (#375) (67ebe5d)
- Drop persistent-store cache after FDv2 in-memory store init (#373) (9a29b20)
Bug Fixes
- execute afterTrack hooks in registration order (#379) (851d1d0)
- remove non-spec Silent/Catastrophe fields from FDv2 Goodbye (#369) (381cffe)
7.14.7 (2026-04-28)
Bug Fixes
- Honor x-ld-fd-fallback header in fdv2 initializer phase (SDK-2203) (#365) (82d0b98)
7.14.6 (2026-02-26)
Bug Fixes
- Expand data system config to allow for list of synchronizers (#343) (0956ce9)
- improves fallback behavior when using custom data system configuration (#348) (4f5b1e9)
7.14.5 (2026-01-16)
Bug Fixes
7.14.4 (2025-12-15)
Bug Fixes
- fdv2 datasystem leaves sychronizer open after client is closed (#337) (e29ee24)
7.14.3 (2025-12-05)
Bug Fixes
- Optimize creation of changesets from collections (#335) (d6fd601)
7.14.2 (2025-12-02)
Bug Fixes
- Add
ChangeSet.Collections to help reduce relay memory usage (#332) (ca33a3c)
- align fdv2 intializer to spec (#330) (68599fa)
- Update changeset builder to support chaining calls (#333) (69e269b)
7.14.1 (2025-11-21)
Bug Fixes
- Bump github.com/launchdarkly/go-ntlm-proxy-auth from v1.0.2 -> v1.0.3 (#326) (822e8d6)
- Bump minimum go to 1.24 (#325) (6e2cebf)
7.14.0 (2025-11-12)
Features
- Add new transport configuration options (#320) (e2d9a7c)
7.13.4 (2025-08-21)
Bug Fixes
- experimental: Update usability warning for LDScopedClient - in beta, subject to change (#312) (b1b102c)
7.13.3 (2025-08-20)
Bug Fixes
- experimental: NewScopedClient can now only take one context argument (#309) (b149429)
- experimental: NewScopedClient, AddContext, OverwriteContextByKind emit usage events (#310) (4a36949)
7.13.2 (2025-08-14)
Bug Fixes
- experimental: Add experimental LDScopedClient for incrementally building and propagating contexts (#297) (2b96332)
- experimental: Functions for putting/getting an LDScopedClient from context.Context (#305) (d61c744)
7.13.1 (2025-07-25)
Bug Fixes
- Bump go-sdk-common from v3.1.0 to v3.4.0 (#299) (ba1c05b)
7.13.0 (2025-07-16)
Features
7.12.0 (2025-07-09)
Features
7.11.0 (2025-06-24)
Features
7.10.2 (2025-06-02)
Bug Fixes
7.10.1 (2025-04-16)
Bug Fixes
- Handle shutting down data system when all synchronizers permanently fail (#256) (031835e)
7.10.0 (2025-03-28)
Features
- Bump minimum Go version to 1.23 (416d972)
Bug Fixes
- Bump launchdarkly/go-ntlm-proxy-auth to v1.0.2 (416d972)
7.9.0 (2025-03-13)
Features
- Inline context for custom and migration events (ce0245f)
- Update minimum go version to 1.20. (46c9694)
7.8.0 (2024-12-09)
Features
- internal implementation of FDv2 data system (67b411e)
7.7.0 (2024-10-22)
Features
- add support for client-side prerequisite events (#201) (d9804ec)
7.6.2 (2024-08-28)
Bug Fixes
- deps: bump evaluation module to v3.0.1 (#181) (b63cf6c)
7.6.1 (2024-08-20)
Bug Fixes
- add support for testing minimum Go version (c0707a3)
7.6.0 (2024-07-25)
This release introduces the ability to enable compression of event payloads. When enabled, the SDK will compress events before sending them to the LaunchDarkly servers. This can reduce the bandwidth required to send events, which can be useful in high-traffic environments to reduce egress traffic costs.
Important
Relay Proxy users MUST upgrade to version 8.9 or higher prior to enabling this option to prevent loss of event data.
However, enabling this feature is NOT required when using the Relay Proxy as it will manage compression automatically.
Features
- Add option to enable compression for event payloads (#161) (4301a12)
7.5.0 (2024-06-26)
Features
- Optionally omit anonymous contexts from index and identify events. (#158) (b2d304a)
7.4.1 (2024-06-04)
Bug Fixes
- add warning log message if client init duration is longer than recommended (60s) (68e3440)
- align high timeout log msg with spec (#150) (606d224)
- resolve data race in Broadcasters system (#153) (68cb1a4)
7.4.0 (2024-04-10)
This release contains no functional changes. It is a product of structural changes to the repository.
Features
7.3.0 (2024-04-03)
This release introduces a Hooks API. Hooks are collections of user-defined callbacks that are executed by the SDK at various points of interest. You can use them to augment the SDK with metrics or tracing.
Features
7.2.0 (2024-03-25)
Features
- deps: bump supported Go versions to 1.22 and 1.21 (#114) (0ac6d4d)
7.1.1 (2024-03-14)
Bug Fixes
- do not emit error when RelayProxyEndpointsWithoutEvents is used (#110) (0551bf1)
7.1.0 (2024-03-14)
Features
- Inline contexts for all evaluation events (#111) (0fad2bb)
- Redact anonymous attributes within feature events (0fad2bb)
7.0.1 (2024-03-01)
Bug Fixes
- deps: bump golang.org/x/crypto from 0.1.0 to 0.17.0 (5d26f59)
[7.0.0] - 2023-10-11
The latest version of this SDK supports the ability to manage migrations or modernizations, using migration flags. You might use this functionality if you are optimizing queries, upgrading to new tech stacks, migrating from one database to another, or other similar technology changes. Migration flags are part of LaunchDarkly's Early Access Program. This feature is available to all LaunchDarkly customers but may undergo additional changes before it is finalized.
Added:
- New
Migrator type which provides an out-of-the-box configurable migration framework.
- For more advanced use cases, added new
MigrationVariation and TrackMigrationOp methods on LDClient.
Changed:
LDClientEvaluations interface now has a MigrationVariation method.
LDClientEvents interface now has TrackMigrationOp method.
[6.1.1] - 2023-10-11
Fixed:
- Event payloads receiving an HTTP 413 status code will no longer prevent subsequent event payloads from being attempted.
- Readme Get started hyperlink destination. (Thanks, christgf!)
[6.1.0] - 2023-04-13
Added:
- Support for Payload Filtering in streaming and polling modes. Payload Filtering is a beta feature that allows SDKs to download a subset of environment data, rather than full environments.
[6.0.3] - 2023-03-01
Changed:
- Bumped go-sdk-events to v2.0.1
- Bumped go-server-sdk-evaluation to v2.0.2
Fixed:
- Bumped go-sdk-common to v3.0.1. This fixes a bug within the easyJSON unmarshaller when an unexpected privateAttributes or redactedAttributes was encountered in a Context _meta attribute.
[6.0.2] - 2023-02-27
Changed:
- Bumped golang/x/crypto and golang/x/sys to v0.1.0
[6.0.1] - 2023-01-17
Fixed:
- If the application configured custom base URIs that did not have a valid URI syntax, the SDK could panic at startup time. It will now simply log an error and be unable to connect to LaunchDarkly.
- Fixed shared test logic that is used by the database integration packages.
[5.10.1] - 2023-01-17
Fixed:
- If the application configured custom base URIs that did not have a valid URI syntax, the SDK could panic at startup time. It will now simply log an error and be unable to connect to LaunchDarkly.
- Fixed shared test logic that is used by the database integration packages.
[6.0.0] - 2022-12-07
The latest version of this SDK supports LaunchDarkly's new custom contexts feature. Contexts are an evolution of a previously-existing concept, "users." Contexts let you create targeting rules for feature flags based on a variety of different information, including attributes pertaining to users, organizations, devices, and more. You can even combine contexts to create "multi-contexts."
For detailed information about this version, please refer to the list below. For information on how to upgrade from the previous version, please read the migration guide.
Added:
- In
go-sdk-common, the new package ldcontext with the types Context and Kind defines the new context model.
- The
ldtestdata flag builder methods have been extended to support now context-related options, such as matching a key for a specific context type other than "user".
LDClient.FlushAndWait() is a synchronous version of Flush().
Changed (breaking changes from 5.x):
- The SDK packages now use regular Go module import paths rather than
gopkg.in paths: gopkg.in/launchdarkly/go-server-sdk.v5 is replaced by github.com/launchdarkly/go-server-sdk/v6 and gopkg.in/launchdarkly/go-sdk-common.v2 is replaced by github.com/launchdarkly/go-sdk-common/v3.
- The type
lduser.User has been redefined to be an alias for ldcontext.Context. This means that existing application code referencing lduser.User can still work as long as it is treating the user as an opaque value, and not calling methods on it that were specific to that type.
- All methods that used the type
lduser.User now use ldcontext.Context instead.
lduser.NewUser and lduser.UserBuilder now create an instance of Context instead of User. This is as a convenience so that any code that was previously using these methods to construct a user, but did not reference the User type directly for the result, may still be usable without changes. It is still preferable to use the new constructors and builders for Context.
- The
Secondary attribute which existed in User does not exist in Context and is no longer a supported feature.
- It was previously allowable to set a user key to an empty string. In the new context model, the key is not allowed to be empty. Trying to use an empty key will cause evaluations to fail and return the default value.
- If you were using JSON serialization to produce a representation of a
User, the new type Context uses a different JSON schema, so any code that reads the JSON will need to be adjusted. If you are passing the JSON to other code that uses LaunchDarkly SDKs, make sure you have updated all SDKs to versions that use the new context model. (However, unmarshaling a Context from JSON data will still work correctly even if the JSON is in the old user format.)
- Types such as
DataStore, which define the low-level interfaces of LaunchDarkly SDK components and allow implementation of custom components, have been moved out of the interfaces subpackage into a new subsystems subpackage. Some types have been removed by using generics: for instance, the interface type DataSourceFactory has been replaced by ComponentConfigurer[DataSource]. Application code normally does not refer to these types except possibly to hold a value for a configuration property such as Config.DataStore, so this change is likely to only affect configuration-related logic.
Changed (requirements/dependencies/build):
- The minimum Go version is now 1.18.
Changed (behavioral changes):
- The SDK can now evaluate segments that have rules referencing other segments.
- Analytics event data now uses a new JSON schema due to differences between the context model and the old user model.
Removed:
- Removed all types, fields, and methods that were deprecated as of the most recent 5.x release.
- Removed the
Secondary meta-attribute in lduser.User and lduser.UserBuilder.
- The
Alias method no longer exists because alias events are not needed in the new context model.
- The
InlineUsersInEvents option no longer exists because it is not relevant in the new context model.
[5.10.0] - 2022-07-05
Added:
ldtestdata.FlagBuilder.VariationForAll and VariationForAllIndex: new names for the deprecated methods listed below.
Changed:
- It was possible to cause analytics event data to be lost by passing
ldvalue.Raw(nil) or ldvalue.Raw(json.RawMessage("")) as a default value parameter to JSONVariation, or as the value of a custom user attribute, because a zero-length byte array is not a valid JSON value and would cause the event output to be malformed. The SDK now guards against this by encoding such a value as null in the event data. It is still possible to cause a similar problem by passing a malformed raw value as as ldvalue.Raw(json.RawMessage("{{{")); it is the caller's responsibility not to do so, as the purpose of json.RawMessage is to avoid unnecessary parsing and implies that the value is known to be syntactically valid.
Fixed:
- If a field in
Config.ApplicationInfo is set to a string longer than 64 characters, the SDK will now log a warning and discard it, since the LaunchDarkly services cannot process such strings for these fields.
- Prevented a potential data race in
LDClient.Initialized(). (#69)
Deprecated:
ldtestdata.FlagBuilder.VariationForAllUsers and VariationForAllUsersIndex. These methods are being renamed because in the future, there will be other possible kinds of evaluation inputs that are not users, and these test methods will apply equally to those.
[5.9.0] - 2022-03-22
Added:
Config.ApplicationInfo, for configuration of application metadata that may be used in LaunchDarkly analytics or other product features. This does not affect feature flag evaluations.
[5.8.1] - 2022-01-19
Fixed:
- When using
AllFlagsState to produce bootstrap data for the JavaScript SDK, the Go SDK was not returning the correct metadata for evaluations that involved an experiment. As a result, the analytics events produced by the JavaScript SDK did not correctly reflect experimentation results.
[5.8.0] - 2022-01-10
Added:
Config.ServiceEndpoints provides a simpler way of setting custom service base URIs, if you are connecting to a LaunchDarkly Relay Proxy instance, a private LaunchDarkly instance, or a test fixture. Previously, this required setting a BaseURI property for each individual service (streaming, events, etc.). If using the Relay Proxy, simply remove any BaseURI calls in your SDK configuration and set the ServiceEndpoints property to ldcomponents.RelayProxyEndpoints(myRelayProxyUri) (use RelayProxyEndpointsWithoutEvents instead if your Relay Proxy instance does not have event forwarding enabled).
[5.7.0] - 2022-01-07
Added:
HTTPConfigurationBuilder.Header allows adding custom HTTP headers to all of the SDK's requests.