text: (window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["global-overview"],{"0f02":function(t,e,a){},1017:function(t,e,a){"use strict";var r=a("467d"),n=a.n(r);n.a},2055:function(t,e,a){},2226:function(t,e,a){"use strict";a.r(e);var r=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"overview"},[a("page-header",{attrs:{noflex:""}},[a("breadcrumbs")],1),a("MetricGrid",{attrs:{metrics:t.overviewMetrics}}),a("div",{staticClass:"card-wrapper"},[a("div",[a("CardSkeleton",{staticClass:"card-item",attrs:{"card-action-route":{name:"create-mesh"},"card-title":"Create a new Mesh resource","card-action-button-text":"Create Mesh"}},[a("template",{slot:"cardContent"},[a("p",[t._v("\n            You can create multiple Mesh resources (i.e. per application, or per team)\n            on the same "+t._s(t.title)+" cluster.\n          ")])])],2)],1),a("div",[a("CardSkeleton",{staticClass:"card-item",attrs:{"card-action-route":t.dataplaneWizardRoute,"card-title":"Connect a Dataplane to "+t.title,"card-action-button-text":"Connect Dataplanes"}},[a("template",{slot:"cardContent"},[a("p",[t._v("\n            Every service must have its own Dataplane resource in order to start\n            the data plane proxy and associate it with a Mesh.\n          ")])])],2)],1),a("div",[a("CardSkeleton",{staticClass:"card-item",attrs:{"card-action-route":"https://kuma.io/policies/","card-title":"Apply "+t.title+" Policies","card-action-button-text":"Explore Policies","external-link":""}},[a("template",{slot:"cardContent"},[a("p",[t._v("\n            Once we have created your Mesh and started the data planes, we can now\n            use "+t._s(t.title)+" Policies to manage the Mesh.\n          ")])])],2)],1)])],1)},n=[],o=(a("8e6e"),a("456d"),a("ac6a"),a("bd86")),c=a("2f62"),i=a("43c3"),s=a("b6c6"),u=a("be10"),l=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"skeleton-card-wrapper"},[a("KCard",{class:{"is-centered":t.centerText},attrs:{title:t.cardTitle}},[a("template",{slot:"body"},[t._t("cardContent"),t.cardActionButtonText&&t.cardActionRoute?a("div",{staticClass:"skeleton-card__action mt-4"},[t._t("cardAction",[t.externalLink?a("a",{staticClass:"external-link-btn",attrs:{href:t.cardActionRoute,target:"_blank"}},[t._v("\n            "+t._s(t.cardActionButtonText)+"\n          ")]):a("KButton",{attrs:{to:t.cardActionRoute,appearance:"primary"}},[t._v("\n            "+t._s(t.cardActionButtonText)+"\n          ")])])],2):t._e()],2)],2)],1)},f=[],m=a("d05b"),h=a("ce72"),d={name:"CardSkeleton",components:{KCard:m["a"],KButton:h["a"]},props:{cardTitle:{type:String,required:!0},cardActionRoute:{type:[Object,String],required:!0},cardActionButtonText:{type:String,required:!0},centerText:{type:Boolean,default:!1},externalLink:{type:Boolean,default:!1}}},p=d,C=(a("1017"),a("2877")),v=Object(C["a"])(p,l,f,!1,null,"531623a5",null),b=v.exports;function T(t,e){var a=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),a.push.apply(a,r)}return a}function y(t){for(var e=1;e<arguments.length;e++){var a=null!=arguments[e]?arguments[e]:{};e%2?T(Object(a),!0).forEach((function(e){Object(o["a"])(t,e,a[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):T(Object(a)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(a,e))}))}return t}var M={name:"Overview",metaInfo:function(){return{title:this.$route.meta.title}},components:{PageHeader:i["a"],Breadcrumbs:s["a"],MetricGrid:u["a"],CardSkeleton:b},computed:y({},Object(c["b"])({title:"getTagline",environment:"getEnvironment",selectedMesh:"getSelectedMesh",multicluster:"getMulticlusterStatus"}),{pageTitle:function(){var t=this.$route.meta.title,e=this.selectedMesh;return"all"===e?"".concat(t," for all Meshes"):"".concat(t," for ").concat(e)},overviewMetrics:function(){var t,e=this.selectedMesh,a=this.$store.state;t="all"===e?{meshCount:a.totalMeshCount,dataplaneCount:a.totalDataplaneCount,faultInjectionCount:a.totalFaultInjectionCount,healthCheckCount:a.totalHealthCheckCount,proxyTemplateCount:a.totalProxyTemplateCount,trafficLogCount:a.totalTrafficLogCount,trafficPermissionCount:a.totalTrafficPermissionCount,trafficRouteCount:a.totalTrafficRouteCount,trafficTraceCount:a.totalTrafficTraceCount,circuitBreakerCount:a.totalCircuitBreakerCount}:{dataplaneCount:a.totalDataplaneCountFromMesh,faultInjectionCount:a.totalFaultInjectionCountFromMesh,healthCheckCount:a.totalHealthCheckCountFromMesh,proxyTemplateCount:a.totalProxyTemplateCountFromMesh,trafficLogCount:a.totalTrafficLogCountFromMesh,trafficPermissionCount:a.totalTrafficPermissionCountFromMesh,trafficRouteCount:a.totalTrafficRouteCountFromMesh,trafficTraceCount:a.totalTrafficTraceCountFromMesh,circuitBreakerCount:a.totalCircuitBreakerCountFromMesh};var r=[{metric:"Meshes",value:t.meshCount,url:"/meshes/".concat(this.selectedMesh)},{metric:"Dataplanes",value:t.dataplaneCount,url:"/".concat(this.selectedMesh,"/dataplanes")},{metric:"Circuit Breakers",value:t.circuitBreakerCount,url:"/".concat(this.selectedMesh,"/circuit-breakers")},{metric:"Fault Injections",value:t.faultInjectionCount,url:"/".concat(this.selectedMesh,"/fault-injections")},{metric:"Health Checks",value:t.healthCheckCount,url:"/".concat(this.selectedMesh,"/health-checks")},{metric:"Proxy Templates",value:t.proxyTemplateCount,url:"/".concat(this.selectedMesh,"/proxy-templates")},{metric:"Traffic Logs",value:t.trafficLogCount,url:"/".concat(this.selectedMesh,"/traffic-logs")},{metric:"Traffic Permissions",value:t.trafficPermissionCount,url:"/".concat(this.selectedMesh,"/traffic-permissions")},{metric:"Traffic Routes",value:t.trafficRouteCount,url:"/".concat(this.selectedMesh,"/traffic-routes")},{metric:"Traffic Traces",value:t.trafficTraceCount,url:"/".concat(this.selectedMesh,"/traffic-traces")}];if(this.multicluster){var n={metric:"Remote CPs",value:this.$store.state.totalClusters,url:"/remote-cp"};r.push(n)}return"all"!==e&&r.shift(),r},dataplaneWizardRoute:function(){return"universal"===this.environment?{name:"universal-dataplane"}:{name:"kubernetes-dataplane"}}}),watch:{selectedMesh:function(){this.init()}},beforeMount:function(){this.init()},methods:{init:function(){this.getCounts(),this.multicluster&&this.$store.dispatch("fetchTotalClusterCount")},getCounts:function(){var t,e=this,a=this.selectedMesh;"all"===a?(t=["fetchMeshTotalCount","fetchDataplaneTotalCount","fetchHealthCheckTotalCount","fetchProxyTemplateTotalCount","fetchTrafficLogTotalCount","fetchTrafficPermissionTotalCount","fetchTrafficRouteTotalCount","fetchTrafficTraceTotalCount","fetchFaultInjectionTotalCount","fetchCircuitBreakerTotalCount"],t.forEach((function(t){e.$store.dispatch(t)}))):(t=["fetchDataplaneTotalCountFromMesh","fetchHealthCheckTotalCountFromMesh","fetchProxyTemplateTotalCountFromMesh","fetchTrafficLogTotalCountFromMesh","fetchTrafficPermissionTotalCountFromMesh","fetchTrafficRouteTotalCountFromMesh","fetchTrafficTraceTotalCountFromMesh","fetchFaultInjectionTotalCountFromMesh","fetchCircuitBreakerTotalCountFromMesh"],t.forEach((function(t){e.$store.dispatch(t,a)})))}}},g=M,O=(a("c933"),Object(C["a"])(g,r,n,!1,null,"98f204c8",null));e["default"]=O.exports},"43c3":function(t,e,a){"use strict";var r=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("header",{staticClass:"page-header",class:{"flex justify-between items-center my-6":!t.noflex}},[t._t("default")],2)},n=[],o={props:{noflex:{type:Boolean,default:!1}}},c=o,i=(a("e234"),a("2877")),s=Object(i["a"])(c,r,n,!1,null,null,null);e["a"]=s.exports},"467d":function(t,e,a){},"4d0d":function(t,e,a){},af21:function(t,e,a){},b6c6:function(t,e,a){"use strict";var r=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",[t.hideBreadcrumbs?t._e():a("Krumbs",{attrs:{items:t.routes}})],1)},n=[],o=(a("8e6e"),a("456d"),a("ac6a"),a("8615"),a("bd86")),c=(a("28a5"),a("7f7f"),a("d7c2"));function i(t,e){var a=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),a.push.apply(a,r)}return a}function s(t){for(var e=1;e<arguments.length;e++){var a=null!=arguments[e]?arguments[e]:{};e%2?i(Object(a),!0).forEach((function(e){Object(o["a"])(t,e,a[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(a)):i(Object(a)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(a,e))}))}return t}var u={computed:{pageMesh:function(){return this.$route.params.mesh},routes:function(){var t=this,e=[];this.$route.matched.map((function(a){t.calculateRouteText(a),t.calculateRouteTitle(a);var r=void 0!==a.redirect&&void 0!==a.redirect.name?a.redirect.name:a.name;t.isCurrentRoute(a)&&t.pageMesh&&"global-overview"!==t.$route.name&&e.push({key:t.pageMesh,to:{path:"/meshes/".concat(t.pageMesh)},title:"Mesh Overview for ".concat(t.pageMesh),text:t.pageMesh}),t.isCurrentRoute(a)&&a.meta.parent&&"undefined"!==a.meta.parent?e.push({key:a.meta.parent,to:{name:a.meta.parent},title:a.meta.title,text:a.meta.breadcrumb||a.meta.title}):t.isCurrentRoute(a)&&!a.meta.excludeAsBreadcrumb?e.push({key:r,to:{name:r},title:a.meta.title,text:a.meta.breadcrumb||a.meta.title}):a.meta.parent&&"undefined"!==a.meta.parent&&e.push({key:a.meta.parent,to:{name:a.meta.parent},title:a.meta.title,text:a.meta.breadcrumb||a.meta.title})}));var a=this.calculateRouteTextAdvanced(this.$route);return a&&e.push({title:a,text:a}),e},hideBreadcrumbs:function(){return this.$route.query.hide_breadcrumb}},methods:{getBreadcrumbItem:function(t,e,a,r){return{key:t,to:e,title:a,text:r}},isCurrentRoute:function(t){return t.name&&t.name===this.$router.currentRoute.name||t.redirect===this.$router.currentRoute.name},calculateRouteFromQuery:function(t){var e=t.entity_id,a=t.entity_type;if(e&&a){var r=this.$router.resolve({name:"show-".concat(a.split("_")[0]),params:{id:e.split(",")[0]}}).normalizedTo,n=s({},r,{meta:s({},r.meta)}),o=n.params.id.split("-")[0];return e.split(",").length>1&&e.split(",")[1]&&(o=e.split(",")[1]),n.meta.breadcrumb=o,[s({},this.getBreadcrumbItem(n.name,n,this.calculateRouteTitle(n),this.calculateRouteText(n)))]}},calculateRouteText:function(t){if(t.path&&t.path.indexOf(":mesh")>-1){var e=this.$router.currentRoute.params;return(e&&e.mesh&&Object(c["d"])(e.mesh)?e.mesh.split("-")[0].trim():e.mesh)||t.meta.breadcrumb||t.meta.title}return t.meta&&(t.meta.breadcrumb||t.meta.title)||t.name||t.meta.breadcrumb||t.meta.title},calculateRouteTitle:function(t){return t.params&&t.params.mesh||t.path.indexOf(":mesh")>-1&&this.$router.currentRoute.params&&this.$router.currentRoute.params.mesh},calculateRouteTextAdvanced:function(t){var e=t.params,a="mesh-overview"===t.name,r=Object.assign({},e,{mesh:null});return a?e.mesh:Object.values(r).filter((function(t){return t}))[0]}}},l=u,f=(a("e7ab"),a("2877")),m=Object(f["a"])(l,r,n,!1,null,null,null);e["a"]=m.exports},bc4b:function(t,e,a){"use strict";var r=a("4d0d"),n=a.n(r);n.a},be10:function(t,e,a){"use strict";var r=function(){var t=this,e=t.$createElement,a=t._self._c||e;return t.metrics?a("div",{staticClass:"info-grid",class:{"is-compact":t.isCompact}},t._l(t.metrics,(function(e,r){return null!==e.value?a("div",{key:r,staticClass:"metric",class:e.status,attrs:{"data-testid":e.metric}},[e.url?a("router-link",{staticClass:"metric-card",attrs:{to:e.url}},[a("span",{staticClass:"metric-title"},[t._v("\n        "+t._s(e.metric)+"\n      ")]),a("span",{staticClass:"metric-value",class:{"has-error":r===t.hasError[r]}},[t._v("\n        "+t._s(t._f("formatError")(t._f("formatValue")(e.value)))+"\n      ")])]):a("div",{staticClass:"metric-card"},[a("span",{staticClass:"metric-title"},[t._v("\n        "+t._s(e.metric)+"\n      ")]),a("span",{staticClass:"metric-value",class:{"has-error":r===t.hasError[r]}},[t._v("\n        "+t._s(t._f("formatError")(t._f("formatValue")(e.value)))+"\n      ")])])],1):t._e()})),0):t._e()},n=[],o=(a("456d"),a("ac6a"),a("6b54"),{name:"MetricsGrid",filters:{formatValue:function(t){return t?t.toLocaleString("en").toString():0},formatError:function(t){return"--"===t?"error calculating":t}},props:{metrics:{type:Array,required:!0,default:function(){}},isCompact:{type:Boolean,default:!1}},computed:{hasError:function(){var t=this,e={};return Object.keys(this.metrics).forEach((function(a){"--"===t.metrics[a].value&&(e[a]=a)})),e}}}),c=o,i=(a("bc4b"),a("2877")),s=Object(i["a"])(c,r,n,!1,null,"01f8a47e",null);e["a"]=s.exports},c933:function(t,e,a){"use strict";var r=a("0f02"),n=a.n(r);n.a},e234:function(t,e,a){"use strict";var r=a("2055"),n=a.n(r);n.a},e7ab:function(t,e,a){"use strict";var r=a("af21"),n=a.n(r);n.a}}]);