1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[12],{44623:(e,t,n)=>{n.r(t),n.d(t,{DEFAULT_RUM_PROFILER_CONFIGURATION:()=>m,createRumProfiler:()=>d});var i=n(47848),r=n(20684),a=n(47566),s=n(57986),o=n(83037),l=n(27951);let u=new Map,c=!1;function p(e){if(!1!==c&&!(e.startTime<c))return u.get(e.startTime)}var f=n(91463);let m={sampleIntervalMs:10,collectIntervalMs:6e4,minProfileDurationMs:5e3,minNumberOfSamples:50};function d(e,t,n,v=m){let g,w=(0,l.s5)(l.do.LONG_ANIMATION_FRAME),h=[],b={state:"stopped"};function y(){let n,i=(0,r.V)().Profiler;if(!i)throw Error("RUM Profiler is not supported in this browser.");T(b).catch(a.Dx);let{cleanupTasks:l,observer:p}=function(n){let i;if("running"===n.state)return{cleanupTasks:n.cleanupTasks,observer:n.observer};let r=[];if(e.trackLongTasks){(i=new PerformanceObserver(O)).observe({entryTypes:[w?"long-animation-frame":"longtask"]});let e=t.subscribe(12,e=>{!function({rawRumEvent:e,startTime:t}){var n;"long_task"===e.type&&(n=e.long_task.id,u.set(t,n))}(e)});c=performance.now(),r.push(()=>null==i?void 0:i.disconnect()),r.push(e.unsubscribe)}let a=t.subscribe(2,e=>{k({viewId:e.id,viewName:e.name,startTime:e.startClocks.relative})});return r.push(a.unsubscribe),{cleanupTasks:r,observer:i}}(b);try{n=new i({sampleInterval:v.sampleIntervalMs,maxBufferSize:Math.round(1.5*v.collectIntervalMs/v.sampleIntervalMs)})}catch(e){s.Vy.warn("[DD_RUM] Profiler startup failed. Ensure your server includes the `Document-Policy: js-profiling` response header when serving HTML pages.",e);return}b={state:"running",startTime:performance.now(),profiler:n,timeoutId:(0,o.wg)(y,v.collectIntervalMs),longTasks:[],views:[],cleanupTasks:l,observer:p},k(g),n.addEventListener("samplebufferfull",M)}async function T(t){var i,r;if("running"!==t.state)return;S(null!=(r=null==(i=t.observer)?void 0:i.takeRecords())?r:[]),(0,o.DJ)(t.timeoutId),t.profiler.removeEventListener("samplebufferfull",M);let{startTime:s,longTasks:l,views:m}=t,d=performance.now();await t.profiler.stop().then(t=>{let i=performance.now(),r=l.length>0,o=i-s<v.minProfileDurationMs,g=function(e){let t=0;for(let n of e)void 0!==n.stackId&&t++;return t}(t.samples)<v.minNumberOfSamples;if(r||!o&&!g){var w,h,b,y,T,I,k,M,O,S,D,_,E,N,j;let r,o,g,P,R,A,L,C,x,F,U,B,J,q;w=Object.assign(t,{startTime:s,endTime:i,timeOrigin:performance.timeOrigin,longTasks:l,views:m,sampleInterval:v.sampleIntervalMs}),r=null==(h=n.findTrackedSession())?void 0:h.id,(b=w,y=e.profilingEndpointBuilder,T=e.applicationId,I=r,B=(k=b,M=y,O=T,S=I,R=M.tags,A=(D=k,_=O,E=S,o={application:{id:_}},E&&(o.session={id:E}),(g=Array.from(new Set(D.views.map(e=>e.viewId)))).length&&(o.view={id:g}),(P=D.longTasks.map(e=>p(e)).filter(e=>void 0!==e)).length&&(o.long_task={id:P}),o),L=R.concat(["language:javascript","runtime:chrome","family:chrome","host:browser"]),C=new Date(k.timeOrigin+k.startTime),x=new Date(k.timeOrigin+k.endTime),{...A,attachments:["wall-time.json"],start:C.toISOString(),end:x.toISOString(),family:"chrome",runtime:"chrome",format:"json",version:4,tags_profiler:L.join(",")}),J=(N=b,j=B,F=new Blob([JSON.stringify(N)],{type:"application/json"}),(U=new FormData).append("event",new Blob([JSON.stringify(j)],{type:"application/json"}),"event.json"),U.append("wall-time.json",F,"wall-time.json"),{data:U,bytesCount:0}),q=y.build("fetch",J),(0,f.A2)("Sending profile to public profiling intake",{profilingIntakeURL:q,applicationId:T,sessionId:I}),fetch(q,{body:J.data,method:"POST"})).catch(a.Dx);if(!1!==c&&!(d<c))for(let e of u.keys())e<d&&u.delete(e)}}).catch(a.Dx)}async function I(e){"running"===b.state&&(b.cleanupTasks.forEach(e=>e()),await T(b),b={state:e})}function k(e){"running"===b.state&&e&&b.views.push(e)}function M(){y()}function O(e){S(e.getEntries())}function S(e){if("running"===b.state)for(let t of e)t.duration<v.sampleIntervalMs||b.longTasks.push({id:p(t),duration:t.duration,entryType:t.entryType,startTime:t.startTime})}function D(){"hidden"===document.visibilityState&&"running"===b.state?I("paused").catch(a.Dx):"visible"===document.visibilityState&&"paused"===b.state&&y()}function _(){y()}return{start:function(t){"running"!==b.state&&(g=t?{startTime:t.startClocks.relative,viewId:t.id,viewName:t.name}:void 0,h.push((0,i.q)(e,window,"visibilitychange",D).stop,(0,i.q)(e,window,"beforeunload",_).stop
1),y())},stop:async function e(){await I("stopped"),c=!1,u.clear(),h.forEach(e=>e())},isStopped:function(){return"stopped"===b.state},isRunning:function(){return"running"===b.state},isPaused:function(){return"paused"===b.state}}}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.