@microsoft/applicationinsights-core-js 2.8.0-nightly.2204-17 → 2.8.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/browser/applicationinsights-core-js.integrity.json +9 -9
- package/browser/applicationinsights-core-js.js +30 -22
- package/browser/applicationinsights-core-js.js.map +1 -1
- package/browser/applicationinsights-core-js.min.js +2 -2
- package/browser/applicationinsights-core-js.min.js.map +1 -1
- package/dist/applicationinsights-core-js.api.json +26 -25
- package/dist/applicationinsights-core-js.d.ts +1 -4
- package/dist/applicationinsights-core-js.js +30 -22
- package/dist/applicationinsights-core-js.js.map +1 -1
- package/dist/applicationinsights-core-js.min.js +2 -2
- package/dist/applicationinsights-core-js.min.js.map +1 -1
- package/dist/applicationinsights-core-js.rollup.d.ts +1 -4
- package/dist-esm/JavaScriptSDK/AppInsightsCore.js +1 -1
- package/dist-esm/JavaScriptSDK/BaseCore.js +11 -7
- package/dist-esm/JavaScriptSDK/BaseCore.js.map +1 -1
- package/dist-esm/JavaScriptSDK/BaseTelemetryPlugin.js +7 -5
- package/dist-esm/JavaScriptSDK/BaseTelemetryPlugin.js.map +1 -1
- package/dist-esm/JavaScriptSDK/ChannelController.js +1 -1
- package/dist-esm/JavaScriptSDK/Constants.js +1 -1
- package/dist-esm/JavaScriptSDK/CookieMgr.js +1 -1
- package/dist-esm/JavaScriptSDK/CoreUtils.js +1 -1
- package/dist-esm/JavaScriptSDK/DataCacheHelper.js +2 -2
- package/dist-esm/JavaScriptSDK/DataCacheHelper.js.map +1 -1
- package/dist-esm/JavaScriptSDK/DbgExtensionUtils.js +1 -1
- package/dist-esm/JavaScriptSDK/DiagnosticLogger.js +1 -1
- package/dist-esm/JavaScriptSDK/EnvUtils.js +1 -1
- package/dist-esm/JavaScriptSDK/EventHelpers.js +1 -1
- package/dist-esm/JavaScriptSDK/HelperFuncs.js +1 -1
- package/dist-esm/JavaScriptSDK/InstrumentHooks.js +1 -1
- package/dist-esm/JavaScriptSDK/InternalConstants.js +1 -1
- package/dist-esm/JavaScriptSDK/NotificationManager.js +1 -1
- package/dist-esm/JavaScriptSDK/PerfManager.js +1 -1
- package/dist-esm/JavaScriptSDK/ProcessTelemetryContext.js +16 -13
- package/dist-esm/JavaScriptSDK/ProcessTelemetryContext.js.map +1 -1
- package/dist-esm/JavaScriptSDK/RandomHelper.js +1 -1
- package/dist-esm/JavaScriptSDK/TelemetryHelpers.js +1 -1
- package/dist-esm/JavaScriptSDK/TelemetryInitializerPlugin.js +1 -1
- package/dist-esm/JavaScriptSDK/UnloadHandlerContainer.js +1 -1
- package/dist-esm/JavaScriptSDK.Enums/EnumHelperFuncs.js +1 -1
- package/dist-esm/JavaScriptSDK.Enums/EventsDiscardedReason.js +1 -1
- package/dist-esm/JavaScriptSDK.Enums/LoggingEnums.js +1 -1
- package/dist-esm/JavaScriptSDK.Enums/SendRequestReason.js +1 -1
- package/dist-esm/JavaScriptSDK.Enums/TelemetryUnloadReason.js +1 -1
- package/dist-esm/JavaScriptSDK.Enums/TelemetryUpdateReason.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IAppInsightsCore.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IChannelControls.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IConfiguration.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/ICookieMgr.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IDbgExtension.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IDiagnosticLogger.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IInstrumentHooks.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/INotificationListener.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/INotificationManager.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IPerfEvent.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IPerfManager.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IProcessTelemetryContext.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryInitializers.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryItem.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryPlugin.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryPluginChain.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryUnloadState.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryUpdateState.js +1 -1
- package/dist-esm/JavaScriptSDK.Interfaces/IUnloadableComponent.js +1 -1
- package/dist-esm/applicationinsights-core-js.js +1 -1
- package/package.json +67 -70
- package/src/JavaScriptSDK/BaseCore.ts +14 -6
- package/src/JavaScriptSDK/BaseTelemetryPlugin.ts +6 -4
- package/src/JavaScriptSDK/DataCacheHelper.ts +1 -1
- package/src/JavaScriptSDK/ProcessTelemetryContext.ts +18 -14
- package/src/JavaScriptSDK/TelemetryHelpers.ts +1 -1
- package/src/JavaScriptSDK.Interfaces/IConfiguration.ts +1 -3
- package/types/JavaScriptSDK/ProcessTelemetryContext.d.ts +2 -2
- package/types/JavaScriptSDK/TelemetryHelpers.d.ts +1 -1
- package/types/JavaScriptSDK.Interfaces/IConfiguration.d.ts +0 -3
- package/types/tsdoc-metadata.json +1 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"metadata": {
|
|
3
3
|
"toolPackage": "@microsoft/api-extractor",
|
|
4
|
-
"toolVersion": "7.
|
|
4
|
+
"toolVersion": "7.22.2",
|
|
5
5
|
"schemaVersion": 1005,
|
|
6
6
|
"oldestForwardsCompatibleVersion": 1001,
|
|
7
7
|
"tsdocConfig": {
|
|
@@ -156,7 +156,8 @@
|
|
|
156
156
|
"@betaDocumentation": true,
|
|
157
157
|
"@internalRemarks": true,
|
|
158
158
|
"@preapproved": true
|
|
159
|
-
}
|
|
159
|
+
},
|
|
160
|
+
"reportUnsupportedHtmlElements": false
|
|
160
161
|
}
|
|
161
162
|
},
|
|
162
163
|
"kind": "Package",
|
|
@@ -3231,12 +3232,12 @@
|
|
|
3231
3232
|
],
|
|
3232
3233
|
"extendsTokenRange": {
|
|
3233
3234
|
"startIndex": 1,
|
|
3234
|
-
"endIndex":
|
|
3235
|
+
"endIndex": 2
|
|
3235
3236
|
},
|
|
3236
3237
|
"implementsTokenRanges": [
|
|
3237
3238
|
{
|
|
3238
3239
|
"startIndex": 4,
|
|
3239
|
-
"endIndex":
|
|
3240
|
+
"endIndex": 5
|
|
3240
3241
|
}
|
|
3241
3242
|
]
|
|
3242
3243
|
},
|
|
@@ -4061,7 +4062,7 @@
|
|
|
4061
4062
|
"typeParameterName": "T",
|
|
4062
4063
|
"constraintTokenRange": {
|
|
4063
4064
|
"startIndex": 1,
|
|
4064
|
-
"endIndex":
|
|
4065
|
+
"endIndex": 2
|
|
4065
4066
|
},
|
|
4066
4067
|
"defaultTypeTokenRange": {
|
|
4067
4068
|
"startIndex": 4,
|
|
@@ -4529,7 +4530,7 @@
|
|
|
4529
4530
|
"typeParameterName": "T",
|
|
4530
4531
|
"constraintTokenRange": {
|
|
4531
4532
|
"startIndex": 1,
|
|
4532
|
-
"endIndex":
|
|
4533
|
+
"endIndex": 2
|
|
4533
4534
|
},
|
|
4534
4535
|
"defaultTypeTokenRange": {
|
|
4535
4536
|
"startIndex": 4,
|
|
@@ -5143,7 +5144,7 @@
|
|
|
5143
5144
|
"implementsTokenRanges": [
|
|
5144
5145
|
{
|
|
5145
5146
|
"startIndex": 1,
|
|
5146
|
-
"endIndex":
|
|
5147
|
+
"endIndex": 2
|
|
5147
5148
|
}
|
|
5148
5149
|
]
|
|
5149
5150
|
},
|
|
@@ -6013,7 +6014,7 @@
|
|
|
6013
6014
|
"implementsTokenRanges": [
|
|
6014
6015
|
{
|
|
6015
6016
|
"startIndex": 1,
|
|
6016
|
-
"endIndex":
|
|
6017
|
+
"endIndex": 2
|
|
6017
6018
|
}
|
|
6018
6019
|
]
|
|
6019
6020
|
},
|
|
@@ -7406,7 +7407,7 @@
|
|
|
7406
7407
|
"implementsTokenRanges": [
|
|
7407
7408
|
{
|
|
7408
7409
|
"startIndex": 1,
|
|
7409
|
-
"endIndex":
|
|
7410
|
+
"endIndex": 2
|
|
7410
7411
|
}
|
|
7411
7412
|
]
|
|
7412
7413
|
},
|
|
@@ -9520,7 +9521,7 @@
|
|
|
9520
9521
|
"typeParameterName": "T",
|
|
9521
9522
|
"constraintTokenRange": {
|
|
9522
9523
|
"startIndex": 1,
|
|
9523
|
-
"endIndex":
|
|
9524
|
+
"endIndex": 2
|
|
9524
9525
|
},
|
|
9525
9526
|
"defaultTypeTokenRange": {
|
|
9526
9527
|
"startIndex": 4,
|
|
@@ -9909,7 +9910,7 @@
|
|
|
9909
9910
|
"typeParameterName": "T",
|
|
9910
9911
|
"constraintTokenRange": {
|
|
9911
9912
|
"startIndex": 1,
|
|
9912
|
-
"endIndex":
|
|
9913
|
+
"endIndex": 2
|
|
9913
9914
|
},
|
|
9914
9915
|
"defaultTypeTokenRange": {
|
|
9915
9916
|
"startIndex": 4,
|
|
@@ -10436,7 +10437,7 @@
|
|
|
10436
10437
|
"extendsTokenRanges": [
|
|
10437
10438
|
{
|
|
10438
10439
|
"startIndex": 1,
|
|
10439
|
-
"endIndex":
|
|
10440
|
+
"endIndex": 2
|
|
10440
10441
|
}
|
|
10441
10442
|
]
|
|
10442
10443
|
},
|
|
@@ -11066,7 +11067,7 @@
|
|
|
11066
11067
|
"extendsTokenRanges": [
|
|
11067
11068
|
{
|
|
11068
11069
|
"startIndex": 1,
|
|
11069
|
-
"endIndex":
|
|
11070
|
+
"endIndex": 2
|
|
11070
11071
|
}
|
|
11071
11072
|
]
|
|
11072
11073
|
},
|
|
@@ -11170,7 +11171,7 @@
|
|
|
11170
11171
|
{
|
|
11171
11172
|
"kind": "PropertySignature",
|
|
11172
11173
|
"canonicalReference": "@microsoft/applicationinsights-core-js!IConfiguration#cookieDomain:member",
|
|
11173
|
-
"docComment": "/**\n * @description Custom cookie domain. This is helpful if you want to share Application Insights cookies across subdomains. It can be set here or as part of the cookieCfg.domain, the cookieCfg takes precedence if both are specified. @type {string}
|
|
11174
|
+
"docComment": "/**\n * @description Custom cookie domain. This is helpful if you want to share Application Insights cookies across subdomains. It can be set here or as part of the cookieCfg.domain, the cookieCfg takes precedence if both are specified. @type {string}\n *\n * @defaultValue\n *\n * \"\"\n */\n",
|
|
11174
11175
|
"excerptTokens": [
|
|
11175
11176
|
{
|
|
11176
11177
|
"kind": "Content",
|
|
@@ -11196,7 +11197,7 @@
|
|
|
11196
11197
|
{
|
|
11197
11198
|
"kind": "PropertySignature",
|
|
11198
11199
|
"canonicalReference": "@microsoft/applicationinsights-core-js!IConfiguration#cookiePath:member",
|
|
11199
|
-
"docComment": "/**\n * @description Custom cookie path. This is helpful if you want to share Application Insights cookies behind an application gateway. It can be set here or as part of the cookieCfg.domain, the cookieCfg takes precedence if both are specified. @type {string}
|
|
11200
|
+
"docComment": "/**\n * @description Custom cookie path. This is helpful if you want to share Application Insights cookies behind an application gateway. It can be set here or as part of the cookieCfg.domain, the cookieCfg takes precedence if both are specified. @type {string}\n *\n * @defaultValue\n *\n * \"\"\n */\n",
|
|
11200
11201
|
"excerptTokens": [
|
|
11201
11202
|
{
|
|
11202
11203
|
"kind": "Content",
|
|
@@ -11349,7 +11350,7 @@
|
|
|
11349
11350
|
{
|
|
11350
11351
|
"kind": "PropertySignature",
|
|
11351
11352
|
"canonicalReference": "@microsoft/applicationinsights-core-js!IConfiguration#disableInstrumentationKeyValidation:member",
|
|
11352
|
-
"docComment": "/**\n * @type {boolean}
|
|
11353
|
+
"docComment": "/**\n * @type {boolean} Flag that disables the Instrumentation Key validation.\n */\n",
|
|
11353
11354
|
"excerptTokens": [
|
|
11354
11355
|
{
|
|
11355
11356
|
"kind": "Content",
|
|
@@ -16722,7 +16723,7 @@
|
|
|
16722
16723
|
"extendsTokenRanges": [
|
|
16723
16724
|
{
|
|
16724
16725
|
"startIndex": 1,
|
|
16725
|
-
"endIndex":
|
|
16726
|
+
"endIndex": 2
|
|
16726
16727
|
}
|
|
16727
16728
|
]
|
|
16728
16729
|
},
|
|
@@ -16845,7 +16846,7 @@
|
|
|
16845
16846
|
"extendsTokenRanges": [
|
|
16846
16847
|
{
|
|
16847
16848
|
"startIndex": 1,
|
|
16848
|
-
"endIndex":
|
|
16849
|
+
"endIndex": 2
|
|
16849
16850
|
}
|
|
16850
16851
|
]
|
|
16851
16852
|
},
|
|
@@ -16968,7 +16969,7 @@
|
|
|
16968
16969
|
"extendsTokenRanges": [
|
|
16969
16970
|
{
|
|
16970
16971
|
"startIndex": 1,
|
|
16971
|
-
"endIndex":
|
|
16972
|
+
"endIndex": 2
|
|
16972
16973
|
}
|
|
16973
16974
|
]
|
|
16974
16975
|
},
|
|
@@ -18477,7 +18478,7 @@
|
|
|
18477
18478
|
},
|
|
18478
18479
|
{
|
|
18479
18480
|
"startIndex": 3,
|
|
18480
|
-
"endIndex":
|
|
18481
|
+
"endIndex": 4
|
|
18481
18482
|
}
|
|
18482
18483
|
]
|
|
18483
18484
|
},
|
|
@@ -18613,7 +18614,7 @@
|
|
|
18613
18614
|
"extendsTokenRanges": [
|
|
18614
18615
|
{
|
|
18615
18616
|
"startIndex": 1,
|
|
18616
|
-
"endIndex":
|
|
18617
|
+
"endIndex": 2
|
|
18617
18618
|
}
|
|
18618
18619
|
]
|
|
18619
18620
|
},
|
|
@@ -19736,7 +19737,7 @@
|
|
|
19736
19737
|
"implementsTokenRanges": [
|
|
19737
19738
|
{
|
|
19738
19739
|
"startIndex": 1,
|
|
19739
|
-
"endIndex":
|
|
19740
|
+
"endIndex": 2
|
|
19740
19741
|
}
|
|
19741
19742
|
]
|
|
19742
19743
|
},
|
|
@@ -20899,7 +20900,7 @@
|
|
|
20899
20900
|
"implementsTokenRanges": [
|
|
20900
20901
|
{
|
|
20901
20902
|
"startIndex": 1,
|
|
20902
|
-
"endIndex":
|
|
20903
|
+
"endIndex": 2
|
|
20903
20904
|
}
|
|
20904
20905
|
]
|
|
20905
20906
|
},
|
|
@@ -21199,7 +21200,7 @@
|
|
|
21199
21200
|
"implementsTokenRanges": [
|
|
21200
21201
|
{
|
|
21201
21202
|
"startIndex": 1,
|
|
21202
|
-
"endIndex":
|
|
21203
|
+
"endIndex": 2
|
|
21203
21204
|
}
|
|
21204
21205
|
]
|
|
21205
21206
|
},
|
|
@@ -21783,7 +21784,7 @@
|
|
|
21783
21784
|
"implementsTokenRanges": [
|
|
21784
21785
|
{
|
|
21785
21786
|
"startIndex": 1,
|
|
21786
|
-
"endIndex":
|
|
21787
|
+
"endIndex": 2
|
|
21787
21788
|
}
|
|
21788
21789
|
]
|
|
21789
21790
|
},
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*
|
|
2
|
-
* Microsoft Application Insights Core Javascript SDK, 2.8.0
|
|
2
|
+
* Microsoft Application Insights Core Javascript SDK, 2.8.0
|
|
3
3
|
* Copyright (c) Microsoft and contributors. All rights reserved.
|
|
4
4
|
*
|
|
5
5
|
* Microsoft Application Insights Team
|
|
@@ -1099,7 +1099,6 @@ declare namespace ApplicationInsights {
|
|
|
1099
1099
|
channels?: IChannelControls[][];
|
|
1100
1100
|
/**
|
|
1101
1101
|
* @type {boolean}
|
|
1102
|
-
* @memberof IConfiguration
|
|
1103
1102
|
* Flag that disables the Instrumentation Key validation.
|
|
1104
1103
|
*/
|
|
1105
1104
|
disableInstrumentationKeyValidation?: boolean;
|
|
@@ -1131,7 +1130,6 @@ declare namespace ApplicationInsights {
|
|
|
1131
1130
|
* @description Custom cookie domain. This is helpful if you want to share Application Insights cookies across subdomains. It
|
|
1132
1131
|
* can be set here or as part of the cookieCfg.domain, the cookieCfg takes precedence if both are specified.
|
|
1133
1132
|
* @type {string}
|
|
1134
|
-
* @memberof IConfig
|
|
1135
1133
|
* @defaultValue ""
|
|
1136
1134
|
*/
|
|
1137
1135
|
cookieDomain?: string;
|
|
@@ -1139,7 +1137,6 @@ declare namespace ApplicationInsights {
|
|
|
1139
1137
|
* @description Custom cookie path. This is helpful if you want to share Application Insights cookies behind an application
|
|
1140
1138
|
* gateway. It can be set here or as part of the cookieCfg.domain, the cookieCfg takes precedence if both are specified.
|
|
1141
1139
|
* @type {string}
|
|
1142
|
-
* @memberof IConfig
|
|
1143
1140
|
* @defaultValue ""
|
|
1144
1141
|
*/
|
|
1145
1142
|
cookiePath?: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Application Insights JavaScript SDK - Core, 2.8.0
|
|
2
|
+
* Application Insights JavaScript SDK - Core, 2.8.0
|
|
3
3
|
* Copyright (c) Microsoft and contributors. All rights reserved.
|
|
4
4
|
*/
|
|
5
5
|
(function (global, factory) {
|
|
@@ -1577,7 +1577,7 @@
|
|
|
1577
1577
|
}
|
|
1578
1578
|
|
|
1579
1579
|
var _objDefineProperty = ObjDefineProperty;
|
|
1580
|
-
var version = "2.8.0
|
|
1580
|
+
var version = "2.8.0";
|
|
1581
1581
|
var instanceName = "." + newId(6);
|
|
1582
1582
|
var _dataUid = 0;
|
|
1583
1583
|
function _createAccessor(target, prop, value) {
|
|
@@ -1727,20 +1727,20 @@
|
|
|
1727
1727
|
var strHasRunFlags = "_hasRun";
|
|
1728
1728
|
var strGetTelCtx = "_getTelCtx";
|
|
1729
1729
|
var _chainId = 0;
|
|
1730
|
-
function _getNextProxyStart(proxy,
|
|
1730
|
+
function _getNextProxyStart(proxy, core, startAt) {
|
|
1731
1731
|
while (proxy) {
|
|
1732
1732
|
if (proxy.getPlugin() === startAt) {
|
|
1733
1733
|
return proxy;
|
|
1734
1734
|
}
|
|
1735
1735
|
proxy = proxy.getNext();
|
|
1736
1736
|
}
|
|
1737
|
-
return createTelemetryProxyChain([startAt], config, core);
|
|
1737
|
+
return createTelemetryProxyChain([startAt], core.config || {}, core);
|
|
1738
1738
|
}
|
|
1739
1739
|
function _createInternalContext(telemetryChain, config, core, startAt) {
|
|
1740
1740
|
var _nextProxy = null;
|
|
1741
1741
|
var _onComplete = [];
|
|
1742
1742
|
if (startAt !== null) {
|
|
1743
|
-
_nextProxy = startAt ? _getNextProxyStart(telemetryChain,
|
|
1743
|
+
_nextProxy = startAt ? _getNextProxyStart(telemetryChain, core, startAt) : telemetryChain;
|
|
1744
1744
|
}
|
|
1745
1745
|
var context = {
|
|
1746
1746
|
_next: _moveNext,
|
|
@@ -1827,6 +1827,7 @@
|
|
|
1827
1827
|
}
|
|
1828
1828
|
});
|
|
1829
1829
|
}
|
|
1830
|
+
theConfig = newConfig_1;
|
|
1830
1831
|
}
|
|
1831
1832
|
}
|
|
1832
1833
|
return theConfig;
|
|
@@ -1873,7 +1874,8 @@
|
|
|
1873
1874
|
context.createNew = _createNew;
|
|
1874
1875
|
return context;
|
|
1875
1876
|
}
|
|
1876
|
-
function createProcessTelemetryUnloadContext(telemetryChain,
|
|
1877
|
+
function createProcessTelemetryUnloadContext(telemetryChain, core, startAt) {
|
|
1878
|
+
var config = core.config || {};
|
|
1877
1879
|
var internalContext = _createInternalContext(telemetryChain, config, core, startAt);
|
|
1878
1880
|
var context = internalContext.ctx;
|
|
1879
1881
|
function _processNext(unloadState) {
|
|
@@ -1886,19 +1888,20 @@
|
|
|
1886
1888
|
if (isArray(plugins)) {
|
|
1887
1889
|
plugins = createTelemetryProxyChain(plugins, config, core, startAt);
|
|
1888
1890
|
}
|
|
1889
|
-
return createProcessTelemetryUnloadContext(plugins || context.getNext(),
|
|
1891
|
+
return createProcessTelemetryUnloadContext(plugins || context.getNext(), core, startAt);
|
|
1890
1892
|
}
|
|
1891
1893
|
context.processNext = _processNext;
|
|
1892
1894
|
context.createNew = _createNew;
|
|
1893
1895
|
return context;
|
|
1894
1896
|
}
|
|
1895
|
-
function createProcessTelemetryUpdateContext(telemetryChain,
|
|
1897
|
+
function createProcessTelemetryUpdateContext(telemetryChain, core, startAt) {
|
|
1898
|
+
var config = core.config || {};
|
|
1896
1899
|
var internalContext = _createInternalContext(telemetryChain, config, core, startAt);
|
|
1897
1900
|
var context = internalContext.ctx;
|
|
1898
1901
|
function _processNext(updateState) {
|
|
1899
1902
|
return context.iterate(function (plugin) {
|
|
1900
|
-
if (isFunction(plugin
|
|
1901
|
-
plugin
|
|
1903
|
+
if (isFunction(plugin.update)) {
|
|
1904
|
+
plugin.update(context, updateState);
|
|
1902
1905
|
}
|
|
1903
1906
|
});
|
|
1904
1907
|
}
|
|
@@ -1907,7 +1910,7 @@
|
|
|
1907
1910
|
if (isArray(plugins)) {
|
|
1908
1911
|
plugins = createTelemetryProxyChain(plugins, config, core, startAt);
|
|
1909
1912
|
}
|
|
1910
|
-
return createProcessTelemetryUpdateContext(plugins || context.getNext(),
|
|
1913
|
+
return createProcessTelemetryUpdateContext(plugins || context.getNext(), core, startAt);
|
|
1911
1914
|
}
|
|
1912
1915
|
context.processNext = _processNext;
|
|
1913
1916
|
context.createNew = _createNew;
|
|
@@ -1999,7 +2002,7 @@
|
|
|
1999
2002
|
hasRun = true;
|
|
2000
2003
|
}
|
|
2001
2004
|
if (!nextProxy || !hasNextRun) {
|
|
2002
|
-
_throwInternal(itemCtx.diagLog(), 1 , 73 , "Plugin [" +
|
|
2005
|
+
_throwInternal(itemCtx.diagLog(), 1 , 73 , "Plugin [" + identifier + "] failed during " + name + " - " + dumpObj(error) + ", run flags: " + dumpObj(hasRunContext));
|
|
2003
2006
|
}
|
|
2004
2007
|
}
|
|
2005
2008
|
}, details, isAsync);
|
|
@@ -2013,7 +2016,7 @@
|
|
|
2013
2016
|
return false;
|
|
2014
2017
|
}
|
|
2015
2018
|
var pluginState = _getPluginState(plugin);
|
|
2016
|
-
if (pluginState
|
|
2019
|
+
if (pluginState.teardown || pluginState[strDisabled]) {
|
|
2017
2020
|
return false;
|
|
2018
2021
|
}
|
|
2019
2022
|
if (hasSetNext) {
|
|
@@ -2562,12 +2565,13 @@
|
|
|
2562
2565
|
_isinitialized = true;
|
|
2563
2566
|
};
|
|
2564
2567
|
_self.teardown = function (unloadCtx, unloadState) {
|
|
2565
|
-
|
|
2568
|
+
var core = _self.core;
|
|
2569
|
+
if (!core || (unloadCtx && core !== unloadCtx.core())) {
|
|
2566
2570
|
return;
|
|
2567
2571
|
}
|
|
2568
2572
|
var result;
|
|
2569
2573
|
var unloadDone = false;
|
|
2570
|
-
var theUnloadCtx = unloadCtx || createProcessTelemetryUnloadContext(null,
|
|
2574
|
+
var theUnloadCtx = unloadCtx || createProcessTelemetryUnloadContext(null, core, _nextPlugin && _nextPlugin[strGetPlugin] ? _nextPlugin[strGetPlugin]() : _nextPlugin);
|
|
2571
2575
|
var theUnloadState = unloadState || {
|
|
2572
2576
|
reason: 0 ,
|
|
2573
2577
|
isAsync: false
|
|
@@ -2595,12 +2599,13 @@
|
|
|
2595
2599
|
return result;
|
|
2596
2600
|
};
|
|
2597
2601
|
_self.update = function (updateCtx, updateState) {
|
|
2598
|
-
|
|
2602
|
+
var core = _self.core;
|
|
2603
|
+
if (!core || (updateCtx && core !== updateCtx.core())) {
|
|
2599
2604
|
return;
|
|
2600
2605
|
}
|
|
2601
2606
|
var result;
|
|
2602
2607
|
var updateDone = false;
|
|
2603
|
-
var theUpdateCtx = updateCtx || createProcessTelemetryUpdateContext(null,
|
|
2608
|
+
var theUpdateCtx = updateCtx || createProcessTelemetryUpdateContext(null, core, _nextPlugin && _nextPlugin[strGetPlugin] ? _nextPlugin[strGetPlugin]() : _nextPlugin);
|
|
2604
2609
|
var theUpdateState = updateState || {
|
|
2605
2610
|
reason: 0
|
|
2606
2611
|
};
|
|
@@ -2757,6 +2762,9 @@
|
|
|
2757
2762
|
var strNotificationManager = "_notificationManager";
|
|
2758
2763
|
var strSdkUnloadingError = "SDK is still unloading...";
|
|
2759
2764
|
var strSdkNotInitialized = "SDK is not initialized";
|
|
2765
|
+
var defaultInitConfig = {
|
|
2766
|
+
loggingLevelConsole: 1
|
|
2767
|
+
};
|
|
2760
2768
|
function _createPerfManager(core, notificationMgr) {
|
|
2761
2769
|
return new PerfManager(notificationMgr);
|
|
2762
2770
|
}
|
|
@@ -2965,7 +2973,7 @@
|
|
|
2965
2973
|
isAsync: isAsync,
|
|
2966
2974
|
flushComplete: false
|
|
2967
2975
|
};
|
|
2968
|
-
var processUnloadCtx = createProcessTelemetryUnloadContext(_getPluginChain(), _self
|
|
2976
|
+
var processUnloadCtx = createProcessTelemetryUnloadContext(_getPluginChain(), _self);
|
|
2969
2977
|
processUnloadCtx.onComplete(function () {
|
|
2970
2978
|
_initDefaults();
|
|
2971
2979
|
unloadComplete && unloadComplete(unloadState);
|
|
@@ -3031,8 +3039,8 @@
|
|
|
3031
3039
|
proxyFunctionAs(_self, "addUnloadCb", function () { return _unloadHandlers; }, "add");
|
|
3032
3040
|
function _initDefaults() {
|
|
3033
3041
|
_isInitialized = false;
|
|
3034
|
-
_self.
|
|
3035
|
-
_self.
|
|
3042
|
+
_self.config = objExtend(true, {}, defaultInitConfig);
|
|
3043
|
+
_self.logger = new DiagnosticLogger(_self.config);
|
|
3036
3044
|
_self._extensions = [];
|
|
3037
3045
|
_telemetryInitializerPlugin = new TelemetryInitializerPlugin();
|
|
3038
3046
|
_eventQueue = [];
|
|
@@ -3140,7 +3148,7 @@
|
|
|
3140
3148
|
function _removePlugins(thePlugins, unloadState, removeComplete) {
|
|
3141
3149
|
if (thePlugins && thePlugins.length > 0) {
|
|
3142
3150
|
var unloadChain = createTelemetryProxyChain(thePlugins, _self.config, _self);
|
|
3143
|
-
var unloadCtx = createProcessTelemetryUnloadContext(unloadChain, _self
|
|
3151
|
+
var unloadCtx = createProcessTelemetryUnloadContext(unloadChain, _self);
|
|
3144
3152
|
unloadCtx.onComplete(function () {
|
|
3145
3153
|
var removed = false;
|
|
3146
3154
|
var newConfigExtensions = [];
|
|
@@ -3223,7 +3231,7 @@
|
|
|
3223
3231
|
extConfig.NotificationManager = _notificationManager;
|
|
3224
3232
|
}
|
|
3225
3233
|
function _doUpdate(updateState) {
|
|
3226
|
-
var updateCtx = createProcessTelemetryUpdateContext(_getPluginChain(), _self
|
|
3234
|
+
var updateCtx = createProcessTelemetryUpdateContext(_getPluginChain(), _self);
|
|
3227
3235
|
if (!_self._updateHook || _self._updateHook(updateCtx, updateState) !== true) {
|
|
3228
3236
|
updateCtx.processNext(updateState);
|
|
3229
3237
|
}
|