@microsoft/applicationinsights-channel-js 2.7.2-nightly.2111-25 → 2.7.2-nightly.2112-05
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/browser/applicationinsights-channel-js.integrity.json +9 -9
- package/browser/applicationinsights-channel-js.js +2 -2
- package/browser/applicationinsights-channel-js.js.map +1 -1
- package/browser/applicationinsights-channel-js.min.js +2 -2
- package/browser/applicationinsights-channel-js.min.js.map +1 -1
- package/dist/applicationinsights-channel-js.d.ts +1 -1
- package/dist/applicationinsights-channel-js.js +2 -2
- package/dist/applicationinsights-channel-js.js.map +1 -1
- package/dist/applicationinsights-channel-js.min.js +2 -2
- package/dist/applicationinsights-channel-js.min.js.map +1 -1
- package/dist/applicationinsights-channel-js.rollup.d.ts +1 -1
- package/dist-esm/EnvelopeCreator.js +2 -2
- package/dist-esm/EnvelopeCreator.js.map +1 -1
- package/dist-esm/Interfaces.js +1 -1
- package/dist-esm/Offline.js +1 -1
- package/dist-esm/SendBuffer.js +1 -1
- package/dist-esm/Sender.js +1 -1
- package/dist-esm/Serializer.js +1 -1
- package/dist-esm/TelemetryProcessors/Sample.js +1 -1
- package/dist-esm/TelemetryProcessors/SamplingScoreGenerators/HashCodeScoreGenerator.js +1 -1
- package/dist-esm/TelemetryProcessors/SamplingScoreGenerators/SamplingScoreGenerator.js +1 -1
- package/dist-esm/applicationinsights-channel-js.js +1 -1
- package/package.json +3 -3
- package/src/EnvelopeCreator.ts +1 -1
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
|
-
* Application Insights JavaScript SDK - Channel, 2.7.2-nightly.
|
|
2
|
+
* Application Insights JavaScript SDK - Channel, 2.7.2-nightly.2112-05
|
|
3
3
|
* Copyright (c) Microsoft and contributors. All rights reserved.
|
|
4
4
|
*/
|
|
5
|
-
var e=this,t=function(e){"use strict";var o="function",s="object",i="undefined",a="prototype",l="hasOwnProperty",n=Object,u=n[a],t=n.assign,r=n.create,c=n.defineProperty,f=u[l];function d(){return typeof globalThis!==i&&globalThis?globalThis:typeof self!==i&&self?self:typeof window!==i&&window?window:typeof global!==i&&global?global:null}function p(e){throw new TypeError(e)}(d()||{}).Symbol,(d()||{}).Reflect;var g=t||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])u[l].call(t,i)&&(e[i]=t[i]);return e},m=function(e,t){return(m=n.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t[l](n)&&(e[n]=t[n])})(e,t)};function h(e,t){function n(){this.constructor=e}typeof t!==o&&null!==t&&p("Class extends value "+t+" is not a constructor or null"),m(e,t),e[a]=null===t?function(e){if(r)return r(e);if(null==e)return{};var t=typeof e;function n(){}return t!==s&&t!==o&&p("Object prototype may only be an Object:"+e),n[a]=e,new n}(t):(n[a]=t[a],new n)}var M,v="constructor",y="prototype",I="function",C="_dynInstFuncs",S="_isDynProxy",T="_dynClass",w="_dynInstChk",b=w,x="_dfOpts",N="_unknown_",_="__proto__",R="useBaseInst",A="setInstFuncs",L=Object,F=L.getPrototypeOf,E=0;function D(e,t){return e&&L[y].hasOwnProperty.call(e,t)}function B(e){return e&&(e===L[y]||e===Array[y])}function k(e){return B(e)||e===Function[y]}function P(e){if(e){if(F)return F(e);if(e=e[_]||e[y]||(e[v]?e[v][y]:null))return e}return null}function O(e,t){var n=[],r=L.getOwnPropertyNames;if(r)n=r(e);else for(var i in e)"string"==typeof i&&D(e,i)&&n.push(i);if(n&&0<n.length)for(var a=0;a<n.length;a++)t(n[a])}function U(e,t,n){return t!==v&&typeof e[t]===I&&(n||D(e,t))}function z(e){throw new TypeError("DynamicProto: "+e)}function j(e,t){for(var n=e.length-1;0<=n;n--)if(e[n]===t)return 1}function K(e,t){return D(e,y)?e.name||t||N:((e||{})[v]||{}).name||t||N}function q(e,r,t,n){D(e,y)||z("theClass is an invalid class definition.");var i=e[y];!function(e){if(F)for(var t=[],n=P(r);n&&!k(n)&&!j(t,n);){if(n===e)return 1;t.push(n),n=P(n)}}(i)&&z("["+K(e)+"] is not in class hierarchy of ["+K(r)+"]");var a=null;D(i,T)?a=i[T]:(a="_dynCls$"+K(e,"_")+"$"+E,E++,i[T]=a);var o=q[x],s=!!o[R];s&&n&&n[R]!==undefined&&(s=!!n[R]);var l,u,c,f,d,p,e=(u={},O(l=r,function(e){!u[e]&&U(l,e,!1)&&(u[e]=l[e])}),u);t(r,function(e,t,n,a){function r(e,t,n){var r,i=t[n];return i[S]&&a&&!1!==(r=e[C]||{})[b]&&(i=(r[t[T]]||{})[n]||i),function(){return i.apply(e,arguments)}}var i={};O(n,function(e){i[e]=r(t,n,e)});for(var o=P(e),s=[];o&&!k(o)&&!j(s,o);)O(o,function(e){!i[e]&&U(o,e,!F)&&(i[e]=r(t,o,e))}),s.push(o),o=P(o);return i}(i,r,e,s)),o=!!F&&!!o[A],c=i,a=a,f=r,d=e,n=!1!==(o=o&&n?!!n[A]:o),B(c)||(o=f[C]=f[C]||{},p=o[a]=o[a]||{},!1!==o[b]&&(o[b]=!!n),O(f,function(e){var n,r,i;U(f,e,!1)&&f[e]!==d[e]&&(p[e]=f[e],delete f[e],D(c,e)&&(!c[e]||c[e][S])||(c[e]=(n=c,r=e,(i=function(){var e,t;return(function(e,t,n,r){var i=null;if(e&&D(n,T)){var a=e[C]||{};if((i=(a[n[T]]||{})[t])||z("Missing ["+t+"] "+I),!i[w]&&!1!==a[b]){for(var o=!D(e,t),s=P(e),l=[];o&&s&&!k(s)&&!j(l,s);){var u=s[t];if(u){o=u===r;break}l.push(s),s=P(s)}try{o&&(e[t]=i),i[w]=1}catch(c){a[b]=!1}}}return i}(this,r,n,i)||(typeof(t=(t=n[e=r])===i?P(n)[e]:t)!==I&&z("["+e+"] is not a "+I),t)).apply(this,arguments)})[S]=1,i)))}))}q[x]={setInstFuncs:!0,useBaseInst:!0},(kt=M=M||{})[kt.CRITICAL=1]="CRITICAL",kt[kt.WARNING=2]="WARNING";var W={BrowserDoesNotSupportLocalStorage:0,BrowserCannotReadLocalStorage:1,BrowserCannotReadSessionStorage:2,BrowserCannotWriteLocalStorage:3,BrowserCannotWriteSessionStorage:4,BrowserFailedRemovalFromLocalStorage:5,BrowserFailedRemovalFromSessionStorage:6,CannotSendEmptyTelemetry:7,ClientPerformanceMathError:8,ErrorParsingAISessionCookie:9,ErrorPVCalc:10,ExceptionWhileLoggingError:11,FailedAddingTelemetryToBuffer:12,FailedMonitorAjaxAbort:13,FailedMonitorAjaxDur:14,FailedMonitorAjaxOpen:15,FailedMonitorAjaxRSC:16,FailedMonitorAjaxSend:17,FailedMonitorAjaxGetCorrelationHeader:18,FailedToAddHandlerForOnBeforeUnload:19,FailedToSendQueuedTelemetry:20,FailedToReportDataLoss:21,FlushFailed:22,MessageLimitPerPVExceeded:23,MissingRequiredFieldSpecification:24,NavigationTimingNotSupported:25,OnError:26,SessionRenewalDateIsZero:27,SenderNotInitialized:28,StartTrackEventFailed:29,StopTrackEventFailed:30,StartTrackFailed:31,StopTrackFailed:32,TelemetrySampledAndNotSent:33,TrackEventFailed:34,TrackExceptionFailed:35,TrackMetricFailed:36,TrackPVFailed:37,TrackPVFailedCalc:38,TrackTraceFailed:39,TransmissionFailed:40,FailedToSetStorageBuffer:41,FailedToRestoreStorageBuffer:42,InvalidBackendResponse:43,FailedToFixDepricatedValues:44,InvalidDurationValue:45,TelemetryEnvelopeInvalid:46,CreateEnvelopeError:47,CannotSerializeObject:48,CannotSerializeObjectNonSerializable:49,CircularReferenceDetected:50,ClearAuthContextFailed:51,ExceptionTruncated:52,IllegalCharsInName:53,ItemNotInArray:54,MaxAjaxPerPVExceeded:55,MessageTruncated:56,NameTooLong:57,SampleRateOutOfRange:58,SetAuthContextFailed:59,SetAuthContextFailedAccountName:60,StringValueTooLong:61,StartCalledMoreThanOnce:62,StopCalledWithoutStart:63,TelemetryInitializerFailed:64,TrackArgumentsNotSpecified:65,UrlTooLong:66,SessionStorageBufferFull:67,CannotAccessCookie:68,IdTooLong:69,InvalidEvent:70,FailedMonitorAjaxSetRequestHeader:71,SendBrowserInfoOnUserInit:72,PluginException:73,NotificationException:74,SnippetScriptLoadFailure:99,InvalidInstrumentationKey:100,CannotParseAiBlobValue:101,InvalidContentBlob:102,TrackPageActionEventFailed:103,FailedAddingCustomDefinedRequestContext:104,InMemoryStorageBufferFull:105},V="on",G="attachEvent",H="addEventListener",X=c;function Y(e){return u.toString.call(e)}function J(e){return e===undefined||typeof e===i}function Z(e){return null===e||J(e)}function $(e){return typeof e===s}function Q(e){return typeof e===o}function ee(e,t,n,r){void 0===r&&(r=!1);var i=!1;if(!Z(e))try{Z(e[H])?Z(e[G])||(e[G](V+t,n),i=!0):(e[H](t,n,r),i=!0)}catch(a){}return i}function te(e,t){if(e)for(var n in e)f.call(e,n)&&t.call(e,n,e[n])}function ne(e,t){return e&&t&&~e.indexOf(t)}function re(e){return"[object Array]"===Y(e)}function ie(e){return"[object Error]"===Y(e)}function ae(e){return"string"==typeof e}function oe(e){if("[object Date]"===Y(e)){var t=function(e){return 1===(e=""+e).length?"0"+e:e};return e.getUTCFullYear()+"-"+t(1+e.getUTCMonth())+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())+"."+(""+(e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}}function se(e,t,n){var r=e.length;try{for(var i=0;i<r&&!(i in e&&-1===t.call(n||e,e[i],i,e));i++);}catch(a){}}function le(e,t,n){var r=e.length,i=n||e,a=Array(r);try{for(var o=0;o<r;o++)o in e&&(a[o]=t.call(i,e[o],e))}catch(s){}return a}function ue(e){return"string"!=typeof e?e:e.replace(/^\s+|\s+$/g,"")}var ce=!{toString:null}.propertyIsEnumerable("toString"),fe=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];function de(e){var t=typeof e;t===o||t===s&&null!==e||p("objKeys called on non-object");var n,r=[];for(n in e)e&&f.call(e,n)&&r.push(n);if(ce)for(var i=fe.length,a=0;a<i;a++)e&&f.call(e,fe[a])&&r.push(fe[a]);return r}function pe(){var e=Date;return e.now?e.now():(new e).getTime()}function ge(e){return ie(e)?e.name:""}function me(e,t,n,r,i){var a=n;return e&&((a=e[t])===n||i&&!i(a)||r&&!r(n)||(e[t]=a=n)),a}function he(e){return!!e}function ve(e){return e&&n(t?t({},e):e)}var ye="window",Ie="navigator",Ce="JSON",Se="trident/",Te=null,we=null;function be(e,t){var n,r=!1;if(e){try{(r=t in e)||(n=e[a])&&(r=t in n)}catch(i){}if(!r)try{r=!J((new e)[t])}catch(i){}}return r}function xe(e){var t=d();return t&&t[e]?t[e]:e===ye&&Ne()?window:null}function Ne(){return typeof window===s&&window}function _e(){return Ne()?window:xe(ye)}function Re(){return typeof document===s&&document?document:xe("document")}function Ae(){return!(typeof navigator!==s||!navigator)}function Le(){return Ae()?navigator:xe(Ie)}function Fe(){return typeof JSON===s&&JSON||null!==xe(Ce)}function Ee(){return Fe()?JSON||xe(Ce):null}function Me(e){var t=Object[a].toString.call(e),n="";return"[object Error]"===t?n="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e.name+"'":Fe()&&(n=Ee().stringify(e)),t+n}function De(){return we=null===we?Ae()&&!!Le().sendBeacon:we}function Be(e){var t=!1;try{var t=!!xe("fetch"),n=xe("Request");t&&e&&n&&(t=be(n,"keepalive"))}catch(r){}return t}function ke(){return Te=null===Te&&(Te=typeof XDomainRequest!==undefined)&&Pe()?Te&&!be(xe("XMLHttpRequest"),"withCredentials"):Te}function Pe(){var e=!1;try{e=!!xe("XMLHttpRequest")}catch(t){}return e}var Oe=null;function Ue(e){return e?'"'+e.replace(/\"/g,"")+'"':""}function ze(e,t){var n,r=typeof console!==i?console:xe("console");r&&(n="log",Q(r[n=r[e]?e:n])&&r[n](t))}var je=(Ke.dataType="MessageData",Ke);function Ke(e,t,n,r){void 0===n&&(n=!1),this.messageId=e,this.message=(n?"AI: ":"AI (Internal): ")+e,e="",Fe()&&(e=Ee().stringify(r)),e=(t?" message:"+Ue(t):"")+(r?" props:"+Ue(e):""),this.message+=e}function qe(e,t){return(e||{}).logger||new We(t)}var We=function yr(i){this.identifier="DiagnosticLogger",this.queue=[];var s=0,l={};q(yr,this,function(a){function e(e,t){return Z(e=i[e])?t:e}function o(e,t){var n,r=(n=i,(r=(r=Oe)||!0===n.disableDbgExt?r:Oe||(n=xe("Microsoft"),Oe=n?n.ApplicationInsights:Oe))?r.ChromeDbgExt:null);r&&r.diagLog&&r.diagLog(e,t)}Z(i)&&(i={}),a.consoleLoggingLevel=function(){return e("loggingLevelConsole",0)},a.telemetryLoggingLevel=function(){return e("loggingLevelTelemetry",1)},a.maxInternalMessageLimit=function(){return e("maxMessageLimit",25)},a.enableDebugExceptions=function(){return e("enableDebugExceptions",!1)},a.throwInternal=function(e,t,n,r,i){if(t=new je(t,n,i=void 0!==i&&i,r),a.enableDebugExceptions())throw t;n=e===M.CRITICAL?"errorToConsole":"warnToConsole",J(t.message)?o("throw"+(e===M.CRITICAL?"Critical":"Warning"),t):(r=a.consoleLoggingLevel(),i?(i=+t.messageId,!l[i]&&e<=r&&(a[n](t.message),l[i]=!0)):e<=r&&a[n](t.message),a.logInternalMessage(e,t))},a.warnToConsole=function(e){ze("warn",e),o("warning",e)},a.errorToConsole=function(e){ze("error",e),o("error",e)},a.resetInternalMessageCount=function(){s=0,l={}},a.logInternalMessage=function(e,t){var n,r;s>=a.maxInternalMessageLimit()||(r=!0,n="AITR_"+t.messageId,l[n]?r=!1:l[n]=!0,r&&(e<=a.telemetryLoggingLevel()&&(a.queue.push(t),s++,o(e===M.CRITICAL?"error":"warn",t)),s===a.maxInternalMessageLimit()&&(t=new je(W.MessageLimitPerPVExceeded,r="Internal events throttle limit per PageView reached for this app.",!1),a.queue.push(t),e===M.CRITICAL?a.errorToConsole(r):a.warnToConsole(r))))}})},Ve=(Ge.ParentContextKey="parent",Ge.ChildrenContextKey="childEvts",Ge);function Ge(e,i,t){var r,a=this,o=!1;a.start=pe(),a.name=e,a.isAsync=t,a.isChildEvt=function(){return!1},Q(i)&&(o=function(e){if(X)try{var t={enumerable:!0,configurable:!0,get:function(){return!r&&Q(i)&&(r=i(),i=null),r}};return X(e,"payload",t),!0}catch(n){}return!1}(a)),a.getCtx=function(e){return e?(e===Ge.ParentContextKey||e===Ge.ChildrenContextKey?a:a.ctx||{})[e]:null},a.setCtx=function(e,t){e&&(e===Ge.ParentContextKey?(a[e]||(a.isChildEvt=function(){return!0}),a[e]=t):e===Ge.ChildrenContextKey?a[e]=t:(a.ctx=a.ctx||{})[e]=t)},a.complete=function(){var e=0,t=a.getCtx(Ge.ChildrenContextKey);if(re(t))for(var n=0;n<t.length;n++){var r=t[n];r&&(e+=r.time)}a.time=pe()-a.start,a.exTime=a.time-e,a.complete=function(){},!o&&Q(i)&&(a.payload=i())}}var He="CoreUtils.doPerf";function Xe(e,t,n,r,i){if(e){var a=e;if(a=Q(a.getPerfMgr)?a.getPerfMgr():a){var o,s=void 0,e=a.getCtx(He);try{if(s=a.create(t(),r,i))return e&&s.setCtx&&(s.setCtx(Ve.ParentContextKey,e),e.getCtx&&e.setCtx&&((o=e.getCtx(Ve.ChildrenContextKey))||(o=[],e.setCtx(Ve.ChildrenContextKey,o)),o.push(s))),a.setCtx(He,s),n(s)}catch(l){s&&s.setCtx&&s.setCtx("exception",l)}finally{s&&a.fire(s),a.setCtx(He,e)}}}return n()}var Ye=function(i,t){var a=this,o=null,s=Q(i.processTelemetry),l=Q(i.setNextPlugin);a._hasRun=!1,a.getPlugin=function(){return i},a.getNext=function(){return o},a.setNext=function(e){o=e},a.processTelemetry=function(n,r){r=r||t;var e=i?i.identifier:"TelemetryPluginChain";Xe(r?r.core():null,function(){return e+":processTelemetry"},function(){if(i&&s){a._hasRun=!0;try{r.setNext(o),l&&i.setNextPlugin(o),o&&(o._hasRun=!1),i.processTelemetry(n,r)}catch(t){var e=o&&o._hasRun;o&&e||r.diagLog().throwInternal(M.CRITICAL,W.PluginException,"Plugin ["+i.identifier+"] failed during processTelemetry - "+Me(t)),o&&!e&&o.processTelemetry(n,r)}}else o&&(a._hasRun=!0,o.processTelemetry(n,r))},function(){return{item:n}},!n.sync)}};function Je(e,t){var n=[];if(e&&0<e.length)for(var r=null,i=0;i<e.length;i++){var a=e[i];a&&Q(a.processTelemetry)&&(a=new Ye(a,t),n.push(a),r&&r.setNext(a),r=a)}return 0<n.length?n[0]:null}var Ze=function Ir(e,i,n,t){var r,a,o,s,l=this,u=null;null!==t&&(e&&Q(e.getPlugin)?u=function(e,t,n){var r=[],i=!n;if(e)for(;e;){var a=e.getPlugin();!i&&a!==n||(i=!0,r.push(a)),e=e.getNext()}return i||r.push(n),Je(r,t)}(e,l,t||e.getPlugin()):t?(r=l,o=e,s=!1,(a=t)&&e&&(o=[],se(e,function(e){!s&&e!==a||(s=!0,o.push(e))})),a&&!s&&(o=o||[]).push(a),u=Je(o,r)):J(t)&&(u=Je(e,l))),l.core=function(){return n},l.diagLog=function(){return qe(n,i)},l.getCfg=function(){return i},l.getExtCfg=function(e,t){var n,r;return void 0===t&&(t={}),!i||(r=i.extensionConfig)&&e&&(n=r[e]),n||t},l.getConfig=function(e,t,n){var r;return void 0===n&&(n=!1),(e=l.getExtCfg(e,null))&&!Z(e[t])?r=e[t]:i&&!Z(i[t])&&(r=i[t]),Z(r)?n:r},l.hasNext=function(){return null!=u},l.getNext=function(){return u},l.setNext=function(e){u=e},l.processNext=function(e){var t=u;t&&(u=t.getNext(),t.processTelemetry(e,l))},l.createNew=function(e,t){return new Ir((e=void 0===e?null:e)||u,i,n,t)}},$e="getPlugin",Qe=(et.prototype.initialize=function(e,t,n,r){this._baseTelInit(e,t,n,r)},et);function et(){var a=this,o=!1,s=null,l=null;a.core=null,a.diagLog=function(e){return a._getTelCtx(e).diagLog()},a.isInitialized=function(){return o},a.setInitialized=function(e){o=e},a.setNextPlugin=function(e){l=e},a.processNext=function(e,t){t?t.processNext(e):l&&Q(l.processTelemetry)&&l.processTelemetry(e,null)},a._getTelCtx=function(e){var t=e=void 0===e?null:e;return t||(e=s||new Ze(null,{},a.core),t=l&&l[$e]?e.createNew(null,l[$e]):e.createNew(null,l)),t},a._baseTelInit=function(e,t,n,r){e&&me(e,"extensionConfig",[],null,Z),!r&&t&&(r=t.getProcessTelContext().getNext());var i=l;l&&l[$e]&&(i=l[$e]()),a.core=t,s=new Ze(r,e,t,i),o=!0}}function tt(e,t,n){var r,i,a=t.length,o=(t&&150<(t=ue(t.toString())).length&&(r=t.substring(0,150),e&&e.throwInternal(M.WARNING,W.NameTooLong,"name is too long. It has been truncated to 150 characters.",{name:t},!0)),r||t);if(o.length!==a){for(var s=0,l=o;n[l]!==undefined;)s++,l=o.substring(0,147)+(i="00"+s).substr(i.length-3);o=l}return o}function nt(e,t,n){var r;return void 0===n&&(n=1024),t&&(n=n||1024,(t=ue(t)).toString().length>n&&(r=t.toString().substring(0,n),e&&e.throwInternal(M.WARNING,W.StringValueTooLong,"string value is too long. It has been truncated to "+n+" characters.",{value:t},!0))),r||t}function rt(e,t){return st(e,t,2048,W.UrlTooLong)}function it(e,t){var n;return t&&32768<t.length&&(n=t.substring(0,32768),e&&e.throwInternal(M.WARNING,W.MessageTruncated,"message is too long, it has been truncated to 32768 characters.",{message:t},!0)),n||t}function at(r,e){var i;return e&&(i={},te(e,function(e,t){if($(t)&&Fe())try{t=Ee().stringify(t)}catch(n){r&&r.throwInternal(M.WARNING,W.CannotSerializeObjectNonSerializable,"custom property is not valid",{exception:n},!0)}t=nt(r,t,8192),e=tt(r,e,i),i[e]=t}),e=i),e}function ot(n,e){var r;return e&&(r={},te(e,function(e,t){e=tt(n,e,r),r[e]=t}),e=r),e}function st(e,t,n,r){var i;return t&&(t=ue(t)).length>n&&(i=t.substring(0,n),e&&e.throwInternal(M.WARNING,r,"input is too long, it has been truncated to "+n+" characters.",{data:t},!0)),i||t}function lt(e){var t=""+Math.floor((e=Math.round(e=isNaN(e)||e<0?0:e))/1e3)%60,n=""+Math.floor(e/6e4)%60,r=""+Math.floor(e/36e5)%24,i=Math.floor(e/864e5),e=1===(e=""+e%1e3).length?"00"+e:2===e.length?"0"+e:e,t=t.length<2?"0"+t:t,n=n.length<2?"0"+n:n;return(0<i?i+".":"")+(r=r.length<2?"0"+r:r)+":"+n+":"+t+"."+e}var ut,ct="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",ft="sampleRate",dt="ProcessLegacy",pt="http.method",gt="not_specified";(Pn=ut=ut||{})[Pn.LocalStorage=0]="LocalStorage",Pn[Pn.SessionStorage=1]="SessionStorage",(Nn=gn=gn||{})[Nn.AI=0]="AI",Nn[Nn.AI_AND_W3C=1]="AI_AND_W3C",Nn[Nn.W3C=2]="W3C";var mt=undefined;function ht(e){try{if(Z(d()))return null;var t=new Date,n=xe(e===ut.LocalStorage?"localStorage":"sessionStorage");n.setItem(t.toString(),t.toString());var r=n.getItem(t.toString())!==t.toString();if(n.removeItem(t.toString()),!r)return n}catch(i){}return null}function vt(){return yt()?ht(ut.SessionStorage):null}function yt(){return mt=mt===undefined?!!ht(ut.SessionStorage):mt}function It(e,t){var n=vt();if(null!==n)try{return n.getItem(t)}catch(r){mt=!1,e.throwInternal(M.WARNING,W.BrowserCannotReadSessionStorage,"Browser failed read of session storage. "+ge(r),{exception:Me(r)})}return null}function Ct(e,t,n){var r=vt();if(null!==r)try{return r.setItem(t,n),1}catch(i){mt=!1,e.throwInternal(M.WARNING,W.BrowserCannotWriteSessionStorage,"Browser failed write to session storage. "+ge(i),{exception:Me(i)})}}var St=Re()||{},Tt=0,wt=[null,null,null,null,null],bt=["https://dc.services.visualstudio.com/v2/track","https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"];function xt(e){return~bt.indexOf(e.toLowerCase())}var Nt,_t=(h(Rt,Nt=function(){}),Rt);function Rt(){return Nt.call(this)||this}var At,Lt=(h(Ft,At=function(){this.ver=1,this.sampleRate=100,this.tags={}}),Ft);function Ft(e,t,n){var r=At.call(this)||this;return r.name=nt(e,n)||gt,r.data=t,r.time=oe(new Date),r.aiDataContract={time:1,iKey:1,name:1,sampleRate:function(){return 100===r.sampleRate?4:1},tags:1,data:1},r}var Et,Mt=(h(Dt,Et=On=function(){this.ver=2,this.properties={},this.measurements={}}),Dt.envelopeType="Microsoft.ApplicationInsights.{0}.Event",Dt.dataType="EventData",Dt);function Dt(e,t,n,r){var i=Et.call(this)||this;return i.aiDataContract={ver:1,name:1,properties:0,measurements:0},i.name=nt(e,t)||gt,i.properties=at(e,n),i.measurements=ot(e,r),i}var Bt=function(){},kt=function(){this.hasFullStack=!0,this.parsedStack=[]},Pt="error",Ot="stack",Ut="stackDetails",zt="errorSrc",jt="message",Kt="description";function qt(e,t){var n=e;return n&&!ae(n)&&(JSON&&JSON.stringify?(n=JSON.stringify(e),!t||n&&"{}"!==n||(n=Q(e.toString)?e.toString():""+e)):n=e+" - (Missing JSON.stringify)"),n||""}function Wt(e,t){var n=e;return e&&((n=n&&!ae(n)&&(e[jt]||e[Kt])||n)&&!ae(n)&&(n=qt(n,!0)),e.filename&&(n=n+" @"+(e.filename||"")+":"+(e.lineno||"?")+":"+(e.colno||"?"))),(t&&"String"!==t&&"Object"!==t&&"Error"!==t&&!~(n||"").indexOf(t)?t+": "+n:n)||""}function Vt(e){return e&&e.src&&ae(e.src)&&e.obj&&re(e.obj)}function Gt(e){var t=e||"",e=(t=ae(t)?t:ae(t[Ot])?t[Ot]:""+t).split("\n");return{src:t,obj:e}}function Ht(e){var t,n=null;if(e)try{e[Ot]?n=Gt(e[Ot]):e[Pt]&&e[Pt][Ot]?n=Gt(e[Pt][Ot]):e.exception&&e.exception[Ot]?n=Gt(e.exception[Ot]):Vt(e)?n=e:Vt(e[Ut])?n=e[Ut]:window.opera&&e[jt]?n=function(e){for(var t=[],n=e.split("\n"),r=0;r<n.length;r++){var i=n[r];n[r+1]&&(i+="@"+n[r+1],r++),t.push(i)}return{src:e,obj:t}}(e.message):ae(e)?n=Gt(e):(t=e[jt]||e[Kt]||"",ae(e[zt])&&(t&&(t+="\n"),t+=" from "+e[zt]),t&&(n=Gt(t)))}catch(r){n=Gt(r)}return n||{src:"",obj:null}}function Xt(e){var t="";if(e&&!(t=e.typeName||e.name||""))try{var n=/function (.{1,200})\(/.exec(e.constructor.toString()),t=n&&1<n.length?n[1]:""}catch(r){}return t}function Yt(e){if(e)try{if(!ae(e)){var t=Xt(e),n=qt(e,!1);return n&&"{}"!==n||(e[Pt]&&(t=Xt(e=e[Pt])),n=qt(e,!0)),n.indexOf(t)&&"String"!==t?t+":"+n:n}}catch(r){}return""+(e||"")}var Jt,Zt=(h($t,Jt=function(){this.ver=2,this.exceptions=[],this.properties={},this.measurements={}}),$t.CreateAutoException=function(e,t,n,r,i,a,o,s){var l=Xt(i||a||e);return{message:Wt(e,l),url:t,lineNumber:n,columnNumber:r,error:Yt(i||a||e),evt:Yt(a||e),typeName:l,stackDetails:Ht(o||i||a),errorSrc:s}},$t.CreateFromInterface=function(t,e,n,r){var i=e.exceptions&&le(e.exceptions,function(e){return en.CreateFromInterface(t,e)});return new $t(t,g(g({},e),{exceptions:i}),n,r)},$t.prototype.toInterface=function(){var e=this.exceptions,t=this.properties,n=this.measurements,r=this.severityLevel;this.ver;var i=this.problemGroup,a=this.id,o=this.isManual;return{ver:"4.0",exceptions:e instanceof Array&&le(e,function(e){return e.toInterface()})||undefined,severityLevel:r,properties:t,measurements:n,problemGroup:i,id:a,isManual:o}},$t.CreateSimpleException=function(e,t,n,r,i,a){return{exceptions:[{hasFullStack:!0,message:e,stack:i,typeName:t}]}},$t.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",$t.dataType="ExceptionData",$t.formatError=Yt,$t);function $t(e,t,n,r,i,a){var o=Jt.call(this)||this;return o.aiDataContract={ver:1,exceptions:1,severityLevel:0,properties:0,measurements:0},function(e){try{if($(e))return"ver"in e&&"exceptions"in e&&"properties"in e}catch(t){}}(t)?(o.exceptions=t.exceptions,o.properties=t.properties,o.measurements=t.measurements,t.severityLevel&&(o.severityLevel=t.severityLevel),t.id&&(o.id=t.id),t.problemGroup&&(o.problemGroup=t.problemGroup),o.ver=2,Z(t.isManual)||(o.isManual=t.isManual)):(o.exceptions=[new en(e,t,n=n||{})],o.properties=at(e,n),o.measurements=ot(e,r),i&&(o.severityLevel=i),a&&(o.id=a)),o}var Qt,en=(h(tn,Qt=kt),tn.prototype.toInterface=function(){var e=this.parsedStack instanceof Array&&le(this.parsedStack,function(e){return e.toInterface()});return{id:this.id,outerId:this.outerId,typeName:this.typeName,message:this.message,hasFullStack:this.hasFullStack,stack:this[Ot],parsedStack:e||undefined}},tn.CreateFromInterface=function(e,t){var n=t.parsedStack instanceof Array&&le(t.parsedStack,function(e){return rn.CreateFromInterface(e)})||t.parsedStack;return new tn(e,g(g({},t),{parsedStack:n}))},tn);function tn(e,t,n){var r,u,i,a,o=Qt.call(this)||this;return o.aiDataContract={id:0,outerId:0,typeName:1,message:1,hasFullStack:0,stack:0,parsedStack:2},function(e){try{if($(e))return"hasFullStack"in e&&"typeName"in e}catch(t){}}(t)?(o.typeName=t.typeName,o.message=t.message,o[Ot]=t[Ot],o.parsedStack=t.parsedStack,o.hasFullStack=t.hasFullStack):(u=(r=t)&&r.evt,ie(r)||(r=r[Pt]||u||r),o.typeName=nt(e,Xt(r))||gt,o.message=it(e,Wt(t||r,o.typeName))||gt,u=t[Ut]||Ht(t),o.parsedStack=function(e){if((e=u.obj)&&0<e.length){var t=[],n=0,r=0;if(se(e,function(e){e=e.toString(),rn.regex.test(e)&&(e=new rn(e,n++),r+=e.sizeInBytes,t.push(e))}),32768<r)for(var i=0,a=t.length-1,o=0,s=i,l=a;i<a;){if(32768<(o+=t[i].sizeInBytes+t[a].sizeInBytes)){t.splice(s,l-s+1);break}s=i,l=a,i++,a--}}return t}(),o[Ot]=(r=e,a="",(e=u)&&(e.obj?se(e.obj,function(e){a+=e+"\n"}):a=e.src||""),!(u=a)||32768<(e=""+u).length&&(i=e.substring(0,32768),r&&r.throwInternal(M.WARNING,W.ExceptionTruncated,"exception is too long, it has been truncated to 32768 characters.",{exception:u},!0)),i||u),o.hasFullStack=re(o.parsedStack)&&0<o.parsedStack.length,n&&(n.typeName=n.typeName||o.typeName)),o}var nn,rn=(h(an,nn=Bt),an.CreateFromInterface=function(e){return new an(e,null)},an.prototype.toInterface=function(){return{level:this.level,method:this.method,assembly:this.assembly,fileName:this.fileName,line:this.line}},an.regex=/^([\s]+at)?[\s]{0,50}([^\@\()]+?)[\s]{0,50}(\@|\()([^\(\n]+):([0-9]+):([0-9]+)(\)?)$/,an.baseSize=58,an);function an(e,t){var n,r=nn.call(this)||this;return r.sizeInBytes=0,r.aiDataContract={level:1,method:1,assembly:0,fileName:0,line:0},"string"==typeof e?(n=e,r.level=t,r.method="<no_method>",r.assembly=ue(n),r.fileName="",r.line=0,(n=n.match(an.regex))&&5<=n.length&&(r.method=ue(n[2])||r.method,r.fileName=ue(n[4]),r.line=parseInt(n[5])||0)):(r.level=e.level,r.method=e.method,r.assembly=e.assembly,r.fileName=e.fileName,r.line=e.line,r.sizeInBytes=0),r.sizeInBytes+=r.method.length,r.sizeInBytes+=r.fileName.length,r.sizeInBytes+=r.assembly.length,r.sizeInBytes+=an.baseSize,r.sizeInBytes+=r.level.toString().length,r.sizeInBytes+=r.line.toString().length,r}var on,c=function(){this.ver=2,this.metrics=[],this.properties={},this.measurements={}};(Pn=on={})[Pn.Measurement=0]="Measurement",Pn[Pn.Aggregation=1]="Aggregation";var sn,ln=(h(un,sn=function(){this.kind=on.Measurement}),un);function un(){var e=null!==sn&&sn.apply(this,arguments)||this;return e.aiDataContract={name:1,kind:0,value:1,count:0,min:0,max:0,stdDev:0},e}var cn,fn=(h(dn,cn=c),dn.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",dn.dataType="MetricData",dn);function dn(e,t,n,r,i,a,o,s,l){var u=cn.call(this)||this;u.aiDataContract={ver:1,metrics:1,properties:0};var c=new ln;return c.count=0<r?r:undefined,c.max=isNaN(a)||null===a?undefined:a,c.min=isNaN(i)||null===i?undefined:i,c.name=nt(e,t)||gt,c.value=n,c.stdDev=isNaN(o)||null===o?undefined:o,u.metrics=[c],u.properties=at(e,s),u.measurements=ot(e,l),u}var pn,gn=(h(mn,pn=On),mn);function mn(){var e=pn.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}var hn,vn=(h(yn,hn=gn),yn.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",yn.dataType="PageviewData",yn);function yn(e,t,n,r,i,a,o){var s=hn.call(this)||this;return s.aiDataContract={ver:1,name:0,url:0,duration:0,properties:0,measurements:0,id:0},s.id=o&&st(e,o,128,W.IdTooLong).toString(),s.url=rt(e,n),s.name=nt(e,t)||gt,isNaN(r)||(s.duration=lt(r)),s.properties=at(e,i),s.measurements=ot(e,a),s}var In,Cn=(h(Sn,In=function(){this.ver=2,this.success=!0,this.properties={},this.measurements={}}),Sn.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",Sn.dataType="RemoteDependencyData",Sn);function Sn(e,t,n,r,i,a,o,s,l,u,c,f){void 0===l&&(l="Ajax");var d=In.call(this)||this;d.aiDataContract={id:1,ver:1,name:0,resultCode:0,duration:0,success:0,data:0,target:0,type:0,properties:0,measurements:0,kind:0,value:0,count:0,min:0,max:0,stdDev:0,dependencyKind:0,dependencySource:0,commandName:0,dependencyTypeName:0},d.id=t,d.duration=lt(i),d.success=a,d.resultCode=o+"",d.type=nt(e,l);var p,g,m,h,v,y,I,C,S,T,o=(p=e,t=s,o=a=i=r,a=(l=n)&&0<l.length?(g=l,T=(S=wt)[C=Tt],St.createElement?S[C]||(T=S[C]=St.createElement("a")):T={host:(y=!0,I=null,!(v=m=g)||null!=(v=v.match(/(\w*):\/\/(.[^/:]+)(\:[\d]+)?/i))&&2<v.length&&ae(v[2])&&0<v[2].length&&(I=v[2]||"",y&&2<v.length&&(y=(v[1]||"").toLowerCase(),v=v[3]||"",I+=v="http"==y&&":80"===v||"https"==y&&":443"===v?"":v)),(m=I||"")&&null!=(h=m.match(/(www[0-9]?\.)?(.[^/:]+)(\:[\d]+)?/i))&&3<h.length&&ae(h[2])&&0<h[2].length?h[2]+(h[3]||""):m)},T.href=g,++C>=S.length&&(C=0),Tt=C,T=(s=T).host,a||(null!=s.pathname?("/"!=((n=0===s.pathname.length?"/":s.pathname)[0]||"")&&(n="/"+n),o=s.pathname,nt(p,t?t+" "+n:n)):nt(p,l))):T=i,{target:T,name:a,data:o});return d.data=rt(e,r)||o.data,d.target=nt(e,o.target),u&&(d.target="".concat(d.target," | ").concat(u)),d.name=nt(e,o.name),d.properties=at(e,c),d.measurements=ot(e,f),d}var Tn,wn=(h(bn,Tn=function(){this.ver=2,this.properties={},this.measurements={}}),bn.envelopeType="Microsoft.ApplicationInsights.{0}.Message",bn.dataType="MessageData",bn);function bn(e,t,n,r,i){var a=Tn.call(this)||this;return a.aiDataContract={ver:1,message:1,severityLevel:0,properties:0},a.message=it(e,t=t||gt),a.properties=at(e,r),a.measurements=ot(e,i),n&&(a.severityLevel=n),a}var xn,Nn=(h(_n,xn=gn),_n);function _n(){var e=xn.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}var Rn,An=(h(Ln,Rn=Nn),Ln.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",Ln.dataType="PageviewPerformanceData",Ln);function Ln(e,t,n,r,i,a,o){var s=Rn.call(this)||this;return s.aiDataContract={ver:1,name:0,url:0,duration:0,perfTotal:0,networkConnect:0,sentRequest:0,receivedResponse:0,domProcessing:0,properties:0,measurements:0},s.url=rt(e,n),s.name=nt(e,t)||gt,s.properties=at(e,i),s.measurements=ot(e,a),o&&(s.domProcessing=o.domProcessing,s.duration=o.duration,s.networkConnect=o.networkConnect,s.perfTotal=o.perfTotal,s.receivedResponse=o.receivedResponse,s.sentRequest=o.sentRequest),s}var Fn,En=(h(Mn,Fn=_t),Mn);function Mn(e,t){var n=Fn.call(this)||this;return n.aiDataContract={baseType:1,baseData:1},n.baseType=e,n.baseData=t,n}function Dn(e){var t="ai."+e+".";return function(e){return t+e}}var Bn,kn,kt=Dn("application"),Bt=Dn("device"),Pn=Dn("location"),c=Dn("operation"),On=Dn("session"),gn=Dn("user"),Nn=Dn("cloud"),_t=Dn("internal"),Un=(kn={applicationVersion:kt("ver"),applicationBuild:kt("build"),applicationTypeId:kt("typeId"),applicationId:kt("applicationId"),applicationLayer:kt("layer"),deviceId:Bt("id"),deviceIp:Bt("ip"),deviceLanguage:Bt("language"),deviceLocale:Bt("locale"),deviceModel:Bt("model"),deviceFriendlyName:Bt("friendlyName"),deviceNetwork:Bt("network"),deviceNetworkName:Bt("networkName"),deviceOEMName:Bt("oemName"),deviceOS:Bt("os"),deviceOSVersion:Bt("osVersion"),deviceRoleInstance:Bt("roleInstance"),deviceRoleName:Bt("roleName"),deviceScreenResolution:Bt("screenResolution"),deviceType:Bt("type"),deviceMachineName:Bt("machineName"),deviceVMName:Bt("vmName"),deviceBrowser:Bt("browser"),deviceBrowserVersion:Bt("browserVersion"),locationIp:Pn("ip"),locationCountry:Pn("country"),locationProvince:Pn("province"),locationCity:Pn("city"),operationId:c("id"),operationName:c("name"),operationParentId:c("parentId"),operationRootId:c("rootId"),operationSyntheticSource:c("syntheticSource"),operationCorrelationVector:c("correlationVector"),sessionId:On("id"),sessionIsFirst:On("isFirst"),sessionIsNew:On("isNew"),userAccountAcquisitionDate:gn("accountAcquisitionDate"),userAccountId:gn("accountId"),userAgent:gn("userAgent"),userId:gn("id"),userStoreRegion:gn("storeRegion"),userAuthUserId:gn("authUserId"),userAnonymousUserAcquisitionDate:gn("anonUserAcquisitionDate"),userAuthenticatedUserAcquisitionDate:gn("authUserAcquisitionDate"),cloudName:Nn("name"),cloudRole:Nn("role"),cloudRoleVer:Nn("roleVer"),cloudRoleInstance:Nn("roleInstance"),cloudEnvironment:Nn("environment"),cloudLocation:Nn("location"),cloudDeploymentUnit:Nn("deploymentUnit"),internalNodeName:_t("nodeName"),internalSdkVersion:_t("sdkVersion"),internalAgentVersion:_t("agentVersion"),internalSnippet:_t("snippet"),internalSdkSrc:_t("sdkSrc")},h(zn,Bn=function(){var n=this;te(kn,function(e,t){n[e]=t})}),zn);function zn(){return Bn.call(this)||this}var jn,Kn=new Un,qn=(h(Wn,jn=_t=function Cr(n,r){var i=[],a=!1;this._get=function(){return i},this._set=function(e){return i=e},q(Cr,this,function(t){t.enqueue=function(e){t.count()>=r.eventsLimitInMem()?a||(n.throwInternal(M.WARNING,W.InMemoryStorageBufferFull,"Maximum in-memory buffer size reached: "+t.count(),!0),a=!0):i.push(e)},t.count=function(){return i.length},t.size=function(){for(var e=i.length,t=0;t<i.length;t++)e+=i[t].length;return r.emitLineDelimitedJson()||(e+=2),e},t.clear=function(){a=!(i=[])},t.getItems=function(){return i.slice(0)},t.batchPayloads=function(e){return e&&0<e.length?r.emitLineDelimitedJson()?e.join("\n"):"["+e.join(",")+"]":null}})}),Wn);function Wn(e,t){return q(Wn,t=jn.call(this,e,t)||this,function(e,t){e.markAsSent=function(e){t.clear()},e.clearSent=function(e){}}),t}var Vn,Gn=(h(Hn,Vn=_t),Hn.BUFFER_KEY="AI_buffer",Hn.SENT_BUFFER_KEY="AI_sentBuffer",Hn.MAX_BUFFER_SIZE=2e3,Hn);function Hn(s,l){var e=Vn.call(this,s,l)||this,u=!1;return q(Hn,e,function(n,t){var e=a(Hn.BUFFER_KEY),r=a(Hn.SENT_BUFFER_KEY);function i(t,e){var n=[];return se(e,function(e){Q(e)||-1!==function(e,t){var n=e.length;try{for(var r=0;r<n;r++)if(r in e&&e[r]===t)return r}catch(i){}return-1}(t,e)||n.push(e)}),n}function a(e){try{var e=l.namePrefix&&l.namePrefix()?l.namePrefix()+"_"+e:e,t=It(s,e);if(t){var n=Ee().parse(t);if((n=ae(n)?Ee().parse(n):n)&&re(n))return n}}catch(r){s.throwInternal(M.CRITICAL,W.FailedToRestoreStorageBuffer," storage key: "+e+", "+ge(r),{exception:Me(r)})}return[]}function o(e,t){try{var e=l.namePrefix&&l.namePrefix()?l.namePrefix()+"_"+e:e,n=JSON.stringify(t);Ct(s,e,n)}catch(r){Ct(s,e,JSON.stringify([])),s.throwInternal(M.WARNING,W.FailedToSetStorageBuffer," storage key: "+e+", "+ge(r)+". Buffer cleared",{exception:Me(r)})}}(e=n._set(e.concat(r))).length>Hn.MAX_BUFFER_SIZE&&(e.length=Hn.MAX_BUFFER_SIZE),o(Hn.SENT_BUFFER_KEY,[]),o(Hn.BUFFER_KEY,e),n.enqueue=function(e){n.count()>=Hn.MAX_BUFFER_SIZE?u||(s.throwInternal(M.WARNING,W.SessionStorageBufferFull,"Maximum buffer size reached: "+n.count(),!0),u=!0):(t.enqueue(e),o(Hn.BUFFER_KEY,n._get()))},n.clear=function(){t.clear(),o(Hn.BUFFER_KEY,n._get()),o(Hn.SENT_BUFFER_KEY,[]),u=!1},n.markAsSent=function(e){o(Hn.BUFFER_KEY,n._set(i(e,n._get())));var t=a(Hn.SENT_BUFFER_KEY);t instanceof Array&&e instanceof Array&&((t=t.concat(e)).length>Hn.MAX_BUFFER_SIZE&&(s.throwInternal(M.CRITICAL,W.SessionStorageBufferFull,"Sent buffer reached its maximum size: "+t.length,!0),t.length=Hn.MAX_BUFFER_SIZE),o(Hn.SENT_BUFFER_KEY,t))},n.clearSent=function(e){e=i(e,e=a(Hn.SENT_BUFFER_KEY)),o(Hn.SENT_BUFFER_KEY,e)}}),e}var Xn="baseType",Yn="baseData",Jn="properties",Zn="true";function $n(e,t,n){return me(e,t,n,he)}function Qn(e,n,r){Z(e)||te(e,function(e,t){"number"==typeof t?r[e]=t:ae(t)?n[e]=t:Fe()&&(n[e]=Ee().stringify(t))})}function er(n,r){Z(n)||te(n,function(e,t){n[e]=t||r})}function tr(e,t,n,r){return $n(r=new Lt(e,r,t),"sampleRate",n[ft]),(n[Yn]||{}).startTime&&(r.time=oe(n[Yn].startTime)),r.iKey=n.iKey,t=n.iKey.replace(/-/g,""),r.name=r.name.replace("{0}",t),function(e,t,n){var r=n.tags=n.tags||{},i=t.ext=t.ext||{},a=t.tags=t.tags||[],o=i.user;o&&($n(r,Kn.userAuthUserId,o.authId),$n(r,Kn.userId,o.id||o.localId)),(o=i.app)&&$n(r,Kn.sessionId,o.sesId),(o=i.device)&&($n(r,Kn.deviceId,o.id||o.localId),$n(r,Kn.deviceType,o.deviceClass),$n(r,Kn.deviceIp,o.ip),$n(r,Kn.deviceModel,o.model),$n(r,Kn.deviceType,o.deviceType)),(o=t.ext.web)&&($n(r,Kn.deviceLanguage,o.browserLang),$n(r,Kn.deviceBrowserVersion,o.browserVer),$n(r,Kn.deviceBrowser,o.browser),$n(t=(t=(t=n.data=n.data||{})[Yn]=t[Yn]||{})[Jn]=t[Jn]||{},"domain",o.domain),$n(t,"isManual",o.isManual?Zn:null),$n(t,"screenRes",o.screenRes),$n(t,"userConsent",o.userConsent?Zn:null)),(o=i.os)&&$n(r,Kn.deviceOS,o.name),(i=i.trace)&&($n(r,Kn.operationParentId,i.parentID),$n(r,Kn.operationName,nt(e,i.name)),$n(r,Kn.operationId,i.traceID));for(var s={},l=a.length-1;0<=l;l--)te(a[l],function(e,t){s[e]=t}),a.splice(l,1);te(a,function(e,t){s[e]=t}),(r=g(g({},r),s))[Kn.internalSdkVersion]||(r[Kn.internalSdkVersion]="javascript:".concat(rr.Version)),n.tags=ve(r)}(e,n,r),n.tags=n.tags||[],ve(r)}function nr(e,t){Z(t[Yn])&&e.throwInternal(M.CRITICAL,W.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.")}var rr={Version:"2.7.2-nightly.2111-25"};function ir(e,t,n){nr(e,t);var r={},i={};return t[Xn]!==Mt.dataType&&(r.baseTypeSource=t[Xn]),t[Xn]===Mt.dataType?(r=t[Yn][Jn]||{},i=t[Yn].measurements||{}):t[Yn]&&Qn(t[Yn],r,i),Qn(t.data,r,i),Z(n)||er(r,n),n=t[Yn].name,i=new Mt(e,n,r,i),i=new En(Mt.dataType,i),tr(e,Mt.envelopeType,t,i)}var ar=function Sr(f){q(Sr,this,function(e){function u(o,s){var e="__aiCircularRefCheck",l={};if(!o)return f.throwInternal(M.CRITICAL,W.CannotSerializeObject,"cannot serialize object because it is null or undefined",{name:s},!0),l;if(o[e])return f.throwInternal(M.WARNING,W.CircularReferenceDetected,"Circular reference detected while serializing object",{name:s},!0),l;if(o.aiDataContract)return o[e]=!0,te(o.aiDataContract,function(e,t){var n=Q(t)?1&t():1&t,r=Q(t)?4&t():4&t,i=2&t,a=o[e]!==undefined,t=$(o[e])&&null!==o[e];!n||a||i?r||(r=void 0,(r=t?(i?c:u)(o[e],e):o[e])!==undefined&&(l[e]=r)):f.throwInternal(M.CRITICAL,W.MissingRequiredFieldSpecification,"Missing required field specification. The field is required but not present on source",{field:e,name:s})}),delete o[e],l;if("measurements"===s)l=n(o,"number",s);else if("properties"===s)l=n(o,"string",s);else if("tags"===s)l=n(o,"string",s);else if(re(o))l=c(o,s);else{f.throwInternal(M.WARNING,W.CannotSerializeObjectNonSerializable,"Attempting to serialize an object which does not implement ISerializable",{name:s},!0);try{Ee().stringify(o),l=o}catch(t){f.throwInternal(M.CRITICAL,W.CannotSerializeObject,t&&Q(t.toString)?t.toString():"Error serializing object",null,!0)}}return l}function c(e,t){if(e)if(re(e))for(var n=[],r=0;r<e.length;r++){var i=u(e[r],t+"["+r+"]");n.push(i)}else f.throwInternal(M.CRITICAL,W.ItemNotInArray,"This field was specified as an array in the contract but the item is not an array.\r\n",{name:t},!0);return n}function n(e,n,r){var i;return e&&(i={},te(e,function(e,t){"string"===n?t===undefined?i[e]="undefined":null===t?i[e]="null":t.toString?i[e]=t.toString():i[e]="invalid field: toString() is not defined.":"number"===n?t===undefined?i[e]="undefined":i[e]=null===t?"null":isNaN(t=parseFloat(t))?"NaN":t:(i[e]="invalid field: "+r+" is of unknown type.",f.throwInternal(M.CRITICAL,i[e],null,!0))})),i}e.serialize=function(e){e=u(e,"root");try{return Ee().stringify(e)}catch(t){f.throwInternal(M.CRITICAL,W.CannotSerializeObject,t&&Q(t.toString)?t.toString():"Error serializing object",null,!0)}}})};function or(){var o=_e(),s=Re(),l=!1,u=!0;q(or,this,function(e){try{var t,n;o&&ee(o,"online",r)&&(ee(o,"offline",i),l=!0),s&&(J((t=s.body||s).ononline)||(t.ononline=r,t.onoffline=i,l=!0)),!l||(n=Le())&&!Z(n.onLine)&&(u=n.onLine)}catch(a){l=!1}function r(){u=!0}function i(){u=!1}e.isListening=l,e.isOnline=function(){var e=!0,t=Le();return l?e=u:t&&!Z(t.onLine)&&(e=t.onLine),e},e.isOffline=function(){return!e.isOnline()}})}var sr=or.Offline=new or,lr=(ur.prototype.getHashCodeScore=function(e){return this.getHashCode(e)/ur.INT_MAX_VALUE*100},ur.prototype.getHashCode=function(e){if(""===e)return 0;for(;e.length<8;)e=e.concat(e);for(var t=5381,n=0;n<e.length;++n)t=(t<<5)+t+e.charCodeAt(n),t&=t;return Math.abs(t)},ur.INT_MAX_VALUE=2147483647,ur);function ur(){}var cr=function(){var t=new lr,n=new Un;this.getSamplingScore=function(e){return e.tags&&e.tags[n.userId]?t.getHashCodeScore(e.tags[n.userId]):e.ext&&e.ext.user&&e.ext.user.id?t.getHashCodeScore(e.ext.user.id):e.tags&&e.tags[n.operationId]?t.getHashCodeScore(e.tags[n.operationId]):e.ext&&e.ext.telemetryTrace&&e.ext.telemetryTrace.traceID?t.getHashCodeScore(e.ext.telemetryTrace.traceID):100*Math.random()}},fr=(dr.prototype.isSampledIn=function(e){var t=this.sampleRate;return null===t||t===undefined||100<=t||e.baseType===fn.dataType||this.samplingScoreGenerator.getSamplingScore(e)<t},dr);function dr(e,t){this.INT_MAX_VALUE=2147483647,t=t||qe(null),(100<e||e<0)&&(t.throwInternal(M.WARNING,W.SampleRateOutOfRange,"Sampling rate is out of range (0..100). Sampling will be disabled, you may be sending too much data which may affect your AI service level.",{samplingRate:e},!0),e=100),this.sampleRate=e,this.samplingScoreGenerator=new cr}function pr(e){try{return e.responseText}catch(t){}return null}function gr(){return{endpointUrl:function(){return"https://dc.services.visualstudio.com/v2/track"},emitLineDelimitedJson:function(){return!1},maxBatchInterval:function(){return 15e3},maxBatchSizeInBytes:function(){return 102400},disableTelemetry:function(){return!1},enableSessionStorageBuffer:function(){return!0},isRetryDisabled:function(){return!1},isBeaconApiDisabled:function(){return!0},disableXhr:function(){return!1},onunloadDisableFetch:function(){return!1},onunloadDisableBeacon:function(){return!1},instrumentationKey:function(){return undefined},namePrefix:function(){return undefined},samplingPercentage:function(){return 100},customHeaders:function(){return undefined},convertUndefined:function(){return undefined},eventsLimitInMem:function(){return 1e4}}}var mr,hr=((_t={})[Mt.dataType]=ir,_t[wn.dataType]=function(e,t,n){nr(e,t);var r=t[Yn].message,i=t[Yn].severityLevel,a=t[Yn][Jn]||{},o=t[Yn].measurements||{};return Qn(t.data,a,o),Z(n)||er(a,n),o=new wn(e,r,i,a,o),o=new En(wn.dataType,o),tr(e,wn.envelopeType,t,o)},_t[vn.dataType]=function(e,t,n){nr(e,t);var r,i="duration";Z(s=t[Yn])||Z(s[Jn])||Z(s[Jn][i])?Z(t.data)||Z(t.data[i])||(r=t.data[i],delete t.data[i]):(r=s[Jn][i],delete s[Jn][i]);var a=t[Yn];((t.ext||{}).trace||{}).traceID&&(u=t.ext.trace.traceID);var o=a.id||u,i=a.name,s=a.uri,l=a[Jn]||{},u=a.measurements||{};return Z(a.refUri)||(l.refUri=a.refUri),Z(a.pageType)||(l.pageType=a.pageType),Z(a.isLoggedIn)||(l.isLoggedIn=a.isLoggedIn.toString()),Z(a[Jn])||te(a[Jn],function(e,t){l[e]=t}),Qn(t.data,l,u),Z(n)||er(l,n),o=new vn(e,i,s,r,l,u,o),o=new En(vn.dataType,o),tr(e,vn.envelopeType,t,o)},_t[An.dataType]=function(e,t,n){nr(e,t);var r=t[Yn],i=r.name,a=r.uri||r.url,o=r[Jn]||{},s=r.measurements||{};return Qn(t.data,o,s),Z(n)||er(o,n),r=new An(e,i,a,undefined,o,s,r),r=new En(An.dataType,r),tr(e,An.envelopeType,t,r)},_t[Zt.dataType]=function(e,t,n){nr(e,t);var r=t[Yn].measurements||{},i=t[Yn][Jn]||{};return Qn(t.data,i,r),Z(n)||er(i,n),n=t[Yn],r=Zt.CreateFromInterface(e,n,i,r),r=new En(Zt.dataType,r),tr(e,Zt.envelopeType,t,r)},_t[fn.dataType]=function(e,t,n){nr(e,t);var r=t[Yn],i=r[Jn]||{},a=r.measurements||{};return Qn(t.data,i,a),Z(n)||er(i,n),a=new fn(e,r.name,r.average,r.sampleCount,r.min,r.max,i,a),a=new En(fn.dataType,a),tr(e,fn.envelopeType,t,a)},_t[Cn.dataType]=function(e,t,n){nr(e,t);var r=t[Yn].measurements||{},i=t[Yn][Jn]||{};Qn(t.data,i,r),Z(n)||er(i,n);var a=t[Yn];return Z(a)?(e.warnToConsole("Invalid input for dependency data"),null):(n=a[Jn]&&a[Jn][pt]?a[Jn][pt]:"GET",r=new Cn(e,a.id,a.target,a.name,a.duration,a.success,a.responseCode,n,a.type,a.correlationContext,i,r),r=new En(Cn.dataType,r),tr(e,Cn.envelopeType,t,r))},_t),Qe=(h(vr,mr=Qe),vr.constructEnvelope=function(e,t,n,r){return t=t===e.iKey||Z(t)?e:g(g({},e),{iKey:t}),(hr[t.baseType]||ir)(n,t,r)},vr);function vr(){var w,b,x=mr.call(this)||this;x.priority=1001;var n,N,_,R,A,L=!(x.identifier="AppInsightsChannelPlugin"),F={},E=0;return x._senderConfig=gr(),q(vr,x,function(u,o){function l(e,t,n,r,i,a){var o=null;u._appId||(o=g(a))&&o.appId&&(u._appId=o.appId),(e<200||300<=e)&&0!==e?(301!==e&&307!==e&&308!==e||s(n))&&!u._senderConfig.isRetryDisabled()&&y(e)?(m(t),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Response code "+e+". Will retry to send "+t.length+" items.")):u._onError(t,i):sr.isOffline()?u._senderConfig.isRetryDisabled()||(m(t,10),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Offline - Response Code: ".concat(e,". Offline status: ").concat(sr.isOffline(),". Will retry to send ").concat(t.length," items."))):(s(n),206===e?(o=o||g(a))&&!u._senderConfig.isRetryDisabled()?u._onPartialSuccess(t,o):u._onError(t,i):(w=0,u._onSuccess(t,r)))}function s(e){return!(10<=_)&&!Z(e)&&""!==e&&e!==u._senderConfig.endpointUrl()&&(u._senderConfig.endpointUrl=function(){return e},++_,1)}function t(e,t){A?A(e,!1):c(e)}function a(e){var t=Le(),n=u._buffer,r=u._senderConfig.endpointUrl(),i=u._buffer.batchPayloads(e),i=new Blob([i],{type:"text/plain;charset=UTF-8"});return(t=t.sendBeacon(r,i))&&(n.markAsSent(e),u._onSuccess(e,e.length)),t}function c(e,t){if(re(e)&&0<e.length&&!a(e)){for(var n=[],r=0;r<e.length;r++){var i=e[r];a([i])||n.push(i)}0<n.length&&(R(n,!0),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with normal sender."))}}function f(t,e){var n=new XMLHttpRequest,r=u._senderConfig.endpointUrl();try{n[ct]=!0}catch(i){}n.open("POST",r,e),n.setRequestHeader("Content-type","application/json"),xt(r)&&n.setRequestHeader("Sdk-Context","appId"),se(de(F),function(e){n.setRequestHeader(e,F[e])}),n.onreadystatechange=function(){return u._xhrReadyStateChange(n,t,t.length)},n.onerror=function(e){return u._onError(t,I(n),e)},r=u._buffer.batchPayloads(t),n.send(r),u._buffer.markAsSent(t)}function d(e,t){if(re(e)){for(var n=e.length,r=0;r<e.length;r++)n+=e[r].length;E+n<=65e3?i(e,!1):De()?c(e):(R&&R(e,!0),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with xhrSender."))}}function p(e,t){i(e,!0)}function i(n,r){var e=u._senderConfig.endpointUrl(),t=u._buffer.batchPayloads(n),i=new Blob([t],{type:"application/json"}),a=new Headers,o=t.length;xt(e)&&a.append("Sdk-Context","appId"),se(de(F),function(e){a.append(e,F[e])}),(i={method:"POST",headers:a,body:i})[ct]=!0,r||(i.keepalive=!0,E+=o),i=new Request(e,i);try{i[ct]=!0}catch(s){}fetch(i).then(function(t){r||(E-=o,o=0),t.ok?t.text().then(function(e){l(t.status,n,t.url,n.length,t.statusText,e)}):u._onError(n,t.statusText)})["catch"](function(e){r||(E-=o,o=0),u._onError(n,e.message)}),u._buffer.markAsSent(n)}function g(e){try{if(e&&""!==e){var t=Ee().parse(e);if(t&&t.itemsReceived&&t.itemsReceived>=t.itemsAccepted&&t.itemsReceived-t.itemsAccepted===t.errors.length)return t}}catch(n){u.diagLog().throwInternal(M.CRITICAL,W.InvalidBackendResponse,"Cannot parse the response. "+ge(n),{response:e})}return null}function m(e,t){if(void 0===t&&(t=1),e&&0!==e.length){var n=u._buffer;n.clearSent(e),w++;for(var r=0,i=e;r<i.length;r++){var a=i[r];n.enqueue(a)}o=w<=1?10:(o=1+Math.floor((Math.pow(2,w)-1)/2*Math.random()*10),Math.max(Math.min(o*=t,3600),10)),o=pe()+1e3*o,b=o,h()}var o}function h(){var e;n||L||(e=b?Math.max(0,b-pe()):0,e=Math.max(u._senderConfig.maxBatchInterval(),e),n=setTimeout(function(){n=null,u.triggerSend(!0,null,1)},e))}function v(){clearTimeout(n),b=n=null}function y(e){return 408===e||429===e||500===e||503===e}function I(e,t){return e?"XMLHttpRequest,Status:"+e.status+",Response:"+pr(e)||e.response||"":t}function C(t,e){var n=u._buffer,r=_e(),i=new XDomainRequest;if(i.onload=function(){return u._xdrOnLoad(i,t)},i.onerror=function(e){return u._onError(t,S(i),e)},r=r&&r.location&&r.location.protocol||"",u._senderConfig.endpointUrl().lastIndexOf(r,0))return u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Cannot send XDomain request. The endpoint URL protocol doesn't match the hosting page protocol."),void n.clear();r=u._senderConfig.endpointUrl().replace(/^(https?:)/,""),i.open("POST",r),r=n.batchPayloads(t),i.send(r),n.markAsSent(t)}function S(e,t){return e?"XDomainRequest,Response:"+pr(e)||"":t}function T(e,t){var n=u.core[n="getNotifyMgr"]?u.core[n]():u.core._notificationManager;if(n&&n.eventsSendRequest)try{n.eventsSendRequest(e,t)}catch(r){u.diagLog().throwInternal(M.CRITICAL,W.NotificationException,"send request notification failed: "+ge(r),{exception:Me(r)})}}u.pause=function(){v(),L=!0},u.resume=function(){L&&(L=!1,b=null,u._buffer.size()>u._senderConfig.maxBatchSizeInBytes()&&u.triggerSend(!0,null,10),h())},u.flush=function(){if(!L){v();try{u.triggerSend(!0,null,1)}catch(e){u.diagLog().throwInternal(M.CRITICAL,W.FlushFailed,"flush failed, telemetry will not be collected: "+ge(e),{exception:Me(e)})}}},u.onunloadFlush=function(){if(!L)if(!1!==u._senderConfig.onunloadDisableBeacon()&&!1!==u._senderConfig.isBeaconApiDisabled()||!De())u.flush();else try{u.triggerSend(!0,t,2)}catch(e){u.diagLog().throwInternal(M.CRITICAL,W.FailedToSendQueuedTelemetry,"failed to flush with beacon sender on page unload, telemetry will not be collected: "+ge(e),{exception:Me(e)})}},u.teardown=function(){!function(){throw Error("Method not implemented.")}()},u.addHeader=function(e,t){F[e]=t},u.initialize=function(e,t,n,r){o.initialize(e,t,n,r);var i=u._getTelCtx(),a=u.identifier;N=new ar(t.logger),b=null,w=0,u._sender=null,_=0,t=u.diagLog(),te(gr(),function(e,t){u._senderConfig[e]=function(){return i.getConfig(a,e,t())}}),u._buffer=new(u._senderConfig.enableSessionStorageBuffer()&&yt()?Gn:qn)(t,u._senderConfig),u._sample=new fr(u._senderConfig.samplingPercentage(),t),!Z((r=e).disableInstrumentationKeyValidation)&&r.disableInstrumentationKeyValidation||/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.test(r.instrumentationKey)||t.throwInternal(M.CRITICAL,W.InvalidInstrumentationKey,"Invalid Instrumentation key "+e.instrumentationKey),!xt(u._senderConfig.endpointUrl())&&u._senderConfig.customHeaders()&&0<u._senderConfig.customHeaders().length&&se(u._senderConfig.customHeaders(),function(e){x.addHeader(e.header,e.value)}),t=null,!(e=u._senderConfig).disableXhr()&&ke()?t=C:!e.disableXhr()&&Pe()&&(t=f),!t&&Be()&&(t=p),R=t||f,!e.isBeaconApiDisabled()&&De()&&(t=c),u._sender=t||f,A=!e.onunloadDisableFetch()&&Be(!0)?d:De()?c:!e.disableXhr()&&ke()?C:!e.disableXhr()&&Pe()?f:R},u.processTelemetry=function(e,n){n=u._getTelCtx(n);try{if(u._senderConfig.disableTelemetry())return;if(!e)return void n.diagLog().throwInternal(M.CRITICAL,W.CannotSendEmptyTelemetry,"Cannot send empty telemetry");if(e.baseData&&!e.baseType)return void n.diagLog().throwInternal(M.CRITICAL,W.InvalidEvent,"Cannot send telemetry without baseData and baseType");if(e.baseType||(e.baseType="EventData"),!u._sender)return void n.diagLog().throwInternal(M.CRITICAL,W.SenderNotInitialized,"Sender was not initialized");if(!u._sample.isSampledIn(e))return void n.diagLog().throwInternal(M.WARNING,W.TelemetrySampledAndNotSent,"Telemetry item was sampled out and not sent",{SampleRate:u._sample.sampleRate});e[ft]=u._sample.sampleRate;var t=u._senderConfig.convertUndefined()||undefined,r=e.iKey||u._senderConfig.instrumentationKey(),i=vr.constructEnvelope(e,r,n.diagLog(),t);if(!i)return void n.diagLog().throwInternal(M.CRITICAL,W.CreateEnvelopeError,"Unable to create an AppInsights envelope");var a=!1;if(e.tags&&e.tags[dt]&&(se(e.tags[dt],function(e){try{e&&!1===e(i)&&(a=!0,n.diagLog().warnToConsole("Telemetry processor check returns false"))}catch(t){n.diagLog().throwInternal(M.CRITICAL,W.TelemetryInitializerFailed,"One of telemetry initializers failed, telemetry item will not be sent: "+ge(t),{exception:Me(t)},!0)}}),delete e.tags[dt]),a)return;var o=N.serialize(i),s=u._buffer;s.size()+o.length>u._senderConfig.maxBatchSizeInBytes()&&u.triggerSend(!0,null,10),s.enqueue(o),h()}catch(l){n.diagLog().throwInternal(M.WARNING,W.FailedAddingTelemetryToBuffer,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+ge(l),{exception:Me(l)})}u.processNext(e,n)},u._xhrReadyStateChange=function(e,t,n){4===e.readyState&&l(e.status,t,e.responseURL,n,I(e),pr(e)||e.response)},u.triggerSend=function(e,t,n){if(void 0===e&&(e=!0),!L)try{var r=u._buffer;u._senderConfig.disableTelemetry()?r.clear():0<r.count()&&(a=r.getItems(),T(n||0,e),t?t.call(x,a,e):u._sender(a,e)),v()}catch(o){(!(e=ne(i=((i=(i=void 0===i?null:i)?i:(a=Le()||{})?(a.userAgent||"").toLowerCase():"")||"").toLowerCase(),"msie")?parseInt(i.split("msie")[1]):ne(i,Se)&&(i=parseInt(i.split(Se)[1]))?i+4:null)||9<e)&&u.diagLog().throwInternal(M.CRITICAL,W.TransmissionFailed,"Telemetry transmission failed, some telemetry will be lost: "+ge(o),{exception:Me(o)})}var i,a},u._onError=function(e,t,n){u.diagLog().throwInternal(M.WARNING,W.OnError,"Failed to send telemetry.",{message:t}),u._buffer.clearSent(e)},u._onPartialSuccess=function(e,t){for(var n=[],r=[],i=0,a=t.errors.reverse();i<a.length;i++){var o=a[i],s=e.splice(o.index,1)[0];(y(o.statusCode)?r:n).push(s)}0<e.length&&u._onSuccess(e,t.itemsAccepted),0<n.length&&u._onError(n,I(null,["partial success",t.itemsAccepted,"of",t.itemsReceived].join(" "))),0<r.length&&(m(r),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,"Partial success. Delivered: "+e.length+", Failed: "+n.length+". Will retry to send "+r.length+" our of "+t.itemsReceived+" items"))},u._onSuccess=function(e,t){u._buffer.clearSent(e)},u._xdrOnLoad=function(e,t){var n=pr(e);!e||n+""!="200"&&""!==n?(n=g(n))&&n.itemsReceived&&n.itemsReceived>n.itemsAccepted&&!u._senderConfig.isRetryDisabled()?u._onPartialSuccess(t,n):u._onError(t,S(e)):(w=0,u._onSuccess(t,0))}}),x}e.Sender=Qe,function(e,t,n){var r=Object.defineProperty;if(r)try{return r(e,t,n)}catch(i){}typeof n.value!==undefined&&(e[t]=n.value)}(e,"__esModule",{value:!0})};"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t(((e="undefined"!=typeof globalThis?globalThis:e||self).Microsoft=e.Microsoft||{},e.Microsoft.ApplicationInsights=e.Microsoft.ApplicationInsights||{}));
|
|
5
|
+
var e=this,t=function(e){"use strict";var o="function",s="object",i="undefined",a="prototype",l="hasOwnProperty",n=Object,u=n[a],t=n.assign,r=n.create,c=n.defineProperty,f=u[l];function d(){return typeof globalThis!==i&&globalThis?globalThis:typeof self!==i&&self?self:typeof window!==i&&window?window:typeof global!==i&&global?global:null}function p(e){throw new TypeError(e)}(d()||{}).Symbol,(d()||{}).Reflect;var g=t||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])u[l].call(t,i)&&(e[i]=t[i]);return e},m=function(e,t){return(m=n.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t[l](n)&&(e[n]=t[n])})(e,t)};function h(e,t){function n(){this.constructor=e}typeof t!==o&&null!==t&&p("Class extends value "+t+" is not a constructor or null"),m(e,t),e[a]=null===t?function(e){if(r)return r(e);if(null==e)return{};var t=typeof e;function n(){}return t!==s&&t!==o&&p("Object prototype may only be an Object:"+e),n[a]=e,new n}(t):(n[a]=t[a],new n)}var M,v="constructor",y="prototype",I="function",C="_dynInstFuncs",S="_isDynProxy",T="_dynClass",w="_dynInstChk",b=w,x="_dfOpts",N="_unknown_",_="__proto__",R="useBaseInst",A="setInstFuncs",L=Object,F=L.getPrototypeOf,E=0;function D(e,t){return e&&L[y].hasOwnProperty.call(e,t)}function B(e){return e&&(e===L[y]||e===Array[y])}function k(e){return B(e)||e===Function[y]}function P(e){if(e){if(F)return F(e);if(e=e[_]||e[y]||(e[v]?e[v][y]:null))return e}return null}function O(e,t){var n=[],r=L.getOwnPropertyNames;if(r)n=r(e);else for(var i in e)"string"==typeof i&&D(e,i)&&n.push(i);if(n&&0<n.length)for(var a=0;a<n.length;a++)t(n[a])}function U(e,t,n){return t!==v&&typeof e[t]===I&&(n||D(e,t))}function z(e){throw new TypeError("DynamicProto: "+e)}function j(e,t){for(var n=e.length-1;0<=n;n--)if(e[n]===t)return 1}function K(e,t){return D(e,y)?e.name||t||N:((e||{})[v]||{}).name||t||N}function q(e,r,t,n){D(e,y)||z("theClass is an invalid class definition.");var i=e[y];!function(e){if(F)for(var t=[],n=P(r);n&&!k(n)&&!j(t,n);){if(n===e)return 1;t.push(n),n=P(n)}}(i)&&z("["+K(e)+"] is not in class hierarchy of ["+K(r)+"]");var a=null;D(i,T)?a=i[T]:(a="_dynCls$"+K(e,"_")+"$"+E,E++,i[T]=a);var o=q[x],s=!!o[R];s&&n&&n[R]!==undefined&&(s=!!n[R]);var l,u,c,f,d,p,e=(u={},O(l=r,function(e){!u[e]&&U(l,e,!1)&&(u[e]=l[e])}),u);t(r,function(e,t,n,a){function r(e,t,n){var r,i=t[n];return i[S]&&a&&!1!==(r=e[C]||{})[b]&&(i=(r[t[T]]||{})[n]||i),function(){return i.apply(e,arguments)}}var i={};O(n,function(e){i[e]=r(t,n,e)});for(var o=P(e),s=[];o&&!k(o)&&!j(s,o);)O(o,function(e){!i[e]&&U(o,e,!F)&&(i[e]=r(t,o,e))}),s.push(o),o=P(o);return i}(i,r,e,s)),o=!!F&&!!o[A],c=i,a=a,f=r,d=e,n=!1!==(o=o&&n?!!n[A]:o),B(c)||(o=f[C]=f[C]||{},p=o[a]=o[a]||{},!1!==o[b]&&(o[b]=!!n),O(f,function(e){var n,r,i;U(f,e,!1)&&f[e]!==d[e]&&(p[e]=f[e],delete f[e],D(c,e)&&(!c[e]||c[e][S])||(c[e]=(n=c,r=e,(i=function(){var e,t;return(function(e,t,n,r){var i=null;if(e&&D(n,T)){var a=e[C]||{};if((i=(a[n[T]]||{})[t])||z("Missing ["+t+"] "+I),!i[w]&&!1!==a[b]){for(var o=!D(e,t),s=P(e),l=[];o&&s&&!k(s)&&!j(l,s);){var u=s[t];if(u){o=u===r;break}l.push(s),s=P(s)}try{o&&(e[t]=i),i[w]=1}catch(c){a[b]=!1}}}return i}(this,r,n,i)||(typeof(t=(t=n[e=r])===i?P(n)[e]:t)!==I&&z("["+e+"] is not a "+I),t)).apply(this,arguments)})[S]=1,i)))}))}q[x]={setInstFuncs:!0,useBaseInst:!0},(kt=M=M||{})[kt.CRITICAL=1]="CRITICAL",kt[kt.WARNING=2]="WARNING";var W={BrowserDoesNotSupportLocalStorage:0,BrowserCannotReadLocalStorage:1,BrowserCannotReadSessionStorage:2,BrowserCannotWriteLocalStorage:3,BrowserCannotWriteSessionStorage:4,BrowserFailedRemovalFromLocalStorage:5,BrowserFailedRemovalFromSessionStorage:6,CannotSendEmptyTelemetry:7,ClientPerformanceMathError:8,ErrorParsingAISessionCookie:9,ErrorPVCalc:10,ExceptionWhileLoggingError:11,FailedAddingTelemetryToBuffer:12,FailedMonitorAjaxAbort:13,FailedMonitorAjaxDur:14,FailedMonitorAjaxOpen:15,FailedMonitorAjaxRSC:16,FailedMonitorAjaxSend:17,FailedMonitorAjaxGetCorrelationHeader:18,FailedToAddHandlerForOnBeforeUnload:19,FailedToSendQueuedTelemetry:20,FailedToReportDataLoss:21,FlushFailed:22,MessageLimitPerPVExceeded:23,MissingRequiredFieldSpecification:24,NavigationTimingNotSupported:25,OnError:26,SessionRenewalDateIsZero:27,SenderNotInitialized:28,StartTrackEventFailed:29,StopTrackEventFailed:30,StartTrackFailed:31,StopTrackFailed:32,TelemetrySampledAndNotSent:33,TrackEventFailed:34,TrackExceptionFailed:35,TrackMetricFailed:36,TrackPVFailed:37,TrackPVFailedCalc:38,TrackTraceFailed:39,TransmissionFailed:40,FailedToSetStorageBuffer:41,FailedToRestoreStorageBuffer:42,InvalidBackendResponse:43,FailedToFixDepricatedValues:44,InvalidDurationValue:45,TelemetryEnvelopeInvalid:46,CreateEnvelopeError:47,CannotSerializeObject:48,CannotSerializeObjectNonSerializable:49,CircularReferenceDetected:50,ClearAuthContextFailed:51,ExceptionTruncated:52,IllegalCharsInName:53,ItemNotInArray:54,MaxAjaxPerPVExceeded:55,MessageTruncated:56,NameTooLong:57,SampleRateOutOfRange:58,SetAuthContextFailed:59,SetAuthContextFailedAccountName:60,StringValueTooLong:61,StartCalledMoreThanOnce:62,StopCalledWithoutStart:63,TelemetryInitializerFailed:64,TrackArgumentsNotSpecified:65,UrlTooLong:66,SessionStorageBufferFull:67,CannotAccessCookie:68,IdTooLong:69,InvalidEvent:70,FailedMonitorAjaxSetRequestHeader:71,SendBrowserInfoOnUserInit:72,PluginException:73,NotificationException:74,SnippetScriptLoadFailure:99,InvalidInstrumentationKey:100,CannotParseAiBlobValue:101,InvalidContentBlob:102,TrackPageActionEventFailed:103,FailedAddingCustomDefinedRequestContext:104,InMemoryStorageBufferFull:105},V="on",G="attachEvent",H="addEventListener",X=c;function Y(e){return u.toString.call(e)}function J(e){return e===undefined||typeof e===i}function Z(e){return null===e||J(e)}function $(e){return typeof e===s}function Q(e){return typeof e===o}function ee(e,t,n,r){void 0===r&&(r=!1);var i=!1;if(!Z(e))try{Z(e[H])?Z(e[G])||(e[G](V+t,n),i=!0):(e[H](t,n,r),i=!0)}catch(a){}return i}function te(e,t){if(e)for(var n in e)f.call(e,n)&&t.call(e,n,e[n])}function ne(e,t){return e&&t&&~e.indexOf(t)}function re(e){return"[object Array]"===Y(e)}function ie(e){return"[object Error]"===Y(e)}function ae(e){return"string"==typeof e}function oe(e){if("[object Date]"===Y(e)){var t=function(e){return 1===(e=""+e).length?"0"+e:e};return e.getUTCFullYear()+"-"+t(1+e.getUTCMonth())+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())+"."+(""+(e.getUTCMilliseconds()/1e3).toFixed(3)).slice(2,5)+"Z"}}function se(e,t,n){var r=e.length;try{for(var i=0;i<r&&!(i in e&&-1===t.call(n||e,e[i],i,e));i++);}catch(a){}}function le(e,t,n){var r=e.length,i=n||e,a=Array(r);try{for(var o=0;o<r;o++)o in e&&(a[o]=t.call(i,e[o],e))}catch(s){}return a}function ue(e){return"string"!=typeof e?e:e.replace(/^\s+|\s+$/g,"")}var ce=!{toString:null}.propertyIsEnumerable("toString"),fe=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"];function de(e){var t=typeof e;t===o||t===s&&null!==e||p("objKeys called on non-object");var n,r=[];for(n in e)e&&f.call(e,n)&&r.push(n);if(ce)for(var i=fe.length,a=0;a<i;a++)e&&f.call(e,fe[a])&&r.push(fe[a]);return r}function pe(){var e=Date;return e.now?e.now():(new e).getTime()}function ge(e){return ie(e)?e.name:""}function me(e,t,n,r,i){var a=n;return e&&((a=e[t])===n||i&&!i(a)||r&&!r(n)||(e[t]=a=n)),a}function he(e){return!!e}function ve(e){return e&&n(t?t({},e):e)}var ye="window",Ie="navigator",Ce="JSON",Se="trident/",Te=null,we=null;function be(e,t){var n,r=!1;if(e){try{(r=t in e)||(n=e[a])&&(r=t in n)}catch(i){}if(!r)try{r=!J((new e)[t])}catch(i){}}return r}function xe(e){var t=d();return t&&t[e]?t[e]:e===ye&&Ne()?window:null}function Ne(){return typeof window===s&&window}function _e(){return Ne()?window:xe(ye)}function Re(){return typeof document===s&&document?document:xe("document")}function Ae(){return!(typeof navigator!==s||!navigator)}function Le(){return Ae()?navigator:xe(Ie)}function Fe(){return typeof JSON===s&&JSON||null!==xe(Ce)}function Ee(){return Fe()?JSON||xe(Ce):null}function Me(e){var t=Object[a].toString.call(e),n="";return"[object Error]"===t?n="{ stack: '"+e.stack+"', message: '"+e.message+"', name: '"+e.name+"'":Fe()&&(n=Ee().stringify(e)),t+n}function De(){return we=null===we?Ae()&&!!Le().sendBeacon:we}function Be(e){var t=!1;try{var t=!!xe("fetch"),n=xe("Request");t&&e&&n&&(t=be(n,"keepalive"))}catch(r){}return t}function ke(){return Te=null===Te&&(Te=typeof XDomainRequest!==undefined)&&Pe()?Te&&!be(xe("XMLHttpRequest"),"withCredentials"):Te}function Pe(){var e=!1;try{e=!!xe("XMLHttpRequest")}catch(t){}return e}var Oe=null;function Ue(e){return e?'"'+e.replace(/\"/g,"")+'"':""}function ze(e,t){var n,r=typeof console!==i?console:xe("console");r&&(n="log",Q(r[n=r[e]?e:n])&&r[n](t))}var je=(Ke.dataType="MessageData",Ke);function Ke(e,t,n,r){void 0===n&&(n=!1),this.messageId=e,this.message=(n?"AI: ":"AI (Internal): ")+e,e="",Fe()&&(e=Ee().stringify(r)),e=(t?" message:"+Ue(t):"")+(r?" props:"+Ue(e):""),this.message+=e}function qe(e,t){return(e||{}).logger||new We(t)}var We=function yr(i){this.identifier="DiagnosticLogger",this.queue=[];var s=0,l={};q(yr,this,function(a){function e(e,t){return Z(e=i[e])?t:e}function o(e,t){var n,r=(n=i,(r=(r=Oe)||!0===n.disableDbgExt?r:Oe||(n=xe("Microsoft"),Oe=n?n.ApplicationInsights:Oe))?r.ChromeDbgExt:null);r&&r.diagLog&&r.diagLog(e,t)}Z(i)&&(i={}),a.consoleLoggingLevel=function(){return e("loggingLevelConsole",0)},a.telemetryLoggingLevel=function(){return e("loggingLevelTelemetry",1)},a.maxInternalMessageLimit=function(){return e("maxMessageLimit",25)},a.enableDebugExceptions=function(){return e("enableDebugExceptions",!1)},a.throwInternal=function(e,t,n,r,i){if(t=new je(t,n,i=void 0!==i&&i,r),a.enableDebugExceptions())throw t;n=e===M.CRITICAL?"errorToConsole":"warnToConsole",J(t.message)?o("throw"+(e===M.CRITICAL?"Critical":"Warning"),t):(r=a.consoleLoggingLevel(),i?(i=+t.messageId,!l[i]&&e<=r&&(a[n](t.message),l[i]=!0)):e<=r&&a[n](t.message),a.logInternalMessage(e,t))},a.warnToConsole=function(e){ze("warn",e),o("warning",e)},a.errorToConsole=function(e){ze("error",e),o("error",e)},a.resetInternalMessageCount=function(){s=0,l={}},a.logInternalMessage=function(e,t){var n,r;s>=a.maxInternalMessageLimit()||(r=!0,n="AITR_"+t.messageId,l[n]?r=!1:l[n]=!0,r&&(e<=a.telemetryLoggingLevel()&&(a.queue.push(t),s++,o(e===M.CRITICAL?"error":"warn",t)),s===a.maxInternalMessageLimit()&&(t=new je(W.MessageLimitPerPVExceeded,r="Internal events throttle limit per PageView reached for this app.",!1),a.queue.push(t),e===M.CRITICAL?a.errorToConsole(r):a.warnToConsole(r))))}})},Ve=(Ge.ParentContextKey="parent",Ge.ChildrenContextKey="childEvts",Ge);function Ge(e,i,t){var r,a=this,o=!1;a.start=pe(),a.name=e,a.isAsync=t,a.isChildEvt=function(){return!1},Q(i)&&(o=function(e){if(X)try{var t={enumerable:!0,configurable:!0,get:function(){return!r&&Q(i)&&(r=i(),i=null),r}};return X(e,"payload",t),!0}catch(n){}return!1}(a)),a.getCtx=function(e){return e?(e===Ge.ParentContextKey||e===Ge.ChildrenContextKey?a:a.ctx||{})[e]:null},a.setCtx=function(e,t){e&&(e===Ge.ParentContextKey?(a[e]||(a.isChildEvt=function(){return!0}),a[e]=t):e===Ge.ChildrenContextKey?a[e]=t:(a.ctx=a.ctx||{})[e]=t)},a.complete=function(){var e=0,t=a.getCtx(Ge.ChildrenContextKey);if(re(t))for(var n=0;n<t.length;n++){var r=t[n];r&&(e+=r.time)}a.time=pe()-a.start,a.exTime=a.time-e,a.complete=function(){},!o&&Q(i)&&(a.payload=i())}}var He="CoreUtils.doPerf";function Xe(e,t,n,r,i){if(e){var a=e;if(a=Q(a.getPerfMgr)?a.getPerfMgr():a){var o,s=void 0,e=a.getCtx(He);try{if(s=a.create(t(),r,i))return e&&s.setCtx&&(s.setCtx(Ve.ParentContextKey,e),e.getCtx&&e.setCtx&&((o=e.getCtx(Ve.ChildrenContextKey))||(o=[],e.setCtx(Ve.ChildrenContextKey,o)),o.push(s))),a.setCtx(He,s),n(s)}catch(l){s&&s.setCtx&&s.setCtx("exception",l)}finally{s&&a.fire(s),a.setCtx(He,e)}}}return n()}var Ye=function(i,t){var a=this,o=null,s=Q(i.processTelemetry),l=Q(i.setNextPlugin);a._hasRun=!1,a.getPlugin=function(){return i},a.getNext=function(){return o},a.setNext=function(e){o=e},a.processTelemetry=function(n,r){r=r||t;var e=i?i.identifier:"TelemetryPluginChain";Xe(r?r.core():null,function(){return e+":processTelemetry"},function(){if(i&&s){a._hasRun=!0;try{r.setNext(o),l&&i.setNextPlugin(o),o&&(o._hasRun=!1),i.processTelemetry(n,r)}catch(t){var e=o&&o._hasRun;o&&e||r.diagLog().throwInternal(M.CRITICAL,W.PluginException,"Plugin ["+i.identifier+"] failed during processTelemetry - "+Me(t)),o&&!e&&o.processTelemetry(n,r)}}else o&&(a._hasRun=!0,o.processTelemetry(n,r))},function(){return{item:n}},!n.sync)}};function Je(e,t){var n=[];if(e&&0<e.length)for(var r=null,i=0;i<e.length;i++){var a=e[i];a&&Q(a.processTelemetry)&&(a=new Ye(a,t),n.push(a),r&&r.setNext(a),r=a)}return 0<n.length?n[0]:null}var Ze=function Ir(e,i,n,t){var r,a,o,s,l=this,u=null;null!==t&&(e&&Q(e.getPlugin)?u=function(e,t,n){var r=[],i=!n;if(e)for(;e;){var a=e.getPlugin();!i&&a!==n||(i=!0,r.push(a)),e=e.getNext()}return i||r.push(n),Je(r,t)}(e,l,t||e.getPlugin()):t?(r=l,o=e,s=!1,(a=t)&&e&&(o=[],se(e,function(e){!s&&e!==a||(s=!0,o.push(e))})),a&&!s&&(o=o||[]).push(a),u=Je(o,r)):J(t)&&(u=Je(e,l))),l.core=function(){return n},l.diagLog=function(){return qe(n,i)},l.getCfg=function(){return i},l.getExtCfg=function(e,t){var n,r;return void 0===t&&(t={}),!i||(r=i.extensionConfig)&&e&&(n=r[e]),n||t},l.getConfig=function(e,t,n){var r;return void 0===n&&(n=!1),(e=l.getExtCfg(e,null))&&!Z(e[t])?r=e[t]:i&&!Z(i[t])&&(r=i[t]),Z(r)?n:r},l.hasNext=function(){return null!=u},l.getNext=function(){return u},l.setNext=function(e){u=e},l.processNext=function(e){var t=u;t&&(u=t.getNext(),t.processTelemetry(e,l))},l.createNew=function(e,t){return new Ir((e=void 0===e?null:e)||u,i,n,t)}},$e="getPlugin",Qe=(et.prototype.initialize=function(e,t,n,r){this._baseTelInit(e,t,n,r)},et);function et(){var a=this,o=!1,s=null,l=null;a.core=null,a.diagLog=function(e){return a._getTelCtx(e).diagLog()},a.isInitialized=function(){return o},a.setInitialized=function(e){o=e},a.setNextPlugin=function(e){l=e},a.processNext=function(e,t){t?t.processNext(e):l&&Q(l.processTelemetry)&&l.processTelemetry(e,null)},a._getTelCtx=function(e){var t=e=void 0===e?null:e;return t||(e=s||new Ze(null,{},a.core),t=l&&l[$e]?e.createNew(null,l[$e]):e.createNew(null,l)),t},a._baseTelInit=function(e,t,n,r){e&&me(e,"extensionConfig",[],null,Z),!r&&t&&(r=t.getProcessTelContext().getNext());var i=l;l&&l[$e]&&(i=l[$e]()),a.core=t,s=new Ze(r,e,t,i),o=!0}}function tt(e,t,n){var r,i,a=t.length,o=(t&&150<(t=ue(t.toString())).length&&(r=t.substring(0,150),e&&e.throwInternal(M.WARNING,W.NameTooLong,"name is too long. It has been truncated to 150 characters.",{name:t},!0)),r||t);if(o.length!==a){for(var s=0,l=o;n[l]!==undefined;)s++,l=o.substring(0,147)+(i="00"+s).substr(i.length-3);o=l}return o}function nt(e,t,n){var r;return void 0===n&&(n=1024),t&&(n=n||1024,(t=ue(t)).toString().length>n&&(r=t.toString().substring(0,n),e&&e.throwInternal(M.WARNING,W.StringValueTooLong,"string value is too long. It has been truncated to "+n+" characters.",{value:t},!0))),r||t}function rt(e,t){return st(e,t,2048,W.UrlTooLong)}function it(e,t){var n;return t&&32768<t.length&&(n=t.substring(0,32768),e&&e.throwInternal(M.WARNING,W.MessageTruncated,"message is too long, it has been truncated to 32768 characters.",{message:t},!0)),n||t}function at(r,e){var i;return e&&(i={},te(e,function(e,t){if($(t)&&Fe())try{t=Ee().stringify(t)}catch(n){r&&r.throwInternal(M.WARNING,W.CannotSerializeObjectNonSerializable,"custom property is not valid",{exception:n},!0)}t=nt(r,t,8192),e=tt(r,e,i),i[e]=t}),e=i),e}function ot(n,e){var r;return e&&(r={},te(e,function(e,t){e=tt(n,e,r),r[e]=t}),e=r),e}function st(e,t,n,r){var i;return t&&(t=ue(t)).length>n&&(i=t.substring(0,n),e&&e.throwInternal(M.WARNING,r,"input is too long, it has been truncated to "+n+" characters.",{data:t},!0)),i||t}function lt(e){var t=""+Math.floor((e=Math.round(e=isNaN(e)||e<0?0:e))/1e3)%60,n=""+Math.floor(e/6e4)%60,r=""+Math.floor(e/36e5)%24,i=Math.floor(e/864e5),e=1===(e=""+e%1e3).length?"00"+e:2===e.length?"0"+e:e,t=t.length<2?"0"+t:t,n=n.length<2?"0"+n:n;return(0<i?i+".":"")+(r=r.length<2?"0"+r:r)+":"+n+":"+t+"."+e}var ut,ct="Microsoft_ApplicationInsights_BypassAjaxInstrumentation",ft="sampleRate",dt="ProcessLegacy",pt="http.method",gt="not_specified";(Pn=ut=ut||{})[Pn.LocalStorage=0]="LocalStorage",Pn[Pn.SessionStorage=1]="SessionStorage",(Nn=gn=gn||{})[Nn.AI=0]="AI",Nn[Nn.AI_AND_W3C=1]="AI_AND_W3C",Nn[Nn.W3C=2]="W3C";var mt=undefined;function ht(e){try{if(Z(d()))return null;var t=new Date,n=xe(e===ut.LocalStorage?"localStorage":"sessionStorage");n.setItem(t.toString(),t.toString());var r=n.getItem(t.toString())!==t.toString();if(n.removeItem(t.toString()),!r)return n}catch(i){}return null}function vt(){return yt()?ht(ut.SessionStorage):null}function yt(){return mt=mt===undefined?!!ht(ut.SessionStorage):mt}function It(e,t){var n=vt();if(null!==n)try{return n.getItem(t)}catch(r){mt=!1,e.throwInternal(M.WARNING,W.BrowserCannotReadSessionStorage,"Browser failed read of session storage. "+ge(r),{exception:Me(r)})}return null}function Ct(e,t,n){var r=vt();if(null!==r)try{return r.setItem(t,n),1}catch(i){mt=!1,e.throwInternal(M.WARNING,W.BrowserCannotWriteSessionStorage,"Browser failed write to session storage. "+ge(i),{exception:Me(i)})}}var St=Re()||{},Tt=0,wt=[null,null,null,null,null],bt=["https://dc.services.visualstudio.com/v2/track","https://breeze.aimon.applicationinsights.io/v2/track","https://dc-int.services.visualstudio.com/v2/track"];function xt(e){return~bt.indexOf(e.toLowerCase())}var Nt,_t=(h(Rt,Nt=function(){}),Rt);function Rt(){return Nt.call(this)||this}var At,Lt=(h(Ft,At=function(){this.ver=1,this.sampleRate=100,this.tags={}}),Ft);function Ft(e,t,n){var r=At.call(this)||this;return r.name=nt(e,n)||gt,r.data=t,r.time=oe(new Date),r.aiDataContract={time:1,iKey:1,name:1,sampleRate:function(){return 100===r.sampleRate?4:1},tags:1,data:1},r}var Et,Mt=(h(Dt,Et=On=function(){this.ver=2,this.properties={},this.measurements={}}),Dt.envelopeType="Microsoft.ApplicationInsights.{0}.Event",Dt.dataType="EventData",Dt);function Dt(e,t,n,r){var i=Et.call(this)||this;return i.aiDataContract={ver:1,name:1,properties:0,measurements:0},i.name=nt(e,t)||gt,i.properties=at(e,n),i.measurements=ot(e,r),i}var Bt=function(){},kt=function(){this.hasFullStack=!0,this.parsedStack=[]},Pt="error",Ot="stack",Ut="stackDetails",zt="errorSrc",jt="message",Kt="description";function qt(e,t){var n=e;return n&&!ae(n)&&(JSON&&JSON.stringify?(n=JSON.stringify(e),!t||n&&"{}"!==n||(n=Q(e.toString)?e.toString():""+e)):n=e+" - (Missing JSON.stringify)"),n||""}function Wt(e,t){var n=e;return e&&((n=n&&!ae(n)&&(e[jt]||e[Kt])||n)&&!ae(n)&&(n=qt(n,!0)),e.filename&&(n=n+" @"+(e.filename||"")+":"+(e.lineno||"?")+":"+(e.colno||"?"))),(t&&"String"!==t&&"Object"!==t&&"Error"!==t&&!~(n||"").indexOf(t)?t+": "+n:n)||""}function Vt(e){return e&&e.src&&ae(e.src)&&e.obj&&re(e.obj)}function Gt(e){var t=e||"",e=(t=ae(t)?t:ae(t[Ot])?t[Ot]:""+t).split("\n");return{src:t,obj:e}}function Ht(e){var t,n=null;if(e)try{e[Ot]?n=Gt(e[Ot]):e[Pt]&&e[Pt][Ot]?n=Gt(e[Pt][Ot]):e.exception&&e.exception[Ot]?n=Gt(e.exception[Ot]):Vt(e)?n=e:Vt(e[Ut])?n=e[Ut]:window.opera&&e[jt]?n=function(e){for(var t=[],n=e.split("\n"),r=0;r<n.length;r++){var i=n[r];n[r+1]&&(i+="@"+n[r+1],r++),t.push(i)}return{src:e,obj:t}}(e.message):ae(e)?n=Gt(e):(t=e[jt]||e[Kt]||"",ae(e[zt])&&(t&&(t+="\n"),t+=" from "+e[zt]),t&&(n=Gt(t)))}catch(r){n=Gt(r)}return n||{src:"",obj:null}}function Xt(e){var t="";if(e&&!(t=e.typeName||e.name||""))try{var n=/function (.{1,200})\(/.exec(e.constructor.toString()),t=n&&1<n.length?n[1]:""}catch(r){}return t}function Yt(e){if(e)try{if(!ae(e)){var t=Xt(e),n=qt(e,!1);return n&&"{}"!==n||(e[Pt]&&(t=Xt(e=e[Pt])),n=qt(e,!0)),n.indexOf(t)&&"String"!==t?t+":"+n:n}}catch(r){}return""+(e||"")}var Jt,Zt=(h($t,Jt=function(){this.ver=2,this.exceptions=[],this.properties={},this.measurements={}}),$t.CreateAutoException=function(e,t,n,r,i,a,o,s){var l=Xt(i||a||e);return{message:Wt(e,l),url:t,lineNumber:n,columnNumber:r,error:Yt(i||a||e),evt:Yt(a||e),typeName:l,stackDetails:Ht(o||i||a),errorSrc:s}},$t.CreateFromInterface=function(t,e,n,r){var i=e.exceptions&&le(e.exceptions,function(e){return en.CreateFromInterface(t,e)});return new $t(t,g(g({},e),{exceptions:i}),n,r)},$t.prototype.toInterface=function(){var e=this.exceptions,t=this.properties,n=this.measurements,r=this.severityLevel;this.ver;var i=this.problemGroup,a=this.id,o=this.isManual;return{ver:"4.0",exceptions:e instanceof Array&&le(e,function(e){return e.toInterface()})||undefined,severityLevel:r,properties:t,measurements:n,problemGroup:i,id:a,isManual:o}},$t.CreateSimpleException=function(e,t,n,r,i,a){return{exceptions:[{hasFullStack:!0,message:e,stack:i,typeName:t}]}},$t.envelopeType="Microsoft.ApplicationInsights.{0}.Exception",$t.dataType="ExceptionData",$t.formatError=Yt,$t);function $t(e,t,n,r,i,a){var o=Jt.call(this)||this;return o.aiDataContract={ver:1,exceptions:1,severityLevel:0,properties:0,measurements:0},function(e){try{if($(e))return"ver"in e&&"exceptions"in e&&"properties"in e}catch(t){}}(t)?(o.exceptions=t.exceptions,o.properties=t.properties,o.measurements=t.measurements,t.severityLevel&&(o.severityLevel=t.severityLevel),t.id&&(o.id=t.id),t.problemGroup&&(o.problemGroup=t.problemGroup),o.ver=2,Z(t.isManual)||(o.isManual=t.isManual)):(o.exceptions=[new en(e,t,n=n||{})],o.properties=at(e,n),o.measurements=ot(e,r),i&&(o.severityLevel=i),a&&(o.id=a)),o}var Qt,en=(h(tn,Qt=kt),tn.prototype.toInterface=function(){var e=this.parsedStack instanceof Array&&le(this.parsedStack,function(e){return e.toInterface()});return{id:this.id,outerId:this.outerId,typeName:this.typeName,message:this.message,hasFullStack:this.hasFullStack,stack:this[Ot],parsedStack:e||undefined}},tn.CreateFromInterface=function(e,t){var n=t.parsedStack instanceof Array&&le(t.parsedStack,function(e){return rn.CreateFromInterface(e)})||t.parsedStack;return new tn(e,g(g({},t),{parsedStack:n}))},tn);function tn(e,t,n){var r,u,i,a,o=Qt.call(this)||this;return o.aiDataContract={id:0,outerId:0,typeName:1,message:1,hasFullStack:0,stack:0,parsedStack:2},function(e){try{if($(e))return"hasFullStack"in e&&"typeName"in e}catch(t){}}(t)?(o.typeName=t.typeName,o.message=t.message,o[Ot]=t[Ot],o.parsedStack=t.parsedStack,o.hasFullStack=t.hasFullStack):(u=(r=t)&&r.evt,ie(r)||(r=r[Pt]||u||r),o.typeName=nt(e,Xt(r))||gt,o.message=it(e,Wt(t||r,o.typeName))||gt,u=t[Ut]||Ht(t),o.parsedStack=function(e){if((e=u.obj)&&0<e.length){var t=[],n=0,r=0;if(se(e,function(e){e=e.toString(),rn.regex.test(e)&&(e=new rn(e,n++),r+=e.sizeInBytes,t.push(e))}),32768<r)for(var i=0,a=t.length-1,o=0,s=i,l=a;i<a;){if(32768<(o+=t[i].sizeInBytes+t[a].sizeInBytes)){t.splice(s,l-s+1);break}s=i,l=a,i++,a--}}return t}(),o[Ot]=(r=e,a="",(e=u)&&(e.obj?se(e.obj,function(e){a+=e+"\n"}):a=e.src||""),!(u=a)||32768<(e=""+u).length&&(i=e.substring(0,32768),r&&r.throwInternal(M.WARNING,W.ExceptionTruncated,"exception is too long, it has been truncated to 32768 characters.",{exception:u},!0)),i||u),o.hasFullStack=re(o.parsedStack)&&0<o.parsedStack.length,n&&(n.typeName=n.typeName||o.typeName)),o}var nn,rn=(h(an,nn=Bt),an.CreateFromInterface=function(e){return new an(e,null)},an.prototype.toInterface=function(){return{level:this.level,method:this.method,assembly:this.assembly,fileName:this.fileName,line:this.line}},an.regex=/^([\s]+at)?[\s]{0,50}([^\@\()]+?)[\s]{0,50}(\@|\()([^\(\n]+):([0-9]+):([0-9]+)(\)?)$/,an.baseSize=58,an);function an(e,t){var n,r=nn.call(this)||this;return r.sizeInBytes=0,r.aiDataContract={level:1,method:1,assembly:0,fileName:0,line:0},"string"==typeof e?(n=e,r.level=t,r.method="<no_method>",r.assembly=ue(n),r.fileName="",r.line=0,(n=n.match(an.regex))&&5<=n.length&&(r.method=ue(n[2])||r.method,r.fileName=ue(n[4]),r.line=parseInt(n[5])||0)):(r.level=e.level,r.method=e.method,r.assembly=e.assembly,r.fileName=e.fileName,r.line=e.line,r.sizeInBytes=0),r.sizeInBytes+=r.method.length,r.sizeInBytes+=r.fileName.length,r.sizeInBytes+=r.assembly.length,r.sizeInBytes+=an.baseSize,r.sizeInBytes+=r.level.toString().length,r.sizeInBytes+=r.line.toString().length,r}var on,c=function(){this.ver=2,this.metrics=[],this.properties={},this.measurements={}};(Pn=on={})[Pn.Measurement=0]="Measurement",Pn[Pn.Aggregation=1]="Aggregation";var sn,ln=(h(un,sn=function(){this.kind=on.Measurement}),un);function un(){var e=null!==sn&&sn.apply(this,arguments)||this;return e.aiDataContract={name:1,kind:0,value:1,count:0,min:0,max:0,stdDev:0},e}var cn,fn=(h(dn,cn=c),dn.envelopeType="Microsoft.ApplicationInsights.{0}.Metric",dn.dataType="MetricData",dn);function dn(e,t,n,r,i,a,o,s,l){var u=cn.call(this)||this;u.aiDataContract={ver:1,metrics:1,properties:0};var c=new ln;return c.count=0<r?r:undefined,c.max=isNaN(a)||null===a?undefined:a,c.min=isNaN(i)||null===i?undefined:i,c.name=nt(e,t)||gt,c.value=n,c.stdDev=isNaN(o)||null===o?undefined:o,u.metrics=[c],u.properties=at(e,s),u.measurements=ot(e,l),u}var pn,gn=(h(mn,pn=On),mn);function mn(){var e=pn.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}var hn,vn=(h(yn,hn=gn),yn.envelopeType="Microsoft.ApplicationInsights.{0}.Pageview",yn.dataType="PageviewData",yn);function yn(e,t,n,r,i,a,o){var s=hn.call(this)||this;return s.aiDataContract={ver:1,name:0,url:0,duration:0,properties:0,measurements:0,id:0},s.id=o&&st(e,o,128,W.IdTooLong).toString(),s.url=rt(e,n),s.name=nt(e,t)||gt,isNaN(r)||(s.duration=lt(r)),s.properties=at(e,i),s.measurements=ot(e,a),s}var In,Cn=(h(Sn,In=function(){this.ver=2,this.success=!0,this.properties={},this.measurements={}}),Sn.envelopeType="Microsoft.ApplicationInsights.{0}.RemoteDependency",Sn.dataType="RemoteDependencyData",Sn);function Sn(e,t,n,r,i,a,o,s,l,u,c,f){void 0===l&&(l="Ajax");var d=In.call(this)||this;d.aiDataContract={id:1,ver:1,name:0,resultCode:0,duration:0,success:0,data:0,target:0,type:0,properties:0,measurements:0,kind:0,value:0,count:0,min:0,max:0,stdDev:0,dependencyKind:0,dependencySource:0,commandName:0,dependencyTypeName:0},d.id=t,d.duration=lt(i),d.success=a,d.resultCode=o+"",d.type=nt(e,l);var p,g,m,h,v,y,I,C,S,T,o=(p=e,t=s,o=a=i=r,a=(l=n)&&0<l.length?(g=l,T=(S=wt)[C=Tt],St.createElement?S[C]||(T=S[C]=St.createElement("a")):T={host:(y=!0,I=null,!(v=m=g)||null!=(v=v.match(/(\w*):\/\/(.[^/:]+)(\:[\d]+)?/i))&&2<v.length&&ae(v[2])&&0<v[2].length&&(I=v[2]||"",y&&2<v.length&&(y=(v[1]||"").toLowerCase(),v=v[3]||"",I+=v="http"==y&&":80"===v||"https"==y&&":443"===v?"":v)),(m=I||"")&&null!=(h=m.match(/(www[0-9]?\.)?(.[^/:]+)(\:[\d]+)?/i))&&3<h.length&&ae(h[2])&&0<h[2].length?h[2]+(h[3]||""):m)},T.href=g,++C>=S.length&&(C=0),Tt=C,T=(s=T).host,a||(null!=s.pathname?("/"!=((n=0===s.pathname.length?"/":s.pathname)[0]||"")&&(n="/"+n),o=s.pathname,nt(p,t?t+" "+n:n)):nt(p,l))):T=i,{target:T,name:a,data:o});return d.data=rt(e,r)||o.data,d.target=nt(e,o.target),u&&(d.target="".concat(d.target," | ").concat(u)),d.name=nt(e,o.name),d.properties=at(e,c),d.measurements=ot(e,f),d}var Tn,wn=(h(bn,Tn=function(){this.ver=2,this.properties={},this.measurements={}}),bn.envelopeType="Microsoft.ApplicationInsights.{0}.Message",bn.dataType="MessageData",bn);function bn(e,t,n,r,i){var a=Tn.call(this)||this;return a.aiDataContract={ver:1,message:1,severityLevel:0,properties:0},a.message=it(e,t=t||gt),a.properties=at(e,r),a.measurements=ot(e,i),n&&(a.severityLevel=n),a}var xn,Nn=(h(_n,xn=gn),_n);function _n(){var e=xn.call(this)||this;return e.ver=2,e.properties={},e.measurements={},e}var Rn,An=(h(Ln,Rn=Nn),Ln.envelopeType="Microsoft.ApplicationInsights.{0}.PageviewPerformance",Ln.dataType="PageviewPerformanceData",Ln);function Ln(e,t,n,r,i,a,o){var s=Rn.call(this)||this;return s.aiDataContract={ver:1,name:0,url:0,duration:0,perfTotal:0,networkConnect:0,sentRequest:0,receivedResponse:0,domProcessing:0,properties:0,measurements:0},s.url=rt(e,n),s.name=nt(e,t)||gt,s.properties=at(e,i),s.measurements=ot(e,a),o&&(s.domProcessing=o.domProcessing,s.duration=o.duration,s.networkConnect=o.networkConnect,s.perfTotal=o.perfTotal,s.receivedResponse=o.receivedResponse,s.sentRequest=o.sentRequest),s}var Fn,En=(h(Mn,Fn=_t),Mn);function Mn(e,t){var n=Fn.call(this)||this;return n.aiDataContract={baseType:1,baseData:1},n.baseType=e,n.baseData=t,n}function Dn(e){var t="ai."+e+".";return function(e){return t+e}}var Bn,kn,kt=Dn("application"),Bt=Dn("device"),Pn=Dn("location"),c=Dn("operation"),On=Dn("session"),gn=Dn("user"),Nn=Dn("cloud"),_t=Dn("internal"),Un=(kn={applicationVersion:kt("ver"),applicationBuild:kt("build"),applicationTypeId:kt("typeId"),applicationId:kt("applicationId"),applicationLayer:kt("layer"),deviceId:Bt("id"),deviceIp:Bt("ip"),deviceLanguage:Bt("language"),deviceLocale:Bt("locale"),deviceModel:Bt("model"),deviceFriendlyName:Bt("friendlyName"),deviceNetwork:Bt("network"),deviceNetworkName:Bt("networkName"),deviceOEMName:Bt("oemName"),deviceOS:Bt("os"),deviceOSVersion:Bt("osVersion"),deviceRoleInstance:Bt("roleInstance"),deviceRoleName:Bt("roleName"),deviceScreenResolution:Bt("screenResolution"),deviceType:Bt("type"),deviceMachineName:Bt("machineName"),deviceVMName:Bt("vmName"),deviceBrowser:Bt("browser"),deviceBrowserVersion:Bt("browserVersion"),locationIp:Pn("ip"),locationCountry:Pn("country"),locationProvince:Pn("province"),locationCity:Pn("city"),operationId:c("id"),operationName:c("name"),operationParentId:c("parentId"),operationRootId:c("rootId"),operationSyntheticSource:c("syntheticSource"),operationCorrelationVector:c("correlationVector"),sessionId:On("id"),sessionIsFirst:On("isFirst"),sessionIsNew:On("isNew"),userAccountAcquisitionDate:gn("accountAcquisitionDate"),userAccountId:gn("accountId"),userAgent:gn("userAgent"),userId:gn("id"),userStoreRegion:gn("storeRegion"),userAuthUserId:gn("authUserId"),userAnonymousUserAcquisitionDate:gn("anonUserAcquisitionDate"),userAuthenticatedUserAcquisitionDate:gn("authUserAcquisitionDate"),cloudName:Nn("name"),cloudRole:Nn("role"),cloudRoleVer:Nn("roleVer"),cloudRoleInstance:Nn("roleInstance"),cloudEnvironment:Nn("environment"),cloudLocation:Nn("location"),cloudDeploymentUnit:Nn("deploymentUnit"),internalNodeName:_t("nodeName"),internalSdkVersion:_t("sdkVersion"),internalAgentVersion:_t("agentVersion"),internalSnippet:_t("snippet"),internalSdkSrc:_t("sdkSrc")},h(zn,Bn=function(){var n=this;te(kn,function(e,t){n[e]=t})}),zn);function zn(){return Bn.call(this)||this}var jn,Kn=new Un,qn=(h(Wn,jn=_t=function Cr(n,r){var i=[],a=!1;this._get=function(){return i},this._set=function(e){return i=e},q(Cr,this,function(t){t.enqueue=function(e){t.count()>=r.eventsLimitInMem()?a||(n.throwInternal(M.WARNING,W.InMemoryStorageBufferFull,"Maximum in-memory buffer size reached: "+t.count(),!0),a=!0):i.push(e)},t.count=function(){return i.length},t.size=function(){for(var e=i.length,t=0;t<i.length;t++)e+=i[t].length;return r.emitLineDelimitedJson()||(e+=2),e},t.clear=function(){a=!(i=[])},t.getItems=function(){return i.slice(0)},t.batchPayloads=function(e){return e&&0<e.length?r.emitLineDelimitedJson()?e.join("\n"):"["+e.join(",")+"]":null}})}),Wn);function Wn(e,t){return q(Wn,t=jn.call(this,e,t)||this,function(e,t){e.markAsSent=function(e){t.clear()},e.clearSent=function(e){}}),t}var Vn,Gn=(h(Hn,Vn=_t),Hn.BUFFER_KEY="AI_buffer",Hn.SENT_BUFFER_KEY="AI_sentBuffer",Hn.MAX_BUFFER_SIZE=2e3,Hn);function Hn(s,l){var e=Vn.call(this,s,l)||this,u=!1;return q(Hn,e,function(n,t){var e=a(Hn.BUFFER_KEY),r=a(Hn.SENT_BUFFER_KEY);function i(t,e){var n=[];return se(e,function(e){Q(e)||-1!==function(e,t){var n=e.length;try{for(var r=0;r<n;r++)if(r in e&&e[r]===t)return r}catch(i){}return-1}(t,e)||n.push(e)}),n}function a(e){try{var e=l.namePrefix&&l.namePrefix()?l.namePrefix()+"_"+e:e,t=It(s,e);if(t){var n=Ee().parse(t);if((n=ae(n)?Ee().parse(n):n)&&re(n))return n}}catch(r){s.throwInternal(M.CRITICAL,W.FailedToRestoreStorageBuffer," storage key: "+e+", "+ge(r),{exception:Me(r)})}return[]}function o(e,t){try{var e=l.namePrefix&&l.namePrefix()?l.namePrefix()+"_"+e:e,n=JSON.stringify(t);Ct(s,e,n)}catch(r){Ct(s,e,JSON.stringify([])),s.throwInternal(M.WARNING,W.FailedToSetStorageBuffer," storage key: "+e+", "+ge(r)+". Buffer cleared",{exception:Me(r)})}}(e=n._set(e.concat(r))).length>Hn.MAX_BUFFER_SIZE&&(e.length=Hn.MAX_BUFFER_SIZE),o(Hn.SENT_BUFFER_KEY,[]),o(Hn.BUFFER_KEY,e),n.enqueue=function(e){n.count()>=Hn.MAX_BUFFER_SIZE?u||(s.throwInternal(M.WARNING,W.SessionStorageBufferFull,"Maximum buffer size reached: "+n.count(),!0),u=!0):(t.enqueue(e),o(Hn.BUFFER_KEY,n._get()))},n.clear=function(){t.clear(),o(Hn.BUFFER_KEY,n._get()),o(Hn.SENT_BUFFER_KEY,[]),u=!1},n.markAsSent=function(e){o(Hn.BUFFER_KEY,n._set(i(e,n._get())));var t=a(Hn.SENT_BUFFER_KEY);t instanceof Array&&e instanceof Array&&((t=t.concat(e)).length>Hn.MAX_BUFFER_SIZE&&(s.throwInternal(M.CRITICAL,W.SessionStorageBufferFull,"Sent buffer reached its maximum size: "+t.length,!0),t.length=Hn.MAX_BUFFER_SIZE),o(Hn.SENT_BUFFER_KEY,t))},n.clearSent=function(e){e=i(e,e=a(Hn.SENT_BUFFER_KEY)),o(Hn.SENT_BUFFER_KEY,e)}}),e}var Xn="baseType",Yn="baseData",Jn="properties",Zn="true";function $n(e,t,n){return me(e,t,n,he)}function Qn(e,n,r){Z(e)||te(e,function(e,t){"number"==typeof t?r[e]=t:ae(t)?n[e]=t:Fe()&&(n[e]=Ee().stringify(t))})}function er(n,r){Z(n)||te(n,function(e,t){n[e]=t||r})}function tr(e,t,n,r){return $n(r=new Lt(e,r,t),"sampleRate",n[ft]),(n[Yn]||{}).startTime&&(r.time=oe(n[Yn].startTime)),r.iKey=n.iKey,t=n.iKey.replace(/-/g,""),r.name=r.name.replace("{0}",t),function(e,t,n){var r=n.tags=n.tags||{},i=t.ext=t.ext||{},a=t.tags=t.tags||[],o=i.user;o&&($n(r,Kn.userAuthUserId,o.authId),$n(r,Kn.userId,o.id||o.localId)),(o=i.app)&&$n(r,Kn.sessionId,o.sesId),(o=i.device)&&($n(r,Kn.deviceId,o.id||o.localId),$n(r,Kn.deviceType,o.deviceClass),$n(r,Kn.deviceIp,o.ip),$n(r,Kn.deviceModel,o.model),$n(r,Kn.deviceType,o.deviceType)),(o=t.ext.web)&&($n(r,Kn.deviceLanguage,o.browserLang),$n(r,Kn.deviceBrowserVersion,o.browserVer),$n(r,Kn.deviceBrowser,o.browser),$n(t=(t=(t=n.data=n.data||{})[Yn]=t[Yn]||{})[Jn]=t[Jn]||{},"domain",o.domain),$n(t,"isManual",o.isManual?Zn:null),$n(t,"screenRes",o.screenRes),$n(t,"userConsent",o.userConsent?Zn:null)),(o=i.os)&&$n(r,Kn.deviceOS,o.name),(i=i.trace)&&($n(r,Kn.operationParentId,i.parentID),$n(r,Kn.operationName,nt(e,i.name)),$n(r,Kn.operationId,i.traceID));for(var s={},l=a.length-1;0<=l;l--)te(a[l],function(e,t){s[e]=t}),a.splice(l,1);te(a,function(e,t){s[e]=t}),(r=g(g({},r),s))[Kn.internalSdkVersion]||(r[Kn.internalSdkVersion]="javascript:".concat(rr.Version)),n.tags=ve(r)}(e,n,r),n.tags=n.tags||[],ve(r)}function nr(e,t){Z(t[Yn])&&e.throwInternal(M.CRITICAL,W.TelemetryEnvelopeInvalid,"telemetryItem.baseData cannot be null.")}var rr={Version:"2.7.2-nightly.2112-05"};function ir(e,t,n){nr(e,t);var r={},i={};return t[Xn]!==Mt.dataType&&(r.baseTypeSource=t[Xn]),t[Xn]===Mt.dataType?(r=t[Yn][Jn]||{},i=t[Yn].measurements||{}):t[Yn]&&Qn(t[Yn],r,i),Qn(t.data,r,i),Z(n)||er(r,n),n=t[Yn].name,i=new Mt(e,n,r,i),i=new En(Mt.dataType,i),tr(e,Mt.envelopeType,t,i)}var ar=function Sr(f){q(Sr,this,function(e){function u(o,s){var e="__aiCircularRefCheck",l={};if(!o)return f.throwInternal(M.CRITICAL,W.CannotSerializeObject,"cannot serialize object because it is null or undefined",{name:s},!0),l;if(o[e])return f.throwInternal(M.WARNING,W.CircularReferenceDetected,"Circular reference detected while serializing object",{name:s},!0),l;if(o.aiDataContract)return o[e]=!0,te(o.aiDataContract,function(e,t){var n=Q(t)?1&t():1&t,r=Q(t)?4&t():4&t,i=2&t,a=o[e]!==undefined,t=$(o[e])&&null!==o[e];!n||a||i?r||(r=void 0,(r=t?(i?c:u)(o[e],e):o[e])!==undefined&&(l[e]=r)):f.throwInternal(M.CRITICAL,W.MissingRequiredFieldSpecification,"Missing required field specification. The field is required but not present on source",{field:e,name:s})}),delete o[e],l;if("measurements"===s)l=n(o,"number",s);else if("properties"===s)l=n(o,"string",s);else if("tags"===s)l=n(o,"string",s);else if(re(o))l=c(o,s);else{f.throwInternal(M.WARNING,W.CannotSerializeObjectNonSerializable,"Attempting to serialize an object which does not implement ISerializable",{name:s},!0);try{Ee().stringify(o),l=o}catch(t){f.throwInternal(M.CRITICAL,W.CannotSerializeObject,t&&Q(t.toString)?t.toString():"Error serializing object",null,!0)}}return l}function c(e,t){if(e)if(re(e))for(var n=[],r=0;r<e.length;r++){var i=u(e[r],t+"["+r+"]");n.push(i)}else f.throwInternal(M.CRITICAL,W.ItemNotInArray,"This field was specified as an array in the contract but the item is not an array.\r\n",{name:t},!0);return n}function n(e,n,r){var i;return e&&(i={},te(e,function(e,t){"string"===n?t===undefined?i[e]="undefined":null===t?i[e]="null":t.toString?i[e]=t.toString():i[e]="invalid field: toString() is not defined.":"number"===n?t===undefined?i[e]="undefined":i[e]=null===t?"null":isNaN(t=parseFloat(t))?"NaN":t:(i[e]="invalid field: "+r+" is of unknown type.",f.throwInternal(M.CRITICAL,i[e],null,!0))})),i}e.serialize=function(e){e=u(e,"root");try{return Ee().stringify(e)}catch(t){f.throwInternal(M.CRITICAL,W.CannotSerializeObject,t&&Q(t.toString)?t.toString():"Error serializing object",null,!0)}}})};function or(){var o=_e(),s=Re(),l=!1,u=!0;q(or,this,function(e){try{var t,n;o&&ee(o,"online",r)&&(ee(o,"offline",i),l=!0),s&&(J((t=s.body||s).ononline)||(t.ononline=r,t.onoffline=i,l=!0)),!l||(n=Le())&&!Z(n.onLine)&&(u=n.onLine)}catch(a){l=!1}function r(){u=!0}function i(){u=!1}e.isListening=l,e.isOnline=function(){var e=!0,t=Le();return l?e=u:t&&!Z(t.onLine)&&(e=t.onLine),e},e.isOffline=function(){return!e.isOnline()}})}var sr=or.Offline=new or,lr=(ur.prototype.getHashCodeScore=function(e){return this.getHashCode(e)/ur.INT_MAX_VALUE*100},ur.prototype.getHashCode=function(e){if(""===e)return 0;for(;e.length<8;)e=e.concat(e);for(var t=5381,n=0;n<e.length;++n)t=(t<<5)+t+e.charCodeAt(n),t&=t;return Math.abs(t)},ur.INT_MAX_VALUE=2147483647,ur);function ur(){}var cr=function(){var t=new lr,n=new Un;this.getSamplingScore=function(e){return e.tags&&e.tags[n.userId]?t.getHashCodeScore(e.tags[n.userId]):e.ext&&e.ext.user&&e.ext.user.id?t.getHashCodeScore(e.ext.user.id):e.tags&&e.tags[n.operationId]?t.getHashCodeScore(e.tags[n.operationId]):e.ext&&e.ext.telemetryTrace&&e.ext.telemetryTrace.traceID?t.getHashCodeScore(e.ext.telemetryTrace.traceID):100*Math.random()}},fr=(dr.prototype.isSampledIn=function(e){var t=this.sampleRate;return null===t||t===undefined||100<=t||e.baseType===fn.dataType||this.samplingScoreGenerator.getSamplingScore(e)<t},dr);function dr(e,t){this.INT_MAX_VALUE=2147483647,t=t||qe(null),(100<e||e<0)&&(t.throwInternal(M.WARNING,W.SampleRateOutOfRange,"Sampling rate is out of range (0..100). Sampling will be disabled, you may be sending too much data which may affect your AI service level.",{samplingRate:e},!0),e=100),this.sampleRate=e,this.samplingScoreGenerator=new cr}function pr(e){try{return e.responseText}catch(t){}return null}function gr(){return{endpointUrl:function(){return"https://dc.services.visualstudio.com/v2/track"},emitLineDelimitedJson:function(){return!1},maxBatchInterval:function(){return 15e3},maxBatchSizeInBytes:function(){return 102400},disableTelemetry:function(){return!1},enableSessionStorageBuffer:function(){return!0},isRetryDisabled:function(){return!1},isBeaconApiDisabled:function(){return!0},disableXhr:function(){return!1},onunloadDisableFetch:function(){return!1},onunloadDisableBeacon:function(){return!1},instrumentationKey:function(){return undefined},namePrefix:function(){return undefined},samplingPercentage:function(){return 100},customHeaders:function(){return undefined},convertUndefined:function(){return undefined},eventsLimitInMem:function(){return 1e4}}}var mr,hr=((_t={})[Mt.dataType]=ir,_t[wn.dataType]=function(e,t,n){nr(e,t);var r=t[Yn].message,i=t[Yn].severityLevel,a=t[Yn][Jn]||{},o=t[Yn].measurements||{};return Qn(t.data,a,o),Z(n)||er(a,n),o=new wn(e,r,i,a,o),o=new En(wn.dataType,o),tr(e,wn.envelopeType,t,o)},_t[vn.dataType]=function(e,t,n){nr(e,t);var r,i="duration";Z(s=t[Yn])||Z(s[Jn])||Z(s[Jn][i])?Z(t.data)||Z(t.data[i])||(r=t.data[i],delete t.data[i]):(r=s[Jn][i],delete s[Jn][i]);var a=t[Yn];((t.ext||{}).trace||{}).traceID&&(u=t.ext.trace.traceID);var o=a.id||u,i=a.name,s=a.uri,l=a[Jn]||{},u=a.measurements||{};return Z(a.refUri)||(l.refUri=a.refUri),Z(a.pageType)||(l.pageType=a.pageType),Z(a.isLoggedIn)||(l.isLoggedIn=a.isLoggedIn.toString()),Z(a[Jn])||te(a[Jn],function(e,t){l[e]=t}),Qn(t.data,l,u),Z(n)||er(l,n),o=new vn(e,i,s,r,l,u,o),o=new En(vn.dataType,o),tr(e,vn.envelopeType,t,o)},_t[An.dataType]=function(e,t,n){nr(e,t);var r=t[Yn],i=r.name,a=r.uri||r.url,o=r[Jn]||{},s=r.measurements||{};return Qn(t.data,o,s),Z(n)||er(o,n),r=new An(e,i,a,undefined,o,s,r),r=new En(An.dataType,r),tr(e,An.envelopeType,t,r)},_t[Zt.dataType]=function(e,t,n){nr(e,t);var r=t[Yn].measurements||{},i=t[Yn][Jn]||{};return Qn(t.data,i,r),Z(n)||er(i,n),n=t[Yn],r=Zt.CreateFromInterface(e,n,i,r),r=new En(Zt.dataType,r),tr(e,Zt.envelopeType,t,r)},_t[fn.dataType]=function(e,t,n){nr(e,t);var r=t[Yn],i=r[Jn]||{},a=r.measurements||{};return Qn(t.data,i,a),Z(n)||er(i,n),a=new fn(e,r.name,r.average,r.sampleCount,r.min,r.max,i,a),a=new En(fn.dataType,a),tr(e,fn.envelopeType,t,a)},_t[Cn.dataType]=function(e,t,n){nr(e,t);var r=t[Yn].measurements||{},i=t[Yn][Jn]||{};Qn(t.data,i,r),Z(n)||er(i,n);var a=t[Yn];return Z(a)?(e.warnToConsole("Invalid input for dependency data"),null):(n=a[Jn]&&a[Jn][pt]?a[Jn][pt]:"GET",r=new Cn(e,a.id,a.target,a.name,a.duration,a.success,a.responseCode,n,a.type,a.correlationContext,i,r),r=new En(Cn.dataType,r),tr(e,Cn.envelopeType,t,r))},_t),Qe=(h(vr,mr=Qe),vr.constructEnvelope=function(e,t,n,r){return t=t===e.iKey||Z(t)?e:g(g({},e),{iKey:t}),(hr[t.baseType]||ir)(n,t,r)},vr);function vr(){var w,b,x=mr.call(this)||this;x.priority=1001;var n,N,_,R,A,L=!(x.identifier="AppInsightsChannelPlugin"),F={},E=0;return x._senderConfig=gr(),q(vr,x,function(u,o){function l(e,t,n,r,i,a){var o=null;u._appId||(o=g(a))&&o.appId&&(u._appId=o.appId),(e<200||300<=e)&&0!==e?(301!==e&&307!==e&&308!==e||s(n))&&!u._senderConfig.isRetryDisabled()&&y(e)?(m(t),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Response code "+e+". Will retry to send "+t.length+" items.")):u._onError(t,i):sr.isOffline()?u._senderConfig.isRetryDisabled()||(m(t,10),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Offline - Response Code: ".concat(e,". Offline status: ").concat(sr.isOffline(),". Will retry to send ").concat(t.length," items."))):(s(n),206===e?(o=o||g(a))&&!u._senderConfig.isRetryDisabled()?u._onPartialSuccess(t,o):u._onError(t,i):(w=0,u._onSuccess(t,r)))}function s(e){return!(10<=_)&&!Z(e)&&""!==e&&e!==u._senderConfig.endpointUrl()&&(u._senderConfig.endpointUrl=function(){return e},++_,1)}function t(e,t){A?A(e,!1):c(e)}function a(e){var t=Le(),n=u._buffer,r=u._senderConfig.endpointUrl(),i=u._buffer.batchPayloads(e),i=new Blob([i],{type:"text/plain;charset=UTF-8"});return(t=t.sendBeacon(r,i))&&(n.markAsSent(e),u._onSuccess(e,e.length)),t}function c(e,t){if(re(e)&&0<e.length&&!a(e)){for(var n=[],r=0;r<e.length;r++){var i=e[r];a([i])||n.push(i)}0<n.length&&(R(n,!0),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with normal sender."))}}function f(t,e){var n=new XMLHttpRequest,r=u._senderConfig.endpointUrl();try{n[ct]=!0}catch(i){}n.open("POST",r,e),n.setRequestHeader("Content-type","application/json"),xt(r)&&n.setRequestHeader("Sdk-Context","appId"),se(de(F),function(e){n.setRequestHeader(e,F[e])}),n.onreadystatechange=function(){return u._xhrReadyStateChange(n,t,t.length)},n.onerror=function(e){return u._onError(t,I(n),e)},r=u._buffer.batchPayloads(t),n.send(r),u._buffer.markAsSent(t)}function d(e,t){if(re(e)){for(var n=e.length,r=0;r<e.length;r++)n+=e[r].length;E+n<=65e3?i(e,!1):De()?c(e):(R&&R(e,!0),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Failed to send telemetry with Beacon API, retried with xhrSender."))}}function p(e,t){i(e,!0)}function i(n,r){var e=u._senderConfig.endpointUrl(),t=u._buffer.batchPayloads(n),i=new Blob([t],{type:"application/json"}),a=new Headers,o=t.length;xt(e)&&a.append("Sdk-Context","appId"),se(de(F),function(e){a.append(e,F[e])}),(i={method:"POST",headers:a,body:i})[ct]=!0,r||(i.keepalive=!0,E+=o),i=new Request(e,i);try{i[ct]=!0}catch(s){}fetch(i).then(function(t){r||(E-=o,o=0),t.ok?t.text().then(function(e){l(t.status,n,t.url,n.length,t.statusText,e)}):u._onError(n,t.statusText)})["catch"](function(e){r||(E-=o,o=0),u._onError(n,e.message)}),u._buffer.markAsSent(n)}function g(e){try{if(e&&""!==e){var t=Ee().parse(e);if(t&&t.itemsReceived&&t.itemsReceived>=t.itemsAccepted&&t.itemsReceived-t.itemsAccepted===t.errors.length)return t}}catch(n){u.diagLog().throwInternal(M.CRITICAL,W.InvalidBackendResponse,"Cannot parse the response. "+ge(n),{response:e})}return null}function m(e,t){if(void 0===t&&(t=1),e&&0!==e.length){var n=u._buffer;n.clearSent(e),w++;for(var r=0,i=e;r<i.length;r++){var a=i[r];n.enqueue(a)}o=w<=1?10:(o=1+Math.floor((Math.pow(2,w)-1)/2*Math.random()*10),Math.max(Math.min(o*=t,3600),10)),o=pe()+1e3*o,b=o,h()}var o}function h(){var e;n||L||(e=b?Math.max(0,b-pe()):0,e=Math.max(u._senderConfig.maxBatchInterval(),e),n=setTimeout(function(){n=null,u.triggerSend(!0,null,1)},e))}function v(){clearTimeout(n),b=n=null}function y(e){return 408===e||429===e||500===e||503===e}function I(e,t){return e?"XMLHttpRequest,Status:"+e.status+",Response:"+pr(e)||e.response||"":t}function C(t,e){var n=u._buffer,r=_e(),i=new XDomainRequest;if(i.onload=function(){return u._xdrOnLoad(i,t)},i.onerror=function(e){return u._onError(t,S(i),e)},r=r&&r.location&&r.location.protocol||"",u._senderConfig.endpointUrl().lastIndexOf(r,0))return u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,". Cannot send XDomain request. The endpoint URL protocol doesn't match the hosting page protocol."),void n.clear();r=u._senderConfig.endpointUrl().replace(/^(https?:)/,""),i.open("POST",r),r=n.batchPayloads(t),i.send(r),n.markAsSent(t)}function S(e,t){return e?"XDomainRequest,Response:"+pr(e)||"":t}function T(e,t){var n=u.core[n="getNotifyMgr"]?u.core[n]():u.core._notificationManager;if(n&&n.eventsSendRequest)try{n.eventsSendRequest(e,t)}catch(r){u.diagLog().throwInternal(M.CRITICAL,W.NotificationException,"send request notification failed: "+ge(r),{exception:Me(r)})}}u.pause=function(){v(),L=!0},u.resume=function(){L&&(L=!1,b=null,u._buffer.size()>u._senderConfig.maxBatchSizeInBytes()&&u.triggerSend(!0,null,10),h())},u.flush=function(){if(!L){v();try{u.triggerSend(!0,null,1)}catch(e){u.diagLog().throwInternal(M.CRITICAL,W.FlushFailed,"flush failed, telemetry will not be collected: "+ge(e),{exception:Me(e)})}}},u.onunloadFlush=function(){if(!L)if(!1!==u._senderConfig.onunloadDisableBeacon()&&!1!==u._senderConfig.isBeaconApiDisabled()||!De())u.flush();else try{u.triggerSend(!0,t,2)}catch(e){u.diagLog().throwInternal(M.CRITICAL,W.FailedToSendQueuedTelemetry,"failed to flush with beacon sender on page unload, telemetry will not be collected: "+ge(e),{exception:Me(e)})}},u.teardown=function(){!function(){throw Error("Method not implemented.")}()},u.addHeader=function(e,t){F[e]=t},u.initialize=function(e,t,n,r){o.initialize(e,t,n,r);var i=u._getTelCtx(),a=u.identifier;N=new ar(t.logger),b=null,w=0,u._sender=null,_=0,t=u.diagLog(),te(gr(),function(e,t){u._senderConfig[e]=function(){return i.getConfig(a,e,t())}}),u._buffer=new(u._senderConfig.enableSessionStorageBuffer()&&yt()?Gn:qn)(t,u._senderConfig),u._sample=new fr(u._senderConfig.samplingPercentage(),t),!Z((r=e).disableInstrumentationKeyValidation)&&r.disableInstrumentationKeyValidation||/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/.test(r.instrumentationKey)||t.throwInternal(M.CRITICAL,W.InvalidInstrumentationKey,"Invalid Instrumentation key "+e.instrumentationKey),!xt(u._senderConfig.endpointUrl())&&u._senderConfig.customHeaders()&&0<u._senderConfig.customHeaders().length&&se(u._senderConfig.customHeaders(),function(e){x.addHeader(e.header,e.value)}),t=null,!(e=u._senderConfig).disableXhr()&&ke()?t=C:!e.disableXhr()&&Pe()&&(t=f),!t&&Be()&&(t=p),R=t||f,!e.isBeaconApiDisabled()&&De()&&(t=c),u._sender=t||f,A=!e.onunloadDisableFetch()&&Be(!0)?d:De()?c:!e.disableXhr()&&ke()?C:!e.disableXhr()&&Pe()?f:R},u.processTelemetry=function(e,n){n=u._getTelCtx(n);try{if(u._senderConfig.disableTelemetry())return;if(!e)return void n.diagLog().throwInternal(M.CRITICAL,W.CannotSendEmptyTelemetry,"Cannot send empty telemetry");if(e.baseData&&!e.baseType)return void n.diagLog().throwInternal(M.CRITICAL,W.InvalidEvent,"Cannot send telemetry without baseData and baseType");if(e.baseType||(e.baseType="EventData"),!u._sender)return void n.diagLog().throwInternal(M.CRITICAL,W.SenderNotInitialized,"Sender was not initialized");if(!u._sample.isSampledIn(e))return void n.diagLog().throwInternal(M.WARNING,W.TelemetrySampledAndNotSent,"Telemetry item was sampled out and not sent",{SampleRate:u._sample.sampleRate});e[ft]=u._sample.sampleRate;var t=u._senderConfig.convertUndefined()||undefined,r=e.iKey||u._senderConfig.instrumentationKey(),i=vr.constructEnvelope(e,r,n.diagLog(),t);if(!i)return void n.diagLog().throwInternal(M.CRITICAL,W.CreateEnvelopeError,"Unable to create an AppInsights envelope");var a=!1;if(e.tags&&e.tags[dt]&&(se(e.tags[dt],function(e){try{e&&!1===e(i)&&(a=!0,n.diagLog().warnToConsole("Telemetry processor check returns false"))}catch(t){n.diagLog().throwInternal(M.CRITICAL,W.TelemetryInitializerFailed,"One of telemetry initializers failed, telemetry item will not be sent: "+ge(t),{exception:Me(t)},!0)}}),delete e.tags[dt]),a)return;var o=N.serialize(i),s=u._buffer;s.size()+o.length>u._senderConfig.maxBatchSizeInBytes()&&u.triggerSend(!0,null,10),s.enqueue(o),h()}catch(l){n.diagLog().throwInternal(M.WARNING,W.FailedAddingTelemetryToBuffer,"Failed adding telemetry to the sender's buffer, some telemetry will be lost: "+ge(l),{exception:Me(l)})}u.processNext(e,n)},u._xhrReadyStateChange=function(e,t,n){4===e.readyState&&l(e.status,t,e.responseURL,n,I(e),pr(e)||e.response)},u.triggerSend=function(e,t,n){if(void 0===e&&(e=!0),!L)try{var r=u._buffer;u._senderConfig.disableTelemetry()?r.clear():0<r.count()&&(a=r.getItems(),T(n||0,e),t?t.call(x,a,e):u._sender(a,e)),v()}catch(o){(!(e=ne(i=((i=(i=void 0===i?null:i)?i:(a=Le()||{})?(a.userAgent||"").toLowerCase():"")||"").toLowerCase(),"msie")?parseInt(i.split("msie")[1]):ne(i,Se)&&(i=parseInt(i.split(Se)[1]))?i+4:null)||9<e)&&u.diagLog().throwInternal(M.CRITICAL,W.TransmissionFailed,"Telemetry transmission failed, some telemetry will be lost: "+ge(o),{exception:Me(o)})}var i,a},u._onError=function(e,t,n){u.diagLog().throwInternal(M.WARNING,W.OnError,"Failed to send telemetry.",{message:t}),u._buffer.clearSent(e)},u._onPartialSuccess=function(e,t){for(var n=[],r=[],i=0,a=t.errors.reverse();i<a.length;i++){var o=a[i],s=e.splice(o.index,1)[0];(y(o.statusCode)?r:n).push(s)}0<e.length&&u._onSuccess(e,t.itemsAccepted),0<n.length&&u._onError(n,I(null,["partial success",t.itemsAccepted,"of",t.itemsReceived].join(" "))),0<r.length&&(m(r),u.diagLog().throwInternal(M.WARNING,W.TransmissionFailed,"Partial success. Delivered: "+e.length+", Failed: "+n.length+". Will retry to send "+r.length+" our of "+t.itemsReceived+" items"))},u._onSuccess=function(e,t){u._buffer.clearSent(e)},u._xdrOnLoad=function(e,t){var n=pr(e);!e||n+""!="200"&&""!==n?(n=g(n))&&n.itemsReceived&&n.itemsReceived>n.itemsAccepted&&!u._senderConfig.isRetryDisabled()?u._onPartialSuccess(t,n):u._onError(t,S(e)):(w=0,u._onSuccess(t,0))}}),x}e.Sender=Qe,function(e,t,n){var r=Object.defineProperty;if(r)try{return r(e,t,n)}catch(i){}typeof n.value!==undefined&&(e[t]=n.value)}(e,"__esModule",{value:!0})};"object"==typeof exports&&"undefined"!=typeof module?t(exports):"function"==typeof define&&define.amd?define(["exports"],t):t(((e="undefined"!=typeof globalThis?globalThis:e||self).Microsoft=e.Microsoft||{},e.Microsoft.ApplicationInsights=e.Microsoft.ApplicationInsights||{}));
|
|
6
6
|
//# sourceMappingURL=applicationinsights-channel-js.min.js.map
|