Skip to content

Releases: statsig-io/node-js-server-sdk

6.0.1 - Fix DataAdapter format

19 Nov 18:29
3d7e2b8
Compare
Choose a tag to compare

Improvements

  • Append / to data adapter key path so it's statsig|/v/1download_config_specs|plain_text|sha256base64(sdkkey)

Included In This Release

  • ccfd105 Xin Li
    • Update adapter key path part to properly have / properly (#530)

Full Changelog: 6.0.0...6.0.1

6.0.0 - Breaking Change on Core API, DataAapter Keys, Environment tier, and getClientIntializeResponse

18 Nov 18:26
74a9406
Compare
Choose a tag to compare

This version introducing several breaking changes, please read when upgrade.
Detailed upgrade guide can be found here

Breaking Changes

Synchronou Core APIs

Summary: Make most of core APIs synchronous functions: checkGate, getFeatureGate, getConfig, getExperiment, getLayer and deprecated many apis.
Changes: We have deprecated a series of apis such as async checkGate() a while ago, now we are removing this series of apis. All core apis within SDKs are synchronous.
b. Deprecate *Sync functions such as checkGateSync, getConfigSync.. Which serve the same functionalities as the new Synchronous APIs
For migration:
1. if you are using _sync functions, you can just rename functions name to be without sync() for example checkGateSync → checkGate
2. If you are using async functions, compile (for ts) or runtime error will be encountered if you are using .then().error() to handle this promise.

GetClientIntializeResponse() Response Changes

What changed: Default hash algorithm for getClientInitializeResponse() changed from sha256 to djb2.
For migration:
1. If you are passing hashAlgorithm, this should have no impact on you.
2. If you are not, please make sure your client SDKs are up to date (so it handles djb2 responses properly)

DataAdapter Cache Key Changes

Summary: Change cache keys SDK used to read and write from your DataAdapter.
Changes
1. Change cache key for config_specs to be “statsig|v1/download_config_specs|plain_text //copmress encoding|{SHA256Hashed(secretkey)} //false”
2. Change cache key for get_id_lists to be “statsig|get_id_lists|plain_text // compress encoding|{SHA256Hashed(secretkey)}”
4. Change cache key for inidividual id list to be statsig|id_list::${String(idListName)}|plain_text//encoding|${SHA256Hashed(secretKey)}
Migration guide
1. ⚠️ If you are using one fo provided Edge DataAdapter, DO NOT upgrade yet
2. If you are ok with cache miss with the first request, then you don’t need to do anything, SDK will write to cache with new key.
3. If you don’t want cold cache, please write with the new key before upgrade

Default SDK environment tier if not being set

What changed: Before if no environment tier is set, we consider it to be null, which will fail rules which set environment tier. We now assign default value to it: 1. Use SDK Key Tier if being set 2. Use production otherwise
Migration guide
Consider setting environment tier if you are not already.
If you are not setting environment tier, SDK will fail rules which set environment tier to be non-production.

Deprecate WithExposureLoggingDisabled

Migration Guide
Use core API with option instead.
For example, Instead of calling Statsig.getConfigWithExposureLoggingDisabled() call Statsig.getConfig(user, config_name,{disableExposureLogging: true})

New Features

  • Log event compression except edge function

Improvements

  • Add pass field to dynamic configs

Included In This Release

  • cabe3f6 dependabot[bot]
    • Bump micromatch from 4.0.5 to 4.0.8 (#493)
  • 10ed575 sroyal-statsig
    • Add Passed Field to Dynamic Configs for GCIR (#522)
  • b84c37e Xin Li
    • refac: Change checkGate getExperiment getConfig and getLayer functions to be synchronous and remove {core_api}_async functions (#511)
  • e8edac7 Xin Li
    • DataAdapter key v2: Include path and sdk keys as part of DataAdapter key (#509)
  • 44d2983 sroyal-statsig
    • Add Support for Default Environment from Server (#521)
  • a942533 kenny-statsig
    • Re-enable log event compression except for Edge (#506)

Included In This Release

  • 74a8802 Xin Li
    • Update data adapter key (#527)
  • cc2d94d Xin Li
    • change data adapter key for idlists (#526)
  • cabe3f6 dependabot[bot]
    • Bump micromatch from 4.0.5 to 4.0.8 (#493)
  • 10ed575 sroyal-statsig
    • Add Passed Field to Dynamic Configs for GCIR (#522)
  • b84c37e Xin Li
    • refac: Change checkGate getExperiment getConfig and getLayer functions to be synchronous and remove {core_api}_async functions (#511)
  • e8edac7 Xin Li
    • DataAdapter key v2: Include path and sdk keys as part of DataAdapter key (#509)
  • 44d2983 sroyal-statsig
    • Add Support for Default Environment from Server (#521)
  • a942533 kenny-statsig
    • Re-enable log event compression except for Edge (#506)

Full Changelog: 5.30.0...6.0.0

5.30.0 - Add support for StatsigOptions.networkOverrideFunc

30 Oct 21:39
57ad32d
Compare
Choose a tag to compare

New Features

  • Allow developers to use their own networking APIs by specifying a StatsigOptions.networkOverrideFunc. This is a fetch like function call.

Included In This Release

  • 532cd78 Daniel
    • feat: add StatsigOptions.networkOverrideFunc (#517)
  • b1b4630 sroyal-statsig
    • Switch Version Metadata to String (#518)
  • 95046f9 sroyal-statsig
    • Include Pass/Fail for Configs and Version on Exposures (#516)

Full Changelog: 5.29.0...5.30.0

5.29.0 - add ID type to client initialize response and memoize last UA parse

19 Oct 02:54
478fab3
Compare
Choose a tag to compare

Improvements

Fixes

  • add IDType to getClientInitializeResponse payload

Included In This Release

  • 5f90be7 tore-statsig
    • Memoize parseUserAgent (#510)
  • 7230be8 sroyal-statsig
    • Add IDType to GCIR (#507)

Full Changelog: 5.28.0...5.29.0

5.28.0 - Initialize details & Enforce targeting for persisted assignments

07 Oct 22:56
7c9a175
Compare
Choose a tag to compare

New Features

  • Return an InitializeDetails object with success/error information

Improvements

  • Allow checking targeting gate before serving persisted assignment via the option enforceTargeting on PersistentAssignemntOptions

Included In This Release

  • d60885a kenny-statsig
    • Respect targeting in persistent evaluation (#503)
  • dbe3040 kenny-statsig
    • Initialization details (#500)

Full Changelog: 5.27.2...5.28.0

5.27.2 - Evaluation process optimization

24 Sep 20:09
4fbe816
Compare
Choose a tag to compare

Improvements

  • Optimized the evaluation process and enhanced the performance.

Included In This Release

  • 7458d71 Weihao Ding
    • optimize: eval rule logic (#501)

Full Changelog: 5.27.1...5.27.2

5.27.1 - disable log event compression

13 Sep 22:55
89cba67
Compare
Choose a tag to compare

Fixes

  • reports that log event compression fails when running the sdk in an edge worker. disabling for now

Included In This Release

  • b5394f9 tore-statsig
    • chore: disable log event compression (#498)

Full Changelog: 5.27.0...5.27.1

5.27.0 - Support array operators, enable event log compression

11 Sep 17:09
8aa5b66
Compare
Choose a tag to compare

New Features

  • Add support for array operators

Improvements

  • Include group_name in the client initialize response

Fixes

  • Fix output log levels
  • Fix awaiting on data adapter save

Included In This Release

  • 7853afe kenny-statsig
    • Fix saving config specs to adapter (#496)
  • ef15876 Daniel
    • chore: re-enable log event compression (#495)
  • 73ab2a2 kenny-statsig
    • Fix output logger log levels (#494)
  • b95a4de Daniel
    • fix: include group_name in gcir (#491)
  • 3d5b6a6 sroyal-statsig
    • Support Array Contains All Operators (#492)
  • 0886e5b sroyal-statsig
    • Support Array Operators (#490)

Full Changelog: 5.26.0...5.27.0

5.26.0 - Persistent assignment

19 Aug 17:54
ea11614
Compare
Choose a tag to compare

New Features

  • Storage interface for persistent assignment

Included In This Release

  • 7739416 kenny-statsig
    • Fix in-line comment (#487)
  • cc847c0 kenny-statsig
    • Persistent assignment (#485)
  • 395a9d4 kenny-statsig
    • Evaluation context (#484)
  • 9de56d9 kenny-statsig
    • Move evaluator utils to shared file (#483)
  • d043956 kenny-statsig
    • Strong typing of secondary exposures (#482)

Full Changelog: 5.25.1...5.26.0

5.25.1 - fix: support timeout in flush() and remove private attributes from gcir

06 Aug 21:00
33780e2
Compare
Choose a tag to compare

Fixes

  • make flush(timeout) respect the timeout applied
    #49
  • remove private attributes from the user returned in getClientInitializeResponse

Included In This Release

  • 7bdbd13 tore-statsig
    • fix: strip private attributes from bootstrap user (#479)
  • 4c6c6c4 tore-statsig
    • fix: flush with timeout not respected by retries (#478)

Full Changelog: 5.25.0...5.25.1