@microsoft/applicationinsights-core-js 3.0.0-beta.2303-11 → 3.0.0-nightly3.2304-28

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 (261) hide show
  1. package/browser/es5/applicationinsights-core-js.cjs.js +5477 -0
  2. package/browser/es5/applicationinsights-core-js.cjs.js.map +1 -0
  3. package/browser/es5/applicationinsights-core-js.cjs.min.js +6 -0
  4. package/browser/es5/applicationinsights-core-js.cjs.min.js.map +1 -0
  5. package/browser/es5/applicationinsights-core-js.gbl.js +5481 -0
  6. package/browser/es5/applicationinsights-core-js.gbl.js.map +1 -0
  7. package/browser/es5/applicationinsights-core-js.gbl.min.js +6 -0
  8. package/browser/es5/applicationinsights-core-js.gbl.min.js.map +1 -0
  9. package/browser/es5/applicationinsights-core-js.integrity.json +66 -0
  10. package/browser/{applicationinsights-core-js.js → es5/applicationinsights-core-js.js} +259 -223
  11. package/browser/es5/applicationinsights-core-js.js.map +1 -0
  12. package/browser/es5/applicationinsights-core-js.min.js +6 -0
  13. package/browser/es5/applicationinsights-core-js.min.js.map +1 -0
  14. package/dist/{applicationinsights-core-js.js → es5/applicationinsights-core-js.js} +259 -223
  15. package/dist/es5/applicationinsights-core-js.js.map +1 -0
  16. package/dist/es5/applicationinsights-core-js.min.js +6 -0
  17. package/dist/es5/applicationinsights-core-js.min.js.map +1 -0
  18. package/{dist-esm → dist-es5}/Config/ConfigDefaultHelpers.js +1 -1
  19. package/{dist-esm → dist-es5}/Config/ConfigDefaults.js +1 -1
  20. package/{dist-esm → dist-es5}/Config/DynamicConfig.js +1 -1
  21. package/{dist-esm → dist-es5}/Config/DynamicProperty.js +1 -1
  22. package/{dist-esm → dist-es5}/Config/DynamicState.js +1 -1
  23. package/{dist-esm → dist-es5}/Config/DynamicSupport.js +1 -1
  24. package/dist-es5/Config/IConfigDefaults.js +8 -0
  25. package/dist-es5/Config/IDynamicConfigHandler.js +8 -0
  26. package/dist-es5/Config/IDynamicPropertyHandler.js +8 -0
  27. package/dist-es5/Config/IDynamicWatcher.js +8 -0
  28. package/dist-es5/Config/_IDynamicConfigHandlerState.js +6 -0
  29. package/{dist-esm → dist-es5}/JavaScriptSDK/AggregationError.js +2 -2
  30. package/{dist-esm → dist-es5}/JavaScriptSDK/AggregationError.js.map +1 -1
  31. package/{dist-esm → dist-es5}/JavaScriptSDK/AppInsightsCore.js +1 -1
  32. package/{dist-esm → dist-es5}/JavaScriptSDK/BaseTelemetryPlugin.js +1 -1
  33. package/{dist-esm → dist-es5}/JavaScriptSDK/Constants.js +1 -1
  34. package/{dist-esm → dist-es5}/JavaScriptSDK/CookieMgr.js +14 -8
  35. package/dist-es5/JavaScriptSDK/CookieMgr.js.map +1 -0
  36. package/{dist-esm → dist-es5}/JavaScriptSDK/CoreUtils.js +1 -1
  37. package/{dist-esm → dist-es5}/JavaScriptSDK/DataCacheHelper.js +2 -2
  38. package/dist-es5/JavaScriptSDK/DataCacheHelper.js.map +1 -0
  39. package/{dist-esm → dist-es5}/JavaScriptSDK/DbgExtensionUtils.js +1 -1
  40. package/{dist-esm → dist-es5}/JavaScriptSDK/DiagnosticLogger.js +1 -1
  41. package/{dist-esm → dist-es5}/JavaScriptSDK/EnvUtils.js +1 -1
  42. package/{dist-esm → dist-es5}/JavaScriptSDK/EventHelpers.js +1 -1
  43. package/{dist-esm → dist-es5}/JavaScriptSDK/HelperFuncs.js +1 -1
  44. package/{dist-esm → dist-es5}/JavaScriptSDK/InstrumentHooks.js +1 -1
  45. package/{dist-esm → dist-es5}/JavaScriptSDK/InternalConstants.js +1 -1
  46. package/{dist-esm → dist-es5}/JavaScriptSDK/NotificationManager.js +1 -1
  47. package/{dist-esm → dist-es5}/JavaScriptSDK/PerfManager.js +1 -1
  48. package/{dist-esm → dist-es5}/JavaScriptSDK/ProcessTelemetryContext.js +1 -1
  49. package/{dist-esm → dist-es5}/JavaScriptSDK/RandomHelper.js +7 -5
  50. package/dist-es5/JavaScriptSDK/RandomHelper.js.map +1 -0
  51. package/{dist-esm → dist-es5}/JavaScriptSDK/TelemetryHelpers.js +1 -1
  52. package/{dist-esm → dist-es5}/JavaScriptSDK/TelemetryInitializerPlugin.js +44 -38
  53. package/dist-es5/JavaScriptSDK/TelemetryInitializerPlugin.js.map +1 -0
  54. package/{dist-esm → dist-es5}/JavaScriptSDK/UnloadHandlerContainer.js +1 -1
  55. package/{dist-esm → dist-es5}/JavaScriptSDK/UnloadHookContainer.js +1 -1
  56. package/{dist-esm → dist-es5}/JavaScriptSDK/W3cTraceParent.js +1 -1
  57. package/{dist-esm → dist-es5}/JavaScriptSDK.Enums/EnumHelperFuncs.js +1 -1
  58. package/{dist-esm → dist-es5}/JavaScriptSDK.Enums/EventsDiscardedReason.js +1 -1
  59. package/{dist-esm → dist-es5}/JavaScriptSDK.Enums/LoggingEnums.js +1 -1
  60. package/dist-es5/JavaScriptSDK.Enums/SendRequestReason.js +6 -0
  61. package/dist-es5/JavaScriptSDK.Enums/TelemetryUnloadReason.js +8 -0
  62. package/dist-es5/JavaScriptSDK.Enums/TelemetryUpdateReason.js +8 -0
  63. package/dist-es5/JavaScriptSDK.Interfaces/IAppInsightsCore.js +6 -0
  64. package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IChannelControls.js +1 -1
  65. package/dist-es5/JavaScriptSDK.Interfaces/IChannelControlsHost.js +8 -0
  66. package/dist-es5/JavaScriptSDK.Interfaces/IConfiguration.js +7 -0
  67. package/dist-es5/JavaScriptSDK.Interfaces/ICookieMgr.js +8 -0
  68. package/dist-es5/JavaScriptSDK.Interfaces/IDbgExtension.js +8 -0
  69. package/dist-es5/JavaScriptSDK.Interfaces/IDiagnosticLogger.js +6 -0
  70. package/dist-es5/JavaScriptSDK.Interfaces/IDistributedTraceContext.js +8 -0
  71. package/dist-es5/JavaScriptSDK.Interfaces/IInstrumentHooks.js +8 -0
  72. package/dist-es5/JavaScriptSDK.Interfaces/INotificationListener.js +9 -0
  73. package/dist-es5/JavaScriptSDK.Interfaces/INotificationManager.js +6 -0
  74. package/dist-es5/JavaScriptSDK.Interfaces/IPerfEvent.js +8 -0
  75. package/dist-es5/JavaScriptSDK.Interfaces/IPerfManager.js +6 -0
  76. package/dist-es5/JavaScriptSDK.Interfaces/IProcessTelemetryContext.js +9 -0
  77. package/dist-es5/JavaScriptSDK.Interfaces/ITelemetryInitializers.js +6 -0
  78. package/dist-es5/JavaScriptSDK.Interfaces/ITelemetryItem.js +9 -0
  79. package/dist-es5/JavaScriptSDK.Interfaces/ITelemetryPlugin.js +9 -0
  80. package/dist-es5/JavaScriptSDK.Interfaces/ITelemetryPluginChain.js +8 -0
  81. package/dist-es5/JavaScriptSDK.Interfaces/ITelemetryUnloadState.js +8 -0
  82. package/dist-es5/JavaScriptSDK.Interfaces/ITelemetryUpdateState.js +8 -0
  83. package/dist-es5/JavaScriptSDK.Interfaces/ITraceParent.js +8 -0
  84. package/dist-es5/JavaScriptSDK.Interfaces/IUnloadHook.js +8 -0
  85. package/dist-es5/JavaScriptSDK.Interfaces/IUnloadableComponent.js +8 -0
  86. package/{dist-esm → dist-es5}/__DynamicConstants.js +2 -2
  87. package/{dist-esm → dist-es5}/__DynamicConstants.js.map +1 -1
  88. package/{dist-esm → dist-es5}/applicationinsights-core-js.js +2 -2
  89. package/dist-es5/applicationinsights-core-js.js.map +1 -0
  90. package/package.json +16 -15
  91. package/tsconfig.json +5 -4
  92. package/types/applicationinsights-core-js.d.ts +3074 -58
  93. package/{dist/applicationinsights-core-js.d.ts → types/applicationinsights-core-js.namespaced.d.ts} +1 -4
  94. package/browser/applicationinsights-core-js.integrity.json +0 -26
  95. package/browser/applicationinsights-core-js.js.map +0 -1
  96. package/browser/applicationinsights-core-js.min.js +0 -6
  97. package/browser/applicationinsights-core-js.min.js.map +0 -1
  98. package/dist/applicationinsights-core-js.api.json +0 -25423
  99. package/dist/applicationinsights-core-js.api.md +0 -1374
  100. package/dist/applicationinsights-core-js.js.map +0 -1
  101. package/dist/applicationinsights-core-js.min.js +0 -6
  102. package/dist/applicationinsights-core-js.min.js.map +0 -1
  103. package/dist/applicationinsights-core-js.rollup.d.ts +0 -3078
  104. package/dist-esm/Config/IConfigDefaults.js +0 -8
  105. package/dist-esm/Config/IDynamicConfigHandler.js +0 -8
  106. package/dist-esm/Config/IDynamicPropertyHandler.js +0 -8
  107. package/dist-esm/Config/IDynamicWatcher.js +0 -8
  108. package/dist-esm/Config/_IDynamicConfigHandlerState.js +0 -6
  109. package/dist-esm/JavaScriptSDK/CookieMgr.js.map +0 -1
  110. package/dist-esm/JavaScriptSDK/DataCacheHelper.js.map +0 -1
  111. package/dist-esm/JavaScriptSDK/RandomHelper.js.map +0 -1
  112. package/dist-esm/JavaScriptSDK/TelemetryInitializerPlugin.js.map +0 -1
  113. package/dist-esm/JavaScriptSDK.Enums/SendRequestReason.js +0 -6
  114. package/dist-esm/JavaScriptSDK.Enums/TelemetryUnloadReason.js +0 -8
  115. package/dist-esm/JavaScriptSDK.Enums/TelemetryUpdateReason.js +0 -8
  116. package/dist-esm/JavaScriptSDK.Interfaces/IAppInsightsCore.js +0 -6
  117. package/dist-esm/JavaScriptSDK.Interfaces/IChannelControlsHost.js +0 -8
  118. package/dist-esm/JavaScriptSDK.Interfaces/IConfiguration.js +0 -7
  119. package/dist-esm/JavaScriptSDK.Interfaces/ICookieMgr.js +0 -8
  120. package/dist-esm/JavaScriptSDK.Interfaces/IDbgExtension.js +0 -8
  121. package/dist-esm/JavaScriptSDK.Interfaces/IDiagnosticLogger.js +0 -6
  122. package/dist-esm/JavaScriptSDK.Interfaces/IDistributedTraceContext.js +0 -8
  123. package/dist-esm/JavaScriptSDK.Interfaces/IInstrumentHooks.js +0 -8
  124. package/dist-esm/JavaScriptSDK.Interfaces/INotificationListener.js +0 -9
  125. package/dist-esm/JavaScriptSDK.Interfaces/INotificationManager.js +0 -6
  126. package/dist-esm/JavaScriptSDK.Interfaces/IPerfEvent.js +0 -8
  127. package/dist-esm/JavaScriptSDK.Interfaces/IPerfManager.js +0 -6
  128. package/dist-esm/JavaScriptSDK.Interfaces/IProcessTelemetryContext.js +0 -9
  129. package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryInitializers.js +0 -6
  130. package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryItem.js +0 -9
  131. package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryPlugin.js +0 -9
  132. package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryPluginChain.js +0 -8
  133. package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryUnloadState.js +0 -8
  134. package/dist-esm/JavaScriptSDK.Interfaces/ITelemetryUpdateState.js +0 -8
  135. package/dist-esm/JavaScriptSDK.Interfaces/ITraceParent.js +0 -8
  136. package/dist-esm/JavaScriptSDK.Interfaces/IUnloadHook.js +0 -8
  137. package/dist-esm/JavaScriptSDK.Interfaces/IUnloadableComponent.js +0 -8
  138. package/dist-esm/applicationinsights-core-js.js.map +0 -1
  139. package/types/Config/ConfigDefaultHelpers.d.ts +0 -47
  140. package/types/Config/ConfigDefaults.d.ts +0 -9
  141. package/types/Config/DynamicConfig.d.ts +0 -23
  142. package/types/Config/DynamicProperty.d.ts +0 -3
  143. package/types/Config/DynamicState.d.ts +0 -3
  144. package/types/Config/DynamicSupport.d.ts +0 -82
  145. package/types/Config/IConfigDefaults.d.ts +0 -63
  146. package/types/Config/IDynamicConfigHandler.d.ts +0 -69
  147. package/types/Config/IDynamicPropertyHandler.d.ts +0 -11
  148. package/types/Config/IDynamicWatcher.d.ts +0 -61
  149. package/types/Config/_IDynamicConfigHandlerState.d.ts +0 -52
  150. package/types/JavaScriptSDK/AggregationError.d.ts +0 -6
  151. package/types/JavaScriptSDK/AppInsightsCore.d.ts +0 -158
  152. package/types/JavaScriptSDK/BaseTelemetryPlugin.d.ts +0 -110
  153. package/types/JavaScriptSDK/Constants.d.ts +0 -1
  154. package/types/JavaScriptSDK/CookieMgr.d.ts +0 -15
  155. package/types/JavaScriptSDK/CoreUtils.d.ts +0 -13
  156. package/types/JavaScriptSDK/DataCacheHelper.d.ts +0 -13
  157. package/types/JavaScriptSDK/DbgExtensionUtils.d.ts +0 -5
  158. package/types/JavaScriptSDK/DiagnosticLogger.d.ts +0 -76
  159. package/types/JavaScriptSDK/EnvUtils.d.ts +0 -81
  160. package/types/JavaScriptSDK/EventHelpers.d.ts +0 -154
  161. package/types/JavaScriptSDK/HelperFuncs.d.ts +0 -106
  162. package/types/JavaScriptSDK/InstrumentHooks.d.ts +0 -43
  163. package/types/JavaScriptSDK/InternalConstants.d.ts +0 -20
  164. package/types/JavaScriptSDK/NotificationManager.d.ts +0 -46
  165. package/types/JavaScriptSDK/PerfManager.d.ts +0 -93
  166. package/types/JavaScriptSDK/ProcessTelemetryContext.d.ts +0 -119
  167. package/types/JavaScriptSDK/RandomHelper.d.ts +0 -29
  168. package/types/JavaScriptSDK/TelemetryHelpers.d.ts +0 -38
  169. package/types/JavaScriptSDK/TelemetryInitializerPlugin.d.ts +0 -16
  170. package/types/JavaScriptSDK/UnloadHandlerContainer.d.ts +0 -8
  171. package/types/JavaScriptSDK/UnloadHookContainer.d.ts +0 -16
  172. package/types/JavaScriptSDK/W3cTraceParent.d.ts +0 -59
  173. package/types/JavaScriptSDK.Enums/EnumHelperFuncs.d.ts +0 -22
  174. package/types/JavaScriptSDK.Enums/EventsDiscardedReason.d.ts +0 -34
  175. package/types/JavaScriptSDK.Enums/LoggingEnums.d.ts +0 -104
  176. package/types/JavaScriptSDK.Enums/SendRequestReason.d.ts +0 -45
  177. package/types/JavaScriptSDK.Enums/TelemetryUnloadReason.d.ts +0 -21
  178. package/types/JavaScriptSDK.Enums/TelemetryUpdateReason.d.ts +0 -21
  179. package/types/JavaScriptSDK.Interfaces/IAppInsightsCore.d.ts +0 -171
  180. package/types/JavaScriptSDK.Interfaces/IChannelControls.d.ts +0 -36
  181. package/types/JavaScriptSDK.Interfaces/IChannelControlsHost.d.ts +0 -9
  182. package/types/JavaScriptSDK.Interfaces/IConfiguration.d.ts +0 -150
  183. package/types/JavaScriptSDK.Interfaces/ICookieMgr.d.ts +0 -97
  184. package/types/JavaScriptSDK.Interfaces/IDbgExtension.d.ts +0 -10
  185. package/types/JavaScriptSDK.Interfaces/IDiagnosticLogger.d.ts +0 -48
  186. package/types/JavaScriptSDK.Interfaces/IDistributedTraceContext.d.ts +0 -43
  187. package/types/JavaScriptSDK.Interfaces/IInstrumentHooks.d.ts +0 -81
  188. package/types/JavaScriptSDK.Interfaces/INotificationListener.d.ts +0 -32
  189. package/types/JavaScriptSDK.Interfaces/INotificationManager.d.ts +0 -43
  190. package/types/JavaScriptSDK.Interfaces/IPerfEvent.d.ts +0 -56
  191. package/types/JavaScriptSDK.Interfaces/IPerfManager.d.ts +0 -45
  192. package/types/JavaScriptSDK.Interfaces/IProcessTelemetryContext.d.ts +0 -129
  193. package/types/JavaScriptSDK.Interfaces/ITelemetryInitializers.d.ts +0 -14
  194. package/types/JavaScriptSDK.Interfaces/ITelemetryItem.d.ts +0 -51
  195. package/types/JavaScriptSDK.Interfaces/ITelemetryPlugin.d.ts +0 -80
  196. package/types/JavaScriptSDK.Interfaces/ITelemetryPluginChain.d.ts +0 -23
  197. package/types/JavaScriptSDK.Interfaces/ITelemetryUnloadState.d.ts +0 -6
  198. package/types/JavaScriptSDK.Interfaces/ITelemetryUpdateState.d.ts +0 -33
  199. package/types/JavaScriptSDK.Interfaces/ITraceParent.d.ts +0 -32
  200. package/types/JavaScriptSDK.Interfaces/IUnloadHook.d.ts +0 -18
  201. package/types/JavaScriptSDK.Interfaces/IUnloadableComponent.d.ts +0 -13
  202. package/types/__DynamicConstants.d.ts +0 -53
  203. package/types/tsdoc-metadata.json +0 -11
  204. /package/{dist-esm → dist-es5}/Config/ConfigDefaultHelpers.js.map +0 -0
  205. /package/{dist-esm → dist-es5}/Config/ConfigDefaults.js.map +0 -0
  206. /package/{dist-esm → dist-es5}/Config/DynamicConfig.js.map +0 -0
  207. /package/{dist-esm → dist-es5}/Config/DynamicProperty.js.map +0 -0
  208. /package/{dist-esm → dist-es5}/Config/DynamicState.js.map +0 -0
  209. /package/{dist-esm → dist-es5}/Config/DynamicSupport.js.map +0 -0
  210. /package/{dist-esm → dist-es5}/Config/IConfigDefaults.js.map +0 -0
  211. /package/{dist-esm → dist-es5}/Config/IDynamicConfigHandler.js.map +0 -0
  212. /package/{dist-esm → dist-es5}/Config/IDynamicPropertyHandler.js.map +0 -0
  213. /package/{dist-esm → dist-es5}/Config/IDynamicWatcher.js.map +0 -0
  214. /package/{dist-esm → dist-es5}/Config/_IDynamicConfigHandlerState.js.map +0 -0
  215. /package/{dist-esm → dist-es5}/JavaScriptSDK/AppInsightsCore.js.map +0 -0
  216. /package/{dist-esm → dist-es5}/JavaScriptSDK/BaseTelemetryPlugin.js.map +0 -0
  217. /package/{dist-esm → dist-es5}/JavaScriptSDK/Constants.js.map +0 -0
  218. /package/{dist-esm → dist-es5}/JavaScriptSDK/CoreUtils.js.map +0 -0
  219. /package/{dist-esm → dist-es5}/JavaScriptSDK/DbgExtensionUtils.js.map +0 -0
  220. /package/{dist-esm → dist-es5}/JavaScriptSDK/DiagnosticLogger.js.map +0 -0
  221. /package/{dist-esm → dist-es5}/JavaScriptSDK/EnvUtils.js.map +0 -0
  222. /package/{dist-esm → dist-es5}/JavaScriptSDK/EventHelpers.js.map +0 -0
  223. /package/{dist-esm → dist-es5}/JavaScriptSDK/HelperFuncs.js.map +0 -0
  224. /package/{dist-esm → dist-es5}/JavaScriptSDK/InstrumentHooks.js.map +0 -0
  225. /package/{dist-esm → dist-es5}/JavaScriptSDK/InternalConstants.js.map +0 -0
  226. /package/{dist-esm → dist-es5}/JavaScriptSDK/NotificationManager.js.map +0 -0
  227. /package/{dist-esm → dist-es5}/JavaScriptSDK/PerfManager.js.map +0 -0
  228. /package/{dist-esm → dist-es5}/JavaScriptSDK/ProcessTelemetryContext.js.map +0 -0
  229. /package/{dist-esm → dist-es5}/JavaScriptSDK/TelemetryHelpers.js.map +0 -0
  230. /package/{dist-esm → dist-es5}/JavaScriptSDK/UnloadHandlerContainer.js.map +0 -0
  231. /package/{dist-esm → dist-es5}/JavaScriptSDK/UnloadHookContainer.js.map +0 -0
  232. /package/{dist-esm → dist-es5}/JavaScriptSDK/W3cTraceParent.js.map +0 -0
  233. /package/{dist-esm → dist-es5}/JavaScriptSDK.Enums/EnumHelperFuncs.js.map +0 -0
  234. /package/{dist-esm → dist-es5}/JavaScriptSDK.Enums/EventsDiscardedReason.js.map +0 -0
  235. /package/{dist-esm → dist-es5}/JavaScriptSDK.Enums/LoggingEnums.js.map +0 -0
  236. /package/{dist-esm → dist-es5}/JavaScriptSDK.Enums/SendRequestReason.js.map +0 -0
  237. /package/{dist-esm → dist-es5}/JavaScriptSDK.Enums/TelemetryUnloadReason.js.map +0 -0
  238. /package/{dist-esm → dist-es5}/JavaScriptSDK.Enums/TelemetryUpdateReason.js.map +0 -0
  239. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IAppInsightsCore.js.map +0 -0
  240. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IChannelControls.js.map +0 -0
  241. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IChannelControlsHost.js.map +0 -0
  242. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IConfiguration.js.map +0 -0
  243. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ICookieMgr.js.map +0 -0
  244. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IDbgExtension.js.map +0 -0
  245. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IDiagnosticLogger.js.map +0 -0
  246. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IDistributedTraceContext.js.map +0 -0
  247. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IInstrumentHooks.js.map +0 -0
  248. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/INotificationListener.js.map +0 -0
  249. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/INotificationManager.js.map +0 -0
  250. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IPerfEvent.js.map +0 -0
  251. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IPerfManager.js.map +0 -0
  252. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IProcessTelemetryContext.js.map +0 -0
  253. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ITelemetryInitializers.js.map +0 -0
  254. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ITelemetryItem.js.map +0 -0
  255. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ITelemetryPlugin.js.map +0 -0
  256. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ITelemetryPluginChain.js.map +0 -0
  257. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ITelemetryUnloadState.js.map +0 -0
  258. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ITelemetryUpdateState.js.map +0 -0
  259. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/ITraceParent.js.map +0 -0
  260. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IUnloadHook.js.map +0 -0
  261. /package/{dist-esm → dist-es5}/JavaScriptSDK.Interfaces/IUnloadableComponent.js.map +0 -0
