diff --git a/app/vmselect/main.go b/app/vmselect/main.go index c22851ab46..47edc3ca97 100644 --- a/app/vmselect/main.go +++ b/app/vmselect/main.go @@ -207,6 +207,7 @@ func requestHandler(w http.ResponseWriter, r *http.Request) bool { } if path == "/api/v1/status/top_queries" { globalTopQueriesRequests.Inc() + httpserver.EnableCORS(w, r) if err := prometheus.QueryStatsHandler(startTime, nil, w, r); err != nil { globalTopQueriesErrors.Inc() sendPrometheusError(w, r, err) @@ -376,6 +377,7 @@ func selectHandler(qt *querytracer.Tracer, startTime time.Time, w http.ResponseW return true case "prometheus/api/v1/status/tsdb": statusTSDBRequests.Inc() + httpserver.EnableCORS(w, r) if err := prometheus.TSDBStatusHandler(startTime, at, w, r); err != nil { statusTSDBErrors.Inc() sendPrometheusError(w, r, err) @@ -388,6 +390,7 @@ func selectHandler(qt *querytracer.Tracer, startTime time.Time, w http.ResponseW return true case "prometheus/api/v1/status/top_queries": topQueriesRequests.Inc() + httpserver.EnableCORS(w, r) if err := prometheus.QueryStatsHandler(startTime, at, w, r); err != nil { topQueriesErrors.Inc() sendPrometheusError(w, r, err) diff --git a/app/vmselect/netstorage/netstorage.go b/app/vmselect/netstorage/netstorage.go index 4d40849ca0..1ad725939d 100644 --- a/app/vmselect/netstorage/netstorage.go +++ b/app/vmselect/netstorage/netstorage.go @@ -2407,10 +2407,20 @@ func (sn *storageNode) getTSDBStatusForDateOnConn(bc *handshake.BufferedConn, ac if err != nil { return nil, fmt.Errorf("cannot read seriesCountByLabelValuePair: %w", err) } + totalSeries, err := readUint64(bc) + if err != nil { + return nil, fmt.Errorf("cannot read totalSeries: %w", err) + } + totalLabelValuePairs, err := readUint64(bc) + if err != nil { + return nil, fmt.Errorf("cannot read totalLabelValuePairs: %w", err) + } status := &storage.TSDBStatus{ SeriesCountByMetricName: seriesCountByMetricName, LabelValueCountByLabelName: labelValueCountByLabelName, SeriesCountByLabelValuePair: seriesCountByLabelValuePair, + TotalSeries: totalSeries, + TotalLabelValuePairs: totalLabelValuePairs, } return status, nil } diff --git a/app/vmselect/prometheus/prometheus.go b/app/vmselect/prometheus/prometheus.go index ae77c127a9..a9c4f792a0 100644 --- a/app/vmselect/prometheus/prometheus.go +++ b/app/vmselect/prometheus/prometheus.go @@ -48,10 +48,10 @@ var ( selectNodes = flagutil.NewArray("selectNode", "Comma-separated addresses of vmselect nodes; usage: -selectNode=vmselect-host1,...,vmselect-hostN") maxUniqueTimeseries = flag.Int("search.maxUniqueTimeseries", 300e3, "The maximum number of unique time series, which can be selected during /api/v1/query and /api/v1/query_range queries. This option allows limiting memory usage") - maxFederateSeries = flag.Int("search.maxFederateSeries", 300e3, "The maximum number of time series, which can be returned from /federate. This option allows limiting memory usage") - maxExportSeries = flag.Int("search.maxExportSeries", 1e6, "The maximum number of time series, which can be returned from /api/v1/export* APIs. This option allows limiting memory usage") - maxTSDBStatusSeries = flag.Int("search.maxTSDBStatusSeries", 1e6, "The maximum number of time series, which can be processed during the call to /api/v1/status/tsdb. This option allows limiting memory usage") - maxSeriesLimit = flag.Int("search.maxSeries", 10e3, "The maximum number of time series, which can be returned from /api/v1/series. This option allows limiting memory usage") + maxFederateSeries = flag.Int("search.maxFederateSeries", 1e6, "The maximum number of time series, which can be returned from /federate. This option allows limiting memory usage") + maxExportSeries = flag.Int("search.maxExportSeries", 10e6, "The maximum number of time series, which can be returned from /api/v1/export* APIs. This option allows limiting memory usage") + maxTSDBStatusSeries = flag.Int("search.maxTSDBStatusSeries", 10e6, "The maximum number of time series, which can be processed during the call to /api/v1/status/tsdb. This option allows limiting memory usage") + maxSeriesLimit = flag.Int("search.maxSeries", 100e3, "The maximum number of time series, which can be returned from /api/v1/series. This option allows limiting memory usage") ) // Default step used if not set. diff --git a/app/vmselect/prometheus/tsdb_status_response.qtpl b/app/vmselect/prometheus/tsdb_status_response.qtpl index 42b108932a..b406457ce6 100644 --- a/app/vmselect/prometheus/tsdb_status_response.qtpl +++ b/app/vmselect/prometheus/tsdb_status_response.qtpl @@ -7,9 +7,11 @@ TSDBStatusResponse generates response for /api/v1/status/tsdb . "status":"success", "isPartial":{% if isPartial %}true{% else %}false{% endif %}, "data":{ + "totalSeries": {%dul= status.TotalSeries %}, + "totalLabelValuePairs": {%dul= status.TotalLabelValuePairs %}, "seriesCountByMetricName":{%= tsdbStatusEntries(status.SeriesCountByMetricName) %}, - "labelValueCountByLabelName":{%= tsdbStatusEntries(status.LabelValueCountByLabelName) %}, - "seriesCountByLabelValuePair":{%= tsdbStatusEntries(status.SeriesCountByLabelValuePair) %} + "seriesCountByLabelValuePair":{%= tsdbStatusEntries(status.SeriesCountByLabelValuePair) %}, + "labelValueCountByLabelName":{%= tsdbStatusEntries(status.LabelValueCountByLabelName) %} } } {% endfunc %} diff --git a/app/vmselect/prometheus/tsdb_status_response.qtpl.go b/app/vmselect/prometheus/tsdb_status_response.qtpl.go index 6081537615..6345b370c9 100644 --- a/app/vmselect/prometheus/tsdb_status_response.qtpl.go +++ b/app/vmselect/prometheus/tsdb_status_response.qtpl.go @@ -37,99 +37,107 @@ func StreamTSDBStatusResponse(qw422016 *qt422016.Writer, isPartial bool, status //line app/vmselect/prometheus/tsdb_status_response.qtpl:8 } //line app/vmselect/prometheus/tsdb_status_response.qtpl:8 - qw422016.N().S(`,"data":{"seriesCountByMetricName":`) + qw422016.N().S(`,"data":{"totalSeries":`) //line app/vmselect/prometheus/tsdb_status_response.qtpl:10 + qw422016.N().DUL(status.TotalSeries) +//line app/vmselect/prometheus/tsdb_status_response.qtpl:10 + qw422016.N().S(`,"totalLabelValuePairs":`) +//line app/vmselect/prometheus/tsdb_status_response.qtpl:11 + qw422016.N().DUL(status.TotalLabelValuePairs) +//line app/vmselect/prometheus/tsdb_status_response.qtpl:11 + qw422016.N().S(`,"seriesCountByMetricName":`) +//line app/vmselect/prometheus/tsdb_status_response.qtpl:12 streamtsdbStatusEntries(qw422016, status.SeriesCountByMetricName) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:10 - qw422016.N().S(`,"labelValueCountByLabelName":`) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:11 - streamtsdbStatusEntries(qw422016, status.LabelValueCountByLabelName) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:11 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:12 qw422016.N().S(`,"seriesCountByLabelValuePair":`) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:12 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:13 streamtsdbStatusEntries(qw422016, status.SeriesCountByLabelValuePair) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:12 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:13 + qw422016.N().S(`,"labelValueCountByLabelName":`) +//line app/vmselect/prometheus/tsdb_status_response.qtpl:14 + streamtsdbStatusEntries(qw422016, status.LabelValueCountByLabelName) +//line app/vmselect/prometheus/tsdb_status_response.qtpl:14 qw422016.N().S(`}}`) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 } -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 func WriteTSDBStatusResponse(qq422016 qtio422016.Writer, isPartial bool, status *storage.TSDBStatus) { -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 qw422016 := qt422016.AcquireWriter(qq422016) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 StreamTSDBStatusResponse(qw422016, isPartial, status) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 qt422016.ReleaseWriter(qw422016) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 } -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 func TSDBStatusResponse(isPartial bool, status *storage.TSDBStatus) string { -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 qb422016 := qt422016.AcquireByteBuffer() -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 WriteTSDBStatusResponse(qb422016, isPartial, status) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 qs422016 := string(qb422016.B) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 qt422016.ReleaseByteBuffer(qb422016) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 return qs422016 -//line app/vmselect/prometheus/tsdb_status_response.qtpl:15 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 } -//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:19 func streamtsdbStatusEntries(qw422016 *qt422016.Writer, a []storage.TopHeapEntry) { -//line app/vmselect/prometheus/tsdb_status_response.qtpl:17 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:19 qw422016.N().S(`[`) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:19 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:21 for i, e := range a { -//line app/vmselect/prometheus/tsdb_status_response.qtpl:19 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:21 qw422016.N().S(`{"name":`) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:21 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:23 qw422016.N().Q(e.Name) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:21 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:23 qw422016.N().S(`,"value":`) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:22 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:24 qw422016.N().D(int(e.Count)) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:22 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:24 qw422016.N().S(`}`) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:24 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:26 if i+1 < len(a) { -//line app/vmselect/prometheus/tsdb_status_response.qtpl:24 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:26 qw422016.N().S(`,`) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:24 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:26 } -//line app/vmselect/prometheus/tsdb_status_response.qtpl:25 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 } -//line app/vmselect/prometheus/tsdb_status_response.qtpl:25 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 qw422016.N().S(`]`) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 } -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 func writetsdbStatusEntries(qq422016 qtio422016.Writer, a []storage.TopHeapEntry) { -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 qw422016 := qt422016.AcquireWriter(qq422016) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 streamtsdbStatusEntries(qw422016, a) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 qt422016.ReleaseWriter(qw422016) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 } -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 func tsdbStatusEntries(a []storage.TopHeapEntry) string { -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 qb422016 := qt422016.AcquireByteBuffer() -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 writetsdbStatusEntries(qb422016, a) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 qs422016 := string(qb422016.B) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 qt422016.ReleaseByteBuffer(qb422016) -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 return qs422016 -//line app/vmselect/prometheus/tsdb_status_response.qtpl:27 +//line app/vmselect/prometheus/tsdb_status_response.qtpl:29 } diff --git a/app/vmselect/vmui/asset-manifest.json b/app/vmselect/vmui/asset-manifest.json index bcdeef4c3b..5544869073 100644 --- a/app/vmselect/vmui/asset-manifest.json +++ b/app/vmselect/vmui/asset-manifest.json @@ -1,12 +1,12 @@ { "files": { "main.css": "./static/css/main.d8362c27.css", - "main.js": "./static/js/main.a35e61a3.js", + "main.js": "./static/js/main.105dbc4f.js", "static/js/27.939f971b.chunk.js": "./static/js/27.939f971b.chunk.js", "index.html": "./index.html" }, "entrypoints": [ "static/css/main.d8362c27.css", - "static/js/main.a35e61a3.js" + "static/js/main.105dbc4f.js" ] } \ No newline at end of file diff --git a/app/vmselect/vmui/favicon.ico b/app/vmselect/vmui/favicon.ico new file mode 100644 index 0000000000..efeb457029 Binary files /dev/null and b/app/vmselect/vmui/favicon.ico differ diff --git a/app/vmselect/vmui/index.html b/app/vmselect/vmui/index.html index c39f59576f..55e9c2552c 100644 --- a/app/vmselect/vmui/index.html +++ b/app/vmselect/vmui/index.html @@ -1 +1 @@ -
'+(n?e:Zk(e,!0))+"
\n":""+(n?e:Zk(e,!0))+"
\n"}},{key:"blockquote",value:function(e){return"\n".concat(e,"\n")}},{key:"html",value:function(e){return e}},{key:"heading",value:function(e,t,n,r){if(this.options.headerIds){var o=this.options.headerPrefix+r.slug(n);return"
".concat(e,"
\n")}},{key:"table",value:function(e,t){return t&&(t="".concat(t,"")),"".concat(e,"
")}},{key:"br",value:function(){return this.options.xhtml?""+Zk(l.message+"",!0)+"";throw l}}Gk.options=Gk.setOptions=function(e){var t;return Fk(Gk.defaults,e),t=Gk.defaults,hk=t,Gk},Gk.getDefaults=pk,Gk.defaults=hk,Gk.use=function(){for(var e=arguments.length,t=new Array(e),n=0;n
"+Zk(r.message+"",!0)+"";throw r}},Gk.Parser=Xk,Gk.parser=Xk.parse,Gk.Renderer=Yk,Gk.TextRenderer=Uk,Gk.Lexer=Vk,Gk.lexer=Vk.lex,Gk.Tokenizer=zk,Gk.Slugger=qk,Gk.parse=Gk;Gk.options,Gk.setOptions,Gk.use,Gk.walkTokens,Gk.parseInline,Xk.parse,Vk.lex;var Kk,Qk,Jk,eS,tS,nS,rS,oS,iS=function(e){var n=e.title,o=e.description,i=e.unit,a=e.expr,u=e.showLegend,l=e.filename,s=e.alias,c=ao().time.period,d=uo(),f=(0,t.useRef)(null),p=(0,t.useState)(!0),h=(0,r.Z)(p,2),m=h[0],v=h[1],g=(0,t.useState)({enable:!1,value:c.step||1}),y=(0,r.Z)(g,2),b=y[0],x=y[1],Z=(0,t.useState)({limits:{enable:!1,range:{1:[0,0]}}}),w=(0,r.Z)(Z,2),D=w[0],k=w[1],S=(0,t.useMemo)((function(){return Array.isArray(a)&&a.every((function(e){return e}))}),[a]),C=Hv({predefinedQuery:S?a:[],display:"chart",visible:m,customStep:b}),_=C.isLoading,E=C.graphData,M=C.error,A=function(e){var t=vn({},D);t.limits.range=e,k(t)};return(0,t.useEffect)((function(){var e=new IntersectionObserver((function(e){e.forEach((function(e){return v(e.isIntersecting)}))}),{threshold:.1});return f.current&&e.observe(f.current),function(){f.current&&e.unobserve(f.current)}}),[]),S?(0,ie.BX)(fi,{border:"1px solid",borderRadius:"2px",borderColor:"divider",width:"100%",height:"100%",ref:f,children:[(0,ie.BX)(fi,{px:2,py:1,display:"flex",flexWrap:"wrap",width:"100%",alignItems:"center",justifyContent:"space-between",borderBottom:"1px solid",borderColor:"divider",children:[(0,ie.tZ)(xd,{arrow:!0,componentsProps:{tooltip:{sx:{maxWidth:"100%"}}},title:(0,ie.BX)(fi,{sx:{p:1},children:[o&&(0,ie.BX)(fi,{mb:2,children:[(0,ie.tZ)(cv,{fontWeight:"500",sx:{mb:.5,textDecoration:"underline"},children:"Description:"}),(0,ie.tZ)("div",{className:"panelDescription",dangerouslySetInnerHTML:{__html:Gk.parse(o)}})]}),(0,ie.BX)(fi,{children:[(0,ie.tZ)(cv,{fontWeight:"500",sx:{mb:.5,textDecoration:"underline"},children:"Queries:"}),(0,ie.tZ)("div",{children:a.map((function(e,t){return(0,ie.tZ)(fi,{mb:.5,children:e},"".concat(t,"_").concat(e))}))})]})]}),children:(0,ie.tZ)(fk.Z,{color:"info",sx:{mr:1}})}),(0,ie.tZ)(cv,{component:"div",variant:"subtitle1",fontWeight:500,sx:{mr:2,py:1,flexGrow:"1"},children:n||""}),(0,ie.tZ)(fi,{mr:2,py:1,children:(0,ie.tZ)(Rv,{defaultStep:c.step,customStepEnable:b.enable,setStep:function(e){return x(vn(vn({},b),{},{value:e}))},toggleEnableStep:function(){return x(vn(vn({},b),{},{enable:!b.enable}))}})}),(0,ie.tZ)(cg,{yaxis:D,setYaxisLimits:A,toggleEnableLimits:function(){var e=vn({},D);e.limits.enable=!e.limits.enable,k(e)}})]}),(0,ie.BX)(fi,{px:2,pb:2,children:[_&&(0,ie.tZ)(Ag,{isLoading:!0,height:"500px"}),M&&(0,ie.tZ)(_t,{color:"error",severity:"error",sx:{whiteSpace:"pre-wrap",mt:2},children:M}),E&&(0,ie.tZ)(Ed,{data:E,period:c,customStep:b,query:a,yaxis:D,unit:i,alias:s,showLegend:u,setYaxisLimits:A,setPeriod:function(e){var t=e.from,n=e.to;d({type:"SET_PERIOD",payload:{from:t,to:n}})}})]})]}):(0,ie.BX)(_t,{color:"error",severity:"error",sx:{m:4},children:[(0,ie.tZ)("code",{children:'"expr"'})," not found. Check the configuration file ",(0,ie.tZ)("b",{children:l}),"."]})},aS={position:"absolute",top:0,bottom:0,width:"10px",opacity:0,cursor:"ew-resize"},uS=function(e){var n=e.index,o=e.title,i=e.panels,a=e.filename,u=Ss(document.body),l=(0,t.useMemo)((function(){return u.width/12}),[u]),s=(0,t.useState)([]),c=(0,r.Z)(s,2),d=c[0],f=c[1];(0,t.useEffect)((function(){f(i.map((function(e){return e.width||12})))}),[i]);var p=(0,t.useState)({start:0,target:0,enable:!1}),h=(0,r.Z)(p,2),m=h[0],v=h[1],g=function(e){if(m.enable){var t=m.start,n=Math.ceil((t-e.clientX)/l);if(!(Math.abs(n)>=12)){var r=d.map((function(e,t){return e-(t===m.target?n:0)}));f(r)}}},y=function(){v(vn(vn({},m),{},{enable:!1}))};return(0,t.useEffect)((function(){return window.addEventListener("mousemove",g),window.addEventListener("mouseup",y),function(){window.removeEventListener("mousemove",g),window.removeEventListener("mouseup",y)}}),[m]),(0,ie.BX)(KD,{defaultExpanded:!n,sx:{boxShadow:"none"},children:[(0,ie.tZ)(ik,{sx:{px:3,bgcolor:"rgba(227, 242, 253, 0.6)"},"aria-controls":"panel".concat(n,"-content"),id:"panel".concat(n,"-header"),expandIcon:(0,ie.tZ)(dk.Z,{}),children:(0,ie.BX)(fi,{display:"flex",alignItems:"center",width:"100%",children:[o&&(0,ie.tZ)(cv,{variant:"h6",fontWeight:"bold",sx:{mr:2},children:o}),i&&(0,ie.BX)(cv,{variant:"body2",fontStyle:"italic",children:["(",i.length," panels)"]})]})}),(0,ie.tZ)(ck,{sx:{display:"grid",gridGap:"10px"},children:(0,ie.tZ)(rb,{container:!0,spacing:2,children:Array.isArray(i)&&i.length?i.map((function(e,t){return(0,ie.tZ)(rb,{item:!0,xs:d[t],sx:{transition:"200ms"},children:(0,ie.BX)(fi,{position:"relative",height:"100%",children:[(0,ie.tZ)(iS,{title:e.title,description:e.description,unit:e.unit,expr:e.expr,alias:e.alias,filename:a,showLegend:e.showLegend}),(0,ie.tZ)("button",{style:vn(vn({},aS),{},{right:0}),onMouseDown:function(e){return function(e,t){v({start:e.clientX,target:t,enable:!0})}(e,t)}})]})},t)})):(0,ie.BX)(_t,{color:"error",severity:"error",sx:{m:4},children:[(0,ie.tZ)("code",{children:'"panels"'})," not found. Check the configuration file ",(0,ie.tZ)("b",{children:a}),"."]})})})]})},lS=function(){var e=(0,t.useState)(),n=(0,r.Z)(e,2),o=n[0],i=n[1],a=(0,t.useState)(0),u=(0,r.Z)(a,2),l=u[0],s=u[1],c=(0,t.useMemo)((function(){return br()(o,[l,"filename"],"")}),[o,l]),d=(0,t.useMemo)((function(){return br()(o,[l,"rows"],[])}),[o,l]);return(0,t.useEffect)((function(){RD().then((function(e){return e.length&&i(e)}))}),[]),(0,ie.BX)(ie.HY,{children:[!o&&(0,ie.tZ)(_t,{color:"info",severity:"info",sx:{m:4},children:"Dashboards not found"}),o&&(0,ie.BX)(ie.HY,{children:[(0,ie.tZ)(fi,{sx:{borderBottom:1,borderColor:"divider"},children:(0,ie.tZ)(Jn,{value:l,onChange:function(e,t){return s(t)},"aria-label":"dashboard-tabs",children:o&&o.map((function(e,t){return(0,ie.tZ)(ur,{label:e.title||e.filename,id:"tab-".concat(t),"aria-controls":"tabpanel-".concat(t)},t)}))})}),(0,ie.tZ)(fi,{children:Array.isArray(d)&&d.length?d.map((function(e,t){return(0,ie.tZ)(uS,{index:t,filename:c,title:e.title,panels:e.panels},"".concat(l,"_").concat(t))})):(0,ie.BX)(_t,{color:"error",severity:"error",sx:{m:4},children:[(0,ie.tZ)("code",{children:'"rows"'})," not found. Check the configuration file ",(0,ie.tZ)("b",{children:c}),"."]})})]})]})},sS=function(e,t){var n=t.match?"&match[]=".concat(t.match):"";return"".concat(e,"/api/v1/status/tsdb?topN=").concat(t.topN,"&date=").concat(t.date).concat(n)},cS=jv(),dS=zv().serverURL,fS={totalSeries:0,totalLabelValuePairs:0,seriesCountByMetricName:[],seriesCountByLabelValuePair:[],labelValueCountByLabelName:[]},pS=(0,ht.Z)((0,ie.tZ)("path",{d:"M5.59 7.41L10.18 12l-4.59 4.59L7 18l6-6-6-6zM16 6h2v12h-2z"}),"LastPage"),hS=(0,ht.Z)((0,ie.tZ)("path",{d:"M18.41 16.59L13.82 12l4.59-4.59L17 6l-6 6 6 6zM6 6h2v12H6z"}),"FirstPage"),mS=["backIconButtonProps","count","getItemAriaLabel","nextIconButtonProps","onPageChange","page","rowsPerPage","showFirstButton","showLastButton"],vS=t.forwardRef((function(e,t){var n=e.backIconButtonProps,r=e.count,i=e.getItemAriaLabel,a=e.nextIconButtonProps,u=e.onPageChange,l=e.page,s=e.rowsPerPage,c=e.showFirstButton,d=e.showLastButton,f=(0,X.Z)(e,mS),p=Ot();return(0,ie.BX)("div",(0,o.Z)({ref:t},f,{children:[c&&(0,ie.tZ)(pt,{onClick:function(e){u(e,0)},disabled:0===l,"aria-label":i("first",l),title:i("first",l),children:"rtl"===p.direction?Kk||(Kk=(0,ie.tZ)(pS,{})):Qk||(Qk=(0,ie.tZ)(hS,{}))}),(0,ie.tZ)(pt,(0,o.Z)({onClick:function(e){u(e,l-1)},disabled:0===l,color:"inherit","aria-label":i("previous",l),title:i("previous",l)},n,{children:"rtl"===p.direction?Jk||(Jk=(0,ie.tZ)(An,{})):eS||(eS=(0,ie.tZ)(Mn,{}))})),(0,ie.tZ)(pt,(0,o.Z)({onClick:function(e){u(e,l+1)},disabled:-1!==r&&l>=Math.ceil(r/s)-1,color:"inherit","aria-label":i("next",l),title:i("next",l)},a,{children:"rtl"===p.direction?tS||(tS=(0,ie.tZ)(Mn,{})):nS||(nS=(0,ie.tZ)(An,{}))})),d&&(0,ie.tZ)(pt,{onClick:function(e){u(e,Math.max(0,Math.ceil(r/s)-1))},disabled:l>=Math.ceil(r/s)-1,"aria-label":i("last",l),title:i("last",l),children:"rtl"===p.direction?rS||(rS=(0,ie.tZ)(hS,{})):oS||(oS=(0,ie.tZ)(pS,{}))})]}))})),gS=vS;function yS(e){return(0,ne.Z)("MuiTablePagination",e)}var bS,xS=(0,re.Z)("MuiTablePagination",["root","toolbar","spacer","selectLabel","selectRoot","select","selectIcon","input","menuItem","displayedRows","actions"]),ZS=["ActionsComponent","backIconButtonProps","className","colSpan","component","count","getItemAriaLabel","labelDisplayedRows","labelRowsPerPage","nextIconButtonProps","onPageChange","onRowsPerPageChange","page","rowsPerPage","rowsPerPageOptions","SelectProps","showFirstButton","showLastButton"],wS=(0,J.ZP)(Xd,{name:"MuiTablePagination",slot:"Root",overridesResolver:function(e,t){return t.root}})((function(e){var t=e.theme;return{overflow:"auto",color:t.palette.text.primary,fontSize:t.typography.pxToRem(14),"&:last-child":{padding:0}}})),DS=(0,J.ZP)(Qg,{name:"MuiTablePagination",slot:"Toolbar",overridesResolver:function(e,t){return(0,o.Z)((0,q.Z)({},"& .".concat(xS.actions),t.actions),t.toolbar)}})((function(e){var t,n=e.theme;return t={minHeight:52,paddingRight:2},(0,q.Z)(t,"".concat(n.breakpoints.up("xs")," and (orientation: landscape)"),{minHeight:52}),(0,q.Z)(t,n.breakpoints.up("sm"),{minHeight:52,paddingRight:2}),(0,q.Z)(t,"& .".concat(xS.actions),{flexShrink:0,marginLeft:20}),t})),kS=(0,J.ZP)("div",{name:"MuiTablePagination",slot:"Spacer",overridesResolver:function(e,t){return t.spacer}})({flex:"1 1 100%"}),SS=(0,J.ZP)("p",{name:"MuiTablePagination",slot:"SelectLabel",overridesResolver:function(e,t){return t.selectLabel}})((function(e){var t=e.theme;return(0,o.Z)({},t.typography.body2,{flexShrink:0})})),CS=(0,J.ZP)(Bm,{name:"MuiTablePagination",slot:"Select",overridesResolver:function(e,t){var n;return(0,o.Z)((n={},(0,q.Z)(n,"& .".concat(xS.selectIcon),t.selectIcon),(0,q.Z)(n,"& .".concat(xS.select),t.select),n),t.input,t.selectRoot)}})((0,q.Z)({color:"inherit",fontSize:"inherit",flexShrink:0,marginRight:32,marginLeft:8},"& .".concat(xS.select),{paddingLeft:8,paddingRight:24,textAlign:"right",textAlignLast:"right"})),_S=(0,J.ZP)(Jm,{name:"MuiTablePagination",slot:"MenuItem",overridesResolver:function(e,t){return t.menuItem}})({}),ES=(0,J.ZP)("p",{name:"MuiTablePagination",slot:"DisplayedRows",overridesResolver:function(e,t){return t.displayedRows}})((function(e){var t=e.theme;return(0,o.Z)({},t.typography.body2,{flexShrink:0})}));function MS(e){var t=e.from,n=e.to,r=e.count;return"".concat(t,"\u2013").concat(n," of ").concat(-1!==r?r:"more than ".concat(n))}function AS(e){return"Go to ".concat(e," page")}var PS=t.forwardRef((function(e,n){var r,i=(0,ee.Z)({props:e,name:"MuiTablePagination"}),a=i.ActionsComponent,u=void 0===a?gS:a,l=i.backIconButtonProps,s=i.className,c=i.colSpan,d=i.component,f=void 0===d?Xd:d,p=i.count,h=i.getItemAriaLabel,m=void 0===h?AS:h,v=i.labelDisplayedRows,g=void 0===v?MS:v,y=i.labelRowsPerPage,b=void 0===y?"Rows per page:":y,x=i.nextIconButtonProps,Z=i.onPageChange,w=i.onRowsPerPageChange,D=i.page,k=i.rowsPerPage,S=i.rowsPerPageOptions,C=void 0===S?[10,25,50,100]:S,_=i.SelectProps,E=void 0===_?{}:_,M=i.showFirstButton,A=void 0!==M&&M,P=i.showLastButton,T=void 0!==P&&P,R=(0,X.Z)(i,ZS),F=i,O=function(e){var t=e.classes;return(0,K.Z)({root:["root"],toolbar:["toolbar"],spacer:["spacer"],selectLabel:["selectLabel"],select:["select"],input:["input"],selectIcon:["selectIcon"],menuItem:["menuItem"],displayedRows:["displayedRows"],actions:["actions"]},yS,t)}(F),B=E.native?"option":_S;f!==Xd&&"td"!==f||(r=c||1e3);var I=(0,ld.Z)(E.id),L=(0,ld.Z)(E.labelId);return(0,ie.tZ)(wS,(0,o.Z)({colSpan:r,ref:n,as:f,ownerState:F,className:(0,G.Z)(O.root,s)},R,{children:(0,ie.BX)(DS,{className:O.toolbar,children:[(0,ie.tZ)(kS,{className:O.spacer}),C.length>1&&(0,ie.tZ)(SS,{className:O.selectLabel,id:L,children:b}),C.length>1&&(0,ie.tZ)(CS,(0,o.Z)({variant:"standard",input:bS||(bS=(0,ie.tZ)(qf,{})),value:k,onChange:w,id:I,labelId:L},E,{classes:(0,o.Z)({},E.classes,{root:(0,G.Z)(O.input,O.selectRoot,(E.classes||{}).root),select:(0,G.Z)(O.select,(E.classes||{}).select),icon:(0,G.Z)(O.selectIcon,(E.classes||{}).icon)}),children:C.map((function(e){return(0,t.createElement)(B,(0,o.Z)({},!Ps(B)&&{ownerState:F},{className:O.menuItem,key:e.label?e.label:e,value:e.value?e.value:e}),e.label?e.label:e)}))})),(0,ie.tZ)(ES,{className:O.displayedRows,children:g({from:0===p?0:D*k+1,to:-1===p?(D+1)*k:-1===k?p:Math.min(p,(D+1)*k),count:-1===p?-1:p,page:D})}),(0,ie.tZ)(u,{className:O.actions,backIconButtonProps:l,count:p,nextIconButtonProps:x,onPageChange:Z,page:D,rowsPerPage:k,showFirstButton:A,showLastButton:T,getItemAriaLabel:m})]})}))})),TS=PS,RS={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:-1,overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"};function FS(e){var t=e.order,n=e.orderBy,r=e.onRequestSort,o=e.headerCells;return(0,ie.tZ)(lf,{children:(0,ie.tZ)(hf,{children:o.map((function(e){return(0,ie.tZ)(Xd,{align:e.numeric?"right":"left",sortDirection:n===e.id&&t,children:(0,ie.BX)(wf,{active:n===e.id,direction:n===e.id?t:"asc",onClick:(o=e.id,function(e){r(e,o)}),children:[e.label,n===e.id?(0,ie.tZ)(fi,{component:"span",sx:RS,children:"desc"===t?"sorted descending":"sorted ascending"}):null]})},e.id);var o}))})})}function OS(e,t,n){return t[n]
'+(n?e:ND(e,!0))+"
\n":""+(n?e:ND(e,!0))+"
\n"}},{key:"blockquote",value:function(e){return"\n".concat(e,"\n")}},{key:"html",value:function(e){return e}},{key:"heading",value:function(e,t,n,r){if(this.options.headerIds){var o=this.options.headerPrefix+r.slug(n);return"
".concat(e,"
\n")}},{key:"table",value:function(e,t){return t&&(t="".concat(t,"")),"".concat(e,"
")}},{key:"br",value:function(){return this.options.xhtml?""+ND(l.message+"",!0)+"";throw l}}hk.options=hk.setOptions=function(e){var t;return QD(hk.defaults,e),t=hk.defaults,PD=t,hk},hk.getDefaults=TD,hk.defaults=PD,hk.use=function(){for(var e=arguments.length,t=new Array(e),n=0;n
"+ND(r.message+"",!0)+"";throw r}},hk.Parser=pk,hk.parser=pk.parse,hk.Renderer=ck,hk.TextRenderer=dk,hk.Lexer=sk,hk.lexer=sk.lex,hk.Tokenizer=ok,hk.Slugger=fk,hk.parse=hk;hk.options,hk.setOptions,hk.use,hk.walkTokens,hk.parseInline,pk.parse,sk.lex;var mk=function(e){var n=e.title,o=e.description,i=e.unit,a=e.expr,u=e.showLegend,l=e.filename,s=e.alias,c=no().time.period,d=ro(),f=(0,t.useRef)(null),p=(0,t.useState)(!0),h=(0,r.Z)(p,2),m=h[0],v=h[1],g=(0,t.useState)({enable:!1,value:c.step||1}),y=(0,r.Z)(g,2),b=y[0],x=y[1],Z=(0,t.useState)({limits:{enable:!1,range:{1:[0,0]}}}),w=(0,r.Z)(Z,2),D=w[0],k=w[1],S=(0,t.useMemo)((function(){return Array.isArray(a)&&a.every((function(e){return e}))}),[a]),C=Fv({predefinedQuery:S?a:[],display:"chart",visible:m,customStep:b}),_=C.isLoading,E=C.graphData,A=C.error,M=function(e){var t=vn({},D);t.limits.range=e,k(t)};return(0,t.useEffect)((function(){var e=new IntersectionObserver((function(e){e.forEach((function(e){return v(e.isIntersecting)}))}),{threshold:.1});return f.current&&e.observe(f.current),function(){f.current&&e.unobserve(f.current)}}),[]),S?(0,ie.BX)(ni,{border:"1px solid",borderRadius:"2px",borderColor:"divider",width:"100%",height:"100%",ref:f,children:[(0,ie.BX)(ni,{px:2,py:1,display:"flex",flexWrap:"wrap",width:"100%",alignItems:"center",justifyContent:"space-between",borderBottom:"1px solid",borderColor:"divider",children:[(0,ie.tZ)(cd,{arrow:!0,componentsProps:{tooltip:{sx:{maxWidth:"100%"}}},title:(0,ie.BX)(ni,{sx:{p:1},children:[o&&(0,ie.BX)(ni,{mb:2,children:[(0,ie.tZ)(ev,{fontWeight:"500",sx:{mb:.5,textDecoration:"underline"},children:"Description:"}),(0,ie.tZ)("div",{className:"panelDescription",dangerouslySetInnerHTML:{__html:hk.parse(o)}})]}),(0,ie.BX)(ni,{children:[(0,ie.tZ)(ev,{fontWeight:"500",sx:{mb:.5,textDecoration:"underline"},children:"Queries:"}),(0,ie.tZ)("div",{children:a.map((function(e,t){return(0,ie.tZ)(ni,{mb:.5,children:e},"".concat(t,"_").concat(e))}))})]})]}),children:(0,ie.tZ)(MD.Z,{color:"info",sx:{mr:1}})}),(0,ie.tZ)(ev,{component:"div",variant:"subtitle1",fontWeight:500,sx:{mr:2,py:1,flexGrow:"1"},children:n||""}),(0,ie.tZ)(ni,{mr:2,py:1,children:(0,ie.tZ)(Dv,{defaultStep:c.step,customStepEnable:b.enable,setStep:function(e){return x(vn(vn({},b),{},{value:e}))},toggleEnableStep:function(){return x(vn(vn({},b),{},{enable:!b.enable}))}})}),(0,ie.tZ)(eg,{yaxis:D,setYaxisLimits:M,toggleEnableLimits:function(){var e=vn({},D);e.limits.enable=!e.limits.enable,k(e)}})]}),(0,ie.BX)(ni,{px:2,pb:2,children:[_&&(0,ie.tZ)(bg,{isLoading:!0,height:"500px"}),A&&(0,ie.tZ)(_t,{color:"error",severity:"error",sx:{whiteSpace:"pre-wrap",mt:2},children:A}),E&&(0,ie.tZ)(yd,{data:E,period:c,customStep:b,query:a,yaxis:D,unit:i,alias:s,showLegend:u,setYaxisLimits:M,setPeriod:function(e){var t=e.from,n=e.to;d({type:"SET_PERIOD",payload:{from:t,to:n}})}})]})]}):(0,ie.BX)(_t,{color:"error",severity:"error",sx:{m:4},children:[(0,ie.tZ)("code",{children:'"expr"'})," not found. Check the configuration file ",(0,ie.tZ)("b",{children:l}),"."]})},vk={position:"absolute",top:0,bottom:0,width:"10px",opacity:0,cursor:"ew-resize"},gk=function(e){var n=e.index,o=e.title,i=e.panels,a=e.filename,u=ms(document.body),l=(0,t.useMemo)((function(){return u.width/12}),[u]),s=(0,t.useState)([]),c=(0,r.Z)(s,2),d=c[0],f=c[1];(0,t.useEffect)((function(){f(i.map((function(e){return e.width||12})))}),[i]);var p=(0,t.useState)({start:0,target:0,enable:!1}),h=(0,r.Z)(p,2),m=h[0],v=h[1],g=function(e){if(m.enable){var t=m.start,n=Math.ceil((t-e.clientX)/l);if(!(Math.abs(n)>=12)){var r=d.map((function(e,t){return e-(t===m.target?n:0)}));f(r)}}},y=function(){v(vn(vn({},m),{},{enable:!1}))};return(0,t.useEffect)((function(){return window.addEventListener("mousemove",g),window.addEventListener("mouseup",y),function(){window.removeEventListener("mousemove",g),window.removeEventListener("mouseup",y)}}),[m]),(0,ie.BX)(mD,{defaultExpanded:!n,sx:{boxShadow:"none"},children:[(0,ie.tZ)(DD,{sx:{px:3,bgcolor:"rgba(227, 242, 253, 0.6)"},"aria-controls":"panel".concat(n,"-content"),id:"panel".concat(n,"-header"),expandIcon:(0,ie.tZ)(AD.Z,{}),children:(0,ie.BX)(ni,{display:"flex",alignItems:"center",width:"100%",children:[o&&(0,ie.tZ)(ev,{variant:"h6",fontWeight:"bold",sx:{mr:2},children:o}),i&&(0,ie.BX)(ev,{variant:"body2",fontStyle:"italic",children:["(",i.length," panels)"]})]})}),(0,ie.tZ)(ED,{sx:{display:"grid",gridGap:"10px"},children:(0,ie.tZ)($y,{container:!0,spacing:2,children:Array.isArray(i)&&i.length?i.map((function(e,t){return(0,ie.tZ)($y,{item:!0,xs:d[t],sx:{transition:"200ms"},children:(0,ie.BX)(ni,{position:"relative",height:"100%",children:[(0,ie.tZ)(mk,{title:e.title,description:e.description,unit:e.unit,expr:e.expr,alias:e.alias,filename:a,showLegend:e.showLegend}),(0,ie.tZ)("button",{style:vn(vn({},vk),{},{right:0}),onMouseDown:function(e){return function(e,t){v({start:e.clientX,target:t,enable:!0})}(e,t)}})]})},t)})):(0,ie.BX)(_t,{color:"error",severity:"error",sx:{m:4},children:[(0,ie.tZ)("code",{children:'"panels"'})," not found. Check the configuration file ",(0,ie.tZ)("b",{children:a}),"."]})})})]})},yk=function(){var e=(0,t.useState)(),n=(0,r.Z)(e,2),o=n[0],i=n[1],a=(0,t.useState)(0),u=(0,r.Z)(a,2),l=u[0],s=u[1],c=(0,t.useMemo)((function(){return yr()(o,[l,"filename"],"")}),[o,l]),d=(0,t.useMemo)((function(){return yr()(o,[l,"rows"],[])}),[o,l]);return(0,t.useEffect)((function(){Kw().then((function(e){return e.length&&i(e)}))}),[]),(0,ie.BX)(ie.HY,{children:[!o&&(0,ie.tZ)(_t,{color:"info",severity:"info",sx:{m:4},children:"Dashboards not found"}),o&&(0,ie.BX)(ie.HY,{children:[(0,ie.tZ)(ni,{sx:{borderBottom:1,borderColor:"divider"},children:(0,ie.tZ)(Jn,{value:l,onChange:function(e,t){return s(t)},"aria-label":"dashboard-tabs",children:o&&o.map((function(e,t){return(0,ie.tZ)(ar,{label:e.title||e.filename,id:"tab-".concat(t),"aria-controls":"tabpanel-".concat(t)},t)}))})}),(0,ie.tZ)(ni,{children:Array.isArray(d)&&d.length?d.map((function(e,t){return(0,ie.tZ)(gk,{index:t,filename:c,title:e.title,panels:e.panels},"".concat(l,"_").concat(t))})):(0,ie.BX)(_t,{color:"error",severity:"error",sx:{m:4},children:[(0,ie.tZ)("code",{children:'"rows"'})," not found. Check the configuration file ",(0,ie.tZ)("b",{children:c}),"."]})})]})]})},bk=function(){return(0,ie.tZ)(ie.HY,{children:(0,ie.BX)(V,{children:[(0,ie.tZ)(Bo,{})," ",(0,ie.BX)(Lo,{dateAdapter:Vo,children:[" ",(0,ie.tZ)(So,{injectFirst:!0,children:(0,ie.BX)(To,{theme:Do,children:[" ",(0,ie.BX)(io,{children:[" ",(0,ie.BX)(mo,{children:[" ",(0,ie.BX)(Zo,{children:[" ",(0,ie.BX)(hn,{children:[" ",(0,ie.tZ)(j,{children:(0,ie.BX)(N,{path:"/",element:(0,ie.tZ)(Xw,{}),children:[(0,ie.tZ)(N,{path:br,element:(0,ie.tZ)(xg,{})}),(0,ie.tZ)(N,{path:xr,element:(0,ie.tZ)(yk,{})})]})})]})]})]})]})]})})]})]})})},xk=function(e){e&&e instanceof Function&&n.e(27).then(n.bind(n,4027)).then((function(t){var n=t.getCLS,r=t.getFID,o=t.getFCP,i=t.getLCP,a=t.getTTFB;n(e),r(e),o(e),i(e),a(e)}))},Zk=document.getElementById("root");Zk&&(0,t.render)((0,ie.tZ)(bk,{}),Zk),xk()}()}(); \ No newline at end of file diff --git a/app/vmstorage/transport/server.go b/app/vmstorage/transport/server.go index 412cba680a..901f28197c 100644 --- a/app/vmstorage/transport/server.go +++ b/app/vmstorage/transport/server.go @@ -959,6 +959,12 @@ func (s *Server) processVMSelectTSDBStatus(ctx *vmselectRequestCtx) error { if err := writeTopHeapEntries(ctx, status.SeriesCountByLabelValuePair); err != nil { return fmt.Errorf("cannot write seriesCountByLabelValuePair to vmselect: %w", err) } + if err := ctx.writeUint64(status.TotalSeries); err != nil { + return fmt.Errorf("cannot write totalSeries to vmselect: %w", err) + } + if err := ctx.writeUint64(status.TotalLabelValuePairs); err != nil { + return fmt.Errorf("cannot write totalLabelValuePairs to vmselect: %w", err) + } return nil } diff --git a/app/vmui/packages/vmui/public/favicon.ico b/app/vmui/packages/vmui/public/favicon.ico new file mode 100644 index 0000000000..efeb457029 Binary files /dev/null and b/app/vmui/packages/vmui/public/favicon.ico differ diff --git a/app/vmui/packages/vmui/src/App.tsx b/app/vmui/packages/vmui/src/App.tsx index 012c16f3ba..f039f87549 100644 --- a/app/vmui/packages/vmui/src/App.tsx +++ b/app/vmui/packages/vmui/src/App.tsx @@ -4,6 +4,7 @@ import {SnackbarProvider} from "./contexts/Snackbar"; import {StateProvider} from "./state/common/StateContext"; import {AuthStateProvider} from "./state/auth/AuthStateContext"; import {GraphStateProvider} from "./state/graph/GraphStateContext"; +import {CardinalityStateProvider} from "./state/cardinality/CardinalityStateContext"; import THEME from "./theme/theme"; import { ThemeProvider, StyledEngineProvider } from "@mui/material/styles"; import CssBaseline from "@mui/material/CssBaseline"; @@ -14,6 +15,7 @@ import router from "./router/index"; import CustomPanel from "./components/CustomPanel/CustomPanel"; import HomeLayout from "./components/Home/HomeLayout"; import DashboardsLayout from "./components/PredefinedPanels/DashboardsLayout"; +import CardinalityPanel from "./components/CardinalityPanel/CardinalityPanel"; const App: FC = () => { @@ -27,14 +29,17 @@ const App: FC = () => {