@microsoft/applicationinsights-core-js 3.4.2-nightly3.2606-02 → 3.4.2

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.
Files changed (254) hide show
  1. package/browser/es5/applicationinsights-core-js.cjs.js +4 -4
  2. package/browser/es5/applicationinsights-core-js.cjs.js.map +1 -1
  3. package/browser/es5/applicationinsights-core-js.cjs.min.js +2 -2
  4. package/browser/es5/applicationinsights-core-js.cjs.min.js.map +1 -1
  5. package/browser/es5/applicationinsights-core-js.gbl.js +6 -6
  6. package/browser/es5/applicationinsights-core-js.gbl.js.map +1 -1
  7. package/browser/es5/applicationinsights-core-js.gbl.min.js +2 -2
  8. package/browser/es5/applicationinsights-core-js.gbl.min.js.map +1 -1
  9. package/browser/es5/applicationinsights-core-js.integrity.json +25 -25
  10. package/browser/es5/applicationinsights-core-js.js +6 -6
  11. package/browser/es5/applicationinsights-core-js.js.map +1 -1
  12. package/browser/es5/applicationinsights-core-js.min.js +2 -2
  13. package/browser/es5/applicationinsights-core-js.min.js.map +1 -1
  14. package/dist/es5/index.js +4 -4
  15. package/dist/es5/index.js.map +1 -1
  16. package/dist/es5/index.min.js +2 -2
  17. package/dist/es5/index.min.js.map +1 -1
  18. package/dist-es5/__DynamicConstants.js +1 -1
  19. package/dist-es5/config/ConfigDefaultHelpers.js +1 -1
  20. package/dist-es5/config/ConfigDefaults.js +1 -1
  21. package/dist-es5/config/DynamicConfig.js +1 -1
  22. package/dist-es5/config/DynamicProperty.js +1 -1
  23. package/dist-es5/config/DynamicState.js +1 -1
  24. package/dist-es5/config/DynamicSupport.js +1 -1
  25. package/dist-es5/constants/Constants.js +1 -1
  26. package/dist-es5/constants/InternalConstants.js +1 -1
  27. package/dist-es5/core/AggregationError.js +1 -1
  28. package/dist-es5/core/AppInsightsCore.js +1 -1
  29. package/dist-es5/core/AsyncUtils.js +1 -1
  30. package/dist-es5/core/BaseTelemetryPlugin.js +1 -1
  31. package/dist-es5/core/CookieMgr.js +1 -1
  32. package/dist-es5/core/DbgExtensionUtils.js +1 -1
  33. package/dist-es5/core/InstrumentHooks.js +1 -1
  34. package/dist-es5/core/NotificationManager.js +1 -1
  35. package/dist-es5/core/PerfManager.js +1 -1
  36. package/dist-es5/core/ProcessTelemetryContext.js +1 -1
  37. package/dist-es5/core/ResponseHelpers.js +1 -1
  38. package/dist-es5/core/SenderPostManager.js +1 -1
  39. package/dist-es5/core/StatsBeat.js +1 -1
  40. package/dist-es5/core/TelemetryHelpers.js +1 -1
  41. package/dist-es5/core/TelemetryInitializerPlugin.js +1 -1
  42. package/dist-es5/core/UnloadHandlerContainer.js +1 -1
  43. package/dist-es5/core/UnloadHookContainer.js +1 -1
  44. package/dist-es5/diagnostics/DiagnosticLogger.js +1 -1
  45. package/dist-es5/diagnostics/ThrottleMgr.js +1 -1
  46. package/dist-es5/enums/EnumHelperFuncs.js +1 -1
  47. package/dist-es5/enums/W3CTraceFlags.js +1 -1
  48. package/dist-es5/enums/ai/DependencyTypes.js +2 -2
  49. package/dist-es5/enums/ai/DependencyTypes.js.map +1 -1
  50. package/dist-es5/enums/ai/Enums.js +4 -4
  51. package/dist-es5/enums/ai/Enums.js.map +1 -1
  52. package/dist-es5/enums/ai/EventsDiscardedReason.js +3 -3
  53. package/dist-es5/enums/ai/EventsDiscardedReason.js.map +1 -1
  54. package/dist-es5/enums/ai/FeatureOptInEnums.js +1 -1
  55. package/dist-es5/enums/ai/InitActiveStatusEnum.js +2 -2
  56. package/dist-es5/enums/ai/InitActiveStatusEnum.js.map +1 -1
  57. package/dist-es5/enums/ai/LoggingEnums.js +2 -2
  58. package/dist-es5/enums/ai/LoggingEnums.js.map +1 -1
  59. package/dist-es5/enums/ai/SendRequestReason.js +1 -1
  60. package/dist-es5/enums/ai/StatsType.js +1 -1
  61. package/dist-es5/enums/ai/TelemetryUnloadReason.js +1 -1
  62. package/dist-es5/enums/ai/TelemetryUpdateReason.js +1 -1
  63. package/dist-es5/enums/ai/TraceHeadersMode.js +1 -1
  64. package/dist-es5/enums/ai/UrlRedactionOptions.js +2 -2
  65. package/dist-es5/enums/ai/UrlRedactionOptions.js.map +1 -1
  66. package/dist-es5/enums/ext/Enums.js +5 -5
  67. package/dist-es5/enums/ext/Enums.js.map +1 -1
  68. package/dist-es5/enums/otel/OTelSamplingDecision.js +2 -2
  69. package/dist-es5/enums/otel/OTelSamplingDecision.js.map +1 -1
  70. package/dist-es5/enums/otel/OTelSpanKind.js +2 -2
  71. package/dist-es5/enums/otel/OTelSpanKind.js.map +1 -1
  72. package/dist-es5/enums/otel/OTelSpanStatus.js +2 -2
  73. package/dist-es5/enums/otel/OTelSpanStatus.js.map +1 -1
  74. package/dist-es5/enums/otel/eAttributeChangeOp.js +1 -1
  75. package/dist-es5/ext/AppInsightsExtCore.js +2 -2
  76. package/dist-es5/ext/AppInsightsExtCore.js.map +1 -1
  77. package/dist-es5/ext/ValueSanitizer.js +1 -1
  78. package/dist-es5/ext/extSpanUtils.js +3 -3
  79. package/dist-es5/ext/extSpanUtils.js.map +1 -1
  80. package/dist-es5/ext/extUtils.js +5 -5
  81. package/dist-es5/ext/extUtils.js.map +1 -1
  82. package/dist-es5/index.js +1 -1
  83. package/dist-es5/interfaces/IException.js +1 -1
  84. package/dist-es5/interfaces/IOTelHrTime.js +1 -1
  85. package/dist-es5/interfaces/ai/ConnectionString.js +1 -1
  86. package/dist-es5/interfaces/ai/IAppInsights.js +1 -1
  87. package/dist-es5/interfaces/ai/IAppInsightsCore.js +1 -1
  88. package/dist-es5/interfaces/ai/IChannelControls.js +1 -1
  89. package/dist-es5/interfaces/ai/IChannelControlsHost.js +1 -1
  90. package/dist-es5/interfaces/ai/IConfig.js +1 -1
  91. package/dist-es5/interfaces/ai/IConfiguration.js +1 -1
  92. package/dist-es5/interfaces/ai/ICookieMgr.js +1 -1
  93. package/dist-es5/interfaces/ai/ICorrelationConfig.js +1 -1
  94. package/dist-es5/interfaces/ai/IDbgExtension.js +1 -1
  95. package/dist-es5/interfaces/ai/IDependencyTelemetry.js +1 -1
  96. package/dist-es5/interfaces/ai/IDiagnosticLogger.js +1 -1
  97. package/dist-es5/interfaces/ai/IDistributedTraceContext.js +1 -1
  98. package/dist-es5/interfaces/ai/IEventTelemetry.js +1 -1
  99. package/dist-es5/interfaces/ai/IExceptionConfig.js +1 -1
  100. package/dist-es5/interfaces/ai/IExceptionTelemetry.js +1 -1
  101. package/dist-es5/interfaces/ai/IFeatureOptIn.js +1 -1
  102. package/dist-es5/interfaces/ai/IInstrumentHooks.js +1 -1
  103. package/dist-es5/interfaces/ai/IMetricTelemetry.js +1 -1
  104. package/dist-es5/interfaces/ai/INetworkStatsbeat.js +1 -1
  105. package/dist-es5/interfaces/ai/INotificationListener.js +1 -1
  106. package/dist-es5/interfaces/ai/INotificationManager.js +1 -1
  107. package/dist-es5/interfaces/ai/IPageViewPerformanceTelemetry.js +1 -1
  108. package/dist-es5/interfaces/ai/IPageViewTelemetry.js +1 -1
  109. package/dist-es5/interfaces/ai/IPartC.js +1 -1
  110. package/dist-es5/interfaces/ai/IPerfEvent.js +1 -1
  111. package/dist-es5/interfaces/ai/IPerfManager.js +1 -1
  112. package/dist-es5/interfaces/ai/IProcessTelemetryContext.js +1 -1
  113. package/dist-es5/interfaces/ai/IPropertiesPlugin.js +1 -1
  114. package/dist-es5/interfaces/ai/IRequestContext.js +1 -1
  115. package/dist-es5/interfaces/ai/IRequestTelemetry.js +1 -1
  116. package/dist-es5/interfaces/ai/ISenderPostManager.js +1 -1
  117. package/dist-es5/interfaces/ai/IStatsBeat.js +1 -1
  118. package/dist-es5/interfaces/ai/IStatsEventData.js +1 -1
  119. package/dist-es5/interfaces/ai/IStatsMgr.js +1 -1
  120. package/dist-es5/interfaces/ai/IStorageBuffer.js +1 -1
  121. package/dist-es5/interfaces/ai/ITelemetryContext.js +1 -1
  122. package/dist-es5/interfaces/ai/ITelemetryInitializers.js +1 -1
  123. package/dist-es5/interfaces/ai/ITelemetryItem.js +1 -1
  124. package/dist-es5/interfaces/ai/ITelemetryPlugin.js +1 -1
  125. package/dist-es5/interfaces/ai/ITelemetryPluginChain.js +1 -1
  126. package/dist-es5/interfaces/ai/ITelemetryUnloadState.js +1 -1
  127. package/dist-es5/interfaces/ai/ITelemetryUpdateState.js +1 -1
  128. package/dist-es5/interfaces/ai/IThrottleMgr.js +1 -1
  129. package/dist-es5/interfaces/ai/ITraceParent.js +1 -1
  130. package/dist-es5/interfaces/ai/ITraceProvider.js +1 -1
  131. package/dist-es5/interfaces/ai/ITraceTelemetry.js +1 -1
  132. package/dist-es5/interfaces/ai/IUnloadHook.js +1 -1
  133. package/dist-es5/interfaces/ai/IUnloadableComponent.js +1 -1
  134. package/dist-es5/interfaces/ai/IW3cTraceState.js +1 -1
  135. package/dist-es5/interfaces/ai/IXDomainRequest.js +1 -1
  136. package/dist-es5/interfaces/ai/IXHROverride.js +1 -1
  137. package/dist-es5/interfaces/ai/PartAExtensions.js +2 -2
  138. package/dist-es5/interfaces/ai/PartAExtensions.js.map +1 -1
  139. package/dist-es5/interfaces/ai/context/IApplication.js +1 -1
  140. package/dist-es5/interfaces/ai/context/IDevice.js +1 -1
  141. package/dist-es5/interfaces/ai/context/IInternal.js +1 -1
  142. package/dist-es5/interfaces/ai/context/ILocation.js +1 -1
  143. package/dist-es5/interfaces/ai/context/IOperatingSystem.js +1 -1
  144. package/dist-es5/interfaces/ai/context/ISample.js +1 -1
  145. package/dist-es5/interfaces/ai/context/ISession.js +1 -1
  146. package/dist-es5/interfaces/ai/context/ISessionManager.js +1 -1
  147. package/dist-es5/interfaces/ai/context/ITelemetryTrace.js +1 -1
  148. package/dist-es5/interfaces/ai/context/IUser.js +1 -1
  149. package/dist-es5/interfaces/ai/context/IWeb.js +1 -1
  150. package/dist-es5/interfaces/ai/contracts/AvailabilityData.js +1 -1
  151. package/dist-es5/interfaces/ai/contracts/ContextTagKeys.js +1 -1
  152. package/dist-es5/interfaces/ai/contracts/DataPointType.js +1 -1
  153. package/dist-es5/interfaces/ai/contracts/DependencyKind.js +1 -1
  154. package/dist-es5/interfaces/ai/contracts/DependencySourceType.js +1 -1
  155. package/dist-es5/interfaces/ai/contracts/IBase.js +1 -1
  156. package/dist-es5/interfaces/ai/contracts/IData.js +1 -1
  157. package/dist-es5/interfaces/ai/contracts/IDataPoint.js +1 -1
  158. package/dist-es5/interfaces/ai/contracts/IDomain.js +1 -1
  159. package/dist-es5/interfaces/ai/contracts/IEventData.js +1 -1
  160. package/dist-es5/interfaces/ai/contracts/IExceptionData.js +1 -1
  161. package/dist-es5/interfaces/ai/contracts/IExceptionDetails.js +1 -1
  162. package/dist-es5/interfaces/ai/contracts/IMessageData.js +1 -1
  163. package/dist-es5/interfaces/ai/contracts/IMetricData.js +1 -1
  164. package/dist-es5/interfaces/ai/contracts/IPageViewData.js +1 -1
  165. package/dist-es5/interfaces/ai/contracts/IPageViewPerfData.js +1 -1
  166. package/dist-es5/interfaces/ai/contracts/IRemoteDependencyData.js +1 -1
  167. package/dist-es5/interfaces/ai/contracts/IStackFrame.js +1 -1
  168. package/dist-es5/interfaces/ai/contracts/SeverityLevel.js +2 -2
  169. package/dist-es5/interfaces/ai/contracts/SeverityLevel.js.map +1 -1
  170. package/dist-es5/interfaces/ai/telemetry/IEnvelope.js +1 -1
  171. package/dist-es5/interfaces/ai/telemetry/ISerializable.js +1 -1
  172. package/dist-es5/interfaces/config/IConfigDefaults.js +1 -1
  173. package/dist-es5/interfaces/config/IDynamicConfigHandler.js +1 -1
  174. package/dist-es5/interfaces/config/IDynamicPropertyHandler.js +1 -1
  175. package/dist-es5/interfaces/config/IDynamicWatcher.js +1 -1
  176. package/dist-es5/interfaces/config/_IDynamicConfigHandlerState.js +1 -1
  177. package/dist-es5/interfaces/ext/DataModels.js +1 -1
  178. package/dist-es5/interfaces/otel/IOTelApi.js +1 -1
  179. package/dist-es5/interfaces/otel/IOTelApiCtx.js +1 -1
  180. package/dist-es5/interfaces/otel/IOTelAttributes.js +1 -1
  181. package/dist-es5/interfaces/otel/attribute/IAttributeContainer.js +1 -1
  182. package/dist-es5/interfaces/otel/config/IOTelAttributeLimits.js +1 -1
  183. package/dist-es5/interfaces/otel/config/IOTelConfig.js +1 -1
  184. package/dist-es5/interfaces/otel/config/IOTelErrorHandlers.js +1 -1
  185. package/dist-es5/interfaces/otel/config/IOTelSpanLimits.js +1 -1
  186. package/dist-es5/interfaces/otel/config/IOTelTraceCfg.js +1 -1
  187. package/dist-es5/interfaces/otel/trace/IOTelSpan.js +1 -1
  188. package/dist-es5/interfaces/otel/trace/IOTelSpanContext.js +1 -1
  189. package/dist-es5/interfaces/otel/trace/IOTelSpanCtx.js +1 -1
  190. package/dist-es5/interfaces/otel/trace/IOTelSpanOptions.js +1 -1
  191. package/dist-es5/interfaces/otel/trace/IOTelSpanStatus.js +1 -1
  192. package/dist-es5/interfaces/otel/trace/IOTelTraceApi.js +1 -1
  193. package/dist-es5/interfaces/otel/trace/IOTelTraceState.js +1 -1
  194. package/dist-es5/interfaces/otel/trace/IOTelTracer.js +1 -1
  195. package/dist-es5/interfaces/otel/trace/IOTelTracerOptions.js +1 -1
  196. package/dist-es5/interfaces/otel/trace/IOTelTracerProvider.js +1 -1
  197. package/dist-es5/interfaces/otel/trace/IReadableSpan.js +1 -1
  198. package/dist-es5/internal/EventHelpers.js +1 -1
  199. package/dist-es5/internal/attributeHelpers.js +1 -1
  200. package/dist-es5/internal/commonUtils.js +2 -2
  201. package/dist-es5/internal/commonUtils.js.map +1 -1
  202. package/dist-es5/internal/handleErrors.js +1 -1
  203. package/dist-es5/internal/noopHelpers.js +1 -1
  204. package/dist-es5/internal/timeHelpers.js +1 -1
  205. package/dist-es5/otel/api/OTelApi.js +1 -1
  206. package/dist-es5/otel/api/errors/OTelError.js +1 -1
  207. package/dist-es5/otel/api/errors/OTelInvalidAttributeError.js +1 -1
  208. package/dist-es5/otel/api/errors/OTelSpanError.js +1 -1
  209. package/dist-es5/otel/api/trace/span.js +1 -1
  210. package/dist-es5/otel/api/trace/spanContext.js +1 -1
  211. package/dist-es5/otel/api/trace/traceApi.js +1 -1
  212. package/dist-es5/otel/api/trace/traceProvider.js +1 -1
  213. package/dist-es5/otel/api/trace/traceState.js +1 -1
  214. package/dist-es5/otel/api/trace/tracer.js +1 -1
  215. package/dist-es5/otel/api/trace/tracerProvider.js +1 -1
  216. package/dist-es5/otel/api/trace/utils.js +1 -1
  217. package/dist-es5/otel/attribute/SemanticConventions.js +1 -1
  218. package/dist-es5/otel/attribute/attributeContainer.js +1 -1
  219. package/dist-es5/telemetry/ConnectionStringParser.js +1 -1
  220. package/dist-es5/telemetry/RequestResponseHeaders.js +2 -2
  221. package/dist-es5/telemetry/RequestResponseHeaders.js.map +1 -1
  222. package/dist-es5/telemetry/TelemetryItemCreator.js +1 -1
  223. package/dist-es5/telemetry/W3cTraceState.js +2 -2
  224. package/dist-es5/telemetry/W3cTraceState.js.map +1 -1
  225. package/dist-es5/telemetry/ai/Common/Data.js +1 -1
  226. package/dist-es5/telemetry/ai/Common/DataPoint.js +1 -1
  227. package/dist-es5/telemetry/ai/Common/DataSanitizer.js +1 -1
  228. package/dist-es5/telemetry/ai/Common/Envelope.js +1 -1
  229. package/dist-es5/telemetry/ai/DataTypes.js +1 -1
  230. package/dist-es5/telemetry/ai/EnvelopeTypes.js +9 -9
  231. package/dist-es5/telemetry/ai/EnvelopeTypes.js.map +1 -1
  232. package/dist-es5/telemetry/ai/Event.js +1 -1
  233. package/dist-es5/telemetry/ai/Exception.js +3 -3
  234. package/dist-es5/telemetry/ai/Exception.js.map +1 -1
  235. package/dist-es5/telemetry/ai/Metric.js +1 -1
  236. package/dist-es5/telemetry/ai/PageView.js +1 -1
  237. package/dist-es5/telemetry/ai/PageViewPerformance.js +1 -1
  238. package/dist-es5/telemetry/ai/RemoteDependencyData.js +1 -1
  239. package/dist-es5/telemetry/ai/Trace.js +1 -1
  240. package/dist-es5/utils/CoreUtils.js +1 -1
  241. package/dist-es5/utils/DataCacheHelper.js +2 -2
  242. package/dist-es5/utils/DataCacheHelper.js.map +1 -1
  243. package/dist-es5/utils/DomHelperFuncs.js +1 -1
  244. package/dist-es5/utils/EnvUtils.js +1 -1
  245. package/dist-es5/utils/HelperFuncs.js +1 -1
  246. package/dist-es5/utils/Offline.js +1 -1
  247. package/dist-es5/utils/RandomHelper.js +1 -1
  248. package/dist-es5/utils/StorageHelperFuncs.js +1 -1
  249. package/dist-es5/utils/TraceParent.js +1 -1
  250. package/dist-es5/utils/UrlHelperFuncs.js +1 -1
  251. package/dist-es5/utils/Util.js +1 -1
  252. package/package.json +82 -85
  253. package/types/applicationinsights-core-js.d.ts +3 -3
  254. package/types/applicationinsights-core-js.namespaced.d.ts +3 -3
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  import { __extendsFn as __extends } from "@microsoft/applicationinsights-shims";
@@ -22,7 +22,7 @@ import { ExtFullVersionString, getTime, isLatency } from "./extUtils";
22
22
  * WE MUST include all defaults here to ensure that the config is created with all of the properties