@@ -1,171 +0,0 @@
1
- import { ITelemetryItem } from "./ITelemetryItem";
2
- import { IChannelControls } from "./IChannelControls";
3
- import { IPlugin, ITelemetryPlugin } from "./ITelemetryPlugin";
4
- import { IConfiguration } from "./IConfiguration";
5
- import { INotificationManager } from "./INotificationManager";
6
- import { INotificationListener } from "./INotificationListener";
7
- import { IDiagnosticLogger } from "./IDiagnosticLogger";
8
- import { IProcessTelemetryContext } from "./IProcessTelemetryContext";
9
- import { IPerfManagerProvider } from "./IPerfManager";
10
- import { ICookieMgr } from "./ICookieMgr";
11
- import { ITelemetryInitializerHandler, TelemetryInitializerFunction } from "./ITelemetryInitializers";
12
- import { ITelemetryUnloadState } from "./ITelemetryUnloadState";
13
- import { UnloadHandler } from "../JavaScriptSDK/UnloadHandlerContainer";
14
- import { SendRequestReason } from "../JavaScriptSDK.Enums/SendRequestReason";
15
- import { IDistributedTraceContext } from "./IDistributedTraceContext";
16
- import { ILegacyUnloadHook, IUnloadHook } from "./IUnloadHook";
17
- import { WatcherFunction } from "../Config/IDynamicWatcher";
18
- import { ITimerHandler } from "@nevware21/ts-utils";
19
- export interface ILoadedPlugin<T extends IPlugin> {
20
- plugin: T;
21
- /**
22
- * Identifies whether the plugin is enabled and can process events. This is slightly different from isInitialized as the plugin may be initialized but disabled
23
- * via the setEnabled() or it may be a shared plugin which has had it's teardown function called from another instance..
24
- * @returns boolean = true if the plugin is in a state where it is operational.
25
- */
26
- isEnabled: () => boolean;
27
- /**
28
- * You can optionally enable / disable a plugin from processing events.
29
- * Setting enabled to true will not necessarily cause the `isEnabled()` to also return true
30
- * as the plugin must also have been successfully initialized and not had it's `teardown` method called
31
- * (unless it's also been re-initialized)
32
- */
33
- setEnabled: (isEnabled: boolean) => void;
34
- remove: (isAsync?: boolean, removeCb?: (removed?: boolean) => void) => void;
35
- }
36
- export interface IAppInsightsCore<CfgType extends IConfiguration = IConfiguration> extends IPerfManagerProvider {
37
- readonly config: CfgType;
38
- /**
39
- * The current logger instance for this instance.
40
- */
41
- readonly logger: IDiagnosticLogger;
42
- /**
43
- * An array of the installed plugins that provide a version
44
- */
45
- readonly pluginVersionStringArr: string[];
46
- /**
47
- * The formatted string of the installed plugins that contain a version number
48
- */
49
- readonly pluginVersionString: string;
50
- /**
51
- * Returns a value that indicates whether the instance has already been previously initialized.
52
- */
53
- isInitialized?: () => boolean;
54
- initialize(config: CfgType, extensions: IPlugin[], logger?: IDiagnosticLogger, notificationManager?: INotificationManager): void;
55
- getChannels(): IChannelControls[];
56
- track(telemetryItem: ITelemetryItem): void;
57
- /**
58
- * Get the current notification manager
59
- */
60
- getNotifyMgr(): INotificationManager;
61
- /**
62
- * Get the current cookie manager for this instance
63
- */
64
- getCookieMgr(): ICookieMgr;
65
- /**
66
- * Set the current cookie manager for this instance
67
- * @param cookieMgr - The manager, if set to null/undefined will cause the default to be created
68
- */
69
- setCookieMgr(cookieMgr: ICookieMgr): void;
70
- /**
71
- * Adds a notification listener. The SDK calls methods on the listener when an appropriate notification is raised.
72
- * The added plugins must raise notifications. If the plugins do not implement the notifications, then no methods will be
73
- * called.
74
- * @param listener - An INotificationListener object.
75
- */
76
- addNotificationListener?(listener: INotificationListener): void;
77
- /**
78
- * Removes all instances of the listener.
79
- * @param listener - INotificationListener to remove.
80
- */
81
- removeNotificationListener?(listener: INotificationListener): void;
82
- /**
83
- * Add a telemetry processor to decorate or drop telemetry events.
84
- * @param telemetryInitializer - The Telemetry Initializer function
85
- * @returns - A ITelemetryInitializerHandler to enable the initializer to be removed
86
- */
87
- addTelemetryInitializer(telemetryInitializer: TelemetryInitializerFunction): ITelemetryInitializerHandler;
88
- pollInternalLogs?(eventName?: string): ITimerHandler;
89
- stopPollingInternalLogs?(): void;
90
- /**
91
- * Return a new instance of the IProcessTelemetryContext for processing events
92
- */
93
- getProcessTelContext(): IProcessTelemetryContext;
94
- /**
95
- * Unload and Tear down the SDK and any initialized plugins, after calling this the SDK will be considered
96
- * to be un-initialized and non-operational, re-initializing the SDK should only be attempted if the previous
97
- * unload call return `true` stating that all plugins reported that they also unloaded, the recommended
98
- * approach is to create a new instance and initialize that instance.
99
- * This is due to possible unexpected side effects caused by plugins not supporting unload / teardown, unable
100
- * to successfully remove any global references or they may just be completing the unload process asynchronously.
101
- * @param isAsync - Can the unload be performed asynchronously (default)
102
- * @param unloadComplete - An optional callback that will be called once the unload has completed
103
- * @param cbTimeout - An optional timeout to wait for any flush operations to complete before proceeding with the unload. Defaults to 5 seconds.
104
- */
105
- unload(isAsync?: boolean, unloadComplete?: (unloadState: ITelemetryUnloadState) => void, cbTimeout?: number): void;
106
- /**
107
- * Find and return the (first) plugin with the specified identifier if present
108
- * @param pluginIdentifier
109
- */
110
- getPlugin<T extends IPlugin = IPlugin>(pluginIdentifier: string): ILoadedPlugin<T>;
111
- /**
112
- * Add a new plugin to the installation
113
- * @param plugin - The new plugin to add
114
- * @param replaceExisting - should any existing plugin be replaced, default is false
115
- * @param doAsync - Should the add be performed asynchronously
116
- * @param addCb - [Optional] callback to call after the plugin has been added
117
- */
118
- addPlugin<T extends IPlugin = ITelemetryPlugin>(plugin: T, replaceExisting?: boolean, doAsync?: boolean, addCb?: (added?: boolean) => void): void;
119
- /**
120
- * Update the configuration used and broadcast the changes to all loaded plugins, this does NOT support updating, adding or removing
121
- * any the plugins (extensions or channels). It will notify each plugin (if supported) that the configuration has changed but it will
122
- * not remove or add any new plugins, you need to call addPlugin or getPlugin(identifier).remove();
123
- * @param newConfig - The new configuration is apply
124
- * @param mergeExisting - Should the new configuration merge with the existing or just replace it. Default is to merge.
125
- */
126
- updateCfg(newConfig: CfgType, mergeExisting?: boolean): void;
127
- /**
128
- * Returns the unique event namespace that should be used when registering events
129
- */
130
- evtNamespace(): string;
131
- /**
132
- * Add a handler that will be called when the SDK is being unloaded
133
- * @param handler - the handler
134
- */
135
- addUnloadCb(handler: UnloadHandler): void;
136
- /**
137
- * Add this hook so that it is automatically removed during unloading
138
- * @param hooks - The single hook or an array of IInstrumentHook objects
139
- */
140
- addUnloadHook(hooks: IUnloadHook | IUnloadHook[] | Iterator<IUnloadHook> | ILegacyUnloadHook | ILegacyUnloadHook[] | Iterator<ILegacyUnloadHook>): void;
141
- /**
142
- * Flush and send any batched / cached data immediately
143
- * @param async - send data asynchronously when true (defaults to true)
144
- * @param callBack - if specified, notify caller when send is complete, the channel should return true to indicate to the caller that it will be called.
145
- * If the caller doesn't return true the caller should assume that it may never be called.
146
- * @param sendReason - specify the reason that you are calling "flush" defaults to ManualFlush (1) if not specified
147
- * @param cbTimeout - An optional timeout to wait for any flush operations to complete before proceeding with the unload. Defaults to 5 seconds.
148
- * @returns - true if the callback will be return after the flush is complete otherwise the caller should assume that any provided callback will never be called
149
- */
150
- flush(isAsync?: boolean, callBack?: (flushComplete?: boolean) => void, sendReason?: SendRequestReason, cbTimeout?: number): boolean | void;
151
- /**
152
- * Gets the current distributed trace context for this instance if available
153
- * @param createNew - Optional flag to create a new instance if one doesn't currently exist, defaults to true
154
- */
155
- getTraceCtx(createNew?: boolean): IDistributedTraceContext | null;
156
- /**
157
- * Sets the current distributed trace context for this instance if available
158
- */
159
- setTraceCtx(newTraceCtx: IDistributedTraceContext | null | undefined): void;
160
- /**
161
- * Watches and tracks changes for accesses to the current config, and if the accessed config changes the
162
- * handler will be recalled.
163
- * @param handler
164
- * @returns A watcher handler instance that can be used to remove itself when being unloaded
165
- */
166
- onCfgChange(handler: WatcherFunction<CfgType>): IUnloadHook;
167
- /**
168
- * Function used to identify the get w parameter used to identify status bit to some channels
169
- */
170
- getWParam: () => number;
171
- }
@@ -1,36 +0,0 @@
1
- import { SendRequestReason } from "../JavaScriptSDK.Enums/SendRequestReason";
2
- import { IProcessTelemetryUnloadContext } from "./IProcessTelemetryContext";
3
- import { ITelemetryPlugin } from "./ITelemetryPlugin";
4
- import { ITelemetryUnloadState } from "./ITelemetryUnloadState";
5
- /**
6
- * Provides data transmission capabilities
7
- */
8
- export interface IChannelControls extends ITelemetryPlugin {
9
- /**
10
- * Pause sending data
11
- */
12
- pause?(): void;
13
- /**
14
- * Resume sending data
15
- */
16
- resume?(): void;
17
- /**
18
- * Tear down the plugin and remove any hooked value, the plugin should be removed so that it is no longer initialized and
19
- * therefore could be re-initialized after being torn down. The plugin should ensure that once this has been called any further
20
- * processTelemetry calls are ignored and it just calls the processNext() with the provided context.
21
- * @param unloadCtx - This is the context that should be used during unloading.
22
- * @param unloadState - The details / state of the unload process, it holds details like whether it should be unloaded synchronously or asynchronously and the reason for the unload.
23
- * @returns boolean - true if the plugin has or will call processNext(), this for backward compatibility as previously teardown was synchronous and returned nothing.
24
- */
25
- teardown?: (unloadCtx?: IProcessTelemetryUnloadContext, unloadState?: ITelemetryUnloadState) => void | boolean;
26
- /**
27
- * Flush to send data immediately; channel should default to sending data asynchronously
28
- * @param async - send data asynchronously when true
29
- * @param callBack - if specified, notify caller when send is complete, the channel should return true to indicate to the caller that it will be called.
30
- * If the caller doesn't return true the caller should assume that it may never be called.
31
- * @param sendReason - specify the reason that you are calling "flush" defaults to ManualFlush (1) if not specified
32
- * @returns - true if the callback will be return after the flush is complete otherwise the caller should assume that any provided callback will never be called
33
- */
34
- flush?(async: boolean, callBack?: (flushComplete?: boolean) => void, sendReason?: SendRequestReason): boolean | void;
35
- }
36
- export declare const MinChannelPriorty: number;
@@ -1,9 +0,0 @@
1
- import { IChannelControls } from "./IChannelControls";
2
- import { IPlugin } from "./ITelemetryPlugin";
3
- export interface IChannelControlsHost extends IChannelControls {
4
- /**
5
- * Get and return the named channel instance (if present) from the queues
6
- * @param pluginIdentifier - The identifier name of the plugin
7
- */
8
- getChannel<T extends IPlugin = IPlugin>(pluginIdentifier: string): T;
9
- }
@@ -1,150 +0,0 @@
1
- import { ITelemetryPlugin } from "./ITelemetryPlugin";
2
- import { IChannelControls } from "./IChannelControls";
3
- import { ICookieMgrConfig } from "./ICookieMgr";
4
- import { INotificationManager } from "./INotificationManager";
5
- import { IPerfManager } from "./IPerfManager";
6
- import { IAppInsightsCore } from "./IAppInsightsCore";
7
- /**
8
- * Configuration provided to SDK core
9
- */
10
- export interface IConfiguration {
11
- /**
12
- * Instrumentation key of resource. Either this or connectionString must be specified.
13
- */
14
- instrumentationKey?: string;
15
- /**
16
- * Connection string of resource. Either this or instrumentationKey must be specified.
17
- */
18
- connectionString?: string;
19
- /**
20
- * Polling interval (in ms) for internal logging queue
21
- */
22
- diagnosticLogInterval?: number;
23
- /**
24
- * Maximum number of iKey transmitted logging telemetry per page view
25
- */
26
- maxMessageLimit?: number;
27
- /**
28
- * Console logging level. All logs with a severity level higher
29
- * than the configured level will be printed to console. Otherwise
30
- * they are suppressed. ie Level 2 will print both CRITICAL and
31
- * WARNING logs to console, level 1 prints only CRITICAL.
32
- *
33
- * Note: Logs sent as telemetry to instrumentation key will also
34
- * be logged to console if their severity meets the configured loggingConsoleLevel
35
- *
36
- * 0: ALL console logging off
37
- * 1: logs to console: severity >= CRITICAL
38
- * 2: logs to console: severity >= WARNING
39
- */
40
- loggingLevelConsole?: number;
41
- /**
42
- * Telemtry logging level to instrumentation key. All logs with a severity
43
- * level higher than the configured level will sent as telemetry data to
44
- * the configured instrumentation key.
45
- *
46
- * 0: ALL iKey logging off
47
- * 1: logs to iKey: severity >= CRITICAL
48
- * 2: logs to iKey: severity >= WARNING
49
- */
50
- loggingLevelTelemetry?: number;
51
- /**
52
- * If enabled, uncaught exceptions will be thrown to help with debugging
53
- */
54
- enableDebug?: boolean;
55
- /**
56
- * Endpoint where telemetry data is sent
57
- */
58
- endpointUrl?: string;
59
- /**
60
- * Extension configs loaded in SDK
61
- */
62
- extensionConfig?: {
63
- [key: string]: any;
64
- };
65
- /**
66
- * Additional plugins that should be loaded by core at runtime
67
- */
68
- readonly extensions?: ITelemetryPlugin[];
69
- /**
70
- * Channel queues that is setup by caller in desired order.
71
- * If channels are provided here, core will ignore any channels that are already setup, example if there is a SKU with an initialized channel
72
- */
73
- readonly channels?: IChannelControls[][];
74
- /**
75
- * @type {boolean}
76
- * Flag that disables the Instrumentation Key validation.
77
- */
78
- disableInstrumentationKeyValidation?: boolean;
79
- /**
80
- * [Optional] When enabled this will create local perfEvents based on sections of the code that have been instrumented
81
- * to emit perfEvents (via the doPerf()) when this is enabled. This can be used to identify performance issues within
82
- * the SDK, the way you are using it or optionally your own instrumented code.
83
- * The provided IPerfManager implementation does NOT send any additional telemetry events to the server it will only fire
84
- * the new perfEvent() on the INotificationManager which you can listen to.
85
- * This also does not use the window.performance API, so it will work in environments where this API is not supported.
86
- */
87
- enablePerfMgr?: boolean;
88
- /**
89
- * [Optional] Callback function that will be called to create a the IPerfManager instance when required and ```enablePerfMgr```
90
- * is enabled, this enables you to override the default creation of a PerfManager() without needing to ```setPerfMgr()```
91
- * after initialization.
92
- */
93
- createPerfMgr?: (core: IAppInsightsCore, notificationManager: INotificationManager) => IPerfManager;
94
- /**
95
- * [Optional] Fire every single performance event not just the top level root performance event. Defaults to false.
96
- */
97
- perfEvtsSendAll?: boolean;
98
- /**
99
- * [Optional] Identifies the default length used to generate random session and user id's if non currently exists for the user / session.
100
- * Defaults to 22, previous default value was 5, if you need to keep the previous maximum length you should set this value to 5.
101
- */
102
- idLength?: number;
103
- /**
104
- * @description Custom cookie domain. This is helpful if you want to share Application Insights cookies across subdomains. It
105
- * can be set here or as part of the cookieCfg.domain, the cookieCfg takes precedence if both are specified.
106
- * @type {string}
107
- * @defaultValue ""
108
- */
109
- cookieDomain?: string;
110
- /**
111
- * @description Custom cookie path. This is helpful if you want to share Application Insights cookies behind an application
112
- * gateway. It can be set here or as part of the cookieCfg.domain, the cookieCfg takes precedence if both are specified.
113
- * @type {string}
114
- * @defaultValue ""
115
- */
116
- cookiePath?: string;
117
- /**
118
- * [Optional] A boolean that indicated whether to disable the use of cookies by the SDK. If true, the SDK will not store or
119
- * read any data from cookies. Cookie usage can be re-enabled after initialization via the core.getCookieMgr().enable().
120
- */
121
- disableCookiesUsage?: boolean;
122
- /**
123
- * [Optional] A Cookie Manager configuration which includes hooks to allow interception of the get, set and delete cookie
124
- * operations. If this configuration is specified any specified enabled and domain properties will take precedence over the
125
- * cookieDomain and disableCookiesUsage values.
126
- */
127
- cookieCfg?: ICookieMgrConfig;
128
- /**
129
- * [Optional] An array of the page unload events that you would like to be ignored, special note there must be at least one valid unload
130
- * event hooked, if you list all or the runtime environment only supports a listed "disabled" event it will still be hooked, if required by the SDK.
131
- * Unload events include "beforeunload", "unload", "visibilitychange" (with 'hidden' state) and "pagehide"
132
- */
133
- disablePageUnloadEvents?: string[];
134
- /**
135
- * [Optional] An array of page show events that you would like to be ignored, special note there must be at lease one valid show event
136
- * hooked, if you list all or the runtime environment only supports a listed (disabled) event it will STILL be hooked, if required by the SDK.
137
- * Page Show events include "pageshow" and "visibilitychange" (with 'visible' state)
138
- */
139
- disablePageShowEvents?: string[];
140
- /**
141
- * [Optional] A flag for performance optimization to disable attempting to use the Chrome Debug Extension, if disabled and the extension is installed
142
- * this will not send any notifications.
143
- */
144
- disableDbgExt?: boolean;
145
- /**
146
- * Add "&w=0" parameter to support UA Parsing when web-workers don't have access to Document.
147
- * Default is false
148
- */
149
- enableWParam?: boolean;
150
- }
@@ -1,97 +0,0 @@
1
- import { ITelemetryUpdateState } from "./ITelemetryUpdateState";
2
- export interface ICookieMgr {
3
- /**
4
- * Enable or Disable the usage of cookies
5
- */
6
- setEnabled(value: boolean): void;
7
- /**
8
- * Can the system use cookies, if this returns false then all cookie setting and access functions will return nothing
9
- */
10
- isEnabled(): boolean;
11
- /**
12
- * Set the named cookie with the value and optional domain and optional
13
- * @param name - The name of the cookie
14
- * @param value - The value of the cookie (Must already be encoded)
15
- * @param maxAgeSec - [optional] The maximum number of SECONDS that this cookie should survive
16
- * @param domain - [optional] The domain to set for the cookie
17
- * @param path - [optional] Path to set for the cookie, if not supplied will default to "/"
18
- * @returns - True if the cookie was set otherwise false (Because cookie usage is not enabled or available)
19
- */
20
- set(name: string, value: string, maxAgeSec?: number, domain?: string, path?: string): boolean;
21
- /**
22
- * Get the value of the named cookie
23
- * @param name - The name of the cookie
24
- */
25
- get(name: string): string;
26
- /**
27
- * Delete/Remove the named cookie if cookie support is available and enabled.
28
- * Note: Not using "delete" as the name because it's a reserved word which would cause issues on older browsers
29
- * @param name - The name of the cookie
30
- * @param path - [optional] Path to set for the cookie, if not supplied will default to "/"
31
- * @returns - True if the cookie was marked for deletion otherwise false (Because cookie usage is not enabled or available)
32
- */
33
- del(name: string, path?: string): boolean;
34
- /**
35
- * Purge the cookie from the system if cookie support is available, this function ignores the enabled setting of the manager
36
- * so any cookie will be removed.
37
- * Note: Not using "delete" as the name because it's a reserved word which would cause issues on older browsers
38
- * @param name - The name of the cookie
39
- * @param path - [optional] Path to set for the cookie, if not supplied will default to "/"
40
- * @returns - True if the cookie was marked for deletion otherwise false (Because cookie usage is not available)
41
- */
42
- purge(name: string, path?: string): boolean;
43
- /**
44
- * Optional Callback hook to allow the diagnostic logger to update it's configuration
45
- * @param updateState
46
- */
47
- update?(updateState: ITelemetryUpdateState): void;
48
- }
49
- /**
50
- * Configuration definition for instance based cookie management configuration
51
- */
52
- export interface ICookieMgrConfig {
53
- /**
54
- * Defaults to true, A boolean that indicates whether the use of cookies by the SDK is enabled by the current instance.
55
- * If false, the instance of the SDK initialized by this configuration will not store or read any data from cookies
56
- */
57
- enabled?: boolean;
58
- /**
59
- * Custom cookie domain. This is helpful if you want to share Application Insights cookies across subdomains.
60
- */
61
- domain?: string;
62
- /**
63
- * Specifies the path to use for the cookie, defaults to '/'
64
- */
65
- path?: string;
66
- /**
67
- * Specify the cookie name(s) to be ignored, this will cause any matching cookie name to never be read or written.
68
- * They may still be explicitly purged or deleted. You do not need to repeat the name in the `blockedCookies`
69
- * configuration.(Since v2.8.8)
70
- */
71
- ignoreCookies?: string[];
72
- /**
73
- * Specify the cookie name(s) to never be written, this will cause any cookie name to never be created or updated,
74
- * they will still be read unless also included in the ignoreCookies and may still be explicitly purged or deleted.
75
- * If not provided defaults to the same list provided in ignoreCookies. (Since v2.8.8)
76
- */
77
- blockedCookies?: string[];
78
- /**
79
- * Hook function to fetch the named cookie value.
80
- * @param name - The name of the cookie
81
- */
82
- getCookie?: (name: string) => string;
83
- /**
84
- * Hook function to set the named cookie with the specified value.
85
- * @param name - The name of the cookie
86
- * @param value - The value to set for the cookie
87
- */
88
- setCookie?: (name: string, value: string) => void;
89
- /**
90
- * Hook function to delete the named cookie with the specified value, separated from
91
- * setCookie to avoid the need to parse the value to determine whether the cookie is being
92
- * added or removed.
93
- * @param name - The name of the cookie
94
- * @param cookieValue - The value to set to expire the cookie
95
- */
96
- delCookie?: (name: string, cookieValue: string) => void;
97
- }
@@ -1,10 +0,0 @@
1
- import { INotificationListener } from "./INotificationListener";
2
- export interface IDbgExtension {
3
- isEnabled: () => boolean;
4
- enable: () => void;
5
- disable: () => void;
6
- listener: INotificationListener;
7
- sendEvt?: (name: string, data: any) => void;
8
- debugMsg?: (name: string, data: any) => void;
9
- diagLog?: (name: string, data: any) => void;
10
- }
@@ -1,48 +0,0 @@
1
- import { LoggingSeverity, _InternalMessageId } from "../JavaScriptSDK.Enums/LoggingEnums";
2
- import { _InternalLogMessage } from "../JavaScriptSDK/DiagnosticLogger";
3
- import { ITelemetryUpdateState } from "./ITelemetryUpdateState";
4
- export interface IDiagnosticLogger {
5
- /**
6
- * 0: OFF
7
- * 1: only critical (default)
8
- * 2: critical + info
9
- */
10
- consoleLoggingLevel: () => number;
11
- /**
12
- * The internal logging queue
13
- */
14
- queue: _InternalLogMessage[];
15
- /**
16
- * This method will throw exceptions in debug mode or attempt to log the error as a console warning.
17
- * @param severity - The severity of the log message
18
- * @param message - The log message.
19
- */
20
- throwInternal(severity: LoggingSeverity, msgId: _InternalMessageId, msg: string, properties?: Object, isUserAct?: boolean): void;
21
- /**
22
- * This will write a warning to the console if possible
23
- * @param message - The warning message
24
- */
25
- warnToConsole(message: string): void;
26
- /**
27
- * This will write an error to the console if possible.
28
- * Provided by the default DiagnosticLogger instance, and internally the SDK will fall back to warnToConsole, however,
29
- * direct callers MUST check for its existence on the logger as you can provide your own IDiagnosticLogger instance.
30
- * @param message - The error message
31
- */
32
- errorToConsole?(message: string): void;
33
- /**
34
- * Resets the internal message count
35
- */
36
- resetInternalMessageCount(): void;
37
- /**
38
- * Logs a message to the internal queue.
39
- * @param severity - The severity of the log message
40
- * @param message - The message to log.
41
- */
42
- logInternalMessage?(severity: LoggingSeverity, message: _InternalLogMessage): void;
43
- /**
44
- * Optional Callback hook to allow the diagnostic logger to update it's configuration
45
- * @param updateState
46
- */
47
- update?(updateState: ITelemetryUpdateState): void;
48
- }
@@ -1,43 +0,0 @@
1
- export interface IDistributedTraceContext {
2
- /**
3
- * Returns the current name of the page
4
- */
5
- getName(): string;
6
- /**
7
- * Sets the current name of the page
8
- * @param pageName
9
- */
10
- setName(pageName: string): void;
11
- /**
12
- * Returns the unique identifier for a trace. All requests / spans from the same trace share the same traceId.
13
- * Must be read from incoming headers or generated according to the W3C TraceContext specification,
14
- * in a hex representation of 16-byte array. A.k.a. trace-id, TraceID or Distributed TraceID
15
- */
16
- getTraceId(): string;
17
- /**
18
- * Set the unique identifier for a trace. All requests / spans from the same trace share the same traceId.
19
- * Must be conform to the W3C TraceContext specification, in a hex representation of 16-byte array.
20
- * A.k.a. trace-id, TraceID or Distributed TraceID https://www.w3.org/TR/trace-context/#trace-id
21
- */
22
- setTraceId(newValue: string): void;
23
- /**
24
- * Self-generated 8-bytes identifier of the incoming request. Must be a hex representation of 8-byte array.
25
- * Also know as the parentId, used to link requests together
26
- */
27
- getSpanId(): string;
28
- /**
29
- * Self-generated 8-bytes identifier of the incoming request. Must be a hex representation of 8-byte array.
30
- * Also know as the parentId, used to link requests together
31
- * https://www.w3.org/TR/trace-context/#parent-id
32
- */
33
- setSpanId(newValue: string): void;
34
- /**
35
- * An integer representation of the W3C TraceContext trace-flags.
36
- */
37
- getTraceFlags(): number | undefined;
38
- /**
39
- * https://www.w3.org/TR/trace-context/#trace-flags
40
- * @param newValue
41
- */
42
- setTraceFlags(newValue?: number): void;
43
- }
@@ -1,81 +0,0 @@
1
- import { IUnloadHook } from "./IUnloadHook";
2
- /**
3
- * A callback function that will be called for the wrapped instrumentation function
4
- * before the original function is executed.
5
- */
6
- export type InstrumentorHooksCallback = (funcArgs: IInstrumentCallDetails, ...orgArgs: any[]) => void;
7
- /**
8
- * The callbacks to call for the instrumented function, you must provide at least the request and/or response callbacks, both are not required.
9
- * You must always supply the error callback
10
- */
11
- export interface IInstrumentHooksCallbacks {
12
- /**
13
- * [Optional] Namespace details (same as the namespace used for events), useful for debugging and testing to
14
- * identify the source of the instrumented hooks
15
- */
16
- ns?: string | string[];
17
- /**
18
- * The hook callback to call before the original function is called
19
- */
20
- req?: InstrumentorHooksCallback;
21
- /**
22
- * The hook callback to call after the original function was called
23
- */
24
- rsp?: InstrumentorHooksCallback;
25
- /**
26
- * The callback to call if the hook function causes an exception
27
- */
28
- hkErr?: InstrumentorHooksCallback;
29
- /**
30
- * The callback to call if the original function causes an exception, even if you
31
- * supply a callback the original exception will still be thrown
32
- */
33
- fnErr?: InstrumentorHooksCallback;
34
- }
35
- /**
36
- * The holder of the specific instance callback
37
- */
38
- export interface IInstrumentHook extends IUnloadHook {
39
- /** Unique Id for this callback on the hooked method */
40
- id: number;
41
- /** Holds the callbacks */
42
- cbks: IInstrumentHooksCallbacks;
43
- /** Remove this hook from the function */
44
- rm: () => void;
45
- }
46
- export interface IInstrumentHooks {
47
- i: number;
48
- n: string;
49
- f: any;
50
- h: IInstrumentHook[];
51
- }
52
- export interface IInstrumentCallDetails {
53
- name: string;
54
- inst: any;
55
- /**
56
- * This returns an object that the hook function can use to store hook specific
57
- * context, it it not shared with any other hook instances and is unique for the
58
- * current call.
59
- * A hook implementation can use this to pass / share context between different
60
- * hook callbacks eg. request/response requst/hookErrors etc.
61
- */
62
- ctx: () => any;
63
- /**
64
- * Allows the hook functions to replace the original arguments
65
- * @param idx - The argument index (0 based)
66
- * @param value - The new value for the argument
67
- */
68
- set: (idx: number, value: any) => void;
69
- /**
70
- * The result of the original method, only populated after the original method has returned
71
- */
72
- rslt?: any;
73
- /**
74
- * The error (exception) which occurred while executing the original method
75
- */
76
- err?: Error;
77
- /**
78
- * The Event object from (window.event) at the start of the original call
79
- */
80
- evt?: Event;
81
- }