@launchdarkly/js-client-sdk-common 1.22.0 → 1.24.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +40 -0
- package/dist/cjs/DataManager.d.ts +33 -0
- package/dist/cjs/DataManager.d.ts.map +1 -1
- package/dist/cjs/api/LDOptions.d.ts +17 -5
- package/dist/cjs/api/LDOptions.d.ts.map +1 -1
- package/dist/cjs/api/datasource/DataSourceEntry.d.ts +57 -0
- package/dist/cjs/api/datasource/DataSourceEntry.d.ts.map +1 -1
- package/dist/cjs/api/datasource/FDv2ConnectionMode.d.ts +5 -0
- package/dist/cjs/api/datasource/FDv2ConnectionMode.d.ts.map +1 -1
- package/dist/cjs/api/datasource/LDClientDataSystemOptions.d.ts +55 -37
- package/dist/cjs/api/datasource/LDClientDataSystemOptions.d.ts.map +1 -1
- package/dist/cjs/api/datasource/ModeDefinition.d.ts +19 -3
- package/dist/cjs/api/datasource/ModeDefinition.d.ts.map +1 -1
- package/dist/cjs/api/datasource/index.d.ts +2 -2
- package/dist/cjs/api/datasource/index.d.ts.map +1 -1
- package/dist/cjs/configuration/Configuration.d.ts +3 -3
- package/dist/cjs/configuration/Configuration.d.ts.map +1 -1
- package/dist/cjs/configuration/validateOptions.d.ts +18 -2
- package/dist/cjs/configuration/validateOptions.d.ts.map +1 -1
- package/dist/cjs/configuration/validators.d.ts +1 -1
- package/dist/cjs/configuration/validators.d.ts.map +1 -1
- package/dist/cjs/datasource/ConnectionModeConfig.d.ts +4 -2
- package/dist/cjs/datasource/ConnectionModeConfig.d.ts.map +1 -1
- package/dist/cjs/datasource/FDv2DataManagerBase.d.ts +87 -0
- package/dist/cjs/datasource/FDv2DataManagerBase.d.ts.map +1 -0
- package/dist/cjs/datasource/LDClientDataSystemOptions.d.ts +38 -3
- package/dist/cjs/datasource/LDClientDataSystemOptions.d.ts.map +1 -1
- package/dist/cjs/datasource/SourceFactoryProvider.d.ts +77 -0
- package/dist/cjs/datasource/SourceFactoryProvider.d.ts.map +1 -0
- package/dist/cjs/datasource/fdv2/FDv2DataSource.d.ts.map +1 -1
- package/dist/cjs/flag-manager/FlagManager.d.ts +16 -1
- package/dist/cjs/flag-manager/FlagManager.d.ts.map +1 -1
- package/dist/cjs/flag-manager/FlagPersistence.d.ts +13 -1
- package/dist/cjs/flag-manager/FlagPersistence.d.ts.map +1 -1
- package/dist/cjs/flag-manager/FlagStore.d.ts +10 -0
- package/dist/cjs/flag-manager/FlagStore.d.ts.map +1 -1
- package/dist/cjs/flag-manager/FlagUpdater.d.ts +13 -1
- package/dist/cjs/flag-manager/FlagUpdater.d.ts.map +1 -1
- package/dist/cjs/index.cjs +2271 -12
- package/dist/cjs/index.cjs.map +1 -1
- package/dist/cjs/index.d.ts +12 -2
- package/dist/cjs/index.d.ts.map +1 -1
- package/dist/cjs/types/index.d.ts +2 -2
- package/dist/esm/DataManager.d.ts +33 -0
- package/dist/esm/DataManager.d.ts.map +1 -1
- package/dist/esm/api/LDOptions.d.ts +17 -5
- package/dist/esm/api/LDOptions.d.ts.map +1 -1
- package/dist/esm/api/datasource/DataSourceEntry.d.ts +57 -0
- package/dist/esm/api/datasource/DataSourceEntry.d.ts.map +1 -1
- package/dist/esm/api/datasource/FDv2ConnectionMode.d.ts +5 -0
- package/dist/esm/api/datasource/FDv2ConnectionMode.d.ts.map +1 -1
- package/dist/esm/api/datasource/LDClientDataSystemOptions.d.ts +55 -37
- package/dist/esm/api/datasource/LDClientDataSystemOptions.d.ts.map +1 -1
- package/dist/esm/api/datasource/ModeDefinition.d.ts +19 -3
- package/dist/esm/api/datasource/ModeDefinition.d.ts.map +1 -1
- package/dist/esm/api/datasource/index.d.ts +2 -2
- package/dist/esm/api/datasource/index.d.ts.map +1 -1
- package/dist/esm/configuration/Configuration.d.ts +3 -3
- package/dist/esm/configuration/Configuration.d.ts.map +1 -1
- package/dist/esm/configuration/validateOptions.d.ts +18 -2
- package/dist/esm/configuration/validateOptions.d.ts.map +1 -1
- package/dist/esm/configuration/validators.d.ts +1 -1
- package/dist/esm/configuration/validators.d.ts.map +1 -1
- package/dist/esm/datasource/ConnectionModeConfig.d.ts +4 -2
- package/dist/esm/datasource/ConnectionModeConfig.d.ts.map +1 -1
- package/dist/esm/datasource/FDv2DataManagerBase.d.ts +87 -0
- package/dist/esm/datasource/FDv2DataManagerBase.d.ts.map +1 -0
- package/dist/esm/datasource/LDClientDataSystemOptions.d.ts +38 -3
- package/dist/esm/datasource/LDClientDataSystemOptions.d.ts.map +1 -1
- package/dist/esm/datasource/SourceFactoryProvider.d.ts +77 -0
- package/dist/esm/datasource/SourceFactoryProvider.d.ts.map +1 -0
- package/dist/esm/datasource/fdv2/FDv2DataSource.d.ts.map +1 -1
- package/dist/esm/flag-manager/FlagManager.d.ts +16 -1
- package/dist/esm/flag-manager/FlagManager.d.ts.map +1 -1
- package/dist/esm/flag-manager/FlagPersistence.d.ts +13 -1
- package/dist/esm/flag-manager/FlagPersistence.d.ts.map +1 -1
- package/dist/esm/flag-manager/FlagStore.d.ts +10 -0
- package/dist/esm/flag-manager/FlagStore.d.ts.map +1 -1
- package/dist/esm/flag-manager/FlagUpdater.d.ts +13 -1
- package/dist/esm/flag-manager/FlagUpdater.d.ts.map +1 -1
- package/dist/esm/index.d.ts +12 -2
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.mjs +2267 -14
- package/dist/esm/index.mjs.map +1 -1
- package/dist/esm/types/index.d.ts +2 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,45 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [1.24.0](https://github.com/launchdarkly/js-core/compare/js-client-sdk-common-v1.23.0...js-client-sdk-common-v1.24.0) (2026-04-14)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* add retry logic to FDv2 polling initializer ([#1230](https://github.com/launchdarkly/js-core/issues/1230)) ([fe8bd37](https://github.com/launchdarkly/js-core/commit/fe8bd375af48edfcfe83822bbbbe4546551c90d9))
|
|
9
|
+
* expose setConnectionMode on browser SDK ([#1232](https://github.com/launchdarkly/js-core/issues/1232)) ([9019808](https://github.com/launchdarkly/js-core/commit/9019808edd5f78cbddd9b031da1589cbaa49938f))
|
|
10
|
+
* FDv2 contract test wiring, suppressions, and example app, cleanup configuration exports. ([#1225](https://github.com/launchdarkly/js-core/issues/1225)) ([c67c5f6](https://github.com/launchdarkly/js-core/commit/c67c5f65f92e39d2e311b26d025a4b90112f2e4f))
|
|
11
|
+
* FDv2DataManagerBase for mode switching and data source lifecycle ([#1210](https://github.com/launchdarkly/js-core/issues/1210)) ([8f8051c](https://github.com/launchdarkly/js-core/commit/8f8051ca769d214a5df09fdf0e71c25f2b98a7f7))
|
|
12
|
+
* support per-mode FDv1 fallback configuration ([#1246](https://github.com/launchdarkly/js-core/issues/1246)) ([9956bce](https://github.com/launchdarkly/js-core/commit/9956bce2cc70642c63da79f904c5d5554892e046))
|
|
13
|
+
* wire FDv2 data manager into BrowserClient ([#1222](https://github.com/launchdarkly/js-core/issues/1222)) ([0b855f0](https://github.com/launchdarkly/js-core/commit/0b855f0be6ad5fd086f293603d7880992d41452e))
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
### Bug Fixes
|
|
17
|
+
|
|
18
|
+
* FDv2 - Support dynamic reconnect URL for streaming. Handle 'error' event types for SSE. ([#1252](https://github.com/launchdarkly/js-core/issues/1252)) ([4ef6cdd](https://github.com/launchdarkly/js-core/commit/4ef6cdd3f07a15e9a6b3b831defcf41d10e6334b))
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
### Dependencies
|
|
22
|
+
|
|
23
|
+
* The following workspace dependencies were updated
|
|
24
|
+
* dependencies
|
|
25
|
+
* @launchdarkly/js-sdk-common bumped from 2.24.0 to 2.24.1
|
|
26
|
+
|
|
27
|
+
## [1.23.0](https://github.com/launchdarkly/js-core/compare/js-client-sdk-common-v1.22.0...js-client-sdk-common-v1.23.0) (2026-03-23)
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
### Features
|
|
31
|
+
|
|
32
|
+
* FDv2 types, refined validators, and DataManager interface ([#1207](https://github.com/launchdarkly/js-core/issues/1207)) ([d7ccfc1](https://github.com/launchdarkly/js-core/commit/d7ccfc1a5359610d70751dc08e3b894bb7ecf334))
|
|
33
|
+
* FlagManager.applyChanges for FDv2 full/partial/none semantics ([#1208](https://github.com/launchdarkly/js-core/issues/1208)) ([d9a1bd7](https://github.com/launchdarkly/js-core/commit/d9a1bd7d24ea68e867496e93be0f3097b709392a))
|
|
34
|
+
* SourceFactoryProvider for declarative data source creation ([#1209](https://github.com/launchdarkly/js-core/issues/1209)) ([e254f77](https://github.com/launchdarkly/js-core/commit/e254f771761b3d0d61a745a1e06f99f6216ff63a))
|
|
35
|
+
|
|
36
|
+
|
|
37
|
+
### Dependencies
|
|
38
|
+
|
|
39
|
+
* The following workspace dependencies were updated
|
|
40
|
+
* dependencies
|
|
41
|
+
* @launchdarkly/js-sdk-common bumped from 2.23.0 to 2.24.0
|
|
42
|
+
|
|
3
43
|
## [1.22.0](https://github.com/launchdarkly/js-core/compare/js-client-sdk-common-v1.21.0...js-client-sdk-common-v1.22.0) (2026-03-16)
|
|
4
44
|
|
|
5
45
|
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { Context, EventName, internal, LDContext, LDHeaders, LDLogger, Platform, ProcessStreamResponse, subsystem } from '@launchdarkly/js-sdk-common';
|
|
2
|
+
import type FDv2ConnectionMode from './api/datasource/FDv2ConnectionMode';
|
|
2
3
|
import { LDIdentifyOptions } from './api/LDIdentifyOptions';
|
|
3
4
|
import { Configuration } from './configuration/Configuration';
|
|
4
5
|
import { DataSourceStatusManager } from './datasource/DataSourceStatusManager';
|
|
@@ -26,6 +27,38 @@ export interface DataManager {
|
|
|
26
27
|
* Closes the data manager. Any active connections are closed.
|
|
27
28
|
*/
|
|
28
29
|
close(): void;
|
|
30
|
+
/**
|
|
31
|
+
* Force streaming on or off. When `true`, the data manager should
|
|
32
|
+
* maintain a streaming connection. When `false`, streaming is disabled.
|
|
33
|
+
* When `undefined`, the forced state is cleared and automatic behavior
|
|
34
|
+
* takes over.
|
|
35
|
+
*
|
|
36
|
+
* Optional — only browser data managers implement this.
|
|
37
|
+
*/
|
|
38
|
+
setForcedStreaming?(streaming?: boolean): void;
|
|
39
|
+
/**
|
|
40
|
+
* Update the automatic streaming state based on whether change listeners
|
|
41
|
+
* are registered. When `true` and forced streaming is not set, the data
|
|
42
|
+
* manager should activate streaming.
|
|
43
|
+
*
|
|
44
|
+
* Optional — only browser data managers implement this.
|
|
45
|
+
*/
|
|
46
|
+
setAutomaticStreamingState?(streaming: boolean): void;
|
|
47
|
+
/**
|
|
48
|
+
* Set an explicit connection mode override. When set, only this mode is
|
|
49
|
+
* used, bypassing all automatic behavior. Pass undefined to clear the
|
|
50
|
+
* override.
|
|
51
|
+
*
|
|
52
|
+
* Optional — only FDv2 data managers implement this.
|
|
53
|
+
*/
|
|
54
|
+
setConnectionMode?(mode?: FDv2ConnectionMode): void;
|
|
55
|
+
/**
|
|
56
|
+
* Set a callback to flush pending analytics events. Called immediately
|
|
57
|
+
* (not debounced) when the lifecycle transitions to background.
|
|
58
|
+
*
|
|
59
|
+
* Optional — only FDv2 data managers implement this.
|
|
60
|
+
*/
|
|
61
|
+
setFlushCallback?(callback: () => void): void;
|
|
29
62
|
}
|
|
30
63
|
/**
|
|
31
64
|
* Factory interface for constructing data managers.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataManager.d.ts","sourceRoot":"","sources":["../src/DataManager.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,OAAO,EACP,SAAS,EACT,QAAQ,EACR,SAAS,EACT,SAAS,EACT,QAAQ,EACR,QAAQ,EACR,qBAAqB,EACrB,SAAS,EACV,MAAM,6BAA6B,CAAC;AAErC,OAAO,EAAE,iBAAiB,EAAE,MAAM,yBAAyB,C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C,EAAE,CAAC,GAAG,EAAE,KAAK,KAAK,IAAI;IAuBvC,SAAS,CAAC,wBAAwB,CAChC,OAAO,EAAE,SAAS,EAClB,cAAc,EAAE,OAAO,EACvB,gBAAgB,EAAE,SAAS,EAC3B,eAAe,CAAC,EAAE,MAAM,IAAI,EAC5B,cAAc,CAAC,EAAE,CAAC,GAAG,EAAE,KAAK,KAAK,IAAI;IAiCvC,SAAS,CAAC,qBAAqB,CAC7B,OAAO,EAAE,OAAO,EAChB,eAAe,CAAC,EAAE,MAAM,IAAI,GAC3B,GAAG,CAAC,SAAS,EAAE,qBAAqB,CAAC;IA4BxC,OAAO,CAAC,qCAAqC;IAqBtC,KAAK;CAIb"}
|
|
@@ -120,8 +120,16 @@ export interface LDOptions {
|
|
|
120
120
|
*/
|
|
121
121
|
logger?: LDLogger;
|
|
122
122
|
/**
|
|
123
|
-
* The maximum number of locally cached contexts.
|
|
124
|
-
* latency and to provide fallback when the SDK cannot reach LaunchDarkly services.
|
|
123
|
+
* The maximum number of locally cached contexts. The cache is used to decrease initialization
|
|
124
|
+
* latency and to provide fallback flag values when the SDK cannot reach LaunchDarkly services.
|
|
125
|
+
*
|
|
126
|
+
* @remarks
|
|
127
|
+
* Setting this to `0` disables caching entirely: the SDK will not read from or
|
|
128
|
+
* write to the cache, and any previously cached entries will be pruned from
|
|
129
|
+
* local storage.
|
|
130
|
+
*
|
|
131
|
+
* To suppress cache read/writes **without** removing existing cached data, use
|
|
132
|
+
* {@link LDOptions.disableCache} instead.
|
|
125
133
|
*
|
|
126
134
|
* @defaultValue 5
|
|
127
135
|
*/
|
|
@@ -253,9 +261,13 @@ export interface LDOptions {
|
|
|
253
261
|
*/
|
|
254
262
|
cleanOldPersistentData?: boolean;
|
|
255
263
|
/**
|
|
256
|
-
* Set to true to
|
|
257
|
-
*
|
|
258
|
-
*
|
|
264
|
+
* Set to `true` to suppress all reads and writes to the persistent flag cache
|
|
265
|
+
* in local storage.
|
|
266
|
+
*
|
|
267
|
+
* @remarks
|
|
268
|
+
* Unlike setting {@link LDOptions.maxCachedContexts} to `0`,
|
|
269
|
+
* this does **not** remove previously cached data — existing entries are left
|
|
270
|
+
* intact. This takes precedence over `maxCachedContexts`.
|
|
259
271
|
*
|
|
260
272
|
* @defaultValue false
|
|
261
273
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LDOptions.d.ts","sourceRoot":"","sources":["../../src/api/LDOptions.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,6BAA6B,CAAC;AAG5D,OAAO,EAAE,IAAI,EAAE,MAAM,sBAAsB,CAAC;AAC5C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAE9C,MAAM,WAAW,SAAS;IACxB;;;;;OAKG;IACH,oBAAoB,CAAC,EAAE,OAAO,CAAC;IAE/B;;;;;OAKG;IACH,eAAe,CAAC,EAAE;QAChB;;;;;;;WAOG;QACH,EAAE,CAAC,EAAE,MAAM,CAAC;QACZ;;;;;;;WAOG;QACH,OAAO,CAAC,EAAE,MAAM,CAAC;QAEjB;;;;;WAKG;QACH,IAAI,CAAC,EAAE,MAAM,CAAC;QAEd;;;;;WAKG;QACH,WAAW,CAAC,EAAE,MAAM,CAAC;KACtB,CAAC;IAEF;;;;OAIG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB;;;;;;;;;;;OAWG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB;;;;OAIG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;IAEhB;;;;;;;;;;OAUG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAE3B;;;;;;;OAOG;IACH,2BAA2B,CAAC,EAAE,MAAM,CAAC;IAErC;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;;OAIG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC;IAEvB;;;;;;;;;;OAUG;IACH,MAAM,CAAC,EAAE,Q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CAAC,EAAE,OAAO,CAAC;IAErB;;;;;;;;OAQG;IACH,2BAA2B,CAAC,EAAE,MAAM,CAAC;IAErC;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;;;OAIG;IACH,YAAY,CAAC,EAAE,MAAM,CAAC;IAEtB;;;;;OAKG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IAEpB;;;;;;;;;OASG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IAEtB;;;;;OAKG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IAErB;;;;OAIG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC;IAExB;;;;;;;;;;;;;OAaG;IACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAE1B;;;;;;;;;;;;;;;;OAgBG;IACH,KAAK,CAAC,EAAE,IAAI,EAAE,CAAC;IAEf;;;;;;;OAOG;IACH,UAAU,CAAC,EAAE,YAAY,EAAE,CAAC;IAE5B;;;;;OAKG;IACH,sBAAsB,CAAC,EAAE,OAAO,CAAC;IAiBjC;;;;;;;;;;OAUG;IACH,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB"}
|
|
@@ -4,6 +4,11 @@
|
|
|
4
4
|
*
|
|
5
5
|
* When not specified, the SDK uses `baseUri` for polling and `streamUri` for
|
|
6
6
|
* streaming from the base SDK configuration.
|
|
7
|
+
*
|
|
8
|
+
* This interface is not stable, and not subject to any backwards compatibility
|
|
9
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
10
|
+
* to this feature please join the EAP.
|
|
11
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
7
12
|
*/
|
|
8
13
|
export interface EndpointConfig {
|
|
9
14
|
/** Override for the polling base URI. Defaults to `baseUri` from SDK configuration. */
|
|
@@ -13,12 +18,23 @@ export interface EndpointConfig {
|
|
|
13
18
|
}
|
|
14
19
|
/**
|
|
15
20
|
* Configuration for a cache data source entry.
|
|
21
|
+
* Cache is only valid as an initializer (not a synchronizer).
|
|
22
|
+
*
|
|
23
|
+
* This interface is not stable, and not subject to any backwards compatibility
|
|
24
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
25
|
+
* to this feature please join the EAP.
|
|
26
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
16
27
|
*/
|
|
17
28
|
export interface CacheDataSourceEntry {
|
|
18
29
|
readonly type: 'cache';
|
|
19
30
|
}
|
|
20
31
|
/**
|
|
21
32
|
* Configuration for a polling data source entry.
|
|
33
|
+
*
|
|
34
|
+
* This interface is not stable, and not subject to any backwards compatibility
|
|
35
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
36
|
+
* to this feature please join the EAP.
|
|
37
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
22
38
|
*/
|
|
23
39
|
export interface PollingDataSourceEntry {
|
|
24
40
|
readonly type: 'polling';
|
|
@@ -29,6 +45,11 @@ export interface PollingDataSourceEntry {
|
|
|
29
45
|
}
|
|
30
46
|
/**
|
|
31
47
|
* Configuration for a streaming data source entry.
|
|
48
|
+
*
|
|
49
|
+
* This interface is not stable, and not subject to any backwards compatibility
|
|
50
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
51
|
+
* to this feature please join the EAP.
|
|
52
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
32
53
|
*/
|
|
33
54
|
export interface StreamingDataSourceEntry {
|
|
34
55
|
readonly type: 'streaming';
|
|
@@ -37,6 +58,42 @@ export interface StreamingDataSourceEntry {
|
|
|
37
58
|
/** Endpoint overrides for this streaming source. */
|
|
38
59
|
readonly endpoints?: EndpointConfig;
|
|
39
60
|
}
|
|
61
|
+
/**
|
|
62
|
+
* Configuration for the FDv1 polling fallback within a mode definition.
|
|
63
|
+
* When fdv1Endpoints is provided at the platform level, this controls
|
|
64
|
+
* how the FDv1 fallback synchronizer behaves for a specific mode.
|
|
65
|
+
*
|
|
66
|
+
* This interface is not stable, and not subject to any backwards compatibility
|
|
67
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
68
|
+
* to this feature please join the EAP.
|
|
69
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
70
|
+
*/
|
|
71
|
+
export interface FDv1FallbackConfig {
|
|
72
|
+
/** Poll interval for the FDv1 fallback in seconds. Minimum 30. */
|
|
73
|
+
readonly pollInterval?: number;
|
|
74
|
+
/** Endpoint overrides for the FDv1 fallback. */
|
|
75
|
+
readonly endpoints?: EndpointConfig;
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* An entry in the initializers list of a mode definition. Initializers
|
|
79
|
+
* can be cache, polling, or streaming sources.
|
|
80
|
+
*
|
|
81
|
+
* This type is not stable, and not subject to any backwards compatibility
|
|
82
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
83
|
+
* to this feature please join the EAP.
|
|
84
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
85
|
+
*/
|
|
86
|
+
export type InitializerEntry = CacheDataSourceEntry | PollingDataSourceEntry | StreamingDataSourceEntry;
|
|
87
|
+
/**
|
|
88
|
+
* An entry in the synchronizers list of a mode definition. Synchronizers
|
|
89
|
+
* can be polling or streaming sources (not cache).
|
|
90
|
+
*
|
|
91
|
+
* This type is not stable, and not subject to any backwards compatibility
|
|
92
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
93
|
+
* to this feature please join the EAP.
|
|
94
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
95
|
+
*/
|
|
96
|
+
export type SynchronizerEntry = PollingDataSourceEntry | StreamingDataSourceEntry;
|
|
40
97
|
/**
|
|
41
98
|
* A data source entry in a mode table. Each entry identifies a data source type
|
|
42
99
|
* and carries type-specific configuration overrides.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DataSourceEntry.d.ts","sourceRoot":"","sources":["../../../src/api/datasource/DataSourceEntry.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":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tB,wBAAwB,CAAC"}
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Connection modes for the FDv2 data system.
|
|
3
3
|
*
|
|
4
|
+
* This type is not stable, and not subject to any backwards compatibility
|
|
5
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
6
|
+
* to this feature please join the EAP.
|
|
7
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
8
|
+
*
|
|
4
9
|
* This defines the full set of named connection modes available in FDv2.
|
|
5
10
|
* Each mode maps to a specific initializer/synchronizer pipeline via the
|
|
6
11
|
* mode table.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FDv2ConnectionMode.d.ts","sourceRoot":"","sources":["../../../src/api/datasource/FDv2ConnectionMode.ts"],"names":[],"mappings":"AAGA
|
|
1
|
+
{"version":3,"file":"FDv2ConnectionMode.d.ts","sourceRoot":"","sources":["../../../src/api/datasource/FDv2ConnectionMode.ts"],"names":[],"mappings":"AAGA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AACH,KAAK,kBAAkB,GAAG,WAAW,GAAG,SAAS,GAAG,SAAS,GAAG,UAAU,GAAG,YAAY,CAAC;AAE1F,eAAe,kBAAkB,CAAC"}
|
|
@@ -1,51 +1,61 @@
|
|
|
1
1
|
import FDv2ConnectionMode from './FDv2ConnectionMode';
|
|
2
|
+
import { ModeDefinition } from './ModeDefinition';
|
|
2
3
|
/**
|
|
3
4
|
* Configuration for the FDv2 client-side data system.
|
|
5
|
+
*
|
|
6
|
+
* This interface is not stable, and not subject to any backwards compatibility
|
|
7
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
8
|
+
* to this feature please join the EAP.
|
|
9
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
4
10
|
*/
|
|
5
11
|
export interface LDClientDataSystemOptions {
|
|
6
12
|
/**
|
|
7
|
-
*
|
|
13
|
+
* Controls how the SDK switches between connection modes.
|
|
8
14
|
*
|
|
9
|
-
*
|
|
10
|
-
* -
|
|
11
|
-
*
|
|
12
|
-
* -
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
|
|
16
|
-
initialConnectionMode?: FDv2ConnectionMode;
|
|
17
|
-
/**
|
|
18
|
-
* The connection mode to use when the application transitions to the background.
|
|
19
|
-
*
|
|
20
|
-
* This is primarily used by mobile SDKs (React Native). When the application
|
|
21
|
-
* enters the background, the SDK switches to this mode. When returning to
|
|
22
|
-
* the foreground, it switches back to the foreground mode.
|
|
15
|
+
* - `true` — enable all automatic switching (lifecycle + network)
|
|
16
|
+
* - `false` — disable all automatic switching; uses the platform default
|
|
17
|
+
* foreground mode
|
|
18
|
+
* - {@link AutomaticModeSwitchingConfig} — granular control over which
|
|
19
|
+
* platform events trigger automatic mode switches
|
|
20
|
+
* - {@link ManualModeSwitching} — disable automatic switching and specify
|
|
21
|
+
* the initial connection mode explicitly
|
|
23
22
|
*
|
|
24
|
-
*
|
|
25
|
-
* Set to 'background' to use the built-in background mode (polling @ 1hr).
|
|
26
|
-
* Set to 'offline' to stop all connections in the background.
|
|
23
|
+
* Default is `true` for mobile SDKs, `false` for browser.
|
|
27
24
|
*/
|
|
28
|
-
|
|
25
|
+
automaticModeSwitching?: boolean | AutomaticModeSwitchingConfig | ManualModeSwitching;
|
|
29
26
|
/**
|
|
30
|
-
*
|
|
27
|
+
* Override the data source pipeline for specific connection modes.
|
|
31
28
|
*
|
|
32
|
-
*
|
|
33
|
-
* - `
|
|
34
|
-
*
|
|
35
|
-
* which platform events trigger automatic mode switches
|
|
29
|
+
* Each key is a connection mode name (`'streaming'`, `'polling'`, `'offline'`,
|
|
30
|
+
* `'one-shot'`, `'background'`). The value defines the initializers and
|
|
31
|
+
* synchronizers for that mode, replacing the built-in defaults.
|
|
36
32
|
*
|
|
37
|
-
*
|
|
38
|
-
*
|
|
39
|
-
* sources when network availability changes.
|
|
33
|
+
* Only the modes you specify are overridden — unspecified modes retain
|
|
34
|
+
* their built-in definitions.
|
|
40
35
|
*
|
|
41
|
-
*
|
|
36
|
+
* @example
|
|
37
|
+
* ```
|
|
38
|
+
* connectionModes: {
|
|
39
|
+
* streaming: {
|
|
40
|
+
* initializers: [{ type: 'polling' }],
|
|
41
|
+
* synchronizers: [{ type: 'streaming' }],
|
|
42
|
+
* },
|
|
43
|
+
* }
|
|
44
|
+
* ```
|
|
42
45
|
*/
|
|
43
|
-
|
|
46
|
+
connectionModes?: Partial<Record<FDv2ConnectionMode, ModeDefinition>>;
|
|
44
47
|
}
|
|
45
48
|
/**
|
|
46
49
|
* Granular control over which platform events trigger automatic mode switches.
|
|
50
|
+
*
|
|
51
|
+
* This interface is not stable, and not subject to any backwards compatibility
|
|
52
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
53
|
+
* to this feature please join the EAP.
|
|
54
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
47
55
|
*/
|
|
48
56
|
export interface AutomaticModeSwitchingConfig {
|
|
57
|
+
/** Discriminant — selects automatic mode switching. */
|
|
58
|
+
readonly type: 'automatic';
|
|
49
59
|
/**
|
|
50
60
|
* Whether to automatically switch modes in response to application lifecycle
|
|
51
61
|
* events (foreground/background on mobile, visibility changes on browser).
|
|
@@ -62,14 +72,22 @@ export interface AutomaticModeSwitchingConfig {
|
|
|
62
72
|
readonly network?: boolean;
|
|
63
73
|
}
|
|
64
74
|
/**
|
|
65
|
-
*
|
|
75
|
+
* Disable automatic switching and specify the initial connection mode.
|
|
76
|
+
*
|
|
77
|
+
* Subsequent mode transitions must be triggered explicitly via
|
|
78
|
+
* {@link FDv2DataManagerControl.setConnectionMode}.
|
|
79
|
+
*
|
|
80
|
+
* This interface is not stable, and not subject to any backwards compatibility
|
|
81
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
82
|
+
* to this feature please join the EAP.
|
|
83
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
66
84
|
*/
|
|
67
|
-
export interface
|
|
68
|
-
/**
|
|
69
|
-
readonly
|
|
70
|
-
/**
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
85
|
+
export interface ManualModeSwitching {
|
|
86
|
+
/** Discriminant — selects manual mode switching. */
|
|
87
|
+
readonly type: 'manual';
|
|
88
|
+
/**
|
|
89
|
+
* The connection mode to use when the SDK starts.
|
|
90
|
+
*/
|
|
91
|
+
initialConnectionMode: FDv2ConnectionMode;
|
|
74
92
|
}
|
|
75
93
|
//# sourceMappingURL=LDClientDataSystemOptions.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"LDClientDataSystemOptions.d.ts","sourceRoot":"","sources":["../../../src/api/datasource/LDClientDataSystemOptions.ts"],"names":[],"mappings":"AAAA,OAAO,kBAAkB,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"LDClientDataSystemOptions.d.ts","sourceRoot":"","sources":["../../../src/api/datasource/LDClientDataSystemOptions.ts"],"names":[],"mappings":"AAAA,OAAO,kBAAkB,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAKlD;;;;;;;GAOG;AACH,MAAM,WAAW,yBAAyB;IACxC;;;;;;;;;;;;OAYG;IACH,sBAAsB,CAAC,EAAE,OAAO,GAAG,4BAA4B,GAAG,mBAAmB,CAAC;IAEtF;;;;;;;;;;;;;;;;;;;OAmBG;IACH,eAAe,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,kBAAkB,EAAE,cAAc,CAAC,CAAC,CAAC;CACvE;AAED;;;;;;;GAOG;AACH,MAAM,WAAW,4BAA4B;IAC3C,uDAAuD;IACvD,QAAQ,CAAC,IAAI,EAAE,WAAW,CAAC;IAE3B;;;;;OAKG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC;IAE7B;;;;;OAKG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC;CAC5B;AAED;;;;;;;;;;GAUG;AACH,MAAM,WAAW,mBAAmB;IAClC,oDAAoD;IACpD,QAAQ,CAAC,IAAI,EAAE,QAAQ,CAAC;IAExB;;OAEG;IACH,qBAAqB,EAAE,kBAAkB,CAAC;CAC3C"}
|
|
@@ -1,7 +1,12 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { FDv1FallbackConfig, InitializerEntry, SynchronizerEntry } from './DataSourceEntry';
|
|
2
2
|
/**
|
|
3
3
|
* Defines the data pipeline for a connection mode: which data sources
|
|
4
4
|
* are used during initialization and which are used for ongoing synchronization.
|
|
5
|
+
*
|
|
6
|
+
* This interface is not stable, and not subject to any backwards compatibility
|
|
7
|
+
* guarantees or semantic versioning. It is in early access. If you want access
|
|
8
|
+
* to this feature please join the EAP.
|
|
9
|
+
* https://launchdarkly.com/docs/sdk/features/data-saving-mode
|
|
5
10
|
*/
|
|
6
11
|
export interface ModeDefinition {
|
|
7
12
|
/**
|
|
@@ -9,13 +14,24 @@ export interface ModeDefinition {
|
|
|
9
14
|
* Sources are tried in order; the first that successfully provides a full
|
|
10
15
|
* data set transitions the SDK out of the initialization phase.
|
|
11
16
|
*/
|
|
12
|
-
readonly initializers: ReadonlyArray<
|
|
17
|
+
readonly initializers: ReadonlyArray<InitializerEntry>;
|
|
13
18
|
/**
|
|
14
19
|
* Ordered list of data sources for ongoing synchronization after
|
|
15
20
|
* initialization completes. Sources are in priority order with automatic
|
|
16
21
|
* failover to the next source if the primary fails.
|
|
17
22
|
* An empty array means no synchronization occurs (e.g., offline, one-shot).
|
|
18
23
|
*/
|
|
19
|
-
readonly synchronizers: ReadonlyArray<
|
|
24
|
+
readonly synchronizers: ReadonlyArray<SynchronizerEntry>;
|
|
25
|
+
/**
|
|
26
|
+
* Configuration for the FDv1 polling fallback synchronizer for this mode.
|
|
27
|
+
* When the platform provides fdv1Endpoints, a fallback synchronizer is
|
|
28
|
+
* automatically appended to modes with synchronizers. This field controls
|
|
29
|
+
* the poll interval and endpoint overrides for that fallback.
|
|
30
|
+
*
|
|
31
|
+
* When omitted (or when a user overrides a mode without specifying this),
|
|
32
|
+
* the built-in default for the mode is used. The fallback cannot be removed
|
|
33
|
+
* through configuration.
|
|
34
|
+
*/
|
|
35
|
+
readonly fdv1Fallback?: FDv1FallbackConfig;
|
|
20
36
|
}
|
|
21
37
|
//# sourceMappingURL=ModeDefinition.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ModeDefinition.d.ts","sourceRoot":"","sources":["../../../src/api/datasource/ModeDefinition.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"ModeDefinition.d.ts","sourceRoot":"","sources":["../../../src/api/datasource/ModeDefinition.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,MAAM,mBAAmB,CAAC;AAE5F;;;;;;;;GAQG;AACH,MAAM,WAAW,cAAc;IAC7B;;;;OAIG;IACH,QAAQ,CAAC,YAAY,EAAE,aAAa,CAAC,gBAAgB,CAAC,CAAC;IAEvD;;;;;OAKG;IACH,QAAQ,CAAC,aAAa,EAAE,aAAa,CAAC,iBAAiB,CAAC,CAAC;IAEzD;;;;;;;;;OASG;IACH,QAAQ,CAAC,YAAY,CAAC,EAAE,kBAAkB,CAAC;CAC5C"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export type { default as FDv2ConnectionMode } from './FDv2ConnectionMode';
|
|
2
|
-
export type { EndpointConfig, CacheDataSourceEntry, PollingDataSourceEntry, StreamingDataSourceEntry, DataSourceEntry, } from './DataSourceEntry';
|
|
2
|
+
export type { EndpointConfig, FDv1FallbackConfig, CacheDataSourceEntry, PollingDataSourceEntry, StreamingDataSourceEntry, InitializerEntry, SynchronizerEntry, DataSourceEntry, } from './DataSourceEntry';
|
|
3
3
|
export type { ModeDefinition } from './ModeDefinition';
|
|
4
|
-
export type { LDClientDataSystemOptions, AutomaticModeSwitchingConfig,
|
|
4
|
+
export type { LDClientDataSystemOptions, AutomaticModeSwitchingConfig, ManualModeSwitching, } from './LDClientDataSystemOptions';
|
|
5
5
|
export type { LifecycleState, ModeState, ConfiguredMode, ModeResolution, ModeResolutionEntry, ModeResolutionTable, } from './ModeResolution';
|
|
6
6
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/datasource/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1E,YAAY,EACV,cAAc,EACd,oBAAoB,EACpB,sBAAsB,EACtB,wBAAwB,EACxB,eAAe,GAChB,MAAM,mBAAmB,CAAC;AAC3B,YAAY,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,YAAY,EACV,yBAAyB,EACzB,4BAA4B,EAC5B,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/api/datasource/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1E,YAAY,EACV,cAAc,EACd,kBAAkB,EAClB,oBAAoB,EACpB,sBAAsB,EACtB,wBAAwB,EACxB,gBAAgB,EAChB,iBAAiB,EACjB,eAAe,GAChB,MAAM,mBAAmB,CAAC;AAC3B,YAAY,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,YAAY,EACV,yBAAyB,EACzB,4BAA4B,EAC5B,mBAAmB,GACpB,MAAM,6BAA6B,CAAC;AACrC,YAAY,EACV,cAAc,EACd,SAAS,EACT,cAAc,EACd,cAAc,EACd,mBAAmB,EACnB,mBAAmB,GACpB,MAAM,kBAAkB,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { ApplicationTags, internal, LDFlagSet, LDLogger, LDPluginEnvironmentMetadata, ServiceEndpoints } from '@launchdarkly/js-sdk-common';
|
|
2
2
|
import { Hook, type LDOptions } from '../api';
|
|
3
|
-
import type { LDClientDataSystemOptions, PlatformDataSystemDefaults } from '../api/datasource/LDClientDataSystemOptions';
|
|
4
3
|
import { LDInspection } from '../api/LDInspection';
|
|
4
|
+
import type { InternalDataSystemOptions, PlatformDataSystemDefaults } from '../datasource/LDClientDataSystemOptions';
|
|
5
5
|
export interface LDClientInternalOptions extends internal.LDInternalOptions {
|
|
6
6
|
trackEventModifier?: (event: internal.InputCustomEvent) => internal.InputCustomEvent;
|
|
7
7
|
getImplementationHooks: (environmentMetadata: LDPluginEnvironmentMetadata) => Hook[];
|
|
@@ -46,7 +46,7 @@ export interface Configuration {
|
|
|
46
46
|
readonly inspectors: LDInspection[];
|
|
47
47
|
readonly credentialType: 'clientSideId' | 'mobileKey';
|
|
48
48
|
readonly getImplementationHooks: (environmentMetadata: LDPluginEnvironmentMetadata) => Hook[];
|
|
49
|
-
readonly dataSystem?:
|
|
49
|
+
readonly dataSystem?: InternalDataSystemOptions;
|
|
50
50
|
}
|
|
51
51
|
declare const DEFAULT_POLLING: string;
|
|
52
52
|
declare const DEFAULT_STREAM: string;
|
|
@@ -91,7 +91,7 @@ export default class ConfigurationImpl implements Configuration {
|
|
|
91
91
|
readonly trackEventModifier: (event: internal.InputCustomEvent) => internal.InputCustomEvent;
|
|
92
92
|
readonly credentialType: 'clientSideId' | 'mobileKey';
|
|
93
93
|
readonly getImplementationHooks: (environmentMetadata: LDPluginEnvironmentMetadata) => Hook[];
|
|
94
|
-
readonly dataSystem?:
|
|
94
|
+
readonly dataSystem?: InternalDataSystemOptions;
|
|
95
95
|
[index: string]: any;
|
|
96
96
|
constructor(pristineOptions?: LDOptions, internalOptions?: LDClientInternalOptions);
|
|
97
97
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Configuration.d.ts","sourceRoot":"","sources":["../../src/configuration/Configuration.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,eAAe,EAEf,QAAQ,EACR,SAAS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Record<str
|
|
|
29
29
|
* Creates a validator for nested objects. When used in a validator map,
|
|
30
30
|
* `validateOptions` will recursively validate the nested object's properties.
|
|
31
31
|
* Defaults for nested fields are passed through from the parent.
|
|
32
|
+
*
|
|
33
|
+
* @param validators - Validator map for the nested object's fields.
|
|
34
|
+
* @param options - Optional configuration.
|
|
35
|
+
* @param options.defaults - Built-in defaults for nested fields.
|
|
36
|
+
* @param options.is - Custom `is` predicate. When provided, replaces the
|
|
37
|
+
* default "is object" check. Use this to discriminate between object shapes
|
|
38
|
+
* in an `anyOf` (e.g., matching on a `type` discriminant field).
|
|
32
39
|
*/
|
|
33
|
-
export declare function validatorOf(validators: Record<string, TypeValidator>,
|
|
40
|
+
export declare function validatorOf(validators: Record<string, TypeValidator>, options?: {
|
|
41
|
+
defaults?: Record<string, unknown>;
|
|
42
|
+
is?: (u: unknown) => boolean;
|
|
43
|
+
}): CompoundValidator;
|
|
34
44
|
/**
|
|
35
45
|
* Creates a validator for arrays of discriminated objects. Each item in the
|
|
36
46
|
* array must be an object containing a `discriminant` field whose value
|
|
@@ -80,6 +90,10 @@ export declare function anyOf(...validators: TypeValidator[]): CompoundValidator
|
|
|
80
90
|
*
|
|
81
91
|
* @param keyValidator - Validates that each key is an allowed value.
|
|
82
92
|
* @param valueValidator - Validates each value in the record.
|
|
93
|
+
* @param options - Optional configuration.
|
|
94
|
+
* @param options.defaults - Built-in defaults for the record entries. When
|
|
95
|
+
* provided, takes priority over defaults passed from the parent at
|
|
96
|
+
* validation time (same precedence as {@link validatorOf}).
|
|
83
97
|
*
|
|
84
98
|
* @example
|
|
85
99
|
* ```ts
|
|
@@ -91,5 +105,7 @@ export declare function anyOf(...validators: TypeValidator[]): CompoundValidator
|
|
|
91
105
|
* )
|
|
92
106
|
* ```
|
|
93
107
|
*/
|
|
94
|
-
export declare function recordOf(keyValidator: TypeValidator, valueValidator: TypeValidator
|
|
108
|
+
export declare function recordOf(keyValidator: TypeValidator, valueValidator: TypeValidator, options?: {
|
|
109
|
+
defaults?: Record<string, unknown>;
|
|
110
|
+
}): CompoundValidator;
|
|
95
111
|
//# sourceMappingURL=validateOptions.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validateOptions.d.ts","sourceRoot":"","sources":["../../src/configuration/validateOptions.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,QAAQ,EAGR,aAAa,EAEd,MAAM,6BAA6B,CAAC;AAErC;;;;;;;GAOG;AACH,MAAM,WAAW,iBAAkB,SAAQ,aAAa;IACtD,QAAQ,CACN,KAAK,EAAE,OAAO,EACd,IAAI,EAAE,MAAM,EACZ,MAAM,CAAC,EAAE,QAAQ,EACjB,QAAQ,CAAC,EAAE,OAAO,GACjB;QAAE,KAAK,EAAE,OAAO,CAAA;KAAE,GAAG,SAAS,CAAC;CACnC;AAMD;;;;;;;;;;;GAWG;AACH,MAAM,CAAC,OAAO,UAAU,eAAe,CACrC,KAAK,EAAE,OAAO,EACd,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,EAC3C,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EACjC,MAAM,CAAC,EAAE,QAAQ,EACjB,MAAM,CAAC,EAAE,MAAM,GACd,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CA0DzB;AAED
|
|
1
|
+
{"version":3,"file":"validateOptions.d.ts","sourceRoot":"","sources":["../../src/configuration/validateOptions.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,QAAQ,EAGR,aAAa,EAEd,MAAM,6BAA6B,CAAC;AAErC;;;;;;;GAOG;AACH,MAAM,WAAW,iBAAkB,SAAQ,aAAa;IACtD,QAAQ,CACN,KAAK,EAAE,OAAO,EACd,IAAI,EAAE,MAAM,EACZ,MAAM,CAAC,EAAE,QAAQ,EACjB,QAAQ,CAAC,EAAE,OAAO,GACjB;QAAE,KAAK,EAAE,OAAO,CAAA;KAAE,GAAG,SAAS,CAAC;CACnC;AAMD;;;;;;;;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type PlatformDataSystemDefaults } from '../datasource/LDClientDataSystemOptions';
|
|
4
4
|
export interface ValidatorOptions {
|
|
5
5
|
dataSystemDefaults?: PlatformDataSystemDefaults;
|
|
6
6
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"validators.d.ts","sourceRoot":"","sources":["../../src/configuration/validators.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAkB,MAAM,6BAA6B,CAAC;AAE5E,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,QAAQ,CAAC;
|
|
1
|
+
{"version":3,"file":"validators.d.ts","sourceRoot":"","sources":["../../src/configuration/validators.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAkB,MAAM,6BAA6B,CAAC;AAE5E,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,QAAQ,CAAC;AAExC,OAAO,EAEL,KAAK,0BAA0B,EAChC,MAAM,yCAAyC,CAAC;AAGjD,MAAM,WAAW,gBAAgB;IAC/B,kBAAkB,CAAC,EAAE,0BAA0B,CAAC;CACjD;AAED,MAAM,CAAC,OAAO,UAAU,gBAAgB,CACtC,OAAO,CAAC,EAAE,gBAAgB,GACzB,MAAM,CAAC,MAAM,SAAS,EAAE,aAAa,CAAC,CA2CxC"}
|
|
@@ -5,15 +5,17 @@ import type { FDv2ConnectionMode, ModeDefinition } from '../api/datasource';
|
|
|
5
5
|
type ModeTable = {
|
|
6
6
|
readonly [K in FDv2ConnectionMode]: ModeDefinition;
|
|
7
7
|
};
|
|
8
|
+
declare const DEFAULT_FDV1_FALLBACK_POLL_INTERVAL_SECONDS = 300;
|
|
8
9
|
declare const BACKGROUND_POLL_INTERVAL_SECONDS = 3600;
|
|
9
10
|
declare const connectionModeValidator: import("@launchdarkly/js-sdk-common").OneOf;
|
|
10
11
|
declare const modeDefinitionValidators: {
|
|
11
12
|
initializers: import("../configuration/validateOptions").CompoundValidator;
|
|
12
13
|
synchronizers: import("../configuration/validateOptions").CompoundValidator;
|
|
14
|
+
fdv1Fallback: import("../configuration/validateOptions").CompoundValidator;
|
|
13
15
|
};
|
|
14
16
|
declare const MODE_DEFINITION_DEFAULTS: Record<string, unknown>;
|
|
15
|
-
declare const connectionModesValidator: import("../configuration/validateOptions").CompoundValidator;
|
|
16
17
|
declare const MODE_TABLE: ModeTable;
|
|
18
|
+
declare const connectionModesValidator: import("../configuration/validateOptions").CompoundValidator;
|
|
17
19
|
export type { ModeTable };
|
|
18
|
-
export { MODE_TABLE, MODE_DEFINITION_DEFAULTS, BACKGROUND_POLL_INTERVAL_SECONDS, connectionModeValidator, modeDefinitionValidators, connectionModesValidator, };
|
|
20
|
+
export { MODE_TABLE, MODE_DEFINITION_DEFAULTS, DEFAULT_FDV1_FALLBACK_POLL_INTERVAL_SECONDS, BACKGROUND_POLL_INTERVAL_SECONDS, connectionModeValidator, modeDefinitionValidators, connectionModesValidator, };
|
|
19
21
|
//# sourceMappingURL=ConnectionModeConfig.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ConnectionModeConfig.d.ts","sourceRoot":"","sources":["../../src/datasource/ConnectionModeConfig.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAG5E;;GAEG;AACH,KAAK,SAAS,GAAG;IACf,QAAQ,EAAE,CAAC,IAAI,kBAAkB,GAAG,cAAc;CACnD,CAAC;AAEF,QAAA,MAAM,gCAAgC,OAAO,CAAC;AAG9C,QAAA,MAAM,uBAAuB,6CAM5B,CAAC;
|
|
1
|
+
{"version":3,"file":"ConnectionModeConfig.d.ts","sourceRoot":"","sources":["../../src/datasource/ConnectionModeConfig.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAG5E;;GAEG;AACH,KAAK,SAAS,GAAG;IACf,QAAQ,EAAE,CAAC,IAAI,kBAAkB,GAAG,cAAc;CACnD,CAAC;AAEF,QAAA,MAAM,2CAA2C,MAAM,CAAC;AACxD,QAAA,MAAM,gCAAgC,OAAO,CAAC;AAG9C,QAAA,MAAM,uBAAuB,6CAM5B,CAAC;AAuCF,QAAA,MAAM,wBAAwB;;;;CAI7B,CAAC;AAEF,QAAA,MAAM,wBAAwB,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAGrD,CAAC;AAEF,QAAA,MAAM,UAAU,EAAE,SAwBjB,CAAC;AAEF,QAAA,MAAM,wBAAwB,8DAG7B,CAAC;AAEF,YAAY,EAAE,SAAS,EAAE,CAAC;AAC1B,OAAO,EACL,UAAU,EACV,wBAAwB,EACxB,2CAA2C,EAC3C,gCAAgC,EAChC,uBAAuB,EACvB,wBAAwB,EACxB,wBAAwB,GACzB,CAAC"}
|