23
23
  * defined as dynamic.
24
24
  */
25
- var defaultConfig = ( /*#__PURE__*/objDeepFreeze({
25
+ var defaultConfig = (/*#__PURE__*/objDeepFreeze({
26
26
  endpointUrl: STR_DEFAULT_ENDPOINT_URL,
27
27
  propertyStorageOverride: { isVal: _chkPropOverride }
28
28
  }));
@@ -1 +1 @@
1
- {"version":3,"file":"AppInsightsExtCore.js.map","sources":["AppInsightsExtCore.js"],"sourcesContent":["import { __extends } from \"tslib\";\r\n/**\r\n* AppInsightsCore.ts\r\n* @author Abhilash Panwar (abpanwar) Hector Hernandez (hectorh)\r\n* @copyright Microsoft 2018\r\n*/\r\nimport dynamicProto from \"@microsoft/dynamicproto-js\";\r\nimport { dumpObj, objDeepFreeze, throwError } from \"@nevware21/ts-utils\";\r\nimport { _DYN_BASE_DATA, _DYN_INDEX_OF, _DYN_INITIALIZE, _DYN_LOGGER, _DYN_POLL_INTERNAL_LOGS, _DYN_PROPERTIES, _DYN_TIMINGS, _DYN_TRACK } from \"../__DynamicConstants\";\r\nimport { createDynamicConfig } from \"../config/DynamicConfig\";\r\nimport { STR_DEFAULT_ENDPOINT_URL, STR_EMPTY, STR_VERSION } from \"../constants/InternalConstants\";\r\nimport { AppInsightsCore } from \"../core/AppInsightsCore\";\r\nimport { doPerf } from \"../core/PerfManager\";\r\nimport { _throwInternal } from \"../diagnostics/DiagnosticLogger\";\r\nimport { ExtFullVersionString, getTime, isLatency } from \"./extUtils\";\r\n/**\r\n * The default settings for the config.\r\n * WE MUST include all defaults here to ensure that the config is created with all of the properties\r\n * defined as dynamic.\r\n */\r\nvar defaultConfig = ( /*#__PURE__*/objDeepFreeze({\r\n endpointUrl: STR_DEFAULT_ENDPOINT_URL,\r\n propertyStorageOverride: { isVal: _chkPropOverride }\r\n}));\r\n/*#__NO_SIDE_EFFECTS__*/\r\nfunction _chkPropOverride(propertyStorageOverride) {\r\n // Validate property storage override\r\n if (propertyStorageOverride && (!propertyStorageOverride.getProperty || !propertyStorageOverride.setProperty)) {\r\n throwError(\"Invalid property storage override passed.\");\r\n }\r\n return true;\r\n}\r\n/**\r\n * @group Classes\r\n * @group Entrypoint\r\n */\r\nvar AppInsightsExtCore = /** @class */ (function (_super) {\r\n __extends(AppInsightsExtCore, _super);\r\n function AppInsightsExtCore() {\r\n var _this = _super.call(this) || this;\r\n dynamicProto(AppInsightsExtCore, _this, function (_self, _base) {\r\n _self[_DYN_INITIALIZE /* @min:%2einitialize */] = function (config, extensions, logger, notificationManager) {\r\n doPerf(_self, function () { return \"AppInsightsCore.initialize\"; }, function () {\r\n try {\r\n _base.initialize(createDynamicConfig(config, defaultConfig, logger || _self[_DYN_LOGGER /* @min:%2elogger */], false).cfg, extensions, logger, notificationManager);\r\n }\r\n catch (e) {\r\n var logger_1 = _self[_DYN_LOGGER /* @min:%2elogger */];\r\n var message = dumpObj(e);\r\n if (message[_DYN_INDEX_OF /* @min:%2eindexOf */](\"channels\") !== -1) {\r\n // Add some additional context to the underlying reported error\r\n message += \"\\n - Channels must be provided through config.channels only!\";\r\n }\r\n _throwInternal(logger_1, 1 /* eLoggingSeverity.CRITICAL */, 514 /* _eExtendedInternalMessageId.FailedToInitializeSDK */, \"SDK Initialization Failed - no telemetry will be sent: \" + message);\r\n }\r\n }, function () { return ({ config: config, extensions: extensions, logger: logger, notificationManager: notificationManager }); });\r\n };\r\n _self[_DYN_TRACK /* @min:%2etrack */] = function (item) {\r\n doPerf(_self, function () { return \"AppInsightsCore.track\"; }, function () {\r\n var telemetryItem = item;\r\n if (telemetryItem) {\r\n telemetryItem[_DYN_TIMINGS /* @min:%2etimings */] = telemetryItem[_DYN_TIMINGS /* @min:%2etimings */] || {};\r\n telemetryItem[_DYN_TIMINGS /* @min:%2etimings */].trackStart = getTime();\r\n if (!isLatency(telemetryItem.latency)) {\r\n telemetryItem.latency = 1 /* EventLatencyValue.Normal */;\r\n }\r\n var itemExt = telemetryItem.ext = telemetryItem.ext || {};\r\n itemExt.sdk = itemExt.sdk || {};\r\n itemExt.sdk.ver = ExtFullVersionString;\r\n var baseData = telemetryItem[_DYN_BASE_DATA /* @min:%2ebaseData */] = telemetryItem[_DYN_BASE_DATA /* @min:%2ebaseData */] || {};\r\n baseData[_DYN_PROPERTIES /* @min:%2eproperties */] = baseData[_DYN_PROPERTIES /* @min:%2eproperties */] || {};\r\n var itemProperties = baseData[_DYN_PROPERTIES /* @min:%2eproperties */];\r\n itemProperties[STR_VERSION] = itemProperties[STR_VERSION] || _self.pluginVersionString || STR_EMPTY;\r\n }\r\n _base[_DYN_TRACK /* @min:%2etrack */](telemetryItem);\r\n }, function () { return ({ item: item }); }, !(item.sync));\r\n };\r\n _self[_DYN_POLL_INTERNAL_LOGS /* @min:%2epollInternalLogs */] = function (eventName) {\r\n return _base[_DYN_POLL_INTERNAL_LOGS /* @min:%2epollInternalLogs */](eventName || \"InternalLog\");\r\n };\r\n });\r\n return _this;\r\n }\r\n /**\r\n * Initialize the sdk.\r\n * @param config - The configuration to initialize the SDK.\r\n * @param extensions - An array of extensions that are to be used by the core.\r\n */\r\n AppInsightsExtCore.prototype.initialize = function (config, extensions, logger, notificationManager) {\r\n // @DynamicProtoStub -- DO NOT add any code as this will be removed during packaging\r\n };\r\n AppInsightsExtCore.prototype.track = function (item) {\r\n // @DynamicProtoStub -- DO NOT add any code as this will be removed during packaging\r\n };\r\n /**\r\n * Periodically check logger.queue for\r\n */\r\n AppInsightsExtCore.prototype.pollInternalLogs = function (eventName) {\r\n // @DynamicProtoStub -- DO NOT add any code as this will be removed during packaging\r\n return null;\r\n };\r\n return AppInsightsExtCore;\r\n}(AppInsightsCore));\r\nexport { AppInsightsExtCore };\r\n//# sourceMappingURL=AppInsightsExtCore.js.map"],"names":[],"mappings":";;;;AAAA,gFAAkC;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;kEAiBM,CAAC;;;;;8BACuB;AAC9B;AACA;AACA"}
1
+ {"version":3,"file":"AppInsightsExtCore.js.map","sources":["AppInsightsExtCore.js"],"sourcesContent":["import { __extends } from \"tslib\";\r\n/**\r\n* AppInsightsCore.ts\r\n* @author Abhilash Panwar (abpanwar) Hector Hernandez (hectorh)\r\n* @copyright Microsoft 2018\r\n*/\r\nimport dynamicProto from \"@microsoft/dynamicproto-js\";\r\nimport { dumpObj, objDeepFreeze, throwError } from \"@nevware21/ts-utils\";\r\nimport { _DYN_BASE_DATA, _DYN_INDEX_OF, _DYN_INITIALIZE, _DYN_LOGGER, _DYN_POLL_INTERNAL_LOGS, _DYN_PROPERTIES, _DYN_TIMINGS, _DYN_TRACK } from \"../__DynamicConstants\";\r\nimport { createDynamicConfig } from \"../config/DynamicConfig\";\r\nimport { STR_DEFAULT_ENDPOINT_URL, STR_EMPTY, STR_VERSION } from \"../constants/InternalConstants\";\r\nimport { AppInsightsCore } from \"../core/AppInsightsCore\";\r\nimport { doPerf } from \"../core/PerfManager\";\r\nimport { _throwInternal } from \"../diagnostics/DiagnosticLogger\";\r\nimport { ExtFullVersionString, getTime, isLatency } from \"./extUtils\";\r\n/**\r\n * The default settings for the config.\r\n * WE MUST include all defaults here to ensure that the config is created with all of the properties\r\n * defined as dynamic.\r\n */\r\nvar defaultConfig = (/*#__PURE__*/objDeepFreeze({\r\n endpointUrl: STR_DEFAULT_ENDPOINT_URL,\r\n propertyStorageOverride: { isVal: _chkPropOverride }\r\n}));\r\n/*#__NO_SIDE_EFFECTS__*/\r\nfunction _chkPropOverride(propertyStorageOverride) {\r\n // Validate property storage override\r\n if (propertyStorageOverride && (!propertyStorageOverride.getProperty || !propertyStorageOverride.setProperty)) {\r\n throwError(\"Invalid property storage override passed.\");\r\n }\r\n return true;\r\n}\r\n/**\r\n * @group Classes\r\n * @group Entrypoint\r\n */\r\nvar AppInsightsExtCore = /** @class */ (function (_super) {\r\n __extends(AppInsightsExtCore, _super);\r\n function AppInsightsExtCore() {\r\n var _this = _super.call(this) || this;\r\n dynamicProto(AppInsightsExtCore, _this, function (_self, _base) {\r\n _self[_DYN_INITIALIZE /* @min:%2einitialize */] = function (config, extensions, logger, notificationManager) {\r\n doPerf(_self, function () { return \"AppInsightsCore.initialize\"; }, function () {\r\n try {\r\n _base.initialize(createDynamicConfig(config, defaultConfig, logger || _self[_DYN_LOGGER /* @min:%2elogger */], false).cfg, extensions, logger, notificationManager);\r\n }\r\n catch (e) {\r\n var logger_1 = _self[_DYN_LOGGER /* @min:%2elogger */];\r\n var message = dumpObj(e);\r\n if (message[_DYN_INDEX_OF /* @min:%2eindexOf */](\"channels\") !== -1) {\r\n // Add some additional context to the underlying reported error\r\n message += \"\\n - Channels must be provided through config.channels only!\";\r\n }\r\n _throwInternal(logger_1, 1 /* eLoggingSeverity.CRITICAL */, 514 /* _eExtendedInternalMessageId.FailedToInitializeSDK */, \"SDK Initialization Failed - no telemetry will be sent: \" + message);\r\n }\r\n }, function () { return ({ config: config, extensions: extensions, logger: logger, notificationManager: notificationManager }); });\r\n };\r\n _self[_DYN_TRACK /* @min:%2etrack */] = function (item) {\r\n doPerf(_self, function () { return \"AppInsightsCore.track\"; }, function () {\r\n var telemetryItem = item;\r\n if (telemetryItem) {\r\n telemetryItem[_DYN_TIMINGS /* @min:%2etimings */] = telemetryItem[_DYN_TIMINGS /* @min:%2etimings */] || {};\r\n telemetryItem[_DYN_TIMINGS /* @min:%2etimings */].trackStart = getTime();\r\n if (!isLatency(telemetryItem.latency)) {\r\n telemetryItem.latency = 1 /* EventLatencyValue.Normal */;\r\n }\r\n var itemExt = telemetryItem.ext = telemetryItem.ext || {};\r\n itemExt.sdk = itemExt.sdk || {};\r\n itemExt.sdk.ver = ExtFullVersionString;\r\n var baseData = telemetryItem[_DYN_BASE_DATA /* @min:%2ebaseData */] = telemetryItem[_DYN_BASE_DATA /* @min:%2ebaseData */] || {};\r\n baseData[_DYN_PROPERTIES /* @min:%2eproperties */] = baseData[_DYN_PROPERTIES /* @min:%2eproperties */] || {};\r\n var itemProperties = baseData[_DYN_PROPERTIES /* @min:%2eproperties */];\r\n itemProperties[STR_VERSION] = itemProperties[STR_VERSION] || _self.pluginVersionString || STR_EMPTY;\r\n }\r\n _base[_DYN_TRACK /* @min:%2etrack */](telemetryItem);\r\n }, function () { return ({ item: item }); }, !(item.sync));\r\n };\r\n _self[_DYN_POLL_INTERNAL_LOGS /* @min:%2epollInternalLogs */] = function (eventName) {\r\n return _base[_DYN_POLL_INTERNAL_LOGS /* @min:%2epollInternalLogs */](eventName || \"InternalLog\");\r\n };\r\n });\r\n return _this;\r\n }\r\n /**\r\n * Initialize the sdk.\r\n * @param config - The configuration to initialize the SDK.\r\n * @param extensions - An array of extensions that are to be used by the core.\r\n */\r\n AppInsightsExtCore.prototype.initialize = function (config, extensions, logger, notificationManager) {\r\n // @DynamicProtoStub -- DO NOT add any code as this will be removed during packaging\r\n };\r\n AppInsightsExtCore.prototype.track = function (item) {\r\n // @DynamicProtoStub -- DO NOT add any code as this will be removed during packaging\r\n };\r\n /**\r\n * Periodically check logger.queue for\r\n */\r\n AppInsightsExtCore.prototype.pollInternalLogs = function (eventName) {\r\n // @DynamicProtoStub -- DO NOT add any code as this will be removed during packaging\r\n return null;\r\n };\r\n return AppInsightsExtCore;\r\n}(AppInsightsCore));\r\nexport { AppInsightsExtCore };\r\n//# sourceMappingURL=AppInsightsExtCore.js.map"],"names":[],"mappings":";;;;AAAA,gFAAkC;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;kEAiBM,CAAC;;;;;8BACuB;AAC9B;AACA;AACA"}
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  import { arrForEach, arrIncludes, arrIndexOf, getLength, isNullOrUndefined, isString, objForEachKey } from "@nevware21/ts-utils";
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  // Copyright (c) Microsoft Corporation.
@@ -19,14 +19,14 @@ import { toISOString } from "../utils/HelperFuncs";
19
19
  */
20
20
  var AzNamespace = "az.namespace";
21
21
  var AzResourceNamespace = "azure.resource_provider.namespace";
22
- var PORT_REGEX = ( /*#__PURE__*/getLazy(function () { return new RegExp(/(https?)(:\/\/.*)(:\d+)(\S*)/); }));
22
+ var PORT_REGEX = (/*#__PURE__*/getLazy(function () { return new RegExp(/(https?)(:\/\/.*)(:\d+)(\S*)/); }));
23
23
  var HTTP_DOT = "http.";
24
24
  var _MS_PROCESSED_BY_METRICS_EXTRACTORS = "_MS.ProcessedByMetricExtractors";
25
25
  /**
26
26
  * Legacy HTTP semantic convention values
27
27
  * @internal
28
28
  */
29
- var _ignoreSemanticValues = ( /* #__PURE__*/getLazy(_initIgnoreSemanticValues));
29
+ var _ignoreSemanticValues = (/*#__PURE__*/getLazy(_initIgnoreSemanticValues));
30
30
  /* #__NO_SIDE_EFFECTS__ */
31
31
  function _initIgnoreSemanticValues() {
32
32
  return [
@@ -1 +1 @@
1
- {"version":3,"file":"extSpanUtils.js.map","sources":["extSpanUtils.js"],"sourcesContent":["// Copyright (c) Microsoft Corporation.\r\n// Licensed under the MIT License.\r\nimport { arrIncludes, asString, getLazy, getNavigator, isBoolean, isNullOrUndefined, isNumber, isString, strLower, strStartsWith, throwError } from \"@nevware21/ts-utils\";\r\nimport { _DYN_ATTRIBUTES, _DYN_BASE_DATA, _DYN_CONFIG, _DYN_DATA, _DYN_DURATION, _DYN_I_KEY, _DYN_KIND, _DYN_NAME, _DYN_PARENT_SPAN_CONTEXT, _DYN_SPAN_CONTEXT, _DYN_SPAN_ID, _DYN_START_TIME, _DYN_STATUS, _DYN_TRACE_FLAGS, _DYN_TRACE_ID, _DYN_TRACE_STATE, _DYN_USER_AGENT } from \"../__DynamicConstants\";\r\nimport { STR_NOT_SPECIFIED } from \"../constants/InternalConstants\";\r\nimport { getHttpClientIp, getHttpHost, getHttpMethod, getHttpScheme, getHttpStatusCode, getHttpUrl, getSyntheticType, getUserAgent } from \"../internal/commonUtils\";\r\nimport { hrTimeToMilliseconds } from \"../internal/timeHelpers\";\r\nimport { ATTR_CLIENT_ADDRESS, ATTR_CLIENT_PORT, ATTR_ENDUSER_ID, ATTR_ENDUSER_PSEUDO_ID, ATTR_ERROR_TYPE, ATTR_EXCEPTION_MESSAGE, ATTR_EXCEPTION_STACKTRACE, ATTR_EXCEPTION_TYPE, ATTR_HTTP_REQUEST_METHOD, ATTR_HTTP_RESPONSE_STATUS_CODE, ATTR_NETWORK_LOCAL_ADDRESS, ATTR_NETWORK_LOCAL_PORT, ATTR_NETWORK_PEER_ADDRESS, ATTR_NETWORK_PEER_PORT, ATTR_NETWORK_PROTOCOL_NAME, ATTR_NETWORK_PROTOCOL_VERSION, ATTR_NETWORK_TRANSPORT, ATTR_SERVER_ADDRESS, ATTR_SERVER_PORT, ATTR_URL_FULL, ATTR_URL_PATH, ATTR_URL_QUERY, ATTR_URL_SCHEME, ATTR_USER_AGENT_ORIGINAL, EXP_ATTR_ENDUSER_ID, EXP_ATTR_ENDUSER_PSEUDO_ID, EXP_ATTR_SYNTHETIC_TYPE, SEMATTRS_DB_NAME, SEMATTRS_DB_OPERATION, SEMATTRS_DB_STATEMENT, SEMATTRS_DB_SYSTEM, SEMATTRS_ENDUSER_ID, SEMATTRS_EXCEPTION_MESSAGE, SEMATTRS_EXCEPTION_STACKTRACE, SEMATTRS_EXCEPTION_TYPE, SEMATTRS_HTTP_CLIENT_IP, SEMATTRS_HTTP_FLAVOR, SEMATTRS_HTTP_HOST, SEMATTRS_HTTP_METHOD, SEMATTRS_HTTP_ROUTE, SEMATTRS_HTTP_SCHEME, SEMATTRS_HTTP_STATUS_CODE, SEMATTRS_HTTP_TARGET, SEMATTRS_HTTP_URL, SEMATTRS_HTTP_USER_AGENT, SEMATTRS_NET_HOST_IP, SEMATTRS_NET_HOST_NAME, SEMATTRS_NET_HOST_PORT, SEMATTRS_NET_PEER_IP, SEMATTRS_NET_PEER_NAME, SEMATTRS_NET_PEER_PORT, SEMATTRS_NET_TRANSPORT, SEMATTRS_PEER_SERVICE, SEMATTRS_RPC_GRPC_STATUS_CODE, SEMATTRS_RPC_SYSTEM } from \"../otel/attribute/SemanticConventions\";\r\nimport { createAttributeContainer } from \"../otel/attribute/attributeContainer\";\r\nimport { fieldRedaction } from \"../utils/EnvUtils\";\r\nimport { toISOString } from \"../utils/HelperFuncs\";\r\n/**\r\n * Azure SDK namespace.\r\n * @internal\r\n */\r\nvar AzNamespace = \"az.namespace\";\r\nvar AzResourceNamespace = \"azure.resource_provider.namespace\";\r\nvar PORT_REGEX = ( /*#__PURE__*/getLazy(function () { return new RegExp(/(https?)(:\\/\\/.*)(:\\d+)(\\S*)/); }));\r\nvar HTTP_DOT = \"http.\";\r\nvar _MS_PROCESSED_BY_METRICS_EXTRACTORS = \"_MS.ProcessedByMetricExtractors\";\r\n/**\r\n * Legacy HTTP semantic convention values\r\n * @internal\r\n */\r\nvar _ignoreSemanticValues = ( /* #__PURE__*/getLazy(_initIgnoreSemanticValues));\r\n/* #__NO_SIDE_EFFECTS__ */\r\nfunction _initIgnoreSemanticValues() {\r\n return [\r\n // Internal Microsoft attributes\r\n _MS_PROCESSED_BY_METRICS_EXTRACTORS,\r\n // Legacy HTTP semantic values\r\n SEMATTRS_NET_PEER_IP,\r\n SEMATTRS_NET_PEER_NAME,\r\n SEMATTRS_NET_HOST_IP,\r\n SEMATTRS_PEER_SERVICE,\r\n SEMATTRS_HTTP_USER_AGENT,\r\n SEMATTRS_HTTP_METHOD,\r\n SEMATTRS_HTTP_URL,\r\n SEMATTRS_HTTP_STATUS_CODE,\r\n SEMATTRS_HTTP_ROUTE,\r\n SEMATTRS_HTTP_HOST,\r\n SEMATTRS_DB_SYSTEM,\r\n SEMATTRS_DB_STATEMENT,\r\n SEMATTRS_DB_OPERATION,\r\n SEMATTRS_DB_NAME,\r\n SEMATTRS_RPC_SYSTEM,\r\n SEMATTRS_RPC_GRPC_STATUS_CODE,\r\n SEMATTRS_EXCEPTION_TYPE,\r\n SEMATTRS_EXCEPTION_MESSAGE,\r\n SEMATTRS_EXCEPTION_STACKTRACE,\r\n SEMATTRS_HTTP_SCHEME,\r\n SEMATTRS_HTTP_TARGET,\r\n SEMATTRS_HTTP_FLAVOR,\r\n SEMATTRS_NET_TRANSPORT,\r\n SEMATTRS_NET_HOST_NAME,\r\n SEMATTRS_NET_HOST_PORT,\r\n SEMATTRS_NET_PEER_PORT,\r\n SEMATTRS_HTTP_CLIENT_IP,\r\n SEMATTRS_ENDUSER_ID,\r\n HTTP_DOT + \"status_text\",\r\n // http Semabtic conventions\r\n ATTR_CLIENT_ADDRESS,\r\n ATTR_CLIENT_PORT,\r\n ATTR_SERVER_ADDRESS,\r\n ATTR_SERVER_PORT,\r\n ATTR_URL_FULL,\r\n ATTR_URL_PATH,\r\n ATTR_URL_QUERY,\r\n ATTR_URL_SCHEME,\r\n ATTR_ERROR_TYPE,\r\n ATTR_NETWORK_LOCAL_ADDRESS,\r\n ATTR_NETWORK_LOCAL_PORT,\r\n ATTR_NETWORK_PROTOCOL_NAME,\r\n ATTR_NETWORK_PEER_ADDRESS,\r\n ATTR_NETWORK_PEER_PORT,\r\n ATTR_NETWORK_PROTOCOL_VERSION,\r\n ATTR_NETWORK_TRANSPORT,\r\n ATTR_USER_AGENT_ORIGINAL,\r\n ATTR_HTTP_REQUEST_METHOD,\r\n ATTR_HTTP_RESPONSE_STATUS_CODE,\r\n ATTR_EXCEPTION_TYPE,\r\n ATTR_EXCEPTION_MESSAGE,\r\n ATTR_EXCEPTION_STACKTRACE,\r\n EXP_ATTR_ENDUSER_ID,\r\n EXP_ATTR_ENDUSER_PSEUDO_ID,\r\n EXP_ATTR_SYNTHETIC_TYPE,\r\n // Azure SDK attributes are not included as they are not part of the span attributes\r\n AzNamespace,\r\n AzResourceNamespace,\r\n \"az.client_request_id\",\r\n \"azure.client.id\",\r\n \"az.service_request_id\",\r\n \"azure.service.request.id\"\r\n ];\r\n}\r\nfunction _applyExtValue(ext, extName, name, value, overwriteExt) {\r\n if (isString(value) || isNumber(value) || isBoolean(value)) {\r\n var target = ext[extName] = ext[extName] || {};\r\n _applyValue(target, name, value, overwriteExt);\r\n }\r\n}\r\nfunction _applyValue(target, name, value, overwriteTarget) {\r\n if (target) {\r\n if (isString(value) || isNumber(value) || isBoolean(value)) {\r\n var targetValue = target[name];\r\n if (!overwriteTarget && (targetValue || isString(targetValue) || isNumber(targetValue) || isBoolean(targetValue))) {\r\n value = targetValue;\r\n }\r\n target[name] = value;\r\n }\r\n }\r\n return target;\r\n}\r\nfunction _populateExtensionsFromSpan(telemetryItem, span, container) {\r\n var ext = telemetryItem.ext = telemetryItem.ext || {};\r\n // Map OpenTelemetry enduser attributes to Application Insights user attributes\r\n var endUserId = container.get(ATTR_ENDUSER_ID);\r\n if (endUserId) {\r\n _applyExtValue(ext, \"user\", \"authId\", asString(endUserId), false);\r\n }\r\n var endUserPseudoId = container.get(ATTR_ENDUSER_PSEUDO_ID);\r\n if (endUserPseudoId) {\r\n _applyExtValue(ext, \"user\", \"id\", asString(endUserPseudoId), false);\r\n }\r\n}\r\n/**\r\n * Check to see if the key is in the list of known properties to ignore (exclude)\r\n * from part C properties population.\r\n * @param key - the property key to check\r\n * @param contextKeys - The current context keys\r\n * @returns true if the key should be ignored, false otherwise\r\n */\r\nfunction _isIgnorePartCKey(key) {\r\n var result = false;\r\n if (arrIncludes(_ignoreSemanticValues.v, key)) {\r\n // The key is in set of known keys to ignore\r\n result = true;\r\n }\r\n else if (strStartsWith(key, \"microsoft.\")) {\r\n // Ignoring all ALL keys starting with \"microsoft.\"\r\n result = true;\r\n }\r\n return result;\r\n}\r\nfunction _populatePartC(item, container) {\r\n if (container) {\r\n var partC_1 = item[_DYN_DATA /* @min:%2edata */] = (item[_DYN_DATA /* @min:%2edata */] || {});\r\n _applyValue(partC_1, \"httpHost\", getHttpHost(container), false);\r\n _applyValue(partC_1, \"httpScheme\", getHttpScheme(container), false);\r\n _applyValue(partC_1, \"httpClientIp\", getHttpClientIp(container), false);\r\n _applyValue(partC_1, \"httpUserAgent\", getUserAgent(container), false);\r\n _applyValue(partC_1, \"httpRoute\", container.get(SEMATTRS_HTTP_ROUTE), false);\r\n _applyValue(partC_1, \"netPeerName\", container.get(SEMATTRS_NET_PEER_NAME), false);\r\n _applyValue(partC_1, \"netPeerPort\", container.get(SEMATTRS_NET_PEER_PORT), false);\r\n _applyValue(partC_1, \"netPeerIp\", container.get(SEMATTRS_NET_PEER_IP), false);\r\n _applyValue(partC_1, \"peerService\", container.get(\"service.name\") || container.get(SEMATTRS_PEER_SERVICE), false);\r\n var syntheticSource = getSyntheticType(container);\r\n if (!!syntheticSource) {\r\n _applyValue(partC_1, \"userAgentSyntheticType\", syntheticSource, false);\r\n }\r\n var nav = getNavigator();\r\n if (nav && nav[_DYN_USER_AGENT /* @min:%2euserAgent */]) {\r\n _applyValue(partC_1, \"userAgentOriginal\", nav[_DYN_USER_AGENT /* @min:%2euserAgent */], false);\r\n }\r\n // Azure SDK fields\r\n _applyValue(partC_1, \"azureClientRequestId\", container.get(\"azure.client.id\") || container.get(\"az.client_request_id\"), false);\r\n _applyValue(partC_1, \"azureServiceRequestId\", container.get(\"azure.service.request.id\") || container.get(\"az.service_request_id\"), false);\r\n var sampleRate = container.get(\"microsoft.sample_rate\");\r\n if (!isNullOrUndefined(sampleRate)) {\r\n _applyValue(partC_1, \"sampleRate\", sampleRate, false);\r\n }\r\n container.forEach(function (key, value) {\r\n // Avoid duplication ignoring fields already mapped.\r\n if (!_isIgnorePartCKey(key)) {\r\n partC_1[key] = value;\r\n }\r\n });\r\n }\r\n}\r\nfunction _populateHttpProperties(otelSpanTelemetry, container, httpMethod, config) {\r\n if (httpMethod) {\r\n // Step the HTTP method\r\n _applyValue(otelSpanTelemetry, \"httpMethod\", httpMethod, false);\r\n // HTTP Dependency\r\n var httpUrl = getHttpUrl(container);\r\n if (httpUrl) {\r\n try {\r\n // Remove default port\r\n var res = PORT_REGEX.v.exec(asString(httpUrl));\r\n if (res !== null) {\r\n var protocol = res[1];\r\n var port = res[3];\r\n if ((protocol === \"https\" && port === \":443\") ||\r\n (protocol === \"http\" && port === \":80\")) {\r\n // Drop port\r\n httpUrl = res[1] + res[2] + res[4];\r\n }\r\n }\r\n }\r\n catch (_a) {\r\n /* no-op */\r\n }\r\n _applyValue(otelSpanTelemetry, \"httpUrl\", fieldRedaction(asString(httpUrl), config), false);\r\n }\r\n var httpStatusCode = getHttpStatusCode(container);\r\n if (httpStatusCode) {\r\n _applyValue(otelSpanTelemetry, \"httpStatusCode\", httpStatusCode, false);\r\n }\r\n }\r\n}\r\nfunction _populateDbProperties(otelSpanTelemetry, container, dbSystem) {\r\n if (dbSystem) {\r\n _applyValue(otelSpanTelemetry, \"dbSystem\", dbSystem, false);\r\n // Set the statement\r\n _applyValue(otelSpanTelemetry, \"dbStatement\", container.get(SEMATTRS_DB_STATEMENT) || container.get(SEMATTRS_DB_OPERATION), false);\r\n _applyValue(otelSpanTelemetry, \"dbName\", container.get(SEMATTRS_DB_NAME) || dbSystem || \"<undefined>\", false);\r\n }\r\n}\r\nfunction _populateRpcDependencyProperties(otelSpanTelemetry, container, rpcSystem) {\r\n if (rpcSystem) {\r\n _applyValue(otelSpanTelemetry, \"rpcSystem\", strLower(rpcSystem), false);\r\n _applyValue(otelSpanTelemetry, \"rpcGrpcStatusCode\", container.get(SEMATTRS_RPC_GRPC_STATUS_CODE), false);\r\n }\r\n}\r\nfunction _createOTelSpanTelemetryItem(core, span) {\r\n var container = span.attribContainer || createAttributeContainer(span[_DYN_ATTRIBUTES /* @min:%2eattributes */]);\r\n var spanCtx = span[_DYN_SPAN_CONTEXT /* @min:%2espanContext */]();\r\n var statusCode = span[_DYN_STATUS /* @min:%2estatus */] ? span[_DYN_STATUS /* @min:%2estatus */].code : 0 /* eOTelSpanStatusCode.UNSET */;\r\n var spanTelemetry = {\r\n name: span[_DYN_NAME /* @min:%2ename */],\r\n kind: span[_DYN_KIND /* @min:%2ekind */],\r\n startTime: toISOString(new Date(hrTimeToMilliseconds(span[_DYN_START_TIME /* @min:%2estartTime */]))),\r\n success: statusCode !== 0 /* eOTelSpanStatusCode.UNSET */ ? statusCode !== 2 /* eOTelSpanStatusCode.ERROR */ : (Number(getHttpStatusCode(container)) || 0) < 400,\r\n duration: hrTimeToMilliseconds(span[_DYN_DURATION /* @min:%2eduration */])\r\n //azureResourceProvider: undefined, // Not currently supported\r\n //links: UNDEFINED_VALUE, // Not currently supported\r\n };\r\n // Set the parentId if available\r\n var parentCtx = span[_DYN_PARENT_SPAN_CONTEXT /* @min:%2eparentSpanContext */] || (spanCtx ? spanCtx.parentCtx : null);\r\n _applyValue(spanTelemetry, \"parentId\", span.parentSpanId || (parentCtx ? parentCtx[_DYN_SPAN_ID /* @min:%2espanId */] : null), false);\r\n if (spanCtx) {\r\n var traceState = spanCtx[_DYN_TRACE_STATE /* @min:%2etraceState */];\r\n if (traceState && !traceState.isEmpty) {\r\n _applyValue(spanTelemetry, \"traceState\", traceState.hdrs(1)[0], false);\r\n }\r\n }\r\n _populateHttpProperties(spanTelemetry, container, getHttpMethod(container), core[_DYN_CONFIG /* @min:%2econfig */]);\r\n _populateDbProperties(spanTelemetry, container, container.get(SEMATTRS_DB_SYSTEM));\r\n _populateRpcDependencyProperties(spanTelemetry, container, container.get(SEMATTRS_RPC_SYSTEM));\r\n _applyValue(spanTelemetry, \"azureResourceProvider\", container.get(AzResourceNamespace) || container.get(AzNamespace), false);\r\n return _createTelemetryItem(spanTelemetry, span, \"OTelSpan\", \"Ms.Web.Span\");\r\n}\r\nfunction _createTelemetryItem(item, span, baseType, eventName) {\r\n eventName = eventName || STR_NOT_SPECIFIED;\r\n if (isNullOrUndefined(item) ||\r\n isNullOrUndefined(baseType) ||\r\n isNullOrUndefined(eventName)) {\r\n throwError(\"Input doesn't contain all required fields\");\r\n }\r\n var iKey = \"\";\r\n if (item[_DYN_I_KEY /* @min:%2eiKey */]) {\r\n iKey = item[_DYN_I_KEY /* @min:%2eiKey */];\r\n delete item[_DYN_I_KEY /* @min:%2eiKey */];\r\n }\r\n var telemetryItem = {\r\n name: eventName,\r\n time: toISOString(span.endTime ? new Date(hrTimeToMilliseconds(span.endTime)) : new Date()),\r\n iKey: iKey,\r\n ext: {},\r\n baseType: baseType,\r\n baseData: item,\r\n data: {} // part C\r\n };\r\n return telemetryItem;\r\n}\r\n/**\r\n * Create an extended common schema telemetry item from the provided span\r\n * @param core - The app insights core instance\r\n * @param span - The span to create the telemetry item from\r\n * @returns A new extended telemetry item or null if the span kind is not supported\r\n */\r\nexport function createExtendedTelemetryItemFromSpan(core, span) {\r\n var telemetryItem = _createOTelSpanTelemetryItem(core, span);\r\n var container = span.attribContainer || createAttributeContainer(span[_DYN_ATTRIBUTES /* @min:%2eattributes */]);\r\n if (telemetryItem) {\r\n // Set the Span common schema fields\r\n // Set start time for the telemetry item from the event, not the time it is being processed (the default)\r\n // The channel envelope creator uses this value when creating the envelope only when defined, otherwise it\r\n // uses the time when the item is being processed\r\n var partB = telemetryItem[_DYN_BASE_DATA /* @min:%2ebaseData */] = telemetryItem[_DYN_BASE_DATA /* @min:%2ebaseData */] || {};\r\n partB[_DYN_START_TIME /* @min:%2estartTime */] = new Date(hrTimeToMilliseconds(span[_DYN_START_TIME /* @min:%2estartTime */]));\r\n var spanContext = span[_DYN_SPAN_CONTEXT /* @min:%2espanContext */]();\r\n if (spanContext) {\r\n // Add dt extension to the telemetry item\r\n var ext = telemetryItem.ext = telemetryItem.ext || {};\r\n var dt = ext[\"dt\"] = ext[\"dt\"] || {};\r\n // Don't overwrite any existing values\r\n _applyValue(dt, \"spanId\", spanContext[_DYN_SPAN_ID /* @min:%2espanId */], false);\r\n _applyValue(dt, \"traceId\", spanContext[_DYN_TRACE_ID /* @min:%2etraceId */], false);\r\n _applyValue(dt, \"traceFlags\", spanContext[_DYN_TRACE_FLAGS /* @min:%2etraceFlags */], false);\r\n }\r\n _populateExtensionsFromSpan(telemetryItem, span, container);\r\n _populatePartC(telemetryItem, container);\r\n // Azure SDK\r\n }\r\n return telemetryItem;\r\n}\r\n//# sourceMappingURL=extSpanUtils.js.map"],"names":[],"mappings":";;;;AAAA;AACkC;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA"}
1
+ {"version":3,"file":"extSpanUtils.js.map","sources":["extSpanUtils.js"],"sourcesContent":["// Copyright (c) Microsoft Corporation.\r\n// Licensed under the MIT License.\r\nimport { arrIncludes, asString, getLazy, getNavigator, isBoolean, isNullOrUndefined, isNumber, isString, strLower, strStartsWith, throwError } from \"@nevware21/ts-utils\";\r\nimport { _DYN_ATTRIBUTES, _DYN_BASE_DATA, _DYN_CONFIG, _DYN_DATA, _DYN_DURATION, _DYN_I_KEY, _DYN_KIND, _DYN_NAME, _DYN_PARENT_SPAN_CONTEXT, _DYN_SPAN_CONTEXT, _DYN_SPAN_ID, _DYN_START_TIME, _DYN_STATUS, _DYN_TRACE_FLAGS, _DYN_TRACE_ID, _DYN_TRACE_STATE, _DYN_USER_AGENT } from \"../__DynamicConstants\";\r\nimport { STR_NOT_SPECIFIED } from \"../constants/InternalConstants\";\r\nimport { getHttpClientIp, getHttpHost, getHttpMethod, getHttpScheme, getHttpStatusCode, getHttpUrl, getSyntheticType, getUserAgent } from \"../internal/commonUtils\";\r\nimport { hrTimeToMilliseconds } from \"../internal/timeHelpers\";\r\nimport { ATTR_CLIENT_ADDRESS, ATTR_CLIENT_PORT, ATTR_ENDUSER_ID, ATTR_ENDUSER_PSEUDO_ID, ATTR_ERROR_TYPE, ATTR_EXCEPTION_MESSAGE, ATTR_EXCEPTION_STACKTRACE, ATTR_EXCEPTION_TYPE, ATTR_HTTP_REQUEST_METHOD, ATTR_HTTP_RESPONSE_STATUS_CODE, ATTR_NETWORK_LOCAL_ADDRESS, ATTR_NETWORK_LOCAL_PORT, ATTR_NETWORK_PEER_ADDRESS, ATTR_NETWORK_PEER_PORT, ATTR_NETWORK_PROTOCOL_NAME, ATTR_NETWORK_PROTOCOL_VERSION, ATTR_NETWORK_TRANSPORT, ATTR_SERVER_ADDRESS, ATTR_SERVER_PORT, ATTR_URL_FULL, ATTR_URL_PATH, ATTR_URL_QUERY, ATTR_URL_SCHEME, ATTR_USER_AGENT_ORIGINAL, EXP_ATTR_ENDUSER_ID, EXP_ATTR_ENDUSER_PSEUDO_ID, EXP_ATTR_SYNTHETIC_TYPE, SEMATTRS_DB_NAME, SEMATTRS_DB_OPERATION, SEMATTRS_DB_STATEMENT, SEMATTRS_DB_SYSTEM, SEMATTRS_ENDUSER_ID, SEMATTRS_EXCEPTION_MESSAGE, SEMATTRS_EXCEPTION_STACKTRACE, SEMATTRS_EXCEPTION_TYPE, SEMATTRS_HTTP_CLIENT_IP, SEMATTRS_HTTP_FLAVOR, SEMATTRS_HTTP_HOST, SEMATTRS_HTTP_METHOD, SEMATTRS_HTTP_ROUTE, SEMATTRS_HTTP_SCHEME, SEMATTRS_HTTP_STATUS_CODE, SEMATTRS_HTTP_TARGET, SEMATTRS_HTTP_URL, SEMATTRS_HTTP_USER_AGENT, SEMATTRS_NET_HOST_IP, SEMATTRS_NET_HOST_NAME, SEMATTRS_NET_HOST_PORT, SEMATTRS_NET_PEER_IP, SEMATTRS_NET_PEER_NAME, SEMATTRS_NET_PEER_PORT, SEMATTRS_NET_TRANSPORT, SEMATTRS_PEER_SERVICE, SEMATTRS_RPC_GRPC_STATUS_CODE, SEMATTRS_RPC_SYSTEM } from \"../otel/attribute/SemanticConventions\";\r\nimport { createAttributeContainer } from \"../otel/attribute/attributeContainer\";\r\nimport { fieldRedaction } from \"../utils/EnvUtils\";\r\nimport { toISOString } from \"../utils/HelperFuncs\";\r\n/**\r\n * Azure SDK namespace.\r\n * @internal\r\n */\r\nvar AzNamespace = \"az.namespace\";\r\nvar AzResourceNamespace = \"azure.resource_provider.namespace\";\r\nvar PORT_REGEX = (/*#__PURE__*/getLazy(function () { return new RegExp(/(https?)(:\\/\\/.*)(:\\d+)(\\S*)/); }));\r\nvar HTTP_DOT = \"http.\";\r\nvar _MS_PROCESSED_BY_METRICS_EXTRACTORS = \"_MS.ProcessedByMetricExtractors\";\r\n/**\r\n * Legacy HTTP semantic convention values\r\n * @internal\r\n */\r\nvar _ignoreSemanticValues = (/*#__PURE__*/getLazy(_initIgnoreSemanticValues));\r\n/* #__NO_SIDE_EFFECTS__ */\r\nfunction _initIgnoreSemanticValues() {\r\n return [\r\n // Internal Microsoft attributes\r\n _MS_PROCESSED_BY_METRICS_EXTRACTORS,\r\n // Legacy HTTP semantic values\r\n SEMATTRS_NET_PEER_IP,\r\n SEMATTRS_NET_PEER_NAME,\r\n SEMATTRS_NET_HOST_IP,\r\n SEMATTRS_PEER_SERVICE,\r\n SEMATTRS_HTTP_USER_AGENT,\r\n SEMATTRS_HTTP_METHOD,\r\n SEMATTRS_HTTP_URL,\r\n SEMATTRS_HTTP_STATUS_CODE,\r\n SEMATTRS_HTTP_ROUTE,\r\n SEMATTRS_HTTP_HOST,\r\n SEMATTRS_DB_SYSTEM,\r\n SEMATTRS_DB_STATEMENT,\r\n SEMATTRS_DB_OPERATION,\r\n SEMATTRS_DB_NAME,\r\n SEMATTRS_RPC_SYSTEM,\r\n SEMATTRS_RPC_GRPC_STATUS_CODE,\r\n SEMATTRS_EXCEPTION_TYPE,\r\n SEMATTRS_EXCEPTION_MESSAGE,\r\n SEMATTRS_EXCEPTION_STACKTRACE,\r\n SEMATTRS_HTTP_SCHEME,\r\n SEMATTRS_HTTP_TARGET,\r\n SEMATTRS_HTTP_FLAVOR,\r\n SEMATTRS_NET_TRANSPORT,\r\n SEMATTRS_NET_HOST_NAME,\r\n SEMATTRS_NET_HOST_PORT,\r\n SEMATTRS_NET_PEER_PORT,\r\n SEMATTRS_HTTP_CLIENT_IP,\r\n SEMATTRS_ENDUSER_ID,\r\n HTTP_DOT + \"status_text\",\r\n // http Semabtic conventions\r\n ATTR_CLIENT_ADDRESS,\r\n ATTR_CLIENT_PORT,\r\n ATTR_SERVER_ADDRESS,\r\n ATTR_SERVER_PORT,\r\n ATTR_URL_FULL,\r\n ATTR_URL_PATH,\r\n ATTR_URL_QUERY,\r\n ATTR_URL_SCHEME,\r\n ATTR_ERROR_TYPE,\r\n ATTR_NETWORK_LOCAL_ADDRESS,\r\n ATTR_NETWORK_LOCAL_PORT,\r\n ATTR_NETWORK_PROTOCOL_NAME,\r\n ATTR_NETWORK_PEER_ADDRESS,\r\n ATTR_NETWORK_PEER_PORT,\r\n ATTR_NETWORK_PROTOCOL_VERSION,\r\n ATTR_NETWORK_TRANSPORT,\r\n ATTR_USER_AGENT_ORIGINAL,\r\n ATTR_HTTP_REQUEST_METHOD,\r\n ATTR_HTTP_RESPONSE_STATUS_CODE,\r\n ATTR_EXCEPTION_TYPE,\r\n ATTR_EXCEPTION_MESSAGE,\r\n ATTR_EXCEPTION_STACKTRACE,\r\n EXP_ATTR_ENDUSER_ID,\r\n EXP_ATTR_ENDUSER_PSEUDO_ID,\r\n EXP_ATTR_SYNTHETIC_TYPE,\r\n // Azure SDK attributes are not included as they are not part of the span attributes\r\n AzNamespace,\r\n AzResourceNamespace,\r\n \"az.client_request_id\",\r\n \"azure.client.id\",\r\n \"az.service_request_id\",\r\n \"azure.service.request.id\"\r\n ];\r\n}\r\nfunction _applyExtValue(ext, extName, name, value, overwriteExt) {\r\n if (isString(value) || isNumber(value) || isBoolean(value)) {\r\n var target = ext[extName] = ext[extName] || {};\r\n _applyValue(target, name, value, overwriteExt);\r\n }\r\n}\r\nfunction _applyValue(target, name, value, overwriteTarget) {\r\n if (target) {\r\n if (isString(value) || isNumber(value) || isBoolean(value)) {\r\n var targetValue = target[name];\r\n if (!overwriteTarget && (targetValue || isString(targetValue) || isNumber(targetValue) || isBoolean(targetValue))) {\r\n value = targetValue;\r\n }\r\n target[name] = value;\r\n }\r\n }\r\n return target;\r\n}\r\nfunction _populateExtensionsFromSpan(telemetryItem, span, container) {\r\n var ext = telemetryItem.ext = telemetryItem.ext || {};\r\n // Map OpenTelemetry enduser attributes to Application Insights user attributes\r\n var endUserId = container.get(ATTR_ENDUSER_ID);\r\n if (endUserId) {\r\n _applyExtValue(ext, \"user\", \"authId\", asString(endUserId), false);\r\n }\r\n var endUserPseudoId = container.get(ATTR_ENDUSER_PSEUDO_ID);\r\n if (endUserPseudoId) {\r\n _applyExtValue(ext, \"user\", \"id\", asString(endUserPseudoId), false);\r\n }\r\n}\r\n/**\r\n * Check to see if the key is in the list of known properties to ignore (exclude)\r\n * from part C properties population.\r\n * @param key - the property key to check\r\n * @param contextKeys - The current context keys\r\n * @returns true if the key should be ignored, false otherwise\r\n */\r\nfunction _isIgnorePartCKey(key) {\r\n var result = false;\r\n if (arrIncludes(_ignoreSemanticValues.v, key)) {\r\n // The key is in set of known keys to ignore\r\n result = true;\r\n }\r\n else if (strStartsWith(key, \"microsoft.\")) {\r\n // Ignoring all ALL keys starting with \"microsoft.\"\r\n result = true;\r\n }\r\n return result;\r\n}\r\nfunction _populatePartC(item, container) {\r\n if (container) {\r\n var partC_1 = item[_DYN_DATA /* @min:%2edata */] = (item[_DYN_DATA /* @min:%2edata */] || {});\r\n _applyValue(partC_1, \"httpHost\", getHttpHost(container), false);\r\n _applyValue(partC_1, \"httpScheme\", getHttpScheme(container), false);\r\n _applyValue(partC_1, \"httpClientIp\", getHttpClientIp(container), false);\r\n _applyValue(partC_1, \"httpUserAgent\", getUserAgent(container), false);\r\n _applyValue(partC_1, \"httpRoute\", container.get(SEMATTRS_HTTP_ROUTE), false);\r\n _applyValue(partC_1, \"netPeerName\", container.get(SEMATTRS_NET_PEER_NAME), false);\r\n _applyValue(partC_1, \"netPeerPort\", container.get(SEMATTRS_NET_PEER_PORT), false);\r\n _applyValue(partC_1, \"netPeerIp\", container.get(SEMATTRS_NET_PEER_IP), false);\r\n _applyValue(partC_1, \"peerService\", container.get(\"service.name\") || container.get(SEMATTRS_PEER_SERVICE), false);\r\n var syntheticSource = getSyntheticType(container);\r\n if (!!syntheticSource) {\r\n _applyValue(partC_1, \"userAgentSyntheticType\", syntheticSource, false);\r\n }\r\n var nav = getNavigator();\r\n if (nav && nav[_DYN_USER_AGENT /* @min:%2euserAgent */]) {\r\n _applyValue(partC_1, \"userAgentOriginal\", nav[_DYN_USER_AGENT /* @min:%2euserAgent */], false);\r\n }\r\n // Azure SDK fields\r\n _applyValue(partC_1, \"azureClientRequestId\", container.get(\"azure.client.id\") || container.get(\"az.client_request_id\"), false);\r\n _applyValue(partC_1, \"azureServiceRequestId\", container.get(\"azure.service.request.id\") || container.get(\"az.service_request_id\"), false);\r\n var sampleRate = container.get(\"microsoft.sample_rate\");\r\n if (!isNullOrUndefined(sampleRate)) {\r\n _applyValue(partC_1, \"sampleRate\", sampleRate, false);\r\n }\r\n container.forEach(function (key, value) {\r\n // Avoid duplication ignoring fields already mapped.\r\n if (!_isIgnorePartCKey(key)) {\r\n partC_1[key] = value;\r\n }\r\n });\r\n }\r\n}\r\nfunction _populateHttpProperties(otelSpanTelemetry, container, httpMethod, config) {\r\n if (httpMethod) {\r\n // Step the HTTP method\r\n _applyValue(otelSpanTelemetry, \"httpMethod\", httpMethod, false);\r\n // HTTP Dependency\r\n var httpUrl = getHttpUrl(container);\r\n if (httpUrl) {\r\n try {\r\n // Remove default port\r\n var res = PORT_REGEX.v.exec(asString(httpUrl));\r\n if (res !== null) {\r\n var protocol = res[1];\r\n var port = res[3];\r\n if ((protocol === \"https\" && port === \":443\") ||\r\n (protocol === \"http\" && port === \":80\")) {\r\n // Drop port\r\n httpUrl = res[1] + res[2] + res[4];\r\n }\r\n }\r\n }\r\n catch (_a) {\r\n /* no-op */\r\n }\r\n _applyValue(otelSpanTelemetry, \"httpUrl\", fieldRedaction(asString(httpUrl), config), false);\r\n }\r\n var httpStatusCode = getHttpStatusCode(container);\r\n if (httpStatusCode) {\r\n _applyValue(otelSpanTelemetry, \"httpStatusCode\", httpStatusCode, false);\r\n }\r\n }\r\n}\r\nfunction _populateDbProperties(otelSpanTelemetry, container, dbSystem) {\r\n if (dbSystem) {\r\n _applyValue(otelSpanTelemetry, \"dbSystem\", dbSystem, false);\r\n // Set the statement\r\n _applyValue(otelSpanTelemetry, \"dbStatement\", container.get(SEMATTRS_DB_STATEMENT) || container.get(SEMATTRS_DB_OPERATION), false);\r\n _applyValue(otelSpanTelemetry, \"dbName\", container.get(SEMATTRS_DB_NAME) || dbSystem || \"<undefined>\", false);\r\n }\r\n}\r\nfunction _populateRpcDependencyProperties(otelSpanTelemetry, container, rpcSystem) {\r\n if (rpcSystem) {\r\n _applyValue(otelSpanTelemetry, \"rpcSystem\", strLower(rpcSystem), false);\r\n _applyValue(otelSpanTelemetry, \"rpcGrpcStatusCode\", container.get(SEMATTRS_RPC_GRPC_STATUS_CODE), false);\r\n }\r\n}\r\nfunction _createOTelSpanTelemetryItem(core, span) {\r\n var container = span.attribContainer || createAttributeContainer(span[_DYN_ATTRIBUTES /* @min:%2eattributes */]);\r\n var spanCtx = span[_DYN_SPAN_CONTEXT /* @min:%2espanContext */]();\r\n var statusCode = span[_DYN_STATUS /* @min:%2estatus */] ? span[_DYN_STATUS /* @min:%2estatus */].code : 0 /* eOTelSpanStatusCode.UNSET */;\r\n var spanTelemetry = {\r\n name: span[_DYN_NAME /* @min:%2ename */],\r\n kind: span[_DYN_KIND /* @min:%2ekind */],\r\n startTime: toISOString(new Date(hrTimeToMilliseconds(span[_DYN_START_TIME /* @min:%2estartTime */]))),\r\n success: statusCode !== 0 /* eOTelSpanStatusCode.UNSET */ ? statusCode !== 2 /* eOTelSpanStatusCode.ERROR */ : (Number(getHttpStatusCode(container)) || 0) < 400,\r\n duration: hrTimeToMilliseconds(span[_DYN_DURATION /* @min:%2eduration */])\r\n //azureResourceProvider: undefined, // Not currently supported\r\n //links: UNDEFINED_VALUE, // Not currently supported\r\n };\r\n // Set the parentId if available\r\n var parentCtx = span[_DYN_PARENT_SPAN_CONTEXT /* @min:%2eparentSpanContext */] || (spanCtx ? spanCtx.parentCtx : null);\r\n _applyValue(spanTelemetry, \"parentId\", span.parentSpanId || (parentCtx ? parentCtx[_DYN_SPAN_ID /* @min:%2espanId */] : null), false);\r\n if (spanCtx) {\r\n var traceState = spanCtx[_DYN_TRACE_STATE /* @min:%2etraceState */];\r\n if (traceState && !traceState.isEmpty) {\r\n _applyValue(spanTelemetry, \"traceState\", traceState.hdrs(1)[0], false);\r\n }\r\n }\r\n _populateHttpProperties(spanTelemetry, container, getHttpMethod(container), core[_DYN_CONFIG /* @min:%2econfig */]);\r\n _populateDbProperties(spanTelemetry, container, container.get(SEMATTRS_DB_SYSTEM));\r\n _populateRpcDependencyProperties(spanTelemetry, container, container.get(SEMATTRS_RPC_SYSTEM));\r\n _applyValue(spanTelemetry, \"azureResourceProvider\", container.get(AzResourceNamespace) || container.get(AzNamespace), false);\r\n return _createTelemetryItem(spanTelemetry, span, \"OTelSpan\", \"Ms.Web.Span\");\r\n}\r\nfunction _createTelemetryItem(item, span, baseType, eventName) {\r\n eventName = eventName || STR_NOT_SPECIFIED;\r\n if (isNullOrUndefined(item) ||\r\n isNullOrUndefined(baseType) ||\r\n isNullOrUndefined(eventName)) {\r\n throwError(\"Input doesn't contain all required fields\");\r\n }\r\n var iKey = \"\";\r\n if (item[_DYN_I_KEY /* @min:%2eiKey */]) {\r\n iKey = item[_DYN_I_KEY /* @min:%2eiKey */];\r\n delete item[_DYN_I_KEY /* @min:%2eiKey */];\r\n }\r\n var telemetryItem = {\r\n name: eventName,\r\n time: toISOString(span.endTime ? new Date(hrTimeToMilliseconds(span.endTime)) : new Date()),\r\n iKey: iKey,\r\n ext: {},\r\n baseType: baseType,\r\n baseData: item,\r\n data: {} // part C\r\n };\r\n return telemetryItem;\r\n}\r\n/**\r\n * Create an extended common schema telemetry item from the provided span\r\n * @param core - The app insights core instance\r\n * @param span - The span to create the telemetry item from\r\n * @returns A new extended telemetry item or null if the span kind is not supported\r\n */\r\nexport function createExtendedTelemetryItemFromSpan(core, span) {\r\n var telemetryItem = _createOTelSpanTelemetryItem(core, span);\r\n var container = span.attribContainer || createAttributeContainer(span[_DYN_ATTRIBUTES /* @min:%2eattributes */]);\r\n if (telemetryItem) {\r\n // Set the Span common schema fields\r\n // Set start time for the telemetry item from the event, not the time it is being processed (the default)\r\n // The channel envelope creator uses this value when creating the envelope only when defined, otherwise it\r\n // uses the time when the item is being processed\r\n var partB = telemetryItem[_DYN_BASE_DATA /* @min:%2ebaseData */] = telemetryItem[_DYN_BASE_DATA /* @min:%2ebaseData */] || {};\r\n partB[_DYN_START_TIME /* @min:%2estartTime */] = new Date(hrTimeToMilliseconds(span[_DYN_START_TIME /* @min:%2estartTime */]));\r\n var spanContext = span[_DYN_SPAN_CONTEXT /* @min:%2espanContext */]();\r\n if (spanContext) {\r\n // Add dt extension to the telemetry item\r\n var ext = telemetryItem.ext = telemetryItem.ext || {};\r\n var dt = ext[\"dt\"] = ext[\"dt\"] || {};\r\n // Don't overwrite any existing values\r\n _applyValue(dt, \"spanId\", spanContext[_DYN_SPAN_ID /* @min:%2espanId */], false);\r\n _applyValue(dt, \"traceId\", spanContext[_DYN_TRACE_ID /* @min:%2etraceId */], false);\r\n _applyValue(dt, \"traceFlags\", spanContext[_DYN_TRACE_FLAGS /* @min:%2etraceFlags */], false);\r\n }\r\n _populateExtensionsFromSpan(telemetryItem, span, container);\r\n _populatePartC(telemetryItem, container);\r\n // Azure SDK\r\n }\r\n return telemetryItem;\r\n}\r\n//# sourceMappingURL=extSpanUtils.js.map"],"names":[],"mappings":";;;;AAAA;AACkC;AAClC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA"}
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  var _a;
@@ -17,7 +17,7 @@ import { isReactNative } from "../utils/EnvUtils";
17
17
  /**
18
18
  * Identifies the version for the extended SDK
19
19
  */
20
- export var ExtVersion = '4.4.2-nightly3.2606-02';
20
+ export var ExtVersion = '4.4.2';
21
21
  /**
22
22
  * Identifies the full version for the extended SDK
23
23
  */
@@ -51,16 +51,16 @@ var _fieldTypeEventPropMap = (_a = {},
51
51
  * @ignore
52
52
  */
53
53
  // let _uaDisallowsSameSiteNone = null;
54
- var uInt8ArraySupported = ( /* #__PURE__*/null);
54
+ var uInt8ArraySupported = (/*#__PURE__*/null);
55
55
  // var _areCookiesAvailable: boolean | undefined;
56
56
  /**
57
57
  * Checks if document object is available
58
58
  */
59
- export var isDocumentObjectAvailable = ( /* #__PURE__*/hasDocument());
59
+ export var isDocumentObjectAvailable = (/*#__PURE__*/hasDocument());
60
60
  /**
61
61
  * Checks if window object is available
62
62
  */
63
- export var isWindowObjectAvailable = ( /* #__PURE__*/hasWindow());
63
+ export var isWindowObjectAvailable = (/*#__PURE__*/hasWindow());
64
64
  /**
65
65
  * Checks if value is assigned to the given param.
66
66
  * @param value - The token from which the tenant id is to be extracted.
@@ -1 +1 @@
1
- {"version":3,"file":"extUtils.js.map","sources":["extUtils.js"],"sourcesContent":["var _a;\r\n/**\r\n* Utils.ts\r\n* @author Abhilash Panwar (abpanwar) Hector Hernandez (hectorh)\r\n* @copyright Microsoft 2018\r\n* File containing utility functions.\r\n*/\r\nimport { arrForEach, getInst as getGlobalInst, getNavigator, hasDocument, hasWindow, isArray, isBoolean, isNullOrUndefined, isNumber, isObject, isString, isUndefined, isUnsafePropKey, objForEachKey, perfNow, strIndexOf, strLeft } from \"@nevware21/ts-utils\";\r\nimport { _DYN_CALL, _DYN_HAS_OWN_PROPERTY, _DYN_INDEX_OF, _DYN_KIND, _DYN_LENGTH, _DYN_PROCESS_TELEMETRY_ST6, _DYN_REPLACE, _DYN_STRINGIFY, _DYN_TIMINGS, _DYN_TO_LOWER_CASE, _DYN_TO_STRING, _DYN_USER_AGENT, _DYN_VALUE } from \"../__DynamicConstants\";\r\nimport { STR_EMPTY } from \"../constants/InternalConstants\";\r\nimport { newGuid } from \"../utils/CoreUtils\";\r\nimport { isReactNative } from \"../utils/EnvUtils\";\r\n/**\r\n * Identifies the version for the extended SDK\r\n */\r\nexport var ExtVersion = '4.4.2-nightly3.2606-02';\r\n/**\r\n * Identifies the full version for the extended SDK\r\n */\r\nexport var ExtFullVersionString = \"1DS-Web-JS-\" + ExtVersion;\r\n/**\r\n * Identifies the version for the extended SDK (legacy constant)\r\n * @deprecated Use {@link ExtVersion} instead\r\n */\r\nexport var Version = ExtVersion;\r\n/**\r\n * Identifies the full version for the extended SDK (legacy constant)\r\n * @deprecated Use {@link ExtFullVersionString} instead\r\n */\r\nexport var FullVersionString = ExtFullVersionString;\r\nvar ObjHasOwnProperty = Object.prototype[_DYN_HAS_OWN_PROPERTY /* @min:%2ehasOwnProperty */];\r\n// Defining here so we don't need to take (import) the ApplicationInsights Common module\r\nvar strDisabledPropertyName = \"Microsoft_ApplicationInsights_BypassAjaxInstrumentation\";\r\nvar strWithCredentials = \"withCredentials\";\r\nvar strTimeout = \"timeout\";\r\n// If value is array just get the type for the first element\r\nvar _fieldTypeEventPropMap = (_a = {},\r\n _a[0 /* FieldValueSanitizerType.NotSet */] = 0 /* eEventPropertyType.Unspecified */,\r\n _a[2 /* FieldValueSanitizerType.Number */] = 6 /* eEventPropertyType.Double */,\r\n _a[1 /* FieldValueSanitizerType.String */] = 1 /* eEventPropertyType.String */,\r\n _a[3 /* FieldValueSanitizerType.Boolean */] = 7 /* eEventPropertyType.Bool */,\r\n _a[4096 /* FieldValueSanitizerType.Array */ | 2 /* FieldValueSanitizerType.Number */] = 6 /* eEventPropertyType.Double */,\r\n _a[4096 /* FieldValueSanitizerType.Array */ | 1 /* FieldValueSanitizerType.String */] = 1 /* eEventPropertyType.String */,\r\n _a[4096 /* FieldValueSanitizerType.Array */ | 3 /* FieldValueSanitizerType.Boolean */] = 7 /* eEventPropertyType.Bool */,\r\n _a);\r\n/**\r\n * @ignore\r\n */\r\n// let _uaDisallowsSameSiteNone = null;\r\nvar uInt8ArraySupported = ( /* #__PURE__*/null);\r\n// var _areCookiesAvailable: boolean | undefined;\r\n/**\r\n * Checks if document object is available\r\n */\r\nexport var isDocumentObjectAvailable = ( /* #__PURE__*/hasDocument());\r\n/**\r\n * Checks if window object is available\r\n */\r\nexport var isWindowObjectAvailable = ( /* #__PURE__*/hasWindow());\r\n/**\r\n * Checks if value is assigned to the given param.\r\n * @param value - The token from which the tenant id is to be extracted.\r\n * @returns True/false denoting if value is assigned to the param.\r\n */\r\nexport function isValueAssigned(value) {\r\n /// <summary> takes a value and checks for undefined, null and empty string </summary>\r\n /// <param type=\"any\"> value to be tested </param>\r\n /// <returns> true if value is null undefined or emptyString </returns>\r\n return !(value === STR_EMPTY || isNullOrUndefined(value));\r\n}\r\n/**\r\n * Gets the tenant id from the tenant token.\r\n * @param apiKey - The token from which the tenant id is to be extracted.\r\n * @returns The tenant id.\r\n */\r\nexport function getTenantId(apiKey) {\r\n if (apiKey) {\r\n var indexTenantId = strIndexOf(apiKey, \"-\");\r\n if (indexTenantId > -1) {\r\n return strLeft(apiKey, indexTenantId);\r\n }\r\n }\r\n return STR_EMPTY;\r\n}\r\n/**\r\n * Checks if Uint8Array are available in the current environment. Safari and Firefox along with\r\n * ReactNative are known to not support Uint8Array properly.\r\n * @returns True if available, false otherwise.\r\n */\r\nexport function isUint8ArrayAvailable() {\r\n if (uInt8ArraySupported === null) {\r\n uInt8ArraySupported = !isUndefined(Uint8Array) && !isSafariOrFirefox() && !isReactNative();\r\n }\r\n return uInt8ArraySupported;\r\n}\r\n/**\r\n * Checks if the value is a valid EventLatency.\r\n * @param value - The value that needs to be checked.\r\n * @returns True if the value is in AWTEventLatency, false otherwise.\r\n */\r\nexport function isLatency(value) {\r\n if (value && isNumber(value) && value >= 1 /* EventLatencyValue.Normal */ && value <= 4 /* EventLatencyValue.Immediate */) {\r\n return true;\r\n }\r\n return false;\r\n}\r\n/**\r\n * Sanitizes the Property. It checks the that the property name and value are valid. It also\r\n * checks/populates the correct type and pii of the property value.\r\n * @param name - property name - The property name.\r\n * @param property - The property value or an IEventProperty containing value,\r\n * type ,pii and customer content.\r\n * @returns IEventProperty containing valid name, value, pii and type or null if invalid.\r\n */\r\nexport function sanitizeProperty(name, property, stringifyObjects) {\r\n // Check that property is valid\r\n if ((!property && !isValueAssigned(property)) || typeof name !== \"string\") {\r\n return null;\r\n }\r\n // Perf optimization -- only need to get the type once not multiple times\r\n var propType = typeof property;\r\n // If the property isn't IEventProperty (and is either string, number, boolean or array), convert it into one.\r\n if (propType === \"string\" || propType === \"number\" || propType === \"boolean\" || isArray(property)) {\r\n property = { value: property };\r\n }\r\n else if (propType === \"object\" && !ObjHasOwnProperty[_DYN_CALL /* @min:%2ecall */](property, \"value\")) {\r\n property = { value: stringifyObjects ? JSON[_DYN_STRINGIFY /* @min:%2estringify */](property) : property };\r\n }\r\n else if (isNullOrUndefined(property[_DYN_VALUE /* @min:%2evalue */])\r\n || property[_DYN_VALUE /* @min:%2evalue */] === STR_EMPTY || (!isString(property[_DYN_VALUE /* @min:%2evalue */])\r\n && !isNumber(property[_DYN_VALUE /* @min:%2evalue */]) && !isBoolean(property[_DYN_VALUE /* @min:%2evalue */])\r\n && !isArray(property[_DYN_VALUE /* @min:%2evalue */]))) {\r\n // Since property is IEventProperty, we need to validate its value\r\n return null;\r\n }\r\n // We need to check that if the property value is an array, it is valid\r\n if (isArray(property[_DYN_VALUE /* @min:%2evalue */]) &&\r\n !isArrayValid(property[_DYN_VALUE /* @min:%2evalue */])) {\r\n return null;\r\n }\r\n // If either pii or cc is set convert value to string (since only string pii/cc is allowed).\r\n // If the value is a complex type like an array that can't be converted to string we will drop\r\n // the property.\r\n if (!isNullOrUndefined(property[_DYN_KIND /* @min:%2ekind */])) {\r\n if (isArray(property[_DYN_VALUE /* @min:%2evalue */]) || !isValueKind(property[_DYN_KIND /* @min:%2ekind */])) {\r\n return null;\r\n }\r\n property[_DYN_VALUE /* @min:%2evalue */] = property[_DYN_VALUE /* @min:%2evalue */][_DYN_TO_STRING /* @min:%2etoString */]();\r\n }\r\n return property;\r\n}\r\nexport function getCommonSchemaMetaData(value, kind, type) {\r\n var encodedTypeValue = -1;\r\n if (!isUndefined(value)) {\r\n if (kind > 0) {\r\n if (kind === 32 /* eValueKind.CustomerContent_GenericContent */) {\r\n // encode customer content. Value can only be string. bit 13-16 are for cc\r\n encodedTypeValue = (1 << 13);\r\n }\r\n else if (kind <= 13) {\r\n // encode PII. Value can only be string. bits 5-12 are for Pii\r\n encodedTypeValue = (kind << 5);\r\n }\r\n }\r\n // isDataType checks that the \"type\" is a number so we don't need to check for undefined\r\n if (isDataType(type)) {\r\n // Data Type is provided and valid, so use that\r\n if (encodedTypeValue === -1) {\r\n // Don't return -1\r\n encodedTypeValue = 0;\r\n }\r\n encodedTypeValue |= type;\r\n }\r\n else {\r\n var propType = _fieldTypeEventPropMap[getFieldValueType(value)] || -1;\r\n if (encodedTypeValue !== -1 && propType !== -1) {\r\n // pii exists so we must return correct type\r\n encodedTypeValue |= propType;\r\n }\r\n else if (propType === 6 /* eEventPropertyType.Double */) {\r\n encodedTypeValue = propType;\r\n }\r\n }\r\n }\r\n return encodedTypeValue;\r\n}\r\n/**\r\n * Helper to get and decode the cookie value using decodeURIComponent, this is for historical\r\n * backward compatibility where the document.cookie value was decoded before parsing.\r\n * @param cookieMgr - The cookie manager to use\r\n * @param name - The name of the cookie to get\r\n * @param decode - A flag to indicate whether the cookie value should be decoded\r\n * @returns The decoded cookie value (if available) otherwise an empty string.\r\n */\r\nexport function getCookieValue(cookieMgr, name, decode) {\r\n if (decode === void 0) { decode = true; }\r\n var cookieValue;\r\n if (cookieMgr) {\r\n cookieValue = cookieMgr.get(name);\r\n if (decode && cookieValue && decodeURIComponent) {\r\n cookieValue = decodeURIComponent(cookieValue);\r\n }\r\n }\r\n return cookieValue || STR_EMPTY;\r\n}\r\n/**\r\n * Create a new guid.\r\n * @param style - The style of guid to generated, defaults to Digits\r\n * Digits (Default) : 32 digits separated by hyphens: 00000000-0000-0000-0000-000000000000\r\n * Braces - 32 digits separated by hyphens, enclosed in braces: \\{00000000-0000-0000-0000-000000000000\\}\r\n * Parentheses - 32 digits separated by hyphens, enclosed in parentheses: (00000000-0000-0000-0000-000000000000)\r\n * Numeric - 32 digits: 00000000000000000000000000000000\r\n */\r\nexport function createGuid(style) {\r\n if (style === void 0) { style = \"D\" /* GuidStyle.Digits */; }\r\n var theGuid = newGuid();\r\n if (style === \"B\" /* GuidStyle.Braces */) {\r\n theGuid = \"{\" + theGuid + \"}\";\r\n }\r\n else if (style === \"P\" /* GuidStyle.Parentheses */) {\r\n theGuid = \"(\" + theGuid + \")\";\r\n }\r\n else if (style === \"N\" /* GuidStyle.Numeric */) {\r\n theGuid = theGuid[_DYN_REPLACE /* @min:%2ereplace */](/-/g, STR_EMPTY);\r\n }\r\n return theGuid;\r\n}\r\n/**\r\n * Pass in the objects to merge as arguments.\r\n * @param obj1 - object to merge. Set this argument to 'true' for a deep extend.\r\n * @param obj2 - object to merge.\r\n * @param obj3 - object to merge.\r\n * @param obj4 - object to merge.\r\n * @param obj5 - object to merge.\r\n * @returns The extended object.\r\n */\r\nexport function extend(obj, obj2, obj3, obj4, obj5) {\r\n // Variables\r\n var extended = {};\r\n var deep = false;\r\n var i = 0;\r\n var length = arguments[_DYN_LENGTH /* @min:%2elength */];\r\n var theArgs = arguments;\r\n // Check if a deep merge\r\n if (isBoolean(theArgs[0])) {\r\n deep = theArgs[0];\r\n i++;\r\n }\r\n // Loop through each object and conduct a merge\r\n for (; i < length; i++) {\r\n var obj = theArgs[i];\r\n objForEachKey(obj, function (prop, value) {\r\n // Prevent prototype pollution by skipping unsafe keys\r\n if (isUnsafePropKey(prop)) {\r\n return;\r\n }\r\n // If deep merge and property is an object, merge properties\r\n if (deep && value && isObject(value)) {\r\n if (isArray(value)) {\r\n extended[prop] = extended[prop] || [];\r\n arrForEach(value, function (arrayValue, arrayIndex) {\r\n if (arrayValue && isObject(arrayValue)) {\r\n extended[prop][arrayIndex] = extend(true, extended[prop][arrayIndex], arrayValue);\r\n }\r\n else {\r\n extended[prop][arrayIndex] = arrayValue;\r\n }\r\n });\r\n }\r\n else {\r\n extended[prop] = extend(true, extended[prop], value);\r\n }\r\n }\r\n else {\r\n extended[prop] = value;\r\n }\r\n });\r\n }\r\n return extended;\r\n}\r\nexport var getTime = perfNow;\r\nexport function isValueKind(value) {\r\n // Always assume that it's a number (no type checking) for performance as this is used during the JSON serialization\r\n if (value === 0 /* eValueKind.NotSet */ || ((value > 0 /* eValueKind.NotSet */ && value <= 13 /* eValueKind.Pii_IPV4AddressLegacy */) || value === 32 /* eValueKind.CustomerContent_GenericContent */)) {\r\n return true;\r\n }\r\n return false;\r\n}\r\nfunction isDataType(value) {\r\n // Remark: 0 returns false, but it doesn't affect encoding anyways\r\n // Always assume that it's a number (no type checking) for performance as this is used during the JSON serialization\r\n if (value >= 0 && value <= 9) {\r\n return true;\r\n }\r\n return false;\r\n}\r\nfunction isSafariOrFirefox() {\r\n var nav = getNavigator();\r\n // If non-browser navigator will be undefined\r\n if (!isUndefined(nav) && nav[_DYN_USER_AGENT /* @min:%2euserAgent */]) {\r\n var ua = nav.userAgent[_DYN_TO_LOWER_CASE /* @min:%2etoLowerCase */]();\r\n if ((ua[_DYN_INDEX_OF /* @min:%2eindexOf */](\"safari\") >= 0 || ua[_DYN_INDEX_OF /* @min:%2eindexOf */](\"firefox\") >= 0) && ua[_DYN_INDEX_OF /* @min:%2eindexOf */](\"chrome\") < 0) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n}\r\nexport function isArrayValid(value) {\r\n return value[_DYN_LENGTH /* @min:%2elength */] > 0;\r\n}\r\nexport function setProcessTelemetryTimings(event, identifier) {\r\n var evt = event;\r\n evt[_DYN_TIMINGS /* @min:%2etimings */] = evt[_DYN_TIMINGS /* @min:%2etimings */] || {};\r\n evt[_DYN_TIMINGS /* @min:%2etimings */][_DYN_PROCESS_TELEMETRY_ST6 /* @min:%2eprocessTelemetryStart */] = evt[_DYN_TIMINGS /* @min:%2etimings */][_DYN_PROCESS_TELEMETRY_ST6 /* @min:%2eprocessTelemetryStart */] || {};\r\n evt[_DYN_TIMINGS /* @min:%2etimings */][_DYN_PROCESS_TELEMETRY_ST6 /* @min:%2eprocessTelemetryStart */][identifier] = getTime();\r\n}\r\n/**\r\n * Returns a bitwise value for the FieldValueSanitizerType enum representing the decoded type of the passed value\r\n * @param value - The value to determine the type\r\n */\r\nexport function getFieldValueType(value) {\r\n var theType = 0 /* FieldValueSanitizerType.NotSet */;\r\n if (value !== null && value !== undefined) {\r\n var objType = typeof value;\r\n if (objType === \"string\") {\r\n theType = 1 /* FieldValueSanitizerType.String */;\r\n }\r\n else if (objType === \"number\") {\r\n theType = 2 /* FieldValueSanitizerType.Number */;\r\n }\r\n else if (objType === \"boolean\") {\r\n theType = 3 /* FieldValueSanitizerType.Boolean */;\r\n }\r\n else if (objType === \"object\") {\r\n theType = 4 /* FieldValueSanitizerType.Object */;\r\n if (isArray(value)) {\r\n theType = 4096 /* FieldValueSanitizerType.Array */;\r\n if (value[_DYN_LENGTH /* @min:%2elength */] > 0) {\r\n // Empty arrays are not supported and are considered to be the same as null\r\n theType |= getFieldValueType(value[0]);\r\n }\r\n }\r\n else if (ObjHasOwnProperty[_DYN_CALL /* @min:%2ecall */](value, \"value\")) {\r\n // Looks like an IEventProperty\r\n theType = 8192 /* FieldValueSanitizerType.EventProperty */ | getFieldValueType(value[_DYN_VALUE /* @min:%2evalue */]);\r\n }\r\n }\r\n }\r\n return theType;\r\n}\r\n/**\r\n * Helper to identify whether we are running in a chromium based browser environment\r\n */\r\nexport function isChromium() {\r\n return !!getGlobalInst(\"chrome\");\r\n}\r\n/**\r\n * Create and open an XMLHttpRequest object\r\n * @param method - The request method\r\n * @param urlString - The url\r\n * @param withCredentials - Option flag indicating that credentials should be sent\r\n * @param disabled - Optional flag indicating that the XHR object should be marked as disabled and not tracked (default is false)\r\n * @param isSync - Optional flag indicating if the instance should be a synchronous request (defaults to false)\r\n * @param timeout - Optional value identifying the timeout value that should be assigned to the XHR request\r\n * @returns A new opened XHR request\r\n */\r\nexport function openXhr(method, urlString, withCredentials, disabled, isSync, timeout) {\r\n if (disabled === void 0) { disabled = false; }\r\n if (isSync === void 0) { isSync = false; }\r\n function _wrapSetXhrProp(xhr, prop, value) {\r\n try {\r\n xhr[prop] = value;\r\n }\r\n catch (e) {\r\n // - Wrapping as depending on the environment setting the property may fail (non-terminally)\r\n }\r\n }\r\n var xhr = new XMLHttpRequest();\r\n if (disabled) {\r\n // Tag the instance so it's not tracked (trackDependency)\r\n // If the environment has locked down the XMLHttpRequest (preventExtensions and/or freeze), this would\r\n // cause the request to fail and we no telemetry would be sent\r\n _wrapSetXhrProp(xhr, strDisabledPropertyName, disabled);\r\n }\r\n if (withCredentials) {\r\n // Some libraries require that the withCredentials flag is set \"before\" open and\r\n // - Wrapping as IE 10 has started throwing when setting before open\r\n _wrapSetXhrProp(xhr, strWithCredentials, withCredentials);\r\n }\r\n xhr.open(method, urlString, !isSync);\r\n if (withCredentials) {\r\n // withCredentials should be set AFTER open (https://xhr.spec.whatwg.org/#the-withcredentials-attribute)\r\n // And older firefox instances from 11+ will throw for sync events (current versions don't) which happens during unload processing\r\n _wrapSetXhrProp(xhr, strWithCredentials, withCredentials);\r\n }\r\n // Only set the timeout for asynchronous requests as\r\n // \"Timeout shouldn't be used for synchronous XMLHttpRequests requests used in a document environment or it will throw an InvalidAccessError exception.\"\"\r\n // https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/timeout\r\n if (!isSync && timeout) {\r\n _wrapSetXhrProp(xhr, strTimeout, timeout);\r\n }\r\n return xhr;\r\n}\r\n/**\r\n * Check to see if the value is \\> 0\r\n * @param value - The value to check\r\n * @returns true if \\> 0 otherwise false\r\n */\r\nexport function isGreaterThanZero(value) {\r\n return value > 0;\r\n}\r\n//# sourceMappingURL=extUtils.js.map"],"names":[],"mappings":";;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA"}
1
+ {"version":3,"file":"extUtils.js.map","sources":["extUtils.js"],"sourcesContent":["var _a;\r\n/**\r\n* Utils.ts\r\n* @author Abhilash Panwar (abpanwar) Hector Hernandez (hectorh)\r\n* @copyright Microsoft 2018\r\n* File containing utility functions.\r\n*/\r\nimport { arrForEach, getInst as getGlobalInst, getNavigator, hasDocument, hasWindow, isArray, isBoolean, isNullOrUndefined, isNumber, isObject, isString, isUndefined, isUnsafePropKey, objForEachKey, perfNow, strIndexOf, strLeft } from \"@nevware21/ts-utils\";\r\nimport { _DYN_CALL, _DYN_HAS_OWN_PROPERTY, _DYN_INDEX_OF, _DYN_KIND, _DYN_LENGTH, _DYN_PROCESS_TELEMETRY_ST6, _DYN_REPLACE, _DYN_STRINGIFY, _DYN_TIMINGS, _DYN_TO_LOWER_CASE, _DYN_TO_STRING, _DYN_USER_AGENT, _DYN_VALUE } from \"../__DynamicConstants\";\r\nimport { STR_EMPTY } from \"../constants/InternalConstants\";\r\nimport { newGuid } from \"../utils/CoreUtils\";\r\nimport { isReactNative } from \"../utils/EnvUtils\";\r\n/**\r\n * Identifies the version for the extended SDK\r\n */\r\nexport var ExtVersion = '4.4.2';\r\n/**\r\n * Identifies the full version for the extended SDK\r\n */\r\nexport var ExtFullVersionString = \"1DS-Web-JS-\" + ExtVersion;\r\n/**\r\n * Identifies the version for the extended SDK (legacy constant)\r\n * @deprecated Use {@link ExtVersion} instead\r\n */\r\nexport var Version = ExtVersion;\r\n/**\r\n * Identifies the full version for the extended SDK (legacy constant)\r\n * @deprecated Use {@link ExtFullVersionString} instead\r\n */\r\nexport var FullVersionString = ExtFullVersionString;\r\nvar ObjHasOwnProperty = Object.prototype[_DYN_HAS_OWN_PROPERTY /* @min:%2ehasOwnProperty */];\r\n// Defining here so we don't need to take (import) the ApplicationInsights Common module\r\nvar strDisabledPropertyName = \"Microsoft_ApplicationInsights_BypassAjaxInstrumentation\";\r\nvar strWithCredentials = \"withCredentials\";\r\nvar strTimeout = \"timeout\";\r\n// If value is array just get the type for the first element\r\nvar _fieldTypeEventPropMap = (_a = {},\r\n _a[0 /* FieldValueSanitizerType.NotSet */] = 0 /* eEventPropertyType.Unspecified */,\r\n _a[2 /* FieldValueSanitizerType.Number */] = 6 /* eEventPropertyType.Double */,\r\n _a[1 /* FieldValueSanitizerType.String */] = 1 /* eEventPropertyType.String */,\r\n _a[3 /* FieldValueSanitizerType.Boolean */] = 7 /* eEventPropertyType.Bool */,\r\n _a[4096 /* FieldValueSanitizerType.Array */ | 2 /* FieldValueSanitizerType.Number */] = 6 /* eEventPropertyType.Double */,\r\n _a[4096 /* FieldValueSanitizerType.Array */ | 1 /* FieldValueSanitizerType.String */] = 1 /* eEventPropertyType.String */,\r\n _a[4096 /* FieldValueSanitizerType.Array */ | 3 /* FieldValueSanitizerType.Boolean */] = 7 /* eEventPropertyType.Bool */,\r\n _a);\r\n/**\r\n * @ignore\r\n */\r\n// let _uaDisallowsSameSiteNone = null;\r\nvar uInt8ArraySupported = (/*#__PURE__*/null);\r\n// var _areCookiesAvailable: boolean | undefined;\r\n/**\r\n * Checks if document object is available\r\n */\r\nexport var isDocumentObjectAvailable = (/*#__PURE__*/hasDocument());\r\n/**\r\n * Checks if window object is available\r\n */\r\nexport var isWindowObjectAvailable = (/*#__PURE__*/hasWindow());\r\n/**\r\n * Checks if value is assigned to the given param.\r\n * @param value - The token from which the tenant id is to be extracted.\r\n * @returns True/false denoting if value is assigned to the param.\r\n */\r\nexport function isValueAssigned(value) {\r\n /// <summary> takes a value and checks for undefined, null and empty string </summary>\r\n /// <param type=\"any\"> value to be tested </param>\r\n /// <returns> true if value is null undefined or emptyString </returns>\r\n return !(value === STR_EMPTY || isNullOrUndefined(value));\r\n}\r\n/**\r\n * Gets the tenant id from the tenant token.\r\n * @param apiKey - The token from which the tenant id is to be extracted.\r\n * @returns The tenant id.\r\n */\r\nexport function getTenantId(apiKey) {\r\n if (apiKey) {\r\n var indexTenantId = strIndexOf(apiKey, \"-\");\r\n if (indexTenantId > -1) {\r\n return strLeft(apiKey, indexTenantId);\r\n }\r\n }\r\n return STR_EMPTY;\r\n}\r\n/**\r\n * Checks if Uint8Array are available in the current environment. Safari and Firefox along with\r\n * ReactNative are known to not support Uint8Array properly.\r\n * @returns True if available, false otherwise.\r\n */\r\nexport function isUint8ArrayAvailable() {\r\n if (uInt8ArraySupported === null) {\r\n uInt8ArraySupported = !isUndefined(Uint8Array) && !isSafariOrFirefox() && !isReactNative();\r\n }\r\n return uInt8ArraySupported;\r\n}\r\n/**\r\n * Checks if the value is a valid EventLatency.\r\n * @param value - The value that needs to be checked.\r\n * @returns True if the value is in AWTEventLatency, false otherwise.\r\n */\r\nexport function isLatency(value) {\r\n if (value && isNumber(value) && value >= 1 /* EventLatencyValue.Normal */ && value <= 4 /* EventLatencyValue.Immediate */) {\r\n return true;\r\n }\r\n return false;\r\n}\r\n/**\r\n * Sanitizes the Property. It checks the that the property name and value are valid. It also\r\n * checks/populates the correct type and pii of the property value.\r\n * @param name - property name - The property name.\r\n * @param property - The property value or an IEventProperty containing value,\r\n * type ,pii and customer content.\r\n * @returns IEventProperty containing valid name, value, pii and type or null if invalid.\r\n */\r\nexport function sanitizeProperty(name, property, stringifyObjects) {\r\n // Check that property is valid\r\n if ((!property && !isValueAssigned(property)) || typeof name !== \"string\") {\r\n return null;\r\n }\r\n // Perf optimization -- only need to get the type once not multiple times\r\n var propType = typeof property;\r\n // If the property isn't IEventProperty (and is either string, number, boolean or array), convert it into one.\r\n if (propType === \"string\" || propType === \"number\" || propType === \"boolean\" || isArray(property)) {\r\n property = { value: property };\r\n }\r\n else if (propType === \"object\" && !ObjHasOwnProperty[_DYN_CALL /* @min:%2ecall */](property, \"value\")) {\r\n property = { value: stringifyObjects ? JSON[_DYN_STRINGIFY /* @min:%2estringify */](property) : property };\r\n }\r\n else if (isNullOrUndefined(property[_DYN_VALUE /* @min:%2evalue */])\r\n || property[_DYN_VALUE /* @min:%2evalue */] === STR_EMPTY || (!isString(property[_DYN_VALUE /* @min:%2evalue */])\r\n && !isNumber(property[_DYN_VALUE /* @min:%2evalue */]) && !isBoolean(property[_DYN_VALUE /* @min:%2evalue */])\r\n && !isArray(property[_DYN_VALUE /* @min:%2evalue */]))) {\r\n // Since property is IEventProperty, we need to validate its value\r\n return null;\r\n }\r\n // We need to check that if the property value is an array, it is valid\r\n if (isArray(property[_DYN_VALUE /* @min:%2evalue */]) &&\r\n !isArrayValid(property[_DYN_VALUE /* @min:%2evalue */])) {\r\n return null;\r\n }\r\n // If either pii or cc is set convert value to string (since only string pii/cc is allowed).\r\n // If the value is a complex type like an array that can't be converted to string we will drop\r\n // the property.\r\n if (!isNullOrUndefined(property[_DYN_KIND /* @min:%2ekind */])) {\r\n if (isArray(property[_DYN_VALUE /* @min:%2evalue */]) || !isValueKind(property[_DYN_KIND /* @min:%2ekind */])) {\r\n return null;\r\n }\r\n property[_DYN_VALUE /* @min:%2evalue */] = property[_DYN_VALUE /* @min:%2evalue */][_DYN_TO_STRING /* @min:%2etoString */]();\r\n }\r\n return property;\r\n}\r\nexport function getCommonSchemaMetaData(value, kind, type) {\r\n var encodedTypeValue = -1;\r\n if (!isUndefined(value)) {\r\n if (kind > 0) {\r\n if (kind === 32 /* eValueKind.CustomerContent_GenericContent */) {\r\n // encode customer content. Value can only be string. bit 13-16 are for cc\r\n encodedTypeValue = (1 << 13);\r\n }\r\n else if (kind <= 13) {\r\n // encode PII. Value can only be string. bits 5-12 are for Pii\r\n encodedTypeValue = (kind << 5);\r\n }\r\n }\r\n // isDataType checks that the \"type\" is a number so we don't need to check for undefined\r\n if (isDataType(type)) {\r\n // Data Type is provided and valid, so use that\r\n if (encodedTypeValue === -1) {\r\n // Don't return -1\r\n encodedTypeValue = 0;\r\n }\r\n encodedTypeValue |= type;\r\n }\r\n else {\r\n var propType = _fieldTypeEventPropMap[getFieldValueType(value)] || -1;\r\n if (encodedTypeValue !== -1 && propType !== -1) {\r\n // pii exists so we must return correct type\r\n encodedTypeValue |= propType;\r\n }\r\n else if (propType === 6 /* eEventPropertyType.Double */) {\r\n encodedTypeValue = propType;\r\n }\r\n }\r\n }\r\n return encodedTypeValue;\r\n}\r\n/**\r\n * Helper to get and decode the cookie value using decodeURIComponent, this is for historical\r\n * backward compatibility where the document.cookie value was decoded before parsing.\r\n * @param cookieMgr - The cookie manager to use\r\n * @param name - The name of the cookie to get\r\n * @param decode - A flag to indicate whether the cookie value should be decoded\r\n * @returns The decoded cookie value (if available) otherwise an empty string.\r\n */\r\nexport function getCookieValue(cookieMgr, name, decode) {\r\n if (decode === void 0) { decode = true; }\r\n var cookieValue;\r\n if (cookieMgr) {\r\n cookieValue = cookieMgr.get(name);\r\n if (decode && cookieValue && decodeURIComponent) {\r\n cookieValue = decodeURIComponent(cookieValue);\r\n }\r\n }\r\n return cookieValue || STR_EMPTY;\r\n}\r\n/**\r\n * Create a new guid.\r\n * @param style - The style of guid to generated, defaults to Digits\r\n * Digits (Default) : 32 digits separated by hyphens: 00000000-0000-0000-0000-000000000000\r\n * Braces - 32 digits separated by hyphens, enclosed in braces: \\{00000000-0000-0000-0000-000000000000\\}\r\n * Parentheses - 32 digits separated by hyphens, enclosed in parentheses: (00000000-0000-0000-0000-000000000000)\r\n * Numeric - 32 digits: 00000000000000000000000000000000\r\n */\r\nexport function createGuid(style) {\r\n if (style === void 0) { style = \"D\" /* GuidStyle.Digits */; }\r\n var theGuid = newGuid();\r\n if (style === \"B\" /* GuidStyle.Braces */) {\r\n theGuid = \"{\" + theGuid + \"}\";\r\n }\r\n else if (style === \"P\" /* GuidStyle.Parentheses */) {\r\n theGuid = \"(\" + theGuid + \")\";\r\n }\r\n else if (style === \"N\" /* GuidStyle.Numeric */) {\r\n theGuid = theGuid[_DYN_REPLACE /* @min:%2ereplace */](/-/g, STR_EMPTY);\r\n }\r\n return theGuid;\r\n}\r\n/**\r\n * Pass in the objects to merge as arguments.\r\n * @param obj1 - object to merge. Set this argument to 'true' for a deep extend.\r\n * @param obj2 - object to merge.\r\n * @param obj3 - object to merge.\r\n * @param obj4 - object to merge.\r\n * @param obj5 - object to merge.\r\n * @returns The extended object.\r\n */\r\nexport function extend(obj, obj2, obj3, obj4, obj5) {\r\n // Variables\r\n var extended = {};\r\n var deep = false;\r\n var i = 0;\r\n var length = arguments[_DYN_LENGTH /* @min:%2elength */];\r\n var theArgs = arguments;\r\n // Check if a deep merge\r\n if (isBoolean(theArgs[0])) {\r\n deep = theArgs[0];\r\n i++;\r\n }\r\n // Loop through each object and conduct a merge\r\n for (; i < length; i++) {\r\n var obj = theArgs[i];\r\n objForEachKey(obj, function (prop, value) {\r\n // Prevent prototype pollution by skipping unsafe keys\r\n if (isUnsafePropKey(prop)) {\r\n return;\r\n }\r\n // If deep merge and property is an object, merge properties\r\n if (deep && value && isObject(value)) {\r\n if (isArray(value)) {\r\n extended[prop] = extended[prop] || [];\r\n arrForEach(value, function (arrayValue, arrayIndex) {\r\n if (arrayValue && isObject(arrayValue)) {\r\n extended[prop][arrayIndex] = extend(true, extended[prop][arrayIndex], arrayValue);\r\n }\r\n else {\r\n extended[prop][arrayIndex] = arrayValue;\r\n }\r\n });\r\n }\r\n else {\r\n extended[prop] = extend(true, extended[prop], value);\r\n }\r\n }\r\n else {\r\n extended[prop] = value;\r\n }\r\n });\r\n }\r\n return extended;\r\n}\r\nexport var getTime = perfNow;\r\nexport function isValueKind(value) {\r\n // Always assume that it's a number (no type checking) for performance as this is used during the JSON serialization\r\n if (value === 0 /* eValueKind.NotSet */ || ((value > 0 /* eValueKind.NotSet */ && value <= 13 /* eValueKind.Pii_IPV4AddressLegacy */) || value === 32 /* eValueKind.CustomerContent_GenericContent */)) {\r\n return true;\r\n }\r\n return false;\r\n}\r\nfunction isDataType(value) {\r\n // Remark: 0 returns false, but it doesn't affect encoding anyways\r\n // Always assume that it's a number (no type checking) for performance as this is used during the JSON serialization\r\n if (value >= 0 && value <= 9) {\r\n return true;\r\n }\r\n return false;\r\n}\r\nfunction isSafariOrFirefox() {\r\n var nav = getNavigator();\r\n // If non-browser navigator will be undefined\r\n if (!isUndefined(nav) && nav[_DYN_USER_AGENT /* @min:%2euserAgent */]) {\r\n var ua = nav.userAgent[_DYN_TO_LOWER_CASE /* @min:%2etoLowerCase */]();\r\n if ((ua[_DYN_INDEX_OF /* @min:%2eindexOf */](\"safari\") >= 0 || ua[_DYN_INDEX_OF /* @min:%2eindexOf */](\"firefox\") >= 0) && ua[_DYN_INDEX_OF /* @min:%2eindexOf */](\"chrome\") < 0) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n}\r\nexport function isArrayValid(value) {\r\n return value[_DYN_LENGTH /* @min:%2elength */] > 0;\r\n}\r\nexport function setProcessTelemetryTimings(event, identifier) {\r\n var evt = event;\r\n evt[_DYN_TIMINGS /* @min:%2etimings */] = evt[_DYN_TIMINGS /* @min:%2etimings */] || {};\r\n evt[_DYN_TIMINGS /* @min:%2etimings */][_DYN_PROCESS_TELEMETRY_ST6 /* @min:%2eprocessTelemetryStart */] = evt[_DYN_TIMINGS /* @min:%2etimings */][_DYN_PROCESS_TELEMETRY_ST6 /* @min:%2eprocessTelemetryStart */] || {};\r\n evt[_DYN_TIMINGS /* @min:%2etimings */][_DYN_PROCESS_TELEMETRY_ST6 /* @min:%2eprocessTelemetryStart */][identifier] = getTime();\r\n}\r\n/**\r\n * Returns a bitwise value for the FieldValueSanitizerType enum representing the decoded type of the passed value\r\n * @param value - The value to determine the type\r\n */\r\nexport function getFieldValueType(value) {\r\n var theType = 0 /* FieldValueSanitizerType.NotSet */;\r\n if (value !== null && value !== undefined) {\r\n var objType = typeof value;\r\n if (objType === \"string\") {\r\n theType = 1 /* FieldValueSanitizerType.String */;\r\n }\r\n else if (objType === \"number\") {\r\n theType = 2 /* FieldValueSanitizerType.Number */;\r\n }\r\n else if (objType === \"boolean\") {\r\n theType = 3 /* FieldValueSanitizerType.Boolean */;\r\n }\r\n else if (objType === \"object\") {\r\n theType = 4 /* FieldValueSanitizerType.Object */;\r\n if (isArray(value)) {\r\n theType = 4096 /* FieldValueSanitizerType.Array */;\r\n if (value[_DYN_LENGTH /* @min:%2elength */] > 0) {\r\n // Empty arrays are not supported and are considered to be the same as null\r\n theType |= getFieldValueType(value[0]);\r\n }\r\n }\r\n else if (ObjHasOwnProperty[_DYN_CALL /* @min:%2ecall */](value, \"value\")) {\r\n // Looks like an IEventProperty\r\n theType = 8192 /* FieldValueSanitizerType.EventProperty */ | getFieldValueType(value[_DYN_VALUE /* @min:%2evalue */]);\r\n }\r\n }\r\n }\r\n return theType;\r\n}\r\n/**\r\n * Helper to identify whether we are running in a chromium based browser environment\r\n */\r\nexport function isChromium() {\r\n return !!getGlobalInst(\"chrome\");\r\n}\r\n/**\r\n * Create and open an XMLHttpRequest object\r\n * @param method - The request method\r\n * @param urlString - The url\r\n * @param withCredentials - Option flag indicating that credentials should be sent\r\n * @param disabled - Optional flag indicating that the XHR object should be marked as disabled and not tracked (default is false)\r\n * @param isSync - Optional flag indicating if the instance should be a synchronous request (defaults to false)\r\n * @param timeout - Optional value identifying the timeout value that should be assigned to the XHR request\r\n * @returns A new opened XHR request\r\n */\r\nexport function openXhr(method, urlString, withCredentials, disabled, isSync, timeout) {\r\n if (disabled === void 0) { disabled = false; }\r\n if (isSync === void 0) { isSync = false; }\r\n function _wrapSetXhrProp(xhr, prop, value) {\r\n try {\r\n xhr[prop] = value;\r\n }\r\n catch (e) {\r\n // - Wrapping as depending on the environment setting the property may fail (non-terminally)\r\n }\r\n }\r\n var xhr = new XMLHttpRequest();\r\n if (disabled) {\r\n // Tag the instance so it's not tracked (trackDependency)\r\n // If the environment has locked down the XMLHttpRequest (preventExtensions and/or freeze), this would\r\n // cause the request to fail and we no telemetry would be sent\r\n _wrapSetXhrProp(xhr, strDisabledPropertyName, disabled);\r\n }\r\n if (withCredentials) {\r\n // Some libraries require that the withCredentials flag is set \"before\" open and\r\n // - Wrapping as IE 10 has started throwing when setting before open\r\n _wrapSetXhrProp(xhr, strWithCredentials, withCredentials);\r\n }\r\n xhr.open(method, urlString, !isSync);\r\n if (withCredentials) {\r\n // withCredentials should be set AFTER open (https://xhr.spec.whatwg.org/#the-withcredentials-attribute)\r\n // And older firefox instances from 11+ will throw for sync events (current versions don't) which happens during unload processing\r\n _wrapSetXhrProp(xhr, strWithCredentials, withCredentials);\r\n }\r\n // Only set the timeout for asynchronous requests as\r\n // \"Timeout shouldn't be used for synchronous XMLHttpRequests requests used in a document environment or it will throw an InvalidAccessError exception.\"\"\r\n // https://developer.mozilla.org/en-US/docs/Web/API/XMLHttpRequest/timeout\r\n if (!isSync && timeout) {\r\n _wrapSetXhrProp(xhr, strTimeout, timeout);\r\n }\r\n return xhr;\r\n}\r\n/**\r\n * Check to see if the value is \\> 0\r\n * @param value - The value to check\r\n * @returns true if \\> 0 otherwise false\r\n */\r\nexport function isGreaterThanZero(value) {\r\n return value > 0;\r\n}\r\n//# sourceMappingURL=extUtils.js.map"],"names":[],"mappings":";;;;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA"}
package/dist-es5/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  export var MinChannelPriorty = 100;
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  export {};
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  export {};
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  export {};
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
  export {};
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5
 
@@ -1,5 +1,5 @@
1
1
  /*
2
- * Application Insights JavaScript SDK - Core, 3.4.2-nightly3.2606-02
2
+ * Application Insights JavaScript SDK - Core, 3.4.2
3
3
  * Copyright (c) Microsoft and contributors. All rights reserved.
4
4
  */
5
5