@configdirector/react-native-sdk 1.10.0 → 1.10.1
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.
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as createDefaultLogger, d as ConfigDirectorConnectionError, f as ConfigDirectorValidationError, l as nativeValueConfigState, m as _defineProperty, p as Emitter, r as DefaultConfigDirectorClient, s as discardingTelemetryClient, t as INSTALLED_TEST_CLIENT_SLOT } from "./installedTestClient-
|
|
1
|
+
import { c as createDefaultLogger, d as ConfigDirectorConnectionError, f as ConfigDirectorValidationError, l as nativeValueConfigState, m as _defineProperty, p as Emitter, r as DefaultConfigDirectorClient, s as discardingTelemetryClient, t as INSTALLED_TEST_CLIENT_SLOT } from "./installedTestClient-CM98r0qu.mjs";
|
|
2
2
|
//#region ../js-client-core/src/testing/InMemoryConnection.ts
|
|
3
3
|
const TEST_ENVIRONMENT = {
|
|
4
4
|
environmentId: "test-environment",
|
|
@@ -295,7 +295,7 @@ const installTestClient = (testClient) => {
|
|
|
295
295
|
const createTestClient = (options) => {
|
|
296
296
|
return createTestClient$1({
|
|
297
297
|
sdkName: "react-native-sdk",
|
|
298
|
-
sdkVersion: "1.10.
|
|
298
|
+
sdkVersion: "1.10.1"
|
|
299
299
|
}, options);
|
|
300
300
|
};
|
|
301
301
|
//#endregion
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { a as DEFAULT_CACHING_SIZE_LIMIT_BYTES, c as createDefaultLogger, i as CACHED_VALUES_STORAGE_KEY_PREFIX, m as _defineProperty, n as readInstalledTestClient, o as fetchWithTimeout, r as DefaultConfigDirectorClient, u as isFetchErrorFatal } from "./installedTestClient-
|
|
1
|
+
import { a as DEFAULT_CACHING_SIZE_LIMIT_BYTES, c as createDefaultLogger, i as CACHED_VALUES_STORAGE_KEY_PREFIX, m as _defineProperty, n as readInstalledTestClient, o as fetchWithTimeout, r as DefaultConfigDirectorClient, u as isFetchErrorFatal } from "./installedTestClient-CM98r0qu.mjs";
|
|
2
2
|
import React, { Component, useContext as useContext$1 } from "react";
|
|
3
3
|
import { AppState, NativeModules } from "react-native";
|
|
4
4
|
import { sha256 } from "@noble/hashes/sha2.js";
|
|
@@ -777,7 +777,7 @@ const createReactNativeClient = (clientSdkKey, clientOptions) => {
|
|
|
777
777
|
var _clientOptions$logger;
|
|
778
778
|
const sdkIdentity = {
|
|
779
779
|
sdkName: "react-native-sdk",
|
|
780
|
-
sdkVersion: "1.10.
|
|
780
|
+
sdkVersion: "1.10.1"
|
|
781
781
|
};
|
|
782
782
|
const logger = (_clientOptions$logger = clientOptions === null || clientOptions === void 0 ? void 0 : clientOptions.logger) !== null && _clientOptions$logger !== void 0 ? _clientOptions$logger : createConsoleLogger("warn");
|
|
783
783
|
const metadata = resolveMetadata(clientOptions === null || clientOptions === void 0 ? void 0 : clientOptions.metadata, logger);
|
|
@@ -1213,8 +1213,8 @@ var PollingTransport = class extends AbstractPollingTransport {
|
|
|
1213
1213
|
this.pollingIntervalSeconds = (_options$pollingInter = options.pollingInterval) !== null && _options$pollingInter !== void 0 ? _options$pollingInter : 60;
|
|
1214
1214
|
}
|
|
1215
1215
|
async connect(context, timeout) {
|
|
1216
|
-
|
|
1217
|
-
this.
|
|
1216
|
+
this.endCurrentConnection();
|
|
1217
|
+
const generation = this.connectionGeneration;
|
|
1218
1218
|
const clientSession = await this.options.clientSession;
|
|
1219
1219
|
if (generation !== this.connectionGeneration) return this;
|
|
1220
1220
|
try {
|
|
@@ -1229,9 +1229,14 @@ var PollingTransport = class extends AbstractPollingTransport {
|
|
|
1229
1229
|
return this;
|
|
1230
1230
|
}
|
|
1231
1231
|
close() {
|
|
1232
|
-
this.
|
|
1232
|
+
this.endCurrentConnection();
|
|
1233
1233
|
super.close();
|
|
1234
1234
|
}
|
|
1235
|
+
endCurrentConnection() {
|
|
1236
|
+
this.connectionGeneration++;
|
|
1237
|
+
this.clearPollingInterval();
|
|
1238
|
+
this.lastUpdateTimestamp = void 0;
|
|
1239
|
+
}
|
|
1235
1240
|
async fetchConfigs(context, timeout, clientSession) {
|
|
1236
1241
|
if (this.fatalError) {
|
|
1237
1242
|
this.logger.warn("[PollingTransport] There was a prior unrecoverable error. Ignoring attempt to reconnect.");
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@configdirector/react-native-sdk",
|
|
3
|
-
"version": "1.10.
|
|
3
|
+
"version": "1.10.1",
|
|
4
4
|
"description": "React Native client SDK for ConfigDirector. ConfigDirector is a remote configuration and feature flag service.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "ConfigDirector",
|