Releases: launchdarkly/node-server-sdk
7.0.4
7.0.3
7.0.2
[7.0.2] - 2023-06-28
Changed:
- The
launchdarkly-node-server-sdk
project has been renamed to@launchdarkly/node-server-sdk
. All future releases will be made from the new repository. Please consider upgrading and filing potential requests in that repository's issue tracker.
7.0.1
[7.0.1] - 2023-02-08
Fixed:
- Updated the
async
package dependency. The previous version ofasync
was flagged in CVE-2021-43138
7.0.0
[7.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."
This feature is only available to members of LaunchDarkly's Early Access Program (EAP). If you're in the EAP, you can use contexts by updating your SDK to the latest version and, if applicable, updating your Relay Proxy. Outdated SDK versions do not support contexts, and will cause unpredictable flag evaluation behavior.
If you are not in the EAP, only use single contexts of kind "user", or continue to use the user type if available. If you try to create contexts, the context will be sent to LaunchDarkly, but any data not related to the user object will be ignored.
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:
- The types
LDContext
,LDSingleKindContext
, andLDMultiKindContext
define the new "context" model. - All SDK methods that took an
LDUser
parameter now take anLDContext
.LDUser
is now a subset ofLDContext
, so existing code based on users will still work. - Added
contextKeysCapacity
andcontextKeysFlushInterval
toLDOptions
these supersede the equivalentuser
options.
Changed (breaking changes from 6.x):
- There is no longer such a thing as a
secondary
meta-attribute that affects percentage rollouts. If you set an attribute with that name inLDContext
, it will simply be a custom attribute like any other. - Evaluations now treat the
anonymous
attribute as a simple boolean, with no distinction between a false state and an undefined state. LDClient.getUser
has been replaced withLDClient.getContext
.privateAttributeNames
has been replaced withprivateAttributes
inLDOptions
. Private attributes now allow using attribute references.
Changed (behavioral changes):
- 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 6.x release.
- Removed the
secondary
meta-attribute inLDUser
. - The
alias
method no longer exists because alias events are not needed in the new context model. - The
inlineUsersInEvents
options no longer exist because they are not relevant in the new context model.
Deprecated:
- Deprecated
userKeysCapacity
anduserKeysFlushInterval
inLDOptions
. Newcontext
equivalents have been added.
6.4.3
[6.4.3] - 2022-09-06
Fixed:
- The
TestDataRuleBuilder
was using an incorrect field name for operators, which would prevent rules from working correctly with theTestData
feature. (Thanks, LiamMorrow!)
6.4.2
[6.4.2] - 2022-06-06
Changed:
- Enforce a 64 character limit for
application.id
andapplication.version
configuration options.
6.4.1
[6.4.1] - 2022-04-26
Fixed:
- When using polling mode (
stream: false
), if the SDK was shut down withclose()
, a timer task could still remain active for up to 30 seconds (or whatever the polling interval was set to).
5.14.6
[5.14.6] - 2022-03-28
This release contains no changes to SDK functionality. It differs from 5.14.5 only in that the NPM lockfile package-lock.json
has been removed from source control (a change that was already made in 6.x, but had not been backported to the 5.x maintenance branch util now).
The lockfile does not affect the dependencies that are loaded when an application uses the SDK, because NPM only pays attention to the lockfile of the root project (the application). Running a security scan on the node-server-sdk
project produced false results, since the scanner would look at the dependency versions that were current at the time the lockfile was generated-- not the versions that would now be used if an application installed the SDK.
6.4.0
[6.4.0] - 2022-03-22
This release is functionally identical to the 6.3.1 release. It exists for compliance with semantic versioning, and to correct the changelog: the new feature described below was accidentally omitted from the changelog, and the minor version number should have been incremented.
Added:
LDOptions.application
, for configuration of application metadata that may be used in LaunchDarkly analytics or other product features. This does not affect feature flag evaluations.