1import{r as c,ac as j,j as e,M as A,B as w,ad as P,a4 as l}from"./CgBZl8m0.production.bundle.min.js";import{cc as N,cd as R,cf as r,e0 as M,e1 as L,w as O,p as V,e2 as Q,u as q,L as B,T as C,cg as U,a as k,ch as W,e3 as Y,e4 as o,e5 as d,e6 as n,e7 as F}from"./CY9JcdZ7.production.bundle.min.js";import{T as G}from"./B_v3Fv2u.production.bundle.min.js";import"./CUU-sqeu.production.bundle.min.js";import{h as $,c as u}from"./BpQvVIpM.production.bundle.min.js";import{P as D}from"./CHbJgqnE.production.bundle.min.js";import{b as t,a as H}from"./uYRgXL5M.production.bundle.min.js";import{u as v}from"./BWr4BVpJ.production.bundle.min.js";import"./BTOj8ijf.production.bundle.min.js";import"./DpOFvyFl.production.bundle.min.js";import"./D4lvmK5r.production.bundle.min.js";import"./URTTg1rg.production.bundle.min.js";import"./B7jgtT_H.production.bundle.min.js";import"./BFsIcxdk.production.bundle.min.js";import"./CMxhj3GZ.production.bundle.min.js";import"./C7aKDdDU.production.bundle.min.js";import"./CJLuAe4t.production.bundle.min.js";import"./Dsqj8S3w.production.bundle.min.js";import"./9zG8c1d8.production.bundle.min.js";import"./BhEpiGZx.production.bundle.min.js";import"./IimQW1M7.production.bundle.min.js";import"./DuMSlPdM.production.bundle.min.js";import"./BS0dGend.production.bundle.min.js";import"./BZwPEnwo.production.bundle.min.js";import"./DlG3g9Q4.production.bundle.min.js";import"./DhCfBX8j.production.bundle.min.js";import"./DohGM9_I.production.bundle.min.js";import"./Czj00ZrM.production.bundle.min.js";import"./vhNSgALD.production.bundle.min.js";import"./DvJkqRNe.production.bundle.min.js";import"./M_FBjfQJ.production.bundle.min.js";import"./CHbz8HD7.production.bundle.min.js";import"./DV0DPFOt.production.bundle.min.js";import"./BOFlCg2s.production.bundle.min.js";import"./Czbq-YEj.production.bundle.min.js";import"./PSw9bd14.production.bundle.min.js";import"./BaeVAzEX.production.bundle.min.js";import"./CK-5Vo_r.production.bundle.min.js";import"./BAUftK01.production.bundle.min.js";import"./BKtnA6hw.production.bundle.min.js";import"./CIT-tl5U.production.bundle.min.js";import"./DnFKFUTo.production.bundle.min.js";import"./CrsULzDT.production.bundle.min.js";import"./CRSxynHN.production.bundle.min.js";import"./_LyuCvYL.production.bundle.min.js";import"./DnQqxH0F.production.bundle.min.js";const X=()=>{const x=v(N),m=v(R),[b,a]=c.useState(!1),p=c.useCallback(()=>{a(!0)},[]),i=c.useMemo(()=>[{title:"Avg Error Rate",titleInfo:"Avg Error Rate",columns:[r.ERROR_RATE],resourceName:"avg_error_rate",subInfo:"",badgeOptions:{subInfoBadgeRange:[{min:0,max:9.99,badgeType:t.Success,subInfo:""},{min:10.01,max:29.99,badgeType:t.Warning,subInfo:""},{min:30.01,max:100,badgeType:t.Error,subInfo:""}]}},{title:"Active Services",titleInfo:"Number of running services",columns:[M.SERVICE_NAME],resourceName:"active_services",subInfo:"",badgeOptions:{subInfoBadgeRange:[{min:0,max:0,badgeType:t.Warning,subInfo:""},{min:1,max:1e3,badgeType:t.Success,subInfo:""}]}},{title:"Success Rate",titleInfo:"Percentage of requests per second ending in success response",columns:[r.SUCCESS_RATE],resourceName:"success_rate",subInfo:"",badgeOptions:{subInfoBadgeRange:[{min:0,max:79.99,badgeType:t.Error,subInfo:""},{min:80,max:94.99,badgeType:t.Warning,subInfo:""},{min:95,max:100,badgeType:t.Success,subInfo:""}]}},{title:"Max Latency",titleInfo:"Max Latency",columns:[r.MAX_RESPONSE_TIME_NS],resourceName:"max_latency",subInfo:"",badgeOptions:{type:t.Info}}],[x,m]),g=c.useMemo(()=>i.map(s=>({chartType:j,uniqName:s.title,resource:O,columns:s.columns,builderProps:{boxTitle:s.title,filters:x?m.filters:[],subInfo:s.subInfo,nestedProps:{chartHeight:120,titleInfo:s.titleInfo??s.title,countChartOptions:{subInfoBadgeRange:s.badgeOptions.subInfoBadgeRange,badgeType:s.badgeOptions.type}},extraParams:[L.QUICKWIT]}})),[i,x,m.filters]);return e.jsxs("div",{className:"service-overview-card",children:[e.jsx("div",{className:"service-stats",children:i.map((s,T)=>e.jsx("div",{className:`overview-card ${s.resourceName==="max_latency"?"clickable-card":""}`,onClick:s.resourceName==="max_latency"?p:void 0,children:e.jsx(V,{...g[T]})},s.resourceName))}),e.jsx(Q,{isOpen:b,onClose:()=>a(!1)})]})},We=()=>{var y,E;const x=q(),[m,b]=B("apm-services-selected-tab",0),a=c.useContext(A),p=(E=(y=a==null?void 0:a.params)==null?void 0:y.query)==null?void 0:E.get("apm-services-tab"),i=v(N),g=v(R),s=c.useMemo(()=>i?g.filters:[],[i,g.filters]),T=c.useMemo(()=>i?g.filters:[w.Equal(C.STATUS_CODE,U.ERROR_STATUS_CODE)],[i,g.filters]);if(!x(D.ServiceList))return e.jsx(k,{});c.useEffect(()=>(p&&+p!==m&&b(+p),()=>{var h,I,_,S;
1p&&((I=(h=a==null?void 0:a.params)==null?void 0:h.query)==null||I.delete("apm-services-tab"),(S=(_=a==null?void 0:a.params)==null?void 0:_.query)==null||S.redirect())}),[p]);const f=m===1;return e.jsxs("div",{className:`apm-services ${f?"map-view-mode":""}`,children:[e.jsx("div",{className:`header-view ${f?"header-overlay":""}`,children:e.jsx("div",{className:"search-box",children:e.jsx(W,{placeholder:"Search by name, tag, label or annotation",extraElement:e.jsx(G,{tabs:[{label:"Table View",value:0},{label:"Map View",value:1}],selectedTab:m,onTabChange:({value:h})=>b(h)}),regexSearch:C.SERVICE_NAME})})}),e.jsxs("div",{className:`${f?"apm-body-wrapper-map-view":"apm-body-wrapper"}`,children:[f&&e.jsx(Y,{}),!f&&e.jsxs(e.Fragment,{children:[e.jsx("div",{className:"service-stats-wrapper",children:e.jsx(X,{})}),e.jsxs("div",{className:"service-overview-graphs two-card-row",children:[e.jsx(o,{title:"Avg Latency(ms)",column:n(r.AVG_RESPONSE_TIME_MS),name:"service-dashboard-avg_response_time_ms",chartType:P,widgetAppId:$,columnConfig:d,filters:s}),e.jsx(o,{title:"Errors (per Sec)",column:n(r.REQUEST_RATE),name:"service-dashboard-error_rate",chartType:l,widgetAppId:u,columnConfig:{error_rate:{tpl:{type:H,config:{},label:"Count"}}},filters:T})]}),e.jsx("div",{className:"service-list",children:e.jsx(F,{})}),e.jsxs("div",{className:"service-latency-graphs three-card-row",children:[e.jsx("div",{className:"apm-graph-card",children:e.jsx(o,{title:"P50 Latency (ms)",column:n(r.P50_LATENCY),name:"service-dashboard-p_50",chartType:l,widgetAppId:u,columnConfig:d,filters:s})}),e.jsx("div",{className:"apm-graph-card",children:e.jsx(o,{title:"P75 Latency (ms)",column:n(r.P75_LATENCY),name:"service-dashboard-p_75",chartType:l,widgetAppId:u,columnConfig:d,filters:s})}),e.jsx("div",{className:"apm-graph-card",children:e.jsx(o,{title:"P90 Latency (ms)",column:n(r.P90_LATENCY),name:"service-dashboard-p_90",chartType:l,widgetAppId:u,columnConfig:d,filters:s})}),e.jsx("div",{className:"apm-graph-card",children:e.jsx(o,{title:"P95 Latency (ms)",name:"service-dashboard-p_95",column:n(r.P95_LATENCY),chartType:l,widgetAppId:u,columnConfig:d,filters:s})}),e.jsx("div",{className:"apm-graph-card",children:e.jsx(o,{title:"P99 Latency (ms)",column:n(r.P99_LATENCY),name:"service-dashboard-p_99",chartType:l,widgetAppId:u,columnConfig:d,filters:s})}),e.jsx("div",{className:"apm-graph-card",children:e.jsx(o,{title:"Max Latency (ms)",column:n(r.MAX_RESPONSE_TIME_MS),name:"service-dashboard-max_response_time_ms",chartType:l,widgetAppId:u,columnConfig:d,filters:s})})]})]})]})]})};export{We as default};
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.