@microsoft/1ds-core-js 4.3.0-nightly3.2406-07 → 4.3.0-nightly3.2406-08
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/bundle/es5/{ms.core-4.3.0-nightly3.2406-07.gbl.js → ms.core-4.3.0-nightly3.2406-08.gbl.js} +202 -24
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-08.gbl.js.map +1 -0
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-08.gbl.min.js +7 -0
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-08.gbl.min.js.map +1 -0
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-08.integrity.json +46 -0
- package/bundle/es5/{ms.core-4.3.0-nightly3.2406-07.js → ms.core-4.3.0-nightly3.2406-08.js} +202 -24
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-08.js.map +1 -0
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-08.min.js +7 -0
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-08.min.js.map +1 -0
- package/bundle/es5/ms.core.gbl.js +201 -23
- package/bundle/es5/ms.core.gbl.js.map +1 -1
- package/bundle/es5/ms.core.gbl.min.js +2 -2
- package/bundle/es5/ms.core.gbl.min.js.map +1 -1
- package/bundle/es5/ms.core.integrity.json +17 -17
- package/bundle/es5/ms.core.js +201 -23
- package/bundle/es5/ms.core.js.map +1 -1
- package/bundle/es5/ms.core.min.js +2 -2
- package/bundle/es5/ms.core.min.js.map +1 -1
- package/dist/es5/ms.core.js +199 -21
- package/dist/es5/ms.core.js.map +1 -1
- package/dist/es5/ms.core.min.js +2 -2
- package/dist/es5/ms.core.min.js.map +1 -1
- package/dist-es5/AppInsightsCore.js +1 -1
- package/dist-es5/BaseCore.js +1 -1
- package/dist-es5/DataModels.js +1 -1
- package/dist-es5/Enums.js +1 -1
- package/dist-es5/Index.js +1 -1
- package/dist-es5/InternalConstants.js +1 -1
- package/dist-es5/Utils.js +2 -2
- package/dist-es5/Utils.js.map +1 -1
- package/dist-es5/ValueSanitizer.js +1 -1
- package/dist-es5/__DynamicConstants.js +1 -1
- package/package.json +2 -2
- package/types/1ds-core-js.d.ts +2 -2
- package/types/1ds-core-js.namespaced.d.ts +68 -6
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-07.gbl.js.map +0 -1
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-07.gbl.min.js +0 -7
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-07.gbl.min.js.map +0 -1
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-07.integrity.json +0 -46
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-07.js.map +0 -1
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-07.min.js +0 -7
- package/bundle/es5/ms.core-4.3.0-nightly3.2406-07.min.js.map +0 -1
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "ms.core",
|
|
3
|
+
"version": "4.3.0-nightly3.2406-08",
|
|
4
|
+
"ext": {
|
|
5
|
+
"@gbl.js": {
|
|
6
|
+
"file": "ms.core-4.3.0-nightly3.2406-08.gbl.js",
|
|
7
|
+
"type": "text/javascript; charset=utf-8",
|
|
8
|
+
"integrity": "sha256-OJku6aYnT7wYRiRqDY4/tnQk2SMYC96sXWAJFQFFK54= sha384-6mKqdiSoOUGK4aBftHVd8+Ub9Co0fF+xpN+WU8D1meurVBdGEuFUoKggV6OhHqLk sha512-kQHF3dhaiftUntZOKQeJj7HnCr5C6e7gXFpuigOcnRJ+QkP8wyi41VwuBfDrzF8PAh9QSApbs1tvvvYW5zqW7Q==",
|
|
9
|
+
"hashes": {
|
|
10
|
+
"sha256": "OJku6aYnT7wYRiRqDY4/tnQk2SMYC96sXWAJFQFFK54=",
|
|
11
|
+
"sha384": "6mKqdiSoOUGK4aBftHVd8+Ub9Co0fF+xpN+WU8D1meurVBdGEuFUoKggV6OhHqLk",
|
|
12
|
+
"sha512": "kQHF3dhaiftUntZOKQeJj7HnCr5C6e7gXFpuigOcnRJ+QkP8wyi41VwuBfDrzF8PAh9QSApbs1tvvvYW5zqW7Q=="
|
|
13
|
+
}
|
|
14
|
+
},
|
|
15
|
+
"@gbl.min.js": {
|
|
16
|
+
"file": "ms.core-4.3.0-nightly3.2406-08.gbl.min.js",
|
|
17
|
+
"type": "text/javascript; charset=utf-8",
|
|
18
|
+
"integrity": "sha256-XZIemIPq5987cOG/wUepdY4vYUTrgpfIGr2hjVEkj7c= sha384-i+PETfYCBClPJcBdxOZ1GJ68z2ld/PcHRw02nw0vZI6z7CIVG5Etq3HzDNrrtM0u sha512-N8Ds5OZd9dHlDHVQwPcsFQMV7A2lFhTkv/5qvuhuW7s4PYUjG2uGzvVD9rpHKeB9a1i5q2QWhGEI1H8z48Hctw==",
|
|
19
|
+
"hashes": {
|
|
20
|
+
"sha256": "XZIemIPq5987cOG/wUepdY4vYUTrgpfIGr2hjVEkj7c=",
|
|
21
|
+
"sha384": "i+PETfYCBClPJcBdxOZ1GJ68z2ld/PcHRw02nw0vZI6z7CIVG5Etq3HzDNrrtM0u",
|
|
22
|
+
"sha512": "N8Ds5OZd9dHlDHVQwPcsFQMV7A2lFhTkv/5qvuhuW7s4PYUjG2uGzvVD9rpHKeB9a1i5q2QWhGEI1H8z48Hctw=="
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
"@js": {
|
|
26
|
+
"file": "ms.core-4.3.0-nightly3.2406-08.js",
|
|
27
|
+
"type": "text/javascript; charset=utf-8",
|
|
28
|
+
"integrity": "sha256-h6/2mJqAR/WSinINRRO0d5XXClUVqvLRdQDTcMvddSA= sha384-5A8i73CnFwWAZMTqAweTMCNwKZCijCQvhZQT4jaGUfWXrYC83zJVnSywLIFmhNph sha512-SLyX+Lfii7Gg8qNwGP3oMPjZjStP5y8a4GkwDxqYTDYyJ7DVYYJ+cvFEzVxVqEQIkyr3pdXT9rdOqPSgKrPeWA==",
|
|
29
|
+
"hashes": {
|
|
30
|
+
"sha256": "h6/2mJqAR/WSinINRRO0d5XXClUVqvLRdQDTcMvddSA=",
|
|
31
|
+
"sha384": "5A8i73CnFwWAZMTqAweTMCNwKZCijCQvhZQT4jaGUfWXrYC83zJVnSywLIFmhNph",
|
|
32
|
+
"sha512": "SLyX+Lfii7Gg8qNwGP3oMPjZjStP5y8a4GkwDxqYTDYyJ7DVYYJ+cvFEzVxVqEQIkyr3pdXT9rdOqPSgKrPeWA=="
|
|
33
|
+
}
|
|
34
|
+
},
|
|
35
|
+
"@min.js": {
|
|
36
|
+
"file": "ms.core-4.3.0-nightly3.2406-08.min.js",
|
|
37
|
+
"type": "text/javascript; charset=utf-8",
|
|
38
|
+
"integrity": "sha256-Kkk/MFzVmgE62JRXYfutmoKOqMmYX7Mc44Pfa5IenSM= sha384-rYfLTPsQ7mFLRyzaU10a/+Nu5UfZS1j3mnScX5cd3N/tEJwnWQD22rRL0QHTokXe sha512-Kb8idZAK3Wrzt/lONDG8nt9g57aMb+vV8JjZXtqbaT8xoLol6XDFQYJz2jYw4c1g/t/rGRzqscLK9ocNQpd9YQ==",
|
|
39
|
+
"hashes": {
|
|
40
|
+
"sha256": "Kkk/MFzVmgE62JRXYfutmoKOqMmYX7Mc44Pfa5IenSM=",
|
|
41
|
+
"sha384": "rYfLTPsQ7mFLRyzaU10a/+Nu5UfZS1j3mnScX5cd3N/tEJwnWQD22rRL0QHTokXe",
|
|
42
|
+
"sha512": "Kb8idZAK3Wrzt/lONDG8nt9g57aMb+vV8JjZXtqbaT8xoLol6XDFQYJz2jYw4c1g/t/rGRzqscLK9ocNQpd9YQ=="
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* 1DS JS SDK Core, 4.3.0-nightly3.2406-
|
|
2
|
+
* 1DS JS SDK Core, 4.3.0-nightly3.2406-08
|
|
3
3
|
* Copyright (c) Microsoft and contributors. All rights reserved.
|
|
4
4
|
* (Microsoft Internal Only)
|
|
5
5
|
*/
|
|
@@ -8,8 +8,8 @@
|
|
|
8
8
|
typeof exports === "object" && typeof module !== undef ? factory(exports) :
|
|
9
9
|
typeof define === "function" && define.amd ? define(["exports"], factory) :
|
|
10
10
|
(function(global){
|
|
11
|
-
var nsKey, key, nm, theExports = {}, modName = "
|
|
12
|
-
var mods={}, modDetail=mods[modName]={}, ver="4.3.0-nightly3.2406-
|
|
11
|
+
var nsKey, key, nm, theExports = {}, modName = "es5_ms_core_4_3_0_nightly3_2406_08", msMod="__ms$mod__";
|
|
12
|
+
var mods={}, modDetail=mods[modName]={}, ver="4.3.0-nightly3.2406-08";
|
|
13
13
|
// Versioned namespace "oneDS4"
|
|
14
14
|
var exportNs=global, nsKey="oneDS4", exportNs=exportNs[nsKey]=(exportNs[nsKey]||{});
|
|
15
15
|
// Global namespace "oneDS"
|
|
@@ -1304,6 +1304,13 @@ var EventsDiscardedReason = createEnumStyle({
|
|
|
1304
1304
|
QueueFull: 5
|
|
1305
1305
|
});
|
|
1306
1306
|
|
|
1307
|
+
var ActiveStatus = createEnumStyle({
|
|
1308
|
+
NONE: 0 ,
|
|
1309
|
+
PENDING: 3 ,
|
|
1310
|
+
INACTIVE: 1 ,
|
|
1311
|
+
ACTIVE: 2
|
|
1312
|
+
});
|
|
1313
|
+
|
|
1307
1314
|
var _DYN_TO_LOWER_CASE = "toLowerCase";
|
|
1308
1315
|
var _DYN_BLK_VAL = "blkVal";
|
|
1309
1316
|
var _DYN_LENGTH$1 = "length";
|
|
@@ -1324,13 +1331,17 @@ var _DYN_IDENTIFIER = "identifier";
|
|
|
1324
1331
|
var _DYN_REMOVE_NOTIFICATION_0 = "removeNotificationListener";
|
|
1325
1332
|
var _DYN_ADD_NOTIFICATION_LIS1 = "addNotificationListener";
|
|
1326
1333
|
var _DYN_IS_INITIALIZED = "isInitialized";
|
|
1334
|
+
var _DYN_INSTRUMENTATION_KEY = "instrumentationKey";
|
|
1335
|
+
var _DYN__INACTIVE = "INACTIVE";
|
|
1336
|
+
var _DYN_VALUE$1 = "value";
|
|
1327
1337
|
var _DYN_GET_NOTIFY_MGR = "getNotifyMgr";
|
|
1328
1338
|
var _DYN_GET_PLUGIN = "getPlugin";
|
|
1329
|
-
var _DYN_POLL_INTERNAL_LOGS$1 = "pollInternalLogs";
|
|
1330
1339
|
var _DYN_NAME = "name";
|
|
1340
|
+
var _DYN_I_KEY = "iKey";
|
|
1331
1341
|
var _DYN_TIME = "time";
|
|
1332
1342
|
var _DYN_PROCESS_NEXT = "processNext";
|
|
1333
1343
|
var _DYN_GET_PROCESS_TEL_CONT2 = "getProcessTelContext";
|
|
1344
|
+
var _DYN_POLL_INTERNAL_LOGS$1 = "pollInternalLogs";
|
|
1334
1345
|
var _DYN_ENABLED = "enabled";
|
|
1335
1346
|
var _DYN_STOP_POLLING_INTERNA3 = "stopPollingInternalLogs";
|
|
1336
1347
|
var _DYN_UNLOAD = "unload";
|
|
@@ -1680,6 +1691,54 @@ function _createAllPromise(newPromise) {
|
|
|
1680
1691
|
}, additionalArgs);
|
|
1681
1692
|
};
|
|
1682
1693
|
}
|
|
1694
|
+
/*#__NO_SIDE_EFFECTS__*/
|
|
1695
|
+
function _createAllSettledPromise(newPromise) {
|
|
1696
|
+
return createCachedValue(function (input) {
|
|
1697
|
+
var additionalArgs = arrSlice(arguments, 1);
|
|
1698
|
+
return newPromise(function (resolve, reject) {
|
|
1699
|
+
var values = [];
|
|
1700
|
+
var pending = 1;
|
|
1701
|
+
function processItem(item, idx) {
|
|
1702
|
+
pending++;
|
|
1703
|
+
doAwaitResponse(item, function (value) {
|
|
1704
|
+
if (value.rejected) {
|
|
1705
|
+
values[idx] = {
|
|
1706
|
+
status: REJECTED,
|
|
1707
|
+
reason: value.reason
|
|
1708
|
+
};
|
|
1709
|
+
}
|
|
1710
|
+
else {
|
|
1711
|
+
values[idx] = {
|
|
1712
|
+
status: "fulfilled",
|
|
1713
|
+
value: value.value
|
|
1714
|
+
};
|
|
1715
|
+
}
|
|
1716
|
+
if (--pending === 0) {
|
|
1717
|
+
resolve(values);
|
|
1718
|
+
}
|
|
1719
|
+
});
|
|
1720
|
+
}
|
|
1721
|
+
try {
|
|
1722
|
+
if (isArray(input)) {
|
|
1723
|
+
arrForEach(input, processItem);
|
|
1724
|
+
}
|
|
1725
|
+
else if (isIterable(input)) {
|
|
1726
|
+
iterForOf(input, processItem);
|
|
1727
|
+
}
|
|
1728
|
+
else {
|
|
1729
|
+
throwTypeError("Input is not an iterable");
|
|
1730
|
+
}
|
|
1731
|
+
pending--;
|
|
1732
|
+
if (pending === 0) {
|
|
1733
|
+
resolve(values);
|
|
1734
|
+
}
|
|
1735
|
+
}
|
|
1736
|
+
catch (e) {
|
|
1737
|
+
reject(e);
|
|
1738
|
+
}
|
|
1739
|
+
}, additionalArgs);
|
|
1740
|
+
});
|
|
1741
|
+
}
|
|
1683
1742
|
function syncItemProcessor(pending) {
|
|
1684
1743
|
arrForEach(pending, function (fn) {
|
|
1685
1744
|
try {
|
|
@@ -1731,11 +1790,16 @@ function createNativePromise(executor, timeout) {
|
|
|
1731
1790
|
return thePromise;
|
|
1732
1791
|
}
|
|
1733
1792
|
var _promiseCreator;
|
|
1793
|
+
var _allSettledCreator;
|
|
1734
1794
|
function createPromise(executor, timeout) {
|
|
1735
1795
|
!_promiseCreator && (_promiseCreator = createCachedValue(createNativePromise));
|
|
1736
1796
|
return _promiseCreator.v.call(this, executor, timeout);
|
|
1737
1797
|
}
|
|
1738
1798
|
var createAllPromise = /*#__PURE__*/ _createAllPromise(createPromise);
|
|
1799
|
+
function createAllSettledPromise(input, timeout) {
|
|
1800
|
+
!_allSettledCreator && (_allSettledCreator = _createAllSettledPromise(createPromise));
|
|
1801
|
+
return _allSettledCreator.v(input, timeout);
|
|
1802
|
+
}
|
|
1739
1803
|
|
|
1740
1804
|
var UNDEFINED_VALUE = undefined;
|
|
1741
1805
|
var STR_EMPTY$2 = "";
|
|
@@ -2253,7 +2317,7 @@ function newId(maxLength) {
|
|
|
2253
2317
|
return result;
|
|
2254
2318
|
}
|
|
2255
2319
|
|
|
2256
|
-
var version = '3.3.0-nightly3.2406-
|
|
2320
|
+
var version = '3.3.0-nightly3.2406-08';
|
|
2257
2321
|
var instanceName = "." + newId(6);
|
|
2258
2322
|
var _dataUid = 0;
|
|
2259
2323
|
function _canAcceptData(target) {
|
|
@@ -4650,6 +4714,8 @@ var strValidationError = "Plugins must provide initialize method";
|
|
|
4650
4714
|
var strNotificationManager = "_notificationManager";
|
|
4651
4715
|
var strSdkUnloadingError = "SDK is still unloading...";
|
|
4652
4716
|
var strSdkNotInitialized = "SDK is not initialized";
|
|
4717
|
+
var maxInitQueueSize = 100;
|
|
4718
|
+
var maxInitTimeout = 50000;
|
|
4653
4719
|
var defaultConfig$1 = objDeepFreeze((_a$1 = {
|
|
4654
4720
|
cookieCfg: {}
|
|
4655
4721
|
},
|
|
@@ -4806,15 +4872,23 @@ var AppInsightsCore$1 = /** @class */ (function () {
|
|
|
4806
4872
|
var _extensions;
|
|
4807
4873
|
var _pluginVersionStringArr;
|
|
4808
4874
|
var _pluginVersionString;
|
|
4875
|
+
var _activeStatus;
|
|
4876
|
+
var _endpoint;
|
|
4877
|
+
var _initInMemoMaxSize;
|
|
4878
|
+
var _isStatusSet;
|
|
4809
4879
|
var _internalLogPoller;
|
|
4810
4880
|
var _internalLogPollerListening;
|
|
4811
4881
|
var _forceStopInternalLogPoller;
|
|
4812
4882
|
dynamicProto(AppInsightsCore, this, function (_self) {
|
|
4813
4883
|
_initDefaults();
|
|
4814
4884
|
_self["_getDbgPlgTargets"] = function () {
|
|
4815
|
-
return [_extensions];
|
|
4885
|
+
return [_extensions, _eventQueue];
|
|
4816
4886
|
};
|
|
4817
4887
|
_self[_DYN_IS_INITIALIZED ] = function () { return _isInitialized; };
|
|
4888
|
+
_self.activeStatus = function () { return _activeStatus; };
|
|
4889
|
+
_self._setPendingStatus = function () {
|
|
4890
|
+
_activeStatus = 3 ;
|
|
4891
|
+
};
|
|
4818
4892
|
_self[_DYN_INITIALIZE$1 ] = function (config, extensions, logger, notificationManager) {
|
|
4819
4893
|
if (_isUnloading) {
|
|
4820
4894
|
throwError(strSdkUnloadingError);
|
|
@@ -4825,14 +4899,88 @@ var AppInsightsCore$1 = /** @class */ (function () {
|
|
|
4825
4899
|
_configHandler = createDynamicConfig(config, defaultConfig$1, logger || _self[_DYN_LOGGER$1 ], false);
|
|
4826
4900
|
config = _configHandler.cfg;
|
|
4827
4901
|
_addUnloadHook(_configHandler[_DYN_WATCH ](function (details) {
|
|
4828
|
-
|
|
4902
|
+
var rootCfg = details.cfg;
|
|
4903
|
+
var isPending = _activeStatus === 3 ;
|
|
4904
|
+
if (isPending) {
|
|
4905
|
+
return;
|
|
4906
|
+
}
|
|
4907
|
+
_initInMemoMaxSize = rootCfg.initInMemoMaxSize || maxInitQueueSize;
|
|
4908
|
+
var ikey = rootCfg[_DYN_INSTRUMENTATION_KEY ];
|
|
4909
|
+
var endpointUrl = rootCfg.endpointUrl;
|
|
4910
|
+
if (isNullOrUndefined(ikey)) {
|
|
4911
|
+
_instrumentationKey = null;
|
|
4912
|
+
_activeStatus = ActiveStatus[_DYN__INACTIVE ];
|
|
4913
|
+
var msg = "Please provide instrumentation key";
|
|
4914
|
+
if (!_isInitialized) {
|
|
4915
|
+
throwError(msg);
|
|
4916
|
+
}
|
|
4917
|
+
else {
|
|
4918
|
+
_throwInternal(_logger, 1 , 100 , msg);
|
|
4919
|
+
_releaseQueues();
|
|
4920
|
+
}
|
|
4921
|
+
return;
|
|
4922
|
+
}
|
|
4923
|
+
var promises = [];
|
|
4924
|
+
if (isPromiseLike(ikey)) {
|
|
4925
|
+
promises[_DYN_PUSH ](ikey);
|
|
4926
|
+
_instrumentationKey = null;
|
|
4927
|
+
}
|
|
4928
|
+
else {
|
|
4929
|
+
_instrumentationKey = ikey;
|
|
4930
|
+
}
|
|
4931
|
+
if (isPromiseLike(endpointUrl)) {
|
|
4932
|
+
promises[_DYN_PUSH ](endpointUrl);
|
|
4933
|
+
_endpoint = null;
|
|
4934
|
+
}
|
|
4935
|
+
else {
|
|
4936
|
+
_endpoint = endpointUrl;
|
|
4937
|
+
}
|
|
4938
|
+
if (promises[_DYN_LENGTH$1 ]) {
|
|
4939
|
+
_isStatusSet = false;
|
|
4940
|
+
_activeStatus = 3 ;
|
|
4941
|
+
var initTimeout = isNotNullOrUndefined(rootCfg.initTimeOut) ? rootCfg.initTimeOut : maxInitTimeout;
|
|
4942
|
+
var allPromises = createAllSettledPromise(promises);
|
|
4943
|
+
scheduleTimeout(function () {
|
|
4944
|
+
if (!_isStatusSet) {
|
|
4945
|
+
_setStatus();
|
|
4946
|
+
}
|
|
4947
|
+
}, initTimeout);
|
|
4948
|
+
doAwaitResponse(allPromises, function (response) {
|
|
4949
|
+
try {
|
|
4950
|
+
if (_isStatusSet) {
|
|
4951
|
+
return;
|
|
4952
|
+
}
|
|
4953
|
+
if (!response.rejected) {
|
|
4954
|
+
var values = response[_DYN_VALUE$1 ];
|
|
4955
|
+
if (values && values[_DYN_LENGTH$1 ]) {
|
|
4956
|
+
var ikeyRes = values[0];
|
|
4957
|
+
_instrumentationKey = ikeyRes && ikeyRes[_DYN_VALUE$1 ];
|
|
4958
|
+
if (values[_DYN_LENGTH$1 ] > 1) {
|
|
4959
|
+
var endpointRes = values[1];
|
|
4960
|
+
_endpoint = endpointRes && endpointRes[_DYN_VALUE$1 ];
|
|
4961
|
+
}
|
|
4962
|
+
}
|
|
4963
|
+
if (_instrumentationKey) {
|
|
4964
|
+
config[_DYN_INSTRUMENTATION_KEY ] = _instrumentationKey;
|
|
4965
|
+
config.endpointUrl = _endpoint;
|
|
4966
|
+
}
|
|
4967
|
+
}
|
|
4968
|
+
_setStatus();
|
|
4969
|
+
}
|
|
4970
|
+
catch (e) {
|
|
4971
|
+
if (!_isStatusSet) {
|
|
4972
|
+
_setStatus();
|
|
4973
|
+
}
|
|
4974
|
+
}
|
|
4975
|
+
});
|
|
4976
|
+
}
|
|
4977
|
+
else {
|
|
4978
|
+
_setStatus();
|
|
4979
|
+
}
|
|
4829
4980
|
var extCfg = details.ref(details.cfg, STR_EXTENSION_CONFIG);
|
|
4830
4981
|
objForEachKey(extCfg, function (key) {
|
|
4831
4982
|
details.ref(extCfg, key);
|
|
4832
4983
|
});
|
|
4833
|
-
if (isNullOrUndefined(_instrumentationKey)) {
|
|
4834
|
-
throwError("Please provide instrumentation key");
|
|
4835
|
-
}
|
|
4836
4984
|
}));
|
|
4837
4985
|
_notificationManager = notificationManager;
|
|
4838
4986
|
_debugListener = _initDebugListener(_configHandler, _hookContainer, _notificationManager && _self[_DYN_GET_NOTIFY_MGR ](), _debugListener);
|
|
@@ -4855,8 +5003,9 @@ var AppInsightsCore$1 = /** @class */ (function () {
|
|
|
4855
5003
|
_registerDelayedCfgListener(config, _cfgListeners, _logger);
|
|
4856
5004
|
_cfgListeners = null;
|
|
4857
5005
|
_isInitialized = true;
|
|
4858
|
-
|
|
4859
|
-
|
|
5006
|
+
if (_activeStatus === ActiveStatus.ACTIVE) {
|
|
5007
|
+
_releaseQueues();
|
|
5008
|
+
}
|
|
4860
5009
|
};
|
|
4861
5010
|
_self.getChannels = function () {
|
|
4862
5011
|
var controls = [];
|
|
@@ -4877,14 +5026,16 @@ var AppInsightsCore$1 = /** @class */ (function () {
|
|
|
4877
5026
|
_notifyInvalidEvent(telemetryItem);
|
|
4878
5027
|
throwError("telemetry name required");
|
|
4879
5028
|
}
|
|
4880
|
-
telemetryItem
|
|
5029
|
+
telemetryItem[_DYN_I_KEY ] = telemetryItem[_DYN_I_KEY ] || _instrumentationKey;
|
|
4881
5030
|
telemetryItem[_DYN_TIME ] = telemetryItem[_DYN_TIME ] || toISOString(new Date());
|
|
4882
5031
|
telemetryItem.ver = telemetryItem.ver || "4.0";
|
|
4883
|
-
if (!_isUnloading && _self[_DYN_IS_INITIALIZED ]()) {
|
|
5032
|
+
if (!_isUnloading && _self[_DYN_IS_INITIALIZED ]() && _activeStatus === ActiveStatus.ACTIVE) {
|
|
4884
5033
|
_createTelCtx()[_DYN_PROCESS_NEXT ](telemetryItem);
|
|
4885
5034
|
}
|
|
4886
|
-
else {
|
|
4887
|
-
_eventQueue[
|
|
5035
|
+
else if (_activeStatus !== ActiveStatus[_DYN__INACTIVE ]) {
|
|
5036
|
+
if (_eventQueue[_DYN_LENGTH$1 ] <= _initInMemoMaxSize) {
|
|
5037
|
+
_eventQueue[_DYN_PUSH ](telemetryItem);
|
|
5038
|
+
}
|
|
4888
5039
|
}
|
|
4889
5040
|
}, function () { return ({ item: telemetryItem }); }, !(telemetryItem.sync));
|
|
4890
5041
|
};
|
|
@@ -4929,9 +5080,15 @@ var AppInsightsCore$1 = /** @class */ (function () {
|
|
|
4929
5080
|
if (_isInitialized && _eventQueue[_DYN_LENGTH$1 ] > 0) {
|
|
4930
5081
|
var eventQueue = _eventQueue;
|
|
4931
5082
|
_eventQueue = [];
|
|
4932
|
-
|
|
4933
|
-
|
|
4934
|
-
|
|
5083
|
+
if (_activeStatus === 2 ) {
|
|
5084
|
+
arrForEach(eventQueue, function (event) {
|
|
5085
|
+
event[_DYN_I_KEY ] = event[_DYN_I_KEY ] || _instrumentationKey;
|
|
5086
|
+
_createTelCtx()[_DYN_PROCESS_NEXT ](event);
|
|
5087
|
+
});
|
|
5088
|
+
}
|
|
5089
|
+
else {
|
|
5090
|
+
_throwInternal(_logger, 2 , 20 , "core init status is not active");
|
|
5091
|
+
}
|
|
4935
5092
|
}
|
|
4936
5093
|
};
|
|
4937
5094
|
_self[_DYN_POLL_INTERNAL_LOGS$1 ] = function (eventName) {
|
|
@@ -4940,6 +5097,23 @@ var AppInsightsCore$1 = /** @class */ (function () {
|
|
|
4940
5097
|
_internalLogPoller && _internalLogPoller[_DYN_CANCEL ]();
|
|
4941
5098
|
return _startLogPoller(true);
|
|
4942
5099
|
};
|
|
5100
|
+
function _setStatus() {
|
|
5101
|
+
_isStatusSet = true;
|
|
5102
|
+
if (isNullOrUndefined(_instrumentationKey)) {
|
|
5103
|
+
_activeStatus = ActiveStatus[_DYN__INACTIVE ];
|
|
5104
|
+
_throwInternal(_logger, 1 , 112 , "ikey can't be resolved from promises");
|
|
5105
|
+
}
|
|
5106
|
+
else {
|
|
5107
|
+
_activeStatus = ActiveStatus.ACTIVE;
|
|
5108
|
+
}
|
|
5109
|
+
_releaseQueues();
|
|
5110
|
+
}
|
|
5111
|
+
function _releaseQueues() {
|
|
5112
|
+
if (_isInitialized) {
|
|
5113
|
+
_self.releaseQueue();
|
|
5114
|
+
_self[_DYN_POLL_INTERNAL_LOGS$1 ]();
|
|
5115
|
+
}
|
|
5116
|
+
}
|
|
4943
5117
|
function _startLogPoller(alwaysStart) {
|
|
4944
5118
|
if ((!_internalLogPoller || !_internalLogPoller[_DYN_ENABLED ]) && !_forceStopInternalLogPoller) {
|
|
4945
5119
|
var shouldStart = alwaysStart || (_logger && _logger.queue[_DYN_LENGTH$1 ] > 0);
|
|
@@ -5213,6 +5387,10 @@ var AppInsightsCore$1 = /** @class */ (function () {
|
|
|
5213
5387
|
_forceStopInternalLogPoller = false;
|
|
5214
5388
|
_internalLogPoller = null;
|
|
5215
5389
|
_internalLogPollerListening = false;
|
|
5390
|
+
_activeStatus = 0 ;
|
|
5391
|
+
_endpoint = null;
|
|
5392
|
+
_initInMemoMaxSize = null;
|
|
5393
|
+
_isStatusSet = false;
|
|
5216
5394
|
}
|
|
5217
5395
|
function _createTelCtx() {
|
|
5218
5396
|
var theCtx = createProcessTelemetryContext(_getPluginChain(), _configHandler.cfg, _self);
|
|
@@ -5355,7 +5533,7 @@ var AppInsightsCore$1 = /** @class */ (function () {
|
|
|
5355
5533
|
var _a;
|
|
5356
5534
|
var item = (_a = {},
|
|
5357
5535
|
_a[_DYN_NAME ] = _internalLogsEventName ? _internalLogsEventName : "InternalMessageId: " + logMessage[_DYN_MESSAGE_ID ],
|
|
5358
|
-
_a
|
|
5536
|
+
_a[_DYN_I_KEY ] = _instrumentationKey,
|
|
5359
5537
|
_a[_DYN_TIME ] = toISOString(new Date()),
|
|
5360
5538
|
_a.baseType = _InternalLogMessage.dataType,
|
|
5361
5539
|
_a.baseData = { message: logMessage[_DYN_MESSAGE ] },
|
|
@@ -5791,7 +5969,7 @@ var SenderPostManager = /** @class */ (function () {
|
|
|
5791
5969
|
if (!responseHandled) {
|
|
5792
5970
|
responseHandled = true;
|
|
5793
5971
|
if (!result.rejected) {
|
|
5794
|
-
var response_1 = result
|
|
5972
|
+
var response_1 = result[_DYN_VALUE$1 ];
|
|
5795
5973
|
try {
|
|
5796
5974
|
if (!_isOneDs && !response_1.ok) {
|
|
5797
5975
|
_handleError(response_1.statusText);
|
|
@@ -5804,7 +5982,7 @@ var SenderPostManager = /** @class */ (function () {
|
|
|
5804
5982
|
}
|
|
5805
5983
|
else {
|
|
5806
5984
|
doAwaitResponse(response_1.text(), function (resp) {
|
|
5807
|
-
_onFetchComplete(response_1, payload, resp
|
|
5985
|
+
_onFetchComplete(response_1, payload, resp[_DYN_VALUE$1 ]);
|
|
5808
5986
|
resolveFunc && resolveFunc(true);
|
|
5809
5987
|
});
|
|
5810
5988
|
}
|
|
@@ -6251,7 +6429,7 @@ var _DYN_RM_FIELD_SANITIZER = "rmFieldSanitizer";
|
|
|
6251
6429
|
var _DYN_CAN_HANDLE = "canHandle";
|
|
6252
6430
|
|
|
6253
6431
|
var _a;
|
|
6254
|
-
var Version = '4.3.0-nightly3.2406-
|
|
6432
|
+
var Version = '4.3.0-nightly3.2406-08';
|
|
6255
6433
|
var FullVersionString = "1DS-Web-JS-" + Version;
|
|
6256
6434
|
var ObjHasOwnProperty = ObjProto$1.hasOwnProperty;
|
|
6257
6435
|
var strDisabledPropertyName = "Microsoft_ApplicationInsights_BypassAjaxInstrumentation";
|
|
@@ -6997,4 +7175,4 @@ exports.toISOString = toISOString;
|
|
|
6997
7175
|
exports.useXDomainRequest = useXDomainRequest;
|
|
6998
7176
|
|
|
6999
7177
|
}));
|
|
7000
|
-
//# sourceMappingURL=ms.core-4.3.0-nightly3.2406-
|
|
7178
|
+
//# sourceMappingURL=ms.core-4.3.0-nightly3.2406-08.js.map
|