releases.shpreview

4.12.0

September 12, 2019Go SDKView original ↗
$npx -y @buildinternet/releases show rel_bC2p5eUOa2WGjJ9RXByIu

[4.12.0] - 2019-09-12

Added:

  • The Go SDK now has log levels, similar to the logging frameworks used in the other LaunchDarkly SDKs. Log messages can have a level of Debug, Info, Warn, or Error; by default, Debug is hidden. The new package ldlog defines these levels, and you can use Config.Loggers.SetMinLevel() and Config.Loggers.SetBaseLogger() to control the behavior. The old property Config.Logger still works but is deprecated.
  • The SDK will produce very detailed output if you call Config.Loggers.SetMinLevel(ldlog.Debug). This includes information about when and how it connects to LaunchDarkly, and a full dump of all analytics event data it is sending. Since the debug logging is very verbose, and the event data includes user properties, you should not normally enable this log level in production unless advised to by LaunchDarkly support.
  • There is now a different property for specifying a feature store mechanism: Config.FeatureStoreFactory, which takes a factory method, rather than Config.FeatureStore, which takes an implementation instance. Using a factory method allows the implementation to access Config properties such as the logging configuration. The new methods NewInMemoryFeatureStoreFactory, redis.NewRedisFeatureStoreFactory, consul.NewConsulFeatureStoreFactory, and dynamodb.NewDynamoDBFeatureStoreFactory work with this mechanism.
  • The SDK's CI build now verifies compatibility with Go 1.11 and 1.12.

Deprecated:

  • Config.SamplingInterval: the intended use case for the SamplingInterval feature was to reduce analytics event network usage in high-traffic applications. This feature is being deprecated in favor of summary counters, which are meant to track all events.
  • Config.Logger: use Config.Loggers for more flexible configuration.
  • NewInMemoryFeatureStore, redis.NewRedisFeatureStoreWithDefault, consul.NewConsulFeaturStore, dynamodb.NewDynamoDBFeatureStore: see above.

Fetched April 11, 2026