49dca85560
1. Update dist for rc1 release 2. Update version in the package.json Change-Id: Iaf7c0f5261f0e89b7a38acc1d2be5482bc2384a2
1 line
137 KiB
JavaScript
1 line
137 KiB
JavaScript
(window.webpackJsonp=window.webpackJsonp||[]).push([[13],{1209:function(e,a,r){"use strict";var n=r(33),l=r(44),i=r(32),s=r(25),u=r(27),o=r(45),d=r(46),c=r(19),f=r(21);c(a,"__esModule",{value:!0}),a.fetchPrometheus=I,a.getRequestUrl=P,a.addParams=T,a.getInterval=function(e){var t=(e||k(0))[0],a=(e||k(0))[1].diff(t,"minutes");return M[(a>44640?3:a>1440&&a<=44640&&2)||a>60&&a<=1440&&1||a>0&&a<=60&&0||0]},a.getPromises=a.range2IntervalsDict=a.getRange=a.defaultOneHourAgo=a.baseReturnFunc=a.getXScale=a.ChartType=void 0;var m=f(r(65)),p=f(r(33)),v=f(r(27)),h=f(r(81)),g=f(r(57)),y=f(r(36)),b=f(r(91)),_=f(r(111)),x=r(569),C=f(r(119)),S=f(r(48));function D(e,t){var a=n(e);if(l){var r=l(e);t&&(r=i(r).call(r,(function(t){return s(e,t).enumerable}))),a.push.apply(a,r)}return a}function w(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)u(a=D(Object(r),!0)).call(a,(function(t){(0,y.default)(e,t,r[t])}));else if(o)d(e,o(r));else{var n;u(n=D(Object(r))).call(n,(function(t){c(e,t,s(r,t))}))}}return e}a.ChartType={ONELINE:"oneline",MULTILINE:"multiline",ONELINEDEVICES:"oneline_devices",MULTILINEDEVICES:"multiline_devices"};a.getXScale=e=>{var t=(0,C.default)(e[1]).diff((0,C.default)(e[0]),"minutes",!0);return w({type:"time"},N[(t>20160?4:t>10080&&t<=20160&&3)||t>1440&&t<=10080&&2||t>60&&t<=1440&&1||t>0&&t<=60&&0||0])};var E=e=>e;function I(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"range",a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:[],r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:10;return"current"===t?S.default.skyline.query.list({query:e}):"range"===t?S.default.skyline.queryRange.list({query:e,start:(0,x.getTimestamp)(a[0]),end:(0,x.getTimestamp)(a[1]),step:r}):m.default.resolve()}function P(e,t,a,r){var n=w(w({},t),r);return a(0===(0,p.default)(n).length?e:T(e,n))}function T(e,t){var a,r,n="";return(0,v.default)(a=(0,p.default)(t)).call(a,(e=>{var a,r;(0,b.default)(t[e])?n+=(0,h.default)(a="".concat(e,'=~"')).call(a,t[e].join("|"),'",'):n+=(0,h.default)(r="".concat(e,'="')).call(r,t[e],'",')})),(0,h.default)(r="".concat(e,"{")).call(r,n.substring(0,n.length-1),"}")}a.baseReturnFunc=E;a.defaultOneHourAgo=()=>[(0,C.default)().subtract(1,"hours"),(0,C.default)()];var k=e=>({3:[(0,C.default)().subtract(2,"weeks"),(0,C.default)()],2:[(0,C.default)().subtract(1,"weeks"),(0,C.default)()],1:[(0,C.default)().subtract(1,"days"),(0,C.default)()],0:[(0,C.default)().subtract(1,"hours"),(0,C.default)()]}[e]||[(0,C.default)().subtract(1,"hours"),(0,C.default)()]);a.getRange=k;var N=[{formatter:e=>(0,x.getStrFromTimestamp)(e,"HH:mm:ss"),ticketCount:6},{formatter:e=>(0,x.getStrFromTimestamp)(e,"HH:mm:ss"),ticketCount:6},{formatter:e=>(0,x.getStrFromTimestamp)(e,"MM-DD HH:mm"),ticketCount:3},{formatter:e=>(0,x.getStrFromTimestamp)(e,"MM-DD HH:mm"),ticketCount:6},{formatter:e=>(0,x.getStrFromTimestamp)(e,"MM-DD HH:mm"),ticketCount:6}],M=[[{text:t("10s"),value:10},{text:t("1min"),value:60},{text:t("5min"),value:300}],[{text:t("1min"),value:60},{text:t("5min"),value:300},{text:t("1H"),value:3600}],[{text:t("1H"),value:3600},{text:t("1D"),value:86400}],[{text:t("1D"),value:86400}]];a.range2IntervalsDict=M;a.getPromises=e=>{var t,a=(0,_.default)(METRICDICT,e);return(0,g.default)(t=a.url).call(t,((e,t)=>I(P(e,{},(a.finalFormatFunc||[])[t]||E,(a.baseParams||[])[t]||{}),"current")))}},1221:function(e,t,a){"use strict";var r=a(33),n=a(44),l=a(32),i=a(25),s=a(27),u=a(45),o=a(46),d=a(19),c=a(21);d(t,"__esModule",{value:!0}),t.default=t.InstancesStore=void 0;var f,m,p=c(a(57)),v=c(a(25)),h=c(a(51)),g=c(a(71)),y=c(a(36)),b=c(a(54)),_=(c(a(72)),c(a(111))),x=c(a(53)),C=c(a(48)),S=a(34),D=c(a(1218));function w(e,t){var a=r(e);if(n){var s=n(e);t&&(s=l(s).call(s,(function(t){return i(e,t).enumerable}))),a.push.apply(a,s)}return a}function E(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)s(a=w(Object(r),!0)).call(a,(function(t){(0,y.default)(e,t,r[t])}));else if(u)o(e,u(r));else{var n;s(n=w(Object(r))).call(n,(function(t){d(e,t,i(r,t))}))}}return e}var I=(f=class extends x.default{constructor(){super(...arguments),(0,g.default)(this,"dataList",m,this)}get client(){return C.default.trove.instances}get clientDatastore(){return C.default.trove.datastores}get clientConfigurationGroup(){return C.default.trove.configurations}get adminClient(){return C.default.trove.instancesAdmin}get mapper(){return e=>E(E({},e),{},{type:(0,_.default)(e,"datastore.type"),version:(0,_.default)(e,"datastore.version"),size:(0,_.default)(e,"volume.size")})}detailDidFetch(e){return(0,h.default)((function*(){var t=yield D.default.fetchDetail({id:(0,_.default)(e,"flavor.id")});return E(E({},e),{},{flavor:E(E({},e.flavor),t)})}))()}listDidFetch(e){return 0===e.length?e:(0,p.default)(e).call(e,(e=>E(E({},e),{},{project_id:e.tenant_id})))}create(e){var t=this;return(0,h.default)((function*(){return t.submitting(t.client.create(e))}))()}delete(e,t){var a=this;return(0,h.default)((function*(){var{params:r}=e;return a.client.delete(r,t)}))()}update(e,t){return this.submitting(this.client.action(e,t))}operation(e){var t=this;return(0,h.default)((function*(){var{body:a,id:r,key:n=""}=e,l=a;return l||((l={})[n]={}),t.update(r,l)}))()}restart(e){var t=this;return(0,h.default)((function*(){var{id:a}=e;return t.operation({key:"restart",id:a})}))()}reboot(e){var t=this;return(0,h.default)((function*(){var{id:a}=e;return t.operation({key:"reboot",id:a})}))()}stop(e){var t=this;return(0,h.default)((function*(){var{id:a}=e;return t.submitting(t.adminClient.action(a,{stop:{}}))}))()}resizeVolume(e){var t=this;return(0,h.default)((function*(){var{id:a,size:r}=e,n={resize:{volume:{size:r}}};return t.operation({body:n,id:a})}))()}listDatastores(){var e=this;return(0,h.default)((function*(){var t=(yield e.clientDatastore.list()).datastores;e.dataList=(0,p.default)(t).call(t,e.mapper)}))()}fetchListWithoutDetail(){var e=this;return(0,h.default)((function*(){var t=(yield e.client.list())[e.listResponseKey];e.list.data=(0,p.default)(t).call(t,e.mapper)}))()}listConfigurationGroup(){var e=this;return(0,h.default)((function*(){var t=(yield e.clientConfigurationGroup.list()).configurations;e.list.data=(0,p.default)(t).call(t,e.mapper)}))()}},m=(0,b.default)(f.prototype,"dataList",[S.observable],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return[]}}),(0,b.default)(f.prototype,"create",[S.action],(0,v.default)(f.prototype,"create"),f.prototype),(0,b.default)(f.prototype,"delete",[S.action],(0,v.default)(f.prototype,"delete"),f.prototype),(0,b.default)(f.prototype,"update",[S.action],(0,v.default)(f.prototype,"update"),f.prototype),(0,b.default)(f.prototype,"operation",[S.action],(0,v.default)(f.prototype,"operation"),f.prototype),(0,b.default)(f.prototype,"restart",[S.action],(0,v.default)(f.prototype,"restart"),f.prototype),(0,b.default)(f.prototype,"reboot",[S.action],(0,v.default)(f.prototype,"reboot"),f.prototype),(0,b.default)(f.prototype,"stop",[S.action],(0,v.default)(f.prototype,"stop"),f.prototype),(0,b.default)(f.prototype,"resizeVolume",[S.action],(0,v.default)(f.prototype,"resizeVolume"),f.prototype),(0,b.default)(f.prototype,"listDatastores",[S.action],(0,v.default)(f.prototype,"listDatastores"),f.prototype),(0,b.default)(f.prototype,"fetchListWithoutDetail",[S.action],(0,v.default)(f.prototype,"fetchListWithoutDetail"),f.prototype),(0,b.default)(f.prototype,"listConfigurationGroup",[S.action],(0,v.default)(f.prototype,"listConfigurationGroup"),f.prototype),f);t.InstancesStore=I;var P=new I;t.default=P},1263:function(e,t,a){"use strict";var r=a(160),n=a(19),l=a(25),i=a(21);n(t,"__esModule",{value:!0}),t.default=void 0;var s=i(a(580));a(337);var u=i(a(338));a(333);var o=i(a(332)),d=i(a(1273)),c=i(a(51)),f=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=x(t);if(a&&a.has(e))return a.get(e);var r={},i=n&&l;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var u=i?l(e,s):null;u&&(u.get||u.set)?n(r,s,u):r[s]=e[s]}r.default=e,a&&a.set(e,r);return r}(a(0)),m=(a(173),a(555),a(1209)),p=i(a(1603)),v=i(a(4039)),h=i(a(4040)),g=i(a(4041)),y=i(a(1416)),b=a(1351),_=i(a(1417));function x(e){if("function"!=typeof r)return null;var t=new r,a=new r;return(x=function(e){return e?a:t})(e)}var C=e=>{var t,a,{renderTimeRangeSelect:r,chartConfig:n,renderNodeSelect:l,fetchNodesFunc:i,defaultNode:b,children:x,type:C}=e,[S,D,w,E]=(0,g.default)(b),[I,P,T,k]=(0,h.default)((0,m.defaultOneHourAgo)()),[N,M]=(0,v.default)(I),[L,F]=(0,f.useState)(!0),[A,O]=(0,f.useState)(!0),z=function(){var e=(0,c.default)((function*(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(F(!0),l){O(!0);var t=yield i();E(t),S&&!e||w(t[0]),e&&4!==T&&k((0,m.getRange)(T)),O(!1),F(!1)}else(0,s.default)((()=>{F(!1)}),300)}));return function(){return e.apply(this,arguments)}}(),j={interval:N,range:I,node:S};return(0,f.useEffect)((()=>{z()}),[N,I]),(0,f.useEffect)((()=>{z(!0)}),[C]),(0,f.useEffect)((()=>{F(!0),(0,s.default)((()=>{F(!1)}),300)}),[S]),f.default.createElement("div",{className:y.default["base-content-container"]},f.default.createElement(_.default.Provider,{value:j},(r||l)&&f.default.createElement(o.default,{type:"default",icon:f.default.createElement(d.default,null),onClick:()=>z(!0),className:y.default.refresh}),r&&f.default.createElement("div",{className:y.default.header},f.default.createElement(P,null),f.default.createElement(M,null)),l&&(A?f.default.createElement(u.default,null):f.default.createElement(D,null)),l&&A||L&&0!==(null==n||null===(t=n.chartCardList)||void 0===t?void 0:t.length)&&0!==(null==n||null===(a=n.topCardList)||void 0===a?void 0:a.length)?null:f.default.createElement(p.default,n),l&&A||L?f.default.createElement(u.default,null):x))};C.defaultProps={renderNodeSelect:!0,renderTimeRangeSelect:!0,fetchNodesFunc:b.defaultGetNodes,defaultNode:void 0};var S=C;t.default=S},1309:function(e,t,a){"use strict";var r=a(33),n=a(44),l=a(32),i=a(25),s=a(27),u=a(45),o=a(46),d=a(19),c=a(21);d(t,"__esModule",{value:!0}),t.baseFixToChart=y,t.handleResponses=function(e,t,a){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:[],n=[];return(0,m.default)(e).call(e,((e,l)=>{n.push(...b(e,t,a,r[l]))})),n},t.handleResponse=b;var f=c(a(419)),m=c(a(27)),p=c(a(1204)),v=c(a(36)),h=c(a(111));function g(e,t){var a=r(e);if(n){var s=n(e);t&&(s=l(s).call(s,(function(t){return i(e,t).enumerable}))),a.push.apply(a,s)}return a}function y(e){return{x:e[0],y:(0,f.default)((0,f.default)(e[1]).toFixed(2))}}function b(e,t,a,r){var n,{data:l}=e,c=[];return(0,m.default)(n=l.result).call(n,(e=>{var n=(0,p.default)(e)||[e.value]||[];(0,m.default)(n).call(n,(n=>{var l=function(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)s(a=g(Object(r),!0)).call(a,(function(t){(0,v.default)(e,t,r[t])}));else if(u)o(e,u(r));else{var n;s(n=g(Object(r))).call(n,(function(t){d(e,t,i(r,t))}))}}return e}({},y(n));t&&(l.type=(0,h.default)(e.metric,t)),a&&(l.device=(0,h.default)(e.metric,a)),r&&(l.type=r),c.push(l)}))})),c}},1310:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=t.InstancesDatabasesStore=void 0;var l,i=n(a(25)),s=n(a(51)),u=n(a(62)),o=n(a(54)),d=n(a(53)),c=n(a(48)),f=a(34),m=(l=class extends d.default{get client(){return c.default.trove.instances.databases}get isSubResource(){return!0}get responseKey(){return"database"}get paramsFunc(){return e=>{var{id:t}=e;return(0,u.default)(e,["id"])}}create(e,t){var a=this;return(0,s.default)((function*(){return a.submitting(a.client.create(e,t))}))()}deleteDatabase(e){var t=this;return(0,s.default)((function*(){var{id:a,name:r}=e;return t.submitting(t.client.delete(a,r))}))()}},(0,o.default)(l.prototype,"create",[f.action],(0,i.default)(l.prototype,"create"),l.prototype),(0,o.default)(l.prototype,"deleteDatabase",[f.action],(0,i.default)(l.prototype,"deleteDatabase"),l.prototype),l);t.InstancesDatabasesStore=m;var p=new m;t.default=p},1350:function(e,t,a){var r=a(4031);"string"==typeof r&&(r=[[e.i,r,""]]);var n={hmr:!0,transform:undefined,insertInto:void 0};a(75)(r,n);r.locals&&(e.exports=r.locals)},1351:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.getMysqlNodes=t.getRabbitMQNodes=t.getMemcacheNodes=t.defaultGetNodes=void 0;var l=n(a(57)),i=n(a(27)),s=n(a(102)),u=n(a(51)),o=n(a(111)),d=a(1209),c=n(a(1396)),f=function(){var e=(0,u.default)((function*(){var e=yield(0,d.fetchPrometheus)((0,o.default)(METRICDICT,"physicalNode.systemLoad.url[0]"),"current"),{data:{result:t=[]}}=e;return 0===t.length?[{metric:{instance:""}}]:(0,l.default)(t).call(t,(e=>({metric:{instance:e.metric.instance}})))}));return function(){return e.apply(this,arguments)}}();t.defaultGetNodes=f;var m=function(){var e=(0,u.default)((function*(){var e=yield(0,d.fetchPrometheus)((0,o.default)(METRICDICT,"memcacheService.currentConnections.url[0]"),"current"),{data:{result:t=[]}}=e;return 0===t.length?[{metric:{instance:""}}]:(0,l.default)(t).call(t,(e=>({metric:{instance:e.metric.instance}})))}));return function(){return e.apply(this,arguments)}}();t.getMemcacheNodes=m;var p=function(){var e=(0,u.default)((function*(){var e=yield(0,d.fetchPrometheus)((0,o.default)(METRICDICT,"rabbitMQService.serviceStatus.url[0]"),"current"),{data:{result:t=[]}}=e;if(0===t.length)return[{metric:{instance:""}}];var a=[];return(0,i.default)(t).call(t,(e=>{var t={metric:{instance:e.metric.instance}};(0,s.default)(a).call(a,(e=>(0,c.default)(e,t)))||a.push(t)})),a}));return function(){return e.apply(this,arguments)}}();t.getRabbitMQNodes=p;var v=function(){var e=(0,u.default)((function*(){var e=yield(0,d.fetchPrometheus)((0,o.default)(METRICDICT,"mysqlService.runningTime.url[0]"),"current"),{data:{result:t=[]}}=e;return 0===t.length?[{metric:{instance:""}}]:(0,l.default)(t).call(t,(e=>({metric:{instance:e.metric.instance}})))}));return function(){return e.apply(this,arguments)}}();t.getMysqlNodes=v},1352:function(e,a,r){"use strict";var n=r(33),l=r(44),i=r(32),s=r(25),u=r(27),o=r(45),d=r(46),c=r(19),f=r(21);c(a,"__esModule",{value:!0}),a.cephStatusColorMap=a.cephStatusMap=a.fillEmptyMetrics=a.timestampify=a.timeAliasReg=a.isSameDay=a.stopAutoRefresh=a.startAutoRefresh=a.getColorByName=a.getZeroValues=a.getTimesData=a.getLastMonitoringData=a.getXAxisTickFormatter=a.getAreaChartOps=a.getChartData=a.getFormatTime=a.getValueByUnit=a.getSuitableValue=a.getSuitableUnit=void 0;var m=f(r(226)),p=f(r(81)),v=f(r(419)),h=f(r(27)),g=f(r(229)),y=f(r(174)),b=f(r(57)),_=f(r(1265)),x=f(r(198)),C=f(r(588)),S=f(r(620)),D=f(r(4042)),w=f(r(1299)),E=f(r(1204)),I=f(r(62)),P=f(r(36)),T=f(r(4045)),k=f(r(4047)),N=f(r(4049)),M=f(r(1532)),L=f(r(4050)),F=f(r(111)),A=f(r(131)),O=f(r(343)),z=f(r(592)),j=f(r(650)),K=f(r(91)),R=f(r(199)),U=r(334),B=r(569);function q(e,t){var a=n(e);if(l){var r=l(e);t&&(r=i(r).call(r,(function(t){return s(e,t).enumerable}))),a.push.apply(a,r)}return a}function H(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)u(a=q(Object(r),!0)).call(a,(function(t){(0,P.default)(e,t,r[t])}));else if(o)d(e,o(r));else{var n;u(n=q(Object(r))).call(n,(function(t){c(e,t,s(r,t))}))}}return e}var V={second:{conditions:[.01,0],units:["s","ms"]},cpu:{conditions:[.1,0],units:["core","m"]},memory:{conditions:[1024**4,1024**3,1048576,1024,0],units:["TiB","GiB","MiB","KiB","Bytes"]},disk:{conditions:[1e3**4,1e3**3,1e6,1e3,0],units:["TB","GB","MB","KB","Bytes"]},throughput:{conditions:[1e3**4,1e3**3,1e6,1e3,0],units:["TB/s","GB/s","MB/s","KB/s","B/s"]},traffic:{conditions:[1e3**4,1e3**3,1e6,1e3,0],units:["TB/s","GB/s","MB/s","KB/s","B/s"]},bandwidth:{conditions:[131072,128,0],units:["Mbps","Kbps","bps"]}},Q=(e,t)=>{var a,r=V[t];if((0,R.default)(r))return"";var n=(0,K.default)(e)?e:[[0,Number(e)]],l=(0,M.default)(r.units);return(0,m.default)(a=r.conditions).call(a,((e,t)=>{var a=(0,m.default)(n).call(n,(t=>(((0,K.default)(t)?(0,F.default)(t,"[1]"):Number(t))||0)>=e));return a&&(l=r.units[t]),a})),l};a.getSuitableUnit=Q;a.getSuitableValue=function(e){var a,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if(!(0,O.default)(e)&&!(0,A.default)(e)||(0,j.default)(Number(e)))return n;var l=Q(e,r),i=l?" ".concat(t(l)):"",s=G(e,l||r);return(0,p.default)(a="".concat(s)).call(a,i)};var G=(e,t)=>{var a=(0,v.default)(e);switch(t){default:break;case"":case"default":return a;case"iops":return Math.round(a);case"%":a*=100;break;case"m":if((a*=1e3)<1)return 0;break;case"KiB":a/=1024;break;case"MiB":a/=1048576;break;case"GiB":a/=1024**3;break;case"TiB":a/=1024**4;break;case"Bytes":case"B":case"B/s":break;case"KB":case"KB/s":a/=1e3;break;case"MB":case"MB/s":a/=1e6;break;case"GB":case"GB/s":a/=1e3**3;break;case"TB":case"TB/s":a/=1e3**4;break;case"bps":a*=8;break;case"Kbps":a=8*a/1024;break;case"Mbps":a=8*a/1024/1024;break;case"ms":a*=1e3}return 0===Number(a)?0:Number(a.toFixed(2))};a.getValueByUnit=G;var W=e=>(0,B.getStrFromTimestamp)(e).replace(/:00$/g,"");a.getFormatTime=W;var X=e=>{var t,{type:a,unit:r,xKey:n="time",legend:l=[],valuesData:i=[],xFormatter:s}=e,u={};(0,h.default)(i).call(i,((e,t)=>{(0,h.default)(e).call(e,(e=>{var n=(0,g.default)((0,F.default)(e,[0],0),10),i=(0,F.default)(e,[1]),s=(0,F.default)(l,[t]);n&&!u[n]&&(u[n]=(0,y.default)(l).call(l,((e,t)=>(e[t]||(e[t]=null),e)),{})),s&&u[n]&&(u[n][s]="-1"===i?null:G(i,(0,z.default)(r)?a:r))}))}));var o=e=>"time"===n?W(e):e;return(0,b.default)(t=(0,_.default)(u)).call(t,(e=>{var[t,a]=e;return H({[n]:(s||o)(t)},a)}))};a.getChartData=X;a.getAreaChartOps=e=>{var{type:t,title:a,unitType:r,xKey:n="time",legend:l=[],data:i=[],xFormatter:s}=e,u=(0,I.default)(e,["type","title","unitType","xKey","legend","data","xFormatter"]),o=(0,K.default)(i)?i:[],d=(0,b.default)(o).call(o,(e=>(0,F.default)(e,"values")||[])),c=r?Q((0,N.default)(d),r):u.unit,f=X({type:t,unit:c,xKey:n,legend:l,valuesData:d,xFormatter:s}),m="time"===n?Z(f):e=>e;return H(H({},u),{},{title:a,unit:c,xAxisTickFormatter:m,data:f})};var Z=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],a=(0,b.default)(e).call(e,(e=>{var{time:t}=e;return+new Date(t)})),r=(0,k.default)(a),n=(0,T.default)(a);return n-r>864e4?e=>(0,B.getLocalTimeStr)(e,t("Do HH:mm")):e=>(0,B.getLocalTimeStr)(e,"HH:mm:ss")};a.getXAxisTickFormatter=Z;a.getLastMonitoringData=e=>{var t,a={};return(0,h.default)(t=(0,_.default)(e)).call(t,(e=>{var[t,r]=e,n=(0,F.default)(r,"data.result[0].values",[])||[],l=(0,R.default)(n)?(0,F.default)(r,"data.result[0].value",[])||[]:(0,M.default)(n);(0,L.default)(a,"[".concat(t,"].value"),l)})),a};a.getTimesData=e=>{var t=[];return(0,h.default)(e).call(e,(e=>{var a=(0,F.default)(e,"values")||[];(0,h.default)(a).call(a,(e=>{var a=(0,F.default)(e,"[0]",0);(0,x.default)(t).call(t,a)||t.push(a)}))})),(0,C.default)(t).call(t)};a.getZeroValues=()=>{for(var e=[],t=(0,g.default)((0,S.default)()/1e3,10)-6e3,a=0;a<10;a++)e[a]=[t,0],t+=600;return e};a.getColorByName=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"#fff";return U.COLORS_MAP[e]||e};a.startAutoRefresh=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=H({method:"fetchData",interval:5e3,leading:!0},t);if(e&&e[a.method]){var r=e[a.method];a.leading&&r({autoRefresh:!0}),e.timer=(0,D.default)((()=>{r({autoRefresh:!0})}),a.interval)}};a.stopAutoRefresh=e=>{e&&e.timer&&(clearInterval(e.timer),e.timer=null)};a.isSameDay=(e,t)=>Math.floor(e/864e5)===Math.floor(t/864e5);var J=/(\d+)(\w+)/;a.timeAliasReg=J;a.timestampify=e=>{var[,t=0,a]=e.match(J)||[];return Number(t)*(U.MILLISECOND_IN_TIME_UNIT[a]||0)};a.fillEmptyMetrics=(e,t)=>{var a;if(!e.times||!e.start||!e.end)return t;var r=e=>String(e).replace(/\..*$/,""),n=Math.floor((e.end-e.start)/e.times),l=e.times+1;return(0,h.default)(a=(0,w.default)(t)).call(a,(t=>{var a=(0,F.default)(t,"data.result");(0,R.default)(a)||(0,h.default)(a).call(a,(t=>{var a=(0,E.default)(t)||[],i=(0,y.default)(a).call(a,((e,t)=>H(H({},e),{},{[r(t[0])]:t[1]})),{});if(a.length<l){for(var s=[],u=0;u<l;u++){var o=r(e.start+u*n);s.push([o,i[o]||"0"])}t.values=s}}))})),t};var Y={0:t("Healthy"),1:t("Warning"),2:t("Error")};a.cephStatusMap=Y;a.cephStatusColorMap={0:"#379738",1:"#FAAD14",2:"#D93126"}},1353:function(e,t,a){var r=a(4068);"string"==typeof r&&(r=[[e.i,r,""]]);var n={hmr:!0,transform:undefined,insertInto:void 0};a(75)(r,n);r.locals&&(e.exports=r.locals)},1354:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=t.BackupsStore=void 0;var l,i=n(a(25)),s=n(a(51)),u=n(a(54)),o=n(a(53)),d=n(a(48)),c=a(34),f=(l=class extends o.default{get client(){return d.default.trove.backups}create(e){var t=this;return(0,s.default)((function*(){return t.client.create(e)}))()}delete(e,t){var a=this;return(0,s.default)((function*(){var{params:r}=e;return a.client.delete(r,t)}))()}},(0,u.default)(l.prototype,"create",[c.action],(0,i.default)(l.prototype,"create"),l.prototype),(0,u.default)(l.prototype,"delete",[c.action],(0,i.default)(l.prototype,"delete"),l.prototype),l);t.BackupsStore=f;var m=new f;t.default=m},1355:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=t.ConfigurationsStore=void 0;var l,i=n(a(25)),s=n(a(51)),u=n(a(54)),o=n(a(53)),d=n(a(48)),c=a(34),f=(l=class extends o.default{get client(){return d.default.trove.configurations}create(e){var t=this;return(0,s.default)((function*(){return t.client.create(e)}))()}delete(e,t){var a=this;return(0,s.default)((function*(){var{params:r}=e;return a.client.delete(r,t)}))()}},(0,u.default)(l.prototype,"create",[c.action],(0,i.default)(l.prototype,"create"),l.prototype),(0,u.default)(l.prototype,"delete",[c.action],(0,i.default)(l.prototype,"delete"),l.prototype),l);t.ConfigurationsStore=f;var m=new f;t.default=m},1356:function(e,t,a){"use strict";var r=a(33),n=a(44),l=a(32),i=a(25),s=a(27),u=a(45),o=a(46),d=a(19),c=a(21);d(t,"__esModule",{value:!0}),t.default=t.InstancesUsersStore=void 0;var f,m=c(a(57)),p=c(a(32)),v=c(a(102)),h=c(a(25)),g=c(a(36)),y=c(a(51)),b=c(a(62)),_=c(a(54)),x=c(a(53)),C=c(a(48)),S=a(34);function D(e,t){var a=r(e);if(n){var s=n(e);t&&(s=l(s).call(s,(function(t){return i(e,t).enumerable}))),a.push.apply(a,s)}return a}function w(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)s(a=D(Object(r),!0)).call(a,(function(t){(0,g.default)(e,t,r[t])}));else if(u)o(e,u(r));else{var n;s(n=D(Object(r))).call(n,(function(t){d(e,t,i(r,t))}))}}return e}var E=(f=class extends x.default{get client(){return C.default.trove.instances.users}get databaseClient(){return C.default.trove.instances.databases}get instanceClient(){return C.default.trove.instances}get isSubResource(){return!0}get responseKey(){return"user"}get paramsFunc(){return e=>{var{id:t}=e;return(0,b.default)(e,["id"])}}listDidFetch(e,t,a){var r=this;return(0,y.default)((function*(){if(0===e.length)return e;var{id:t}=a,{databases:n=[]}=yield r.databaseClient.list(t);return(0,m.default)(e).call(e,(e=>{var t,a;return w(w({},e),{},{databases:(0,m.default)(t=(0,p.default)(a=e.databases||[]).call(a,(e=>(0,v.default)(n).call(n,(t=>t.name===e.name))))).call(t,(e=>e.name))})}))}))()}create(e,t){var a=this;return(0,y.default)((function*(){return a.submitting(a.client.create(e,t))}))()}deleteUser(e){var t=this;return(0,y.default)((function*(){var{id:a,name:r}=e;return t.submitting(t.client.delete(a,r))}))()}grantDatabaseAccess(e){var t=this;return(0,y.default)((function*(){var{id:a,name:r,data:n}=e;return t.submitting(t.instanceClient.grantDatabase(a,r,n))}))()}},(0,_.default)(f.prototype,"create",[S.action],(0,h.default)(f.prototype,"create"),f.prototype),(0,_.default)(f.prototype,"deleteUser",[S.action],(0,h.default)(f.prototype,"deleteUser"),f.prototype),(0,_.default)(f.prototype,"grantDatabaseAccess",[S.action],(0,h.default)(f.prototype,"grantDatabaseAccess"),f.prototype),f);t.InstancesUsersStore=E;var I=new E;t.default=I},1415:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.createFetchPrometheusClient=function(e){var{requestType:t,metricKey:a}=e,r=(0,f.default)(METRICDICT,a);return function(){var e=(0,o.default)((function*(e){var a,{params:n={},currentRange:s,interval:u}=e,o=(0,l.default)(a=r.url).call(a,((e,a)=>{var l=(r.finalFormatFunc||[])[a]||p.baseReturnFunc,i=(r.baseParams||[])[a]||{},o=(0,p.getRequestUrl)(e,n,l,i);return(0,p.fetchPrometheus)(o,t,s,u)}));return i.default.all(o)}));return function(t){return e.apply(this,arguments)}}()},t.createDataHandler=function(e){var{formatDataFn:t,typeKey:a,deviceKey:r,modifyKeys:n}=e;return e=>{var i=t(e,a,r,n),o=(0,c.default)(i),f="",p=[];if((0,d.default)(i)&&0!==i.length&&i[0].device){var v,h=(new m.default).createView().source(i).transform({type:"partition",groupBy:["device"]});f=(p=(0,l.default)(v=(0,s.default)(h.rows)).call(v,(e=>(0,u.default)(e).call(e,1,e.length))))[0]}return{retData:o,device:f,devices:p}}};var l=n(a(57)),i=n(a(65)),s=n(a(33)),u=n(a(200)),o=n(a(51)),d=n(a(91)),c=n(a(4033)),f=n(a(111)),m=n(a(4034)),p=a(1209)},1416:function(e,t,a){var r=a(4035);"string"==typeof r&&(r=[[e.i,r,""]]);var n={hmr:!0,transform:undefined,insertInto:void 0};a(75)(r,n);r.locals&&(e.exports=r.locals)},1417:function(e,t,a){"use strict";a(19)(t,"__esModule",{value:!0}),t.default=void 0;var r=a(0),n=a(1209),l=(0,r.createContext)({interval:10,range:(0,n.defaultOneHourAgo)(),node:{metric:{hostname:""}}});t.default=l},1418:function(e,a,r){"use strict";var n=r(33),l=r(44),i=r(32),s=r(25),u=r(27),o=r(45),d=r(46),c=r(19),f=r(21);c(a,"__esModule",{value:!0}),c(a,"policyType",{enumerable:!0,get:function(){return v.default}}),a.InstanceStatus=void 0;var m=f(r(36)),p=r(1195),v=f(r(1300));function h(e,t){var a=n(e);if(l){var r=l(e);t&&(r=i(r).call(r,(function(t){return s(e,t).enumerable}))),a.push.apply(a,r)}return a}function g(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)u(a=h(Object(r),!0)).call(a,(function(t){(0,m.default)(e,t,r[t])}));else if(o)d(e,o(r));else{var n;u(n=h(Object(r))).call(n,(function(t){c(e,t,s(r,t))}))}}return e}var y=g(g({},p.instanceStatus),{},{BUILD:t("Building"),ACTIVE:t("Active"),ERROR:t("Error"),DELETE:t("Delete"),MIGRATE:t("Migrate"),RESIZE:t("Resize"),REBOOT:t("Reboot"),PROMOTE:t("Promote"),EJECT:t("Eject")});a.InstanceStatus=y},1603:function(e,t,a){"use strict";var r=a(160),n=a(19),l=a(25),i=a(21);n(t,"__esModule",{value:!0}),t.default=void 0;var s=i(a(57));a(1198);var u=i(a(1199));a(1196);var o=i(a(1197)),d=i(a(409)),c=i(a(62)),f=i(a(593)),m=i(a(111)),p=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=_(t);if(a&&a.has(e))return a.get(e);var r={},i=n&&l;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var u=i?l(e,s):null;u&&(u.get||u.set)?n(r,s,u):r[s]=e[s]}r.default=e,a&&a.set(e,r);return r}(a(0)),v=(a(173),a(1309)),h=i(a(1350)),g=i(a(1604)),y=i(a(4036)),b=i(a(1417));function _(e){if("function"!=typeof r)return null;var t=new r,a=new r;return(_=function(e){return e?a:t})(e)}var x=e=>{var{baseTopCardProps:t,baseChartProps:a,topCardList:r,chartCardList:n}=e,l=(0,p.useContext)(b.default);return p.default.createElement(u.default,{gutter:[16,16]},0!==r.length&&p.default.createElement(o.default,{span:24},p.default.createElement(u.default,{gutter:[16,16],style:{width:"100%"}},(0,s.default)(r).call(r,(e=>{var a,r;if(e.hidden)return null;var n=(0,f.default)({},t,e),{span:i,fetchDataParams:s={}}=n,u=(0,c.default)(n,["span","fetchDataParams"]),m={key:u.title};i?m.span=i:m.flex=1;var v,{params:h={}}=s,y={currentRange:l.range,interval:l.interval,params:h};if(null!==(a=l.node)&&void 0!==a&&a.metric.hostname)y.params.hostname=null===(v=l.node)||void 0===v?void 0:v.metric.hostname;else if(null!==(r=l.node)&&void 0!==r&&r.metric.instance){var b;y.params.instance=null===(b=l.node)||void 0===b?void 0:b.metric.instance}return p.default.createElement(o.default,m,p.default.createElement(g.default,(0,d.default)({},u,{fetchDataParams:y})))})))),0!==n.length&&p.default.createElement(o.default,{span:24}," ",p.default.createElement(u.default,{gutter:[16,16]},(0,s.default)(n).call(n,(e=>{var t,r,n=(0,f.default)({},a,e),{span:i,fetchDataParams:s={}}=n,u=(0,c.default)(n,["span","fetchDataParams"]),m={key:u.title};i?m.span=i:m.flex=1;var v,{params:h={}}=s,g={currentRange:l.range,interval:l.interval,params:h};if(null!==(t=l.node)&&void 0!==t&&t.metric.hostname)g.params.hostname=null===(v=l.node)||void 0===v?void 0:v.metric.hostname;else if(null!==(r=l.node)&&void 0!==r&&r.metric.instance){var b;g.params.instance=null===(b=l.node)||void 0===b?void 0:b.metric.instance}return p.default.createElement(o.default,m,p.default.createElement(y.default,(0,d.default)({},u,{fetchDataParams:g})))})))))};x.defaultProps={baseTopCardProps:{createFetchParams:{requestType:"current"},handleDataParams:{formatDataFn:v.handleResponses},renderContent:e=>{var{data:t}=e;return p.default.createElement("div",{className:h.default["top-content"]},(0,m.default)(t,"[0].y",0))}},baseChartProps:{span:12,createFetchParams:{requestType:"range"},handleDataParams:{formatDataFn:v.handleResponses},chartProps:{height:300,scale:{y:{nice:!0}}}},topCardList:[],chartCardList:[]};var C=x;t.default=C},1604:function(e,t,a){"use strict";var r=a(160),n=a(19),l=a(25),i=a(21);n(t,"__esModule",{value:!0}),t.default=t.PrometheusContext=void 0,a(1229);var s=i(a(1230));a(560);var u=i(a(412)),o=i(a(51)),d=i(a(32)),c=i(a(57)),f=(a(173),function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=h(t);if(a&&a.has(e))return a.get(e);var r={},i=n&&l;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var u=i?l(e,s):null;u&&(u.get||u.set)?n(r,s,u):r[s]=e[s]}r.default=e,a&&a.set(e,r);return r}(a(0))),m=i(a(4032)),p=a(1415),v=i(a(1416));function h(e){if("function"!=typeof r)return null;var t=new r,a=new r;return(h=function(e){return e?a:t})(e)}var g=(0,f.createContext)({data:[],device:"",devices:[]});function y(e,t,a){return t&&0!==a.length?(0,d.default)(e).call(e,(e=>e.device===t)):e}t.PrometheusContext=g;var b=e=>{var{createFetchParams:t,handleDataParams:a,fetchDataParams:r,title:n,visibleHeight:l,extra:i,renderContent:h}=e,[b,_]=(0,f.useState)([]),[x,C]=(0,f.useState)([]),[S,D]=(0,f.useState)(""),[w,E]=(0,f.useState)([]),[I,P]=(0,f.useState)(!0),T=(0,p.createFetchPrometheusClient)(t),k=(0,p.createDataHandler)(a),N={data:x,device:S,devices:w,modifyKeys:a.modifyKeys};(0,f.useEffect)((()=>{(0,o.default)((function*(){P(!0);var e=yield T(r),{retData:t,device:a,devices:n}=k(e);_(t),D(a),E(n);var l=y(t,a,n);C(l),P(!1)}))()}),[]);var M=f.default.createElement(f.default.Fragment,null,!I&&S&&0!==w.length&&f.default.createElement(u.default,{defaultValue:S,style:{width:150,marginRight:16},options:(0,c.default)(w).call(w,(e=>({label:e,value:e}))),onChange:e=>{P(!0);var t=y(b,e,w);D(e),C(t),P(!1)}}),i&&i({initData:b,chartData:x,device:S,devices:w,modifyKeys:a.modifyKeys,filterChartData:e=>{P(!0);var t=(0,d.default)(b).call(b,e);C(t),P(!1)}}));return f.default.createElement(g.Provider,{value:N},f.default.createElement(s.default,{className:v.default["remove-extra-padding"],bodyStyle:{minHeight:l+48},title:n,extra:M,loading:I},f.default.createElement(m.default,{style:{width:"100%",height:l}},(e=>e?f.default.createElement(g.Consumer,null,(e=>h(e))):null))))};b.defaultProps={visibleHeight:100};var _=b;t.default=_},1606:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l=n(a(174)),i=n(a(36)),s=a(1295),u=n(a(0)),o=n(a(16));class d extends u.default.Component{render(){var{data:e,legendFontSize:t,legendOffsetX:a,middleFontSize:r}=this.props;return(0,s.registerShape)("interval","sliceShape",{draw(e,t){var{points:a}=e,r=[];return r.push(["M",a[0].x,a[0].y]),r.push(["L",a[1].x,a[1].y-.01]),r.push(["L",a[2].x,a[2].y-.01]),r.push(["L",a[3].x,a[3].y]),r.push("Z"),r=this.parsePath(r),t.addShape("path",{attrs:{fill:e.color,path:r}})}}),u.default.createElement(s.Chart,{data:e,autoFit:!0,padding:"auto",appendPadding:[0,20,0,0]},u.default.createElement(s.Coordinate,{type:"theta",radius:.8,innerRadius:.75}),u.default.createElement(s.Axis,{visible:!1}),u.default.createElement(s.Tooltip,{showTitle:!1}),u.default.createElement(s.Interval,{adjust:"stack",position:"value",color:"type",shape:"sliceShape"}),u.default.createElement(s.Annotation.Text,{position:["50%","50%"],content:(0,l.default)(e).call(e,((e,t)=>e+t.value),0),style:{lineHeight:240,fontSize:r,fill:"#262626",textAlign:"center"}}),u.default.createElement(s.Legend,{position:"right",offsetX:a,itemName:{style:{fontSize:t}}}),u.default.createElement(s.Interaction,{type:"element-single-selected"}))}}t.default=d,(0,i.default)(d,"propTypes",{data:o.default.array,legendFontSize:o.default.number,legendOffsetX:o.default.number,middleFontSize:o.default.number}),(0,i.default)(d,"defaultProps",{legendFontSize:16,legendOffsetX:-40,middleFontSize:30})},1607:function(e,t,a){var r=a(4060);"string"==typeof r&&(r=[[e.i,r,""]]);var n={hmr:!0,transform:undefined,insertInto:void 0};a(75)(r,n);r.locals&&(e.exports=r.locals)},1608:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(4075)),s=l(r(1609)),u=l(r(4080)),o=l(r(4081)),d=l(r(4082)),c=l(r(4083)),f=l(r(4084)),m={actionConfigs:{rowActions:{firstAction:i.default,moreActions:[{action:u.default},{title:t("Database Instance Status"),actions:[o.default,d.default,c.default]},{title:t("Configuration Update"),actions:[f.default]}]},primaryActions:[s.default],batchActions:[i.default]},actionConfigsAdmin:{rowActions:{firstAction:i.default},primaryActions:[],batchActions:[i.default]}};a.default=m},1609:function(e,a,r){"use strict";var n=r(33),l=r(44),i=r(32),s=r(25),u=r(27),o=r(45),d=r(46),c=r(19),f=r(21);c(a,"__esModule",{value:!0}),a.default=a.StepCreate=void 0;var m=f(r(57)),p=f(r(65));r(1336);var v=f(r(426)),h=f(r(51)),g=f(r(36)),y=r(1193),b=r(406),_=f(r(1221)),x=f(r(407)),C=(r(173),f(r(4076))),S=f(r(4077)),D=f(r(4078)),w=f(r(4079));function E(e,t){var a=n(e);if(l){var r=l(e);t&&(r=i(r).call(r,(function(t){return s(e,t).enumerable}))),a.push.apply(a,r)}return a}function I(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)u(a=E(Object(r),!0)).call(a,(function(t){(0,g.default)(e,t,r[t])}));else if(o)d(e,o(r));else{var n;u(n=E(Object(r))).call(n,(function(t){c(e,t,s(r,t))}))}}return e}class P extends y.StepAction{constructor(){super(...arguments),(0,g.default)(this,"onSubmit",(e=>{var t,{selectedRowKeys:a=[]}=e.network;return(0,m.default)(a).call(a,(e=>({"net-id":e}))),t=[{"net-id":a[0]}],this.store.create({instance:{datastore:{type:e.datastore_type,version:e.datastore_version},name:e.instance_name,flavorRef:e.flavor.selectedRowKeys[0],volume:{size:e.size},availability_zone:e.zone,nics:t,locality:e.locality,configuration:e.configurationGroup,databases:[{character_set:"utf8",collate:"utf8_general_ci",name:e.initialDatabases}],users:[{databases:[{name:e.initialDatabases}],name:e.initialAdminUser,password:e.password}]}})}))}init(){this.store=_.default,this.projectStore=x.default,this.getQuota(),this.state.isLoading=!0,this.errorMsg=""}static allowed(){return p.default.resolve(!0)}get name(){return t("Create Database Instance")}get listUrl(){return this.getRoutePath("databaseInstances")}get hasConfirmStep(){return!1}get steps(){return[{title:t("Details *"),component:C.default},{title:t("Networking *"),component:S.default},{title:t("Initialize Databases"),component:D.default},{title:t("Advanced"),component:w.default}]}get showQuota(){return this.props.rootStore.hasAdminOnlyRole}getQuota(){var e=this;return(0,h.default)((function*(){e.showQuota&&(yield e.projectStore.fetchProjectTroveQuota(e.currentProjectId),e.setState({isLoading:!1}))}))()}get quotaInfo(){if(this.state.isLoading)return[];var{instances:e={},volumes:a={}}=this.projectStore.troveQuota||{},{left:r=0}=e||{},{data:{size:n=0}={}}=this.state,l=I(I({},e),{},{add:r?1:0,name:"instance",title:t("Database Instance")}),{left:i=0}=a,s=I(I({},a),{},{add:-1===i||n<=i?n:0,name:"volumeSize",title:t("Database Disk (GiB)"),type:"line"});return this.checkQuota(this.state.data,this.projectStore.troveQuota),[l,s]}getQuotaMessage(e,a,r){return-1===a?"":0===a?t("Quota: Insufficient { name } quota to create resources.",{name:r}):e>a?t("Insufficient {name} quota to create resources(left { quota }, input { input }).",{name:r,quota:a,input:e}):""}checkQuota(e,a){var{instances:{left:r=0}={},volumes:{left:n=0}={}}=a||{},{size:l=0}=e||{},i=this.getQuotaMessage(1,r,t("Database Instance")),s=this.getQuotaMessage(l,n,t("Database Disk (GiB)"));if(i||s){var u=i||s;this.errorMsg!==u&&v.default.error(u),this.errorMsg=u}else this.errorMsg=""}get disableNext(){return!!this.errorMsg}get disableSubmit(){return!!this.errorMsg}}a.StepCreate=P,(0,g.default)(P,"id","create-database-instance"),(0,g.default)(P,"title",t("Create Database Instance")),(0,g.default)(P,"path","/database/instances/create"),(0,g.default)(P,"policy","instance:create");var T=(0,b.inject)("rootStore")((0,b.observer)(P));a.default=T},4028:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l=n(a(413)),i=n(a(4029)),s=e=>(0,l.default)(i.default,e);t.default=s},4029:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l=n(a(1212)),i=n(a(567)),s=n(a(4030)),u=n(a(4052)),o=n(a(4056)),d=n(a(4061)),c=n(a(4067)),f="/monitor-center",m=[{path:f,component:l.default,routes:[{path:"".concat(f,"/overview-admin"),component:c.default,exact:!0},{path:"".concat(f,"/physical-node-admin"),component:s.default,exact:!0},{path:"".concat(f,"/storage-cluster-admin"),component:u.default,exact:!0},{path:"".concat(f,"/openstack-service-admin"),component:o.default,exact:!0},{path:"".concat(f,"/other-service-admin"),component:d.default,exact:!0},{path:"*",component:i.default}]}];t.default=m},4030:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.chartConfig=a.chartCardList=a.topCardList=void 0;var i=l(r(229)),s=l(r(27)),u=l(r(419)),o=l(r(57)),d=l(r(81));r(1222);var c=l(r(1223)),f=l(r(111)),m=l(r(0)),p=l(r(119)),v=(r(173),l(r(1263))),h=r(1352),g=r(1209),y=r(161),b=l(r(1350)),_=[{title:t("CPU Cores"),span:5,createFetchParams:{metricKey:"physicalNode.cpuCores"},renderContent:e=>m.default.createElement("div",{className:b.default["top-content"]},(0,f.default)(e.data,"length",0))},{title:t("Total Ram"),span:5,createFetchParams:{metricKey:"physicalNode.totalMem"},renderContent:e=>m.default.createElement("div",{className:b.default["top-content"]},(0,h.getSuitableValue)((0,f.default)(e.data[0],"y",0),"memory"))},{title:t("System Running Time"),span:5,createFetchParams:{metricKey:"physicalNode.systemRunningTime"},renderContent:e=>m.default.createElement("div",{className:b.default["top-content"]},(0,y.formatUsedTime)(1e3*((0,p.default)().unix()-(0,i.default)((0,f.default)(e.data[0],"y",(0,p.default)().unix()),10))))},{title:t("File System Free Space"),span:9,createFetchParams:{metricKey:"physicalNode.fileSystemFreeSpace"},handleDataParams:{formatDataFn:function(){for(var e=arguments.length,t=new Array(e),a=0;a<e;a++)t[a]=arguments[a];var[r,n,l]=t,[i,o]=r,{data:{result:d}={result:[]}}=i,c=[];return(0,s.default)(d).call(d,((e,t)=>{c.push({mountpoint:(0,f.default)(e,"metric.".concat(l))+(0,f.default)(e,"metric.".concat(n)),avail:(0,u.default)((0,f.default)(e,"value[1]",0)),total:(0,u.default)((0,f.default)(o,"data.result[".concat(t,"].value[1]"),0))})})),c},typeKey:"mountpoint",deviceKey:"device"},renderContent:e=>{var t;return m.default.createElement("div",{style:{height:100,overflow:"auto"}},(0,o.default)(t=e.data||[]).call(t,((e,t)=>{var a,r=(0,y.computePercentage)(e.avail,e.total)>80?"#FAAD14":"#1890FF";return m.default.createElement("div",{key:e.mountpoint,style:{marginTop:t>0?16:0}},m.default.createElement("div",null,m.default.createElement("div",{style:{float:"left"}},e.mountpoint),m.default.createElement("div",{style:{float:"right"}},(0,d.default)(a="".concat((0,y.formatSize)((0,i.default)(e.avail,10))," / ")).call(a,(0,y.formatSize)((0,i.default)(e.total,10))))),m.default.createElement(c.default,{style:{width:"95%"},percent:Number(((0,i.default)(e.avail,10)/(0,i.default)(e.total,10)*100).toFixed(3)),strokeColor:r}))})))}}];a.topCardList=_;var x=[{title:t("CPU Usage(%)"),createFetchParams:{metricKey:"physicalNode.cpuUsage"},handleDataParams:{typeKey:"mode"},chartProps:{chartType:g.ChartType.MULTILINE}},{title:t("Memory Usage"),createFetchParams:{metricKey:"physicalNode.memUsage"},handleDataParams:{modifyKeys:[t("Used"),t("Free")]},chartProps:{scale:{y:{formatter:e=>(0,h.getSuitableValue)(e,"memory",0)}},chartType:g.ChartType.MULTILINE}},{title:t("DISK IOPS"),createFetchParams:{metricKey:"physicalNode.diskIOPS"},handleDataParams:{modifyKeys:[t("read"),t("write")],deviceKey:"device"},chartProps:{chartType:g.ChartType.MULTILINEDEVICES}},{title:t("DISK Usage(%)"),createFetchParams:{metricKey:"physicalNode.diskUsage"},handleDataParams:{typeKey:"hostname",deviceKey:"device"},chartProps:{scale:{y:{alias:t("DISK Usage(%)")}},chartType:g.ChartType.ONELINEDEVICES}},{title:t("System Load"),span:24,createFetchParams:{metricKey:"physicalNode.systemLoad"},handleDataParams:{typeKey:"__name__"},chartProps:{chartType:g.ChartType.MULTILINE}},{title:t("Network Traffic"),span:12,createFetchParams:{metricKey:"physicalNode.networkTraffic"},handleDataParams:{modifyKeys:[t("receive"),t("transmit")],deviceKey:"device"},chartProps:{chartType:g.ChartType.MULTILINEDEVICES,scale:{y:{formatter:e=>(0,h.getSuitableValue)(e,"traffic",0)}}}},{title:t("TCP Connections"),span:12,createFetchParams:{metricKey:"physicalNode.tcpConnections"},chartProps:{scale:{y:{alias:t("TCP Connections")}},chartType:g.ChartType.ONELINE}},{title:t("Network Errors"),span:12,createFetchParams:{metricKey:"physicalNode.networkErrors"},handleDataParams:{typeKey:"__name__",deviceKey:"device"},chartProps:{scale:{y:{alias:t("Network Errors")}},chartType:g.ChartType.ONELINE}},{title:t("Network Dropped Packets"),span:12,createFetchParams:{metricKey:"physicalNode.networkDroppedPackets"},handleDataParams:{modifyKeys:[t("receive"),t("transmit")],deviceKey:"device"},chartProps:{scale:{y:{alias:t("Network Dropped Packets")}},chartType:g.ChartType.MULTILINEDEVICES}}];a.chartCardList=x;var C={chartCardList:x,topCardList:_};a.chartConfig=C;var S=()=>m.default.createElement(v.default,{chartConfig:C});a.default=S},4031:function(e,t,a){(t=e.exports=a(74)(!1)).push([e.i,".styles__top-content--qpOa2 {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n height: 120px;\n font-weight: 500;\n font-size: 24px;\n}\n",""]),t.locals={"top-content":"styles__top-content--qpOa2"}},4032:function(e,t,a){"use strict";var r=a(160),n=a(19),l=a(25),i=a(21);n(t,"__esModule",{value:!0}),t.default=void 0;var s,u=i(a(65)),o=i(a(27)),d=i(a(1400)),c=i(a(57)),f=i(a(409)),m=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=p(t);if(a&&a.has(e))return a.get(e);var r={},i=n&&l;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var u=i?l(e,s):null;u&&(u.get||u.set)?n(r,s,u):r[s]=e[s]}r.default=e,a&&a.set(e,r);return r}(a(0));function p(e){if("function"!=typeof r)return null;var t=new r,a=new r;return(p=function(e){return e?a:t})(e)}var v=(0,a(406).observer)(s=class extends m.Component{constructor(e){super(e),this.state={visible:!window.IntersectionObserver},this.io=null,this.container=null}componentDidMount(){(window.IntersectionObserver?u.default.resolve():a.e(1).then(a.t.bind(null,4235,7))).then((()=>{this.io=new window.IntersectionObserver((e=>{(0,o.default)(e).call(e,(e=>{this.setState({visible:e.isIntersecting})}))}),{}),this.io.observe(this.container)}))}componentWillUnmount(){this.io&&this.io.disconnect()}render(){var e;return m.default.createElement("div",(0,f.default)({ref:e=>{this.container=e}},this.props),(0,d.default)(this.props.children)?(0,c.default)(e=this.props.children).call(e,(e=>e(this.state.visible))):this.props.children(this.state.visible))}})||s;t.default=v},4035:function(e,t,a){(t=e.exports=a(74)(!1)).push([e.i,".style__remove-extra-padding--1qIOH .ant-card-extra {\n padding: 0;\n}\n.style__remove-extra-padding--1qIOH .ant-card-head {\n border-bottom: none;\n}\n.style__remove-extra-padding--1qIOH .ant-card-body {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n.style__remove-extra-padding--1qIOH .ant-card-body .ant-card-loading-content {\n width: 100%;\n}\n.style__base-content-container--2-qf6 {\n width: 100%;\n height: 100%;\n padding: 20px;\n overflow-y: scroll;\n}\n.style__base-content-container--2-qf6 .style__refresh--sME80 {\n float: left;\n}\n.style__base-content-container--2-qf6 .style__header--3xQ9T {\n margin-bottom: 16px;\n}\n",""]),t.locals={"remove-extra-padding":"style__remove-extra-padding--1qIOH","base-content-container":"style__base-content-container--2-qf6",refresh:"style__refresh--sME80",header:"style__header--3xQ9T"}},4036:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(409));r(333);var s=l(r(332));r(1317);var u=l(r(1318)),o=l(r(62)),d=l(r(593)),c=l(r(0)),f=(r(173),r(1295)),m=l(r(4037)),p=r(1209),v=r(4038),h=l(r(1604)),g=e=>{var{chartProps:a}=e;return c.default.createElement(h.default,(0,i.default)({},e,{renderContent:t=>{var r,{height:n,scale:l,chartType:i,toolTipProps:s=v.baseToolTipProps}=a,{data:u}=t;switch(l.x=(0,d.default)({},(0,p.getXScale)(e.fetchDataParams.currentRange),l.x||{}),i){case p.ChartType.ONELINE:case p.ChartType.ONELINEDEVICES:r=v.baseLineProps;break;case p.ChartType.MULTILINE:case p.ChartType.MULTILINEDEVICES:r=v.multilineProps;break;default:r=v.baseLineProps}return c.default.createElement(f.Chart,{autoFit:!0,padding:"auto",data:u,height:n,scale:l},c.default.createElement(f.Line,r),c.default.createElement(f.Tooltip,s))},visibleHeight:e.chartProps.height,extra:()=>{var{title:n,createFetchParams:l,handleDataParams:i,fetchDataParams:d,isModal:f=!1}=e,p={},{params:v={}}=d,{instance:h,hostname:g}=v,y=(0,o.default)(v,["instance","hostname"]);return v&&(h?p.instance=h:g&&(p.hostname=g)),c.default.createElement(c.default.Fragment,null,e.extra&&e.extra(),!f&&c.default.createElement(s.default,{type:"text",icon:c.default.createElement(m.default,null),onClick:()=>{var s;u.default.info({icon:null,content:(s=r(1263).default,c.default.createElement(s,{renderNodeSelect:!1,defaultNode:{metric:p},visibleHeight:e.chartProps.height,chartConfig:{chartCardList:[{title:n,createFetchParams:l,handleDataParams:i,fetchDataParams:{params:y},chartProps:a,span:24,isModal:!0}]}})),width:1200,okText:t("OK")})}}))}}))};a.default=g},4038:function(e,t,a){"use strict";a(19)(t,"__esModule",{value:!0}),t.baseToolTipProps=t.multilineProps=t.baseLineProps=void 0;t.baseLineProps={position:"x*y"};t.multilineProps={position:"x*y",color:"type"};t.baseToolTipProps={showCrosshairs:!0,shared:!0}},4039:function(e,a,r){"use strict";var n=r(160),l=r(19),i=r(25),s=r(21);l(a,"__esModule",{value:!0}),a.default=void 0;var u=s(r(57));r(560);var o=s(r(412)),d=(r(173),function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=f(t);if(a&&a.has(e))return a.get(e);var r={},n=l&&i;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var u=n?i(e,s):null;u&&(u.get||u.set)?l(r,s,u):r[s]=e[s]}r.default=e,a&&a.set(e,r);return r}(r(0))),c=r(1209);function f(e){if("function"!=typeof n)return null;var t=new n,a=new n;return(f=function(e){return e?a:t})(e)}var{Option:m}=o.default,p=e=>{var a=(0,c.getInterval)(e),[r,n]=(0,d.useState)(a[0].value),l=e=>{n(e)};(0,d.useEffect)((()=>{a=(0,c.getInterval)(e),l(a[0].value)}),[e]);return[r,()=>d.default.createElement(d.default.Fragment,null,d.default.createElement("span",{style:{marginLeft:20,fontSize:14,fontWeight:400,color:"rgba(0,0,0,.85)"}},t("Time Interval: ")),d.default.createElement(o.default,{value:r,style:{width:120},onChange:l},(0,u.default)(a).call(a,(e=>d.default.createElement(m,{key:e.value,value:e.value},e.text)))))]};a.default=p},4040:function(e,a,r){"use strict";var n=r(160),l=r(19),i=r(25),s=r(21);l(a,"__esModule",{value:!0}),a.default=void 0,r(581);var u=s(r(423));r(1319);var o=s(r(1320)),d=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=m(t);if(a&&a.has(e))return a.get(e);var r={},n=l&&i;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var u=n?i(e,s):null;u&&(u.get||u.set)?l(r,s,u):r[s]=e[s]}r.default=e,a&&a.set(e,r);return r}(r(0)),c=(r(173),s(r(119))),f=r(1209);function m(e){if("function"!=typeof n)return null;var t=new n,a=new n;return(m=function(e){return e?a:t})(e)}var{RangePicker:p}=o.default;var v=function(e){var[a,r]=(0,d.useState)(0),[n,l]=(0,d.useState)(e),i=e=>{var t=e.target.value;r(t),l((0,f.getRange)(t))},s=e=>{r(4),l(e)};return[n,()=>d.default.createElement(u.default.Group,{value:a,onChange:i,style:{marginLeft:20}},d.default.createElement(u.default.Button,{value:0},t("Last Hour")),d.default.createElement(u.default.Button,{value:1},t("Last Day")),d.default.createElement(u.default.Button,{value:2},t("Last 7 Days")),d.default.createElement(u.default.Button,{value:3},t("Last 2 Weeks")),d.default.createElement(u.default.Button,{value:4,style:{float:"right",padding:0}},d.default.createElement(p,{showTime:{hideDisabledOptions:!0,defaultValue:[(0,c.default)("00:00:00","HH:mm:ss"),(0,c.default)("00:00:00","HH:mm:ss")]},disabledDate:g,disabledTime:h,onChange:s,value:n,bordered:!1,allowClear:!1}))),a,l]};function h(e){var t=(0,c.default)();if(t.isSame(e,"day"))return t.isSame(e,"hour")?t.isSame(e,"minutes")?{disabledHours:()=>y(t.hour()+1,24),disabledMinutes:()=>y(t.minute()+1,60),disabledSeconds:()=>y(t.second()+1,60)}:{disabledHours:()=>y(t.hour()+1,24),disabledMinutes:()=>y(t.minute()+1,60)}:{disabledHours:()=>y(t.hour()+1,24)}}function g(e){return e>(0,c.default)().endOf("day")}function y(e,t){for(var a=[],r=e;r<t;r++)a.push(r);return a}a.default=v},4041:function(e,t,a){"use strict";var r=a(160),n=a(19),l=a(25),i=a(21);n(t,"__esModule",{value:!0}),t.default=void 0;var s=i(a(102)),u=i(a(57));a(560);var o=i(a(412)),d=i(a(111)),c=(a(173),function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=m(t);if(a&&a.has(e))return a.get(e);var r={},i=n&&l;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var u=i?l(e,s):null;u&&(u.get||u.set)?n(r,s,u):r[s]=e[s]}r.default=e,a&&a.set(e,r);return r}(a(0))),f=i(a(1416));function m(e){if("function"!=typeof r)return null;var t=new r,a=new r;return(m=function(e){return e?a:t})(e)}var{Option:p}=o.default,v=e=>{var[t,a]=(0,c.useState)(e),[r,n]=(0,c.useState)([]),l=e=>{var t=i();a((0,s.default)(r).call(r,(a=>a.metric[t]===e)))};return[t,()=>{var e=i();return c.default.createElement("div",{className:f.default.header},c.default.createElement("span",{style:{color:"black",fontSize:14,fontWeight:400}},"Node:"," "),c.default.createElement(o.default,{value:t.metric[e],onChange:l,style:{minWidth:150}},(0,u.default)(r).call(r,(t=>c.default.createElement(p,{key:t.metric[e],value:t.metric[e]},t.metric[e])))))},a,n];function i(){var e="instance";return(0,d.default)(t,"metric.hostname",!1)&&(e="hostname"),e}};t.default=v},4052:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(27)),s=l(r(81));r(1222);var u=l(r(1223));r(1198);var o=l(r(1199));r(1196);var d=l(r(1197)),c=l(r(111)),f=l(r(0)),m=(r(173),l(r(1263))),p=r(1352),v=l(r(1606)),h=r(1309),g=r(161),y=r(1209),b=l(r(4053)),_=l(r(4054)),x=()=>{var e=[{title:t("Storage Cluster Status"),span:6,createFetchParams:{metricKey:"storageCluster.cephHealthStatus"},renderContent:e=>{var{data:t}=e,a=(0,c.default)(t,"y",0);return f.default.createElement("div",{className:_.default["top-content"],style:{fontSize:28,fontWeight:600,color:p.cephStatusColorMap[a]}},p.cephStatusMap[a])}},{title:"Monitors",span:9,createFetchParams:{metricKey:"storageCluster.cephMonitorStatus"},handleDataParams:{formatDataFn:function(){var e=(0,h.handleResponses)(...arguments),t=[{type:"down",value:0},{type:"up",value:0}];return(0,i.default)(e).call(e,(e=>{var a=t[e.y].value+1;t[e.y].value=a})),t}},renderContent:e=>{var{data:t}=e;return f.default.createElement("div",null,f.default.createElement("div",{style:{height:120}},f.default.createElement(v.default,{data:t})))}},{title:"PGs",span:9,createFetchParams:{metricKey:"storageCluster.cephPGS"},handleDataParams:{formatDataFn:function(){var e=(0,h.handleResponses)(...arguments);return[{type:"clean",value:(0,c.default)(e,"[0].y",0)},{type:"others",value:(0,c.default)(e,"[1].y",0)}]}},renderContent:e=>{var{data:t}=e;return f.default.createElement("div",null,f.default.createElement("div",{style:{height:120}},f.default.createElement(v.default,{data:t})))}},{title:"OSDs",span:9,createFetchParams:{metricKey:"storageCluster.osdData"},handleDataParams:{formatDataFn:e=>{function t(e){return(0,c.default)(e,"data.result[0].value[1]",0)}var[a,r,n,l]=e;return{inUp:t(a),inDown:t(r),outUp:t(n),outDown:t(l)}}},renderContent:e=>{var{data:a}=e;return f.default.createElement(o.default,{className:_.default.osd},f.default.createElement(d.default,{span:8}),f.default.createElement(d.default,{span:8,style:{fontSize:14,opacity:.8}},t("Up")),f.default.createElement(d.default,{span:8,style:{fontSize:14,opacity:.8}},t("Down")),f.default.createElement(d.default,{span:8,style:{fontSize:14,opacity:.8}},t("In Cluster")),f.default.createElement(d.default,{span:8,style:{fontSize:18}},a.inUp),f.default.createElement(d.default,{span:8,style:{fontSize:18}},a.inDown),f.default.createElement(d.default,{span:8,style:{fontSize:14,opacity:.8}},t("Out Cluster")),f.default.createElement(d.default,{span:8,style:{fontSize:18}},a.outUp),f.default.createElement(d.default,{span:8,style:{fontSize:18}},a.outDown))}},{title:t("Average PGs per OSD"),span:5,createFetchParams:{metricKey:"storageCluster.avgPerOSD"}},{title:t("Storage Cluster Usage"),span:10,createFetchParams:{metricKey:"storageCluster.storageClusterUsage"},renderContent:e=>{var a,r,n,{data:l}=e,i=(0,c.default)(l[0],"y",0),d=(0,c.default)(l[1],"y",0),m=(0,p.getSuitableValue)(i,"disk"),v=(0,p.getSuitableValue)(d,"disk"),h=(0,g.computePercentage)(i,d);return f.default.createElement("div",{className:_.default["top-content"]},f.default.createElement("div",{style:{width:"100%",height:"100%"}},f.default.createElement(o.default,{style:{justifyContent:"flex-end",height:"50%"}},f.default.createElement("span",{style:{fontSize:12,marginRight:32}},(0,s.default)(a=(0,s.default)(r=(0,s.default)(n="".concat(t("Used")," ")).call(n,m," / ")).call(r,t("Total")," ")).call(a,v))),f.default.createElement(o.default,{style:{height:"50%"}},f.default.createElement(u.default,{style:{width:"95%"},percent:h,strokeColor:h>80?"#FAAD14":"#1890FF",showInfo:100!==h}))))}}],a={chartCardList:[{title:t("Storage Pool Capacity Usage"),createFetchParams:{metricKey:"storageCluster.poolCapacityUsage"},handleDataParams:{modifyKeys:[t("used"),t("available")]},chartProps:{chartType:y.ChartType.MULTILINE,scale:{y:{formatter:e=>(0,p.getSuitableValue)(e,"disk",0)}}}},{title:t("Storage Cluster OSD Latency"),createFetchParams:{metricKey:"storageCluster.clusterOSDLatency"},handleDataParams:{modifyKeys:["apply","commit"]},chartProps:{chartType:y.ChartType.MULTILINE}},{title:t("Storage Cluster IOPS"),createFetchParams:{metricKey:"storageCluster.clusterIOPS"},handleDataParams:{modifyKeys:[t("read"),t("write")]},chartProps:{chartType:y.ChartType.MULTILINE}},{title:t("Storage Cluster Bandwidth"),createFetchParams:{metricKey:"storageCluster.clusterBandwidth"},handleDataParams:{modifyKeys:[t("in"),t("out")]},chartProps:{scale:{y:{formatter:e=>(0,p.getSuitableValue)(e,"bandwidth",0)}},chartType:y.ChartType.MULTILINE}}],topCardList:e};return f.default.createElement(m.default,{renderNodeSelect:!1,chartConfig:a},f.default.createElement(b.default,null))};a.default=x},4053:function(e,a,r){"use strict";var n=r(33),l=r(44),i=r(32),s=r(25),u=r(27),o=r(45),d=r(46),c=r(19),f=r(160),m=r(21);c(a,"__esModule",{value:!0}),a.default=void 0;var p=m(r(27)),v=m(r(419)),h=m(r(32)),g=m(r(33)),y=m(r(57)),b=m(r(1338)),_=m(r(90)),x=m(r(229)),C=m(r(65)),S=m(r(62)),D=m(r(51)),w=m(r(36));r(1260);var E=m(r(1261)),I=m(r(111)),P=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=A(t);if(a&&a.has(e))return a.get(e);var r={},n=c&&s;for(var l in e)if("default"!==l&&Object.prototype.hasOwnProperty.call(e,l)){var i=n?s(e,l):null;i&&(i.get||i.set)?c(r,l,i):r[l]=e[l]}r.default=e,a&&a.set(e,r);return r}(r(0)),T=(r(173),r(1415)),k=m(r(1530)),N=r(1209),M=r(161),L=m(r(429)),F=m(r(1417));function A(e){if("function"!=typeof f)return null;var t=new f,a=new f;return(A=function(e){return e?a:t})(e)}function O(e,t){var a=n(e);if(l){var r=l(e);t&&(r=i(r).call(r,(function(t){return s(e,t).enumerable}))),a.push.apply(a,r)}return a}function z(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)u(a=O(Object(r),!0)).call(a,(function(t){(0,w.default)(e,t,r[t])}));else if(o)d(e,o(r));else{var n;u(n=O(Object(r))).call(n,(function(t){c(e,t,s(r,t))}))}}return e}var{TabPane:j}=E.default,K=()=>{var[e,a]=(0,P.useState)({}),[r,n]=(0,P.useState)([]),[l,i]=(0,P.useState)([]),[s,u]=(0,P.useState)("pool"),[o,d]=(0,P.useState)(!0),c=(0,P.useContext)(F.default),f=(0,T.createFetchPrometheusClient)({requestType:"current",metricKey:"storageCluster.tabs"}),m=(0,T.createDataHandler)({modifyKeys:["pools","osds"],formatDataFn:e=>{var t,a,r=[],[n,l]=e;return(0,p.default)(t=(0,I.default)(n,"data.result",[])).call(t,(e=>{var{metric:t,value:a}=e;r.push(z(z({type:"pool"},t),{},{value:(0,v.default)(a[1])||0}))})),(0,p.default)(a=(0,I.default)(l,"data.result",[])).call(a,(e=>{var{metric:t,value:a}=e;r.push(z(z({type:"osd"},t),{},{value:(0,v.default)(a[1])||0}))})),r}});function w(t){var a,r=(0,h.default)(t).call(t,(e=>e.type===s));(0,p.default)(a=(0,g.default)(e)).call(a,(t=>{r=(0,h.default)(r).call(r,(a=>a[t]===e[t]))})),i(r)}function M(e){return A.apply(this,arguments)}function A(){return(A=(0,D.default)((function*(e){var t,a,r=[...e],n=(0,y.default)(t=(0,I.default)(METRICDICT,"storageCluster.poolTab.url",[])).call(t,(e=>(0,N.fetchPrometheus)(e,"current"))),l=(0,y.default)(a=(0,I.default)(METRICDICT,"storageCluster.osdTab.url",[])).call(a,(e=>(0,N.fetchPrometheus)(e,"current")));function i(e,t,a){var n;(0,p.default)(n=e.data.result).call(n,(e=>{var n,{metric:l,value:i}=e,s=(0,b.default)(r).call(r,(e=>e[a]===l[a]));3===t?r[s].usage=(0,v.default)((0,v.default)(i[1]).toFixed(2)):(0,_.default)(n=["ceph_pool_objects","ceph_pg_total","ceph_pool_max_avail","ceph_osd_weight","ceph_osd_apply_latency_ms","ceph_osd_commit_latency_ms","ceph_osd_stat_bytes"]).call(n,l.__name__)>-1?r[s][l.__name__]=(0,x.default)(i[1],10):r[s][l.__name__]=i[1]}))}var s=yield C.default.all(n);(0,p.default)(s).call(s,((e,t)=>{i(e,t,"pool_id")}));var u=yield C.default.all(l);return(0,p.default)(u).call(u,((e,t)=>{i(e,t,"ceph_daemon")})),r}))).apply(this,arguments)}function O(){return(O=(0,D.default)((function*(){d(!0);var e=yield f({currentRange:c.range,interval:c.interval}),{retData:t}=m(e),a=yield M(t);n(a),w(a),d(!1)}))).apply(this,arguments)}(0,P.useEffect)((()=>{!function(){O.apply(this,arguments)}()}),[]),(0,P.useEffect)((()=>{w(r)}),[s,e]);var K="pool"===s?R:U;return P.default.createElement(P.default.Fragment,null,P.default.createElement(E.default,{defaultActiveKey:"pool",onChange:e=>{a({}),u(e)}},P.default.createElement(j,{tab:"Pools",key:"pool"}),P.default.createElement(j,{tab:"OSDs",key:"osd"})),P.default.createElement(k.default,{isLoading:o,resourceName:"pool"===s?t("Pools"):t("OSDs"),rowKey:"pool"===s?"pool_id":"name",columns:K,data:l,pagination:z(z({},new L.default),{},{total:l.length}),hideRefresh:!0,searchFilters:"pool"===s?[{label:t("Pool Name"),name:"name"}]:[{label:t("Name"),name:"ceph_daemon"}],itemActions:[],onFilterChange:e=>{var{limit:t,page:r,sortKey:n,sortOrder:l}=e,i=(0,S.default)(e,["limit","page","sortKey","sortOrder"]);a(i)}}))};a.default=K;var R=[{title:t("Pool Name"),dataIndex:"name"},{title:t("PG Count"),dataIndex:"ceph_pg_total",isHideable:!0},{title:t("Object Count "),dataIndex:"ceph_pool_objects",isHideable:!0},{title:t("Max Avail"),dataIndex:"ceph_pool_max_avail",render:e=>(0,M.formatSize)(e),isHideable:!0},{title:t("Usage"),dataIndex:"usage",render:e=>"".concat(e,"%"),isHideable:!0}],U=[{title:t("Name"),dataIndex:"ceph_daemon"},{title:t("Status"),dataIndex:"ceph_osd_up",render:e=>"1"===e?t("Up"):t("Down"),isHideable:!0},{title:t("Instance Addr"),dataIndex:"cluster_addr",isHideable:!0},{title:t("Weight"),dataIndex:"ceph_osd_weight",isHideable:!0},{title:t("Apply Latency(ms)"),dataIndex:"ceph_osd_apply_latency_ms",isHideable:!0},{title:t("Commit Latency(ms)"),dataIndex:"ceph_osd_commit_latency_ms",isHideable:!0},{title:t("Total Capacity"),dataIndex:"ceph_osd_stat_bytes",render:e=>(0,M.formatSize)(e),isHideable:!0},{title:t("Usage"),dataIndex:"usage",render:e=>"".concat((0,v.default)(e).toFixed(2),"%"),isHideable:!0}]},4054:function(e,t,a){var r=a(4055);"string"==typeof r&&(r=[[e.i,r,""]]);var n={hmr:!0,transform:undefined,insertInto:void 0};a(75)(r,n);r.locals&&(e.exports=r.locals)},4055:function(e,t,a){(t=e.exports=a(74)(!1)).push([e.i,".index__osd--2HtuM {\n height: 100%;\n color: rgba(0, 0, 0, 0.85);\n font-weight: 500;\n font-size: 16px;\n text-align: center;\n}\n.index__header--246Eo {\n padding: 20px;\n overflow: auto;\n}\n.index__header--246Eo .index__range--3UhTc .ant-radio-button-wrapper {\n color: rgba(0, 0, 0, 0.65);\n}\n.index__header--246Eo .index__range--3UhTc .ant-radio-button-wrapper-checked {\n color: #0068ff;\n}\n.index__header--246Eo .index__download--21jst {\n float: right;\n}\n.index__header--246Eo .index__download--21jst .ant-btn-icon-only {\n border-radius: 4px;\n}\n.index__my-card-row--rBTsX .index__top--3Nx2m .index__content--2R7tG {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n height: 100%;\n font-size: 24px;\n text-align: center;\n}\n.index__my-card-row--rBTsX .index__top--3Nx2m .ant-card-bordered {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n}\n.index__my-card-row--rBTsX .index__top--3Nx2m .ant-card-bordered .ant-card-body {\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n padding-top: 0;\n overflow: hidden;\n}\n.index__my-card-row--rBTsX .ant-card-bordered {\n -webkit-box-shadow: 0 2px 20px 0 rgba(0, 0, 0, 0.09);\n box-shadow: 0 2px 20px 0 rgba(0, 0, 0, 0.09);\n}\n.index__my-card-row--rBTsX .ant-card-bordered .ant-card-head {\n border-bottom: none;\n}\n.index__outer--3mHPU {\n position: relative;\n width: 100%;\n height: 100%;\n overflow: hidden;\n font-size: 12px;\n}\n.index__outer--3mHPU .index__inner--1HrRB {\n position: absolute;\n left: 0;\n width: 100%;\n height: 100%;\n overflow-x: hidden;\n overflow-y: scroll;\n}\n.index__outer--3mHPU .index__inner--1HrRB::-webkit-scrollbar {\n display: none;\n}\n.index__top-content--2QZJv {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n height: 120px;\n font-weight: 500;\n font-size: 24px;\n}\n.index__tabs--1be8Z .ant-tabs-tab {\n margin-right: 20px;\n border-bottom: 1px solid #f0f0f0;\n}\n.index__tabs--1be8Z .ant-tabs-nav::before {\n border-bottom: none;\n}\n.index__spin-container--2aH9q {\n width: 100%;\n min-height: 400px;\n padding: 30px 50px;\n text-align: center;\n}\n",""]),t.locals={osd:"index__osd--2HtuM",header:"index__header--246Eo",range:"index__range--3UhTc",download:"index__download--21jst","my-card-row":"index__my-card-row--rBTsX",top:"index__top--3Nx2m",content:"index__content--2R7tG",outer:"index__outer--3mHPU",inner:"index__inner--1HrRB","top-content":"index__top-content--2QZJv",tabs:"index__tabs--1be8Z","spin-container":"index__spin-container--2aH9q"}},4056:function(e,a,r){"use strict";var n=r(33),l=r(44),i=r(32),s=r(25),u=r(27),o=r(45),d=r(46),c=r(19),f=r(160),m=r(21);c(a,"__esModule",{value:!0}),a.default=a.OpenstackService=void 0;var p=m(r(562));r(333);var v=m(r(332)),h=m(r(1273)),g=m(r(51)),y=m(r(36)),b=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=w(t);if(a&&a.has(e))return a.get(e);var r={},n=c&&s;for(var l in e)if("default"!==l&&Object.prototype.hasOwnProperty.call(e,l)){var i=n?s(e,l):null;i&&(i.get||i.set)?c(r,l,i):r[l]=e[l]}r.default=e,a&&a.set(e,r);return r}(r(0)),_=r(406),x=r(4057),C=(r(555),r(173),m(r(140))),S=m(r(4059)),D=m(r(1607));function w(e){if("function"!=typeof f)return null;var t=new f,a=new f;return(w=function(e){return e?a:t})(e)}function E(e,t){var a=n(e);if(l){var r=l(e);t&&(r=i(r).call(r,(function(t){return s(e,t).enumerable}))),a.push.apply(a,r)}return a}function I(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)u(a=E(Object(r),!0)).call(a,(function(t){(0,y.default)(e,t,r[t])}));else if(o)d(e,o(r));else{var n;u(n=E(Object(r))).call(n,(function(t){c(e,t,s(r,t))}))}}return e}class P extends b.Component{constructor(e){var t;super(e),t=this,(0,y.default)(this,"getData",(0,g.default)((function*(){yield t.store.getChartData()}))),(0,y.default)(this,"handleRefresh",(()=>{this.getData()}));var{Store:a=x.OpenstackServiceStore}=e;this.store=new a}componentDidMount(){this.getData()}get enableCinder(){return C.default.checkEndpoint("cinder")}render(){var{nova_service:e,network_service:a,other_service:r,cinder_service:n}=this.store,l=[I({key:"nova_service",title:t("Nova Service")},e),I({key:"network_service",title:t("Neutron Service")},a),I({key:"other_service",title:t("Other Service")},r)];return this.enableCinder&&(0,p.default)(l).call(l,2,0,I({key:"cinder_service",title:t("Cinder Service")},n)),b.default.createElement("div",{className:D.default.container},b.default.createElement(v.default,{type:"default",icon:b.default.createElement(h.default,null),onClick:this.handleRefresh}),b.default.createElement(S.default,{serviceMap:l}))}}a.OpenstackService=P;var T=(0,_.observer)(P);a.default=T},4057:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.OpenstackServiceStore=void 0;var i,s,u,o,d,c,f,m,p,v,h=l(r(65)),g=l(r(27)),y=l(r(1338)),b=l(r(51)),_=l(r(71)),x=(l(r(36)),l(r(54))),C=(l(r(72)),r(34)),S=r(1209),D=l(r(4058)),w={mysql_up:t("Database Service"),rabbitmq_identity_info:t("Message Queue Service"),memcached_up:t("Cache Service")},E=[t("Database Service"),t("Message Queue Service"),t("Cache Service")],I=(i=class extends D.default{constructor(){super(...arguments),(0,_.default)(this,"nova_service",s,this),(0,_.default)(this,"network_service",u,this),(0,_.default)(this,"cinder_service",o,this),(0,_.default)(this,"other_service",d,this),(0,_.default)(this,"getChartData",c,this),(0,_.default)(this,"getNovaService",f,this),(0,_.default)(this,"getNetworkService",m,this),(0,_.default)(this,"getCinderService",p,this),(0,_.default)(this,"getOtherService",v,this)}},s=(0,x.default)(i.prototype,"nova_service",[C.observable],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return{isLoading:!1,data:[]}}}),u=(0,x.default)(i.prototype,"network_service",[C.observable],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return{isLoading:!1,data:[]}}}),o=(0,x.default)(i.prototype,"cinder_service",[C.observable],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return{isLoading:!1,data:[]}}}),d=(0,x.default)(i.prototype,"other_service",[C.observable],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return{isLoading:!1,data:[]}}}),c=(0,x.default)(i.prototype,"getChartData",[C.action],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){var e=this;return(0,b.default)((function*(){var t=[e.getNovaService(),e.getNetworkService(),e.getCinderService(),e.getOtherService()];yield h.default.all(t)}))}}),f=(0,x.default)(i.prototype,"getNovaService",[C.action],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){var e=this;return(0,b.default)((function*(){(0,C.set)(e.nova_service,{isLoading:!0,data:[]});var t=[];try{var[a,r,n,l]=yield h.default.all((0,S.getPromises)("openstackService.novaService")),{data:{result:i}}=a;(0,g.default)(i).call(i,(e=>{var{metric:{service:a="",adminState:r="",hostname:n=""}={}}=e;t.push({hostname:n,serviceName:a,state:"enabled"===r?"up":"down"})}));var{data:{result:s}}=r;(0,g.default)(s).call(s,(e=>{var{metric:{service:a="",hostname:r=""}={}}=e,n=(0,y.default)(t).call(t,(e=>e.serviceName===a&&e.hostname===r));t[n]["".concat(a,"24")]="down"}));var{data:{result:u}}=n;(0,g.default)(u).call(u,(e=>{var{metric:a,value:r}=e;t.push({serviceName:"nova_libvirt",hostname:a.hostname,state:"enabled"===r[1]?"up":"down"})}));var{data:{result:o}}=l;(0,g.default)(o).call(o,(e=>{var{metric:{hostname:a=""}={}}=e,r=(0,y.default)(t).call(t,(e=>"nova_libvirt"===e.serviceName&&e.hostname===a));t[r].nova_libvirt24="down"}))}finally{(0,C.set)(e.nova_service,{isLoading:!1,data:t})}}))}}),m=(0,x.default)(i.prototype,"getNetworkService",[C.action],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){var e=this;return(0,b.default)((function*(){(0,C.set)(e.network_service,{isLoading:!0,data:[]});var t=[];try{var[a,r]=yield h.default.all(S.getPromises.call(e,"openstackService.networkService")),{data:{result:n}}=a;(0,g.default)(n).call(n,(e=>{var{metric:{service:a="",adminState:r="",hostname:n=""}={}}=e;t.push({serviceName:a,hostname:n,state:r})}));var{data:{result:l}}=r;(0,g.default)(l).call(l,(e=>{var{metric:{service:a="",hostname:r=""}={}}=e,n=(0,y.default)(t).call(t,(e=>e.serviceName===a&&e.hostname===r));t[n]["".concat(a,"24")]="down"}))}finally{(0,C.set)(e.network_service,{isLoading:!1,data:t})}}))}}),p=(0,x.default)(i.prototype,"getCinderService",[C.action],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){var e=this;return(0,b.default)((function*(){(0,C.set)(e.cinder_service,{isLoading:!0,data:[]});var t=[];try{var[a,r]=yield h.default.all(S.getPromises.call(e,"openstackService.cinderService")),{data:{result:n}}=a;(0,g.default)(n).call(n,(e=>{var{metric:{service:a="",adminState:r="",hostname:n=""}={}}=e;t.push({serviceName:a,hostname:n,state:"enabled"===r?"up":"down"})}));var{data:{result:l}}=r;(0,g.default)(l).call(l,(e=>{var{metric:{service:a="",hostname:r=""}={}}=e,n=(0,y.default)(t).call(t,(e=>e.serviceName===a&&e.hostname===r));t[n]["".concat(a,"24")]="down"}))}finally{(0,C.set)(e.cinder_service,{isLoading:!1,data:t})}}))}}),v=(0,x.default)(i.prototype,"getOtherService",[C.action],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){var e=this;return(0,b.default)((function*(){(0,C.set)(e.other_service,{isLoading:!0,data:[]});var t=[];try{var a=yield h.default.all(S.getPromises.call(e,"openstackService.otherService"));(0,g.default)(a).call(a,(e=>{var{data:{result:a}}=e;(0,g.default)(a).call(a,(e=>{var{metric:a,value:r}=e;t.push({serviceName:w[a.__name__],hostname:a.instance,state:"1"===r[1]?"up":"down"})}))})),a=yield h.default.all(S.getPromises.call(e,"openstackService.otherServiceMinOverTime")),(0,g.default)(a).call(a,((e,a)=>{var{data:{result:r}}=e;(0,g.default)(r).call(r,(e=>{var{metric:{instance:r=""}={}}=e,n=(0,y.default)(t).call(t,(e=>e.serviceName===E[a]&&e.hostname===r));t[n]["".concat(E[a],"24")]="down"}))}))}finally{(0,C.set)(e.other_service,{isLoading:!1,data:t})}}))}}),i);a.OpenstackServiceStore=I;var P=new I;a.default=P},4058:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l,i,s,u,o,d,c,f=n(a(419)),m=n(a(229)),p=n(a(33)),v=n(a(25)),h=n(a(32)),g=n(a(580)),y=n(a(51)),b=n(a(71)),_=(n(a(36)),n(a(54))),x=(n(a(72)),a(34)),C=a(1209),S=a(569),D=n(a(53)),w=(l=class extends D.default{constructor(){super(...arguments),(0,b.default)(this,"currentRange",i,this),(0,b.default)(this,"interval",s,this),(0,b.default)(this,"loading",u,this),(0,b.default)(this,"handleRangePickerChange",o,this),(0,b.default)(this,"handleIntervalChange",d,this),(0,b.default)(this,"handleDeviceChange",c,this)}get responseKey(){return""}get intervals(){return(0,C.getInterval)(this.currentRange)}formatToGiB(e){return(0,f.default)(((0,m.default)(e,10)/1073741824).toFixed(2))}buildRequest(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"range",a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=0===(0,p.default)(a).length?e:(0,C.addParams)(e,a);return"current"===t?this.skylineClient.query.list({query:r}):this.skylineClient.queryRange.list({query:r,start:(0,S.getTimestamp)(this.currentRange[0]),end:(0,S.getTimestamp)(this.currentRange[1]),step:this.interval})}},i=(0,_.default)(l.prototype,"currentRange",[x.observable],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return(0,C.defaultOneHourAgo)()}}),s=(0,_.default)(l.prototype,"interval",[x.observable],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return 10}}),u=(0,_.default)(l.prototype,"loading",[x.observable],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return!0}}),o=(0,_.default)(l.prototype,"handleRangePickerChange",[x.action],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){var e=this;return function(){var t=(0,y.default)((function*(t){var a=arguments.length>1&&void 0!==arguments[1]&&arguments[1];a||(0,S.getTimestamp)(e.currentRange[0])===(0,S.getTimestamp)(t[0])&&(0,S.getTimestamp)(e.currentRange[1])===(0,S.getTimestamp)(t[1])?e.currentRange=t:(e.currentRange=t,e.interval=e.intervals[0].value),yield e.getChartData()}));return function(e){return t.apply(this,arguments)}}()}}),(0,_.default)(l.prototype,"intervals",[x.computed],(0,v.default)(l.prototype,"intervals"),l.prototype),d=(0,_.default)(l.prototype,"handleIntervalChange",[x.action],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){var e=this;return function(){var t=(0,y.default)((function*(t){e.interval=t,yield e.getChartData()}));return function(e){return t.apply(this,arguments)}}()}}),c=(0,_.default)(l.prototype,"handleDeviceChange",[x.action],{configurable:!0,enumerable:!0,writable:!0,initializer:function(){return(e,t)=>{var a,r=this[t];(0,x.set)(r,{isLoading:!0});var n=(0,h.default)(a=r.data).call(a,(t=>t.device===e));(0,g.default)((()=>{(0,x.set)(r,{currentDevice:e,currentShowData:n,isLoading:!1})}),200)}}}),l);t.default=w},4059:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(57));r(1394);var s=l(r(1329));r(1196);var u=l(r(1197));r(411);var o=l(r(227)),d=l(r(1522)),c=l(r(1521));r(1404);var f=l(r(1405)),m=l(r(0)),p=(r(173),r(555),l(r(1607))),{Panel:v}=f.default,h={up:m.default.createElement(c.default,{style:{fontSize:24,marginLeft:36},twoToneColor:"#52C41A"}),down:m.default.createElement(d.default,{style:{fontSize:24,marginLeft:36},twoToneColor:"#EB354D"})},g=e=>{var{serviceMap:a}=e;return m.default.createElement(f.default,{defaultActiveKey:(0,i.default)(a).call(a,(e=>e.key)),ghost:!0},(0,i.default)(a).call(a,(e=>m.default.createElement(v,{header:m.default.createElement("span",{className:p.default.header},e.title),key:e.key},m.default.createElement(s.default,{bordered:!0,dataSource:e.data,className:p.default.list,loading:e.isLoading,renderItem:e=>m.default.createElement(s.default.Item,{className:p.default.item},m.default.createElement(u.default,{className:p.default.title,span:6},e.engine_id?m.default.createElement(o.default,{title:e.engine_id},m.default.createElement("span",null,e.serviceName)):e.serviceName),m.default.createElement(u.default,{className:p.default.title,span:6},e.hostname||e.host),m.default.createElement(u.default,{className:p.default.status,span:6},m.default.createElement("span",null,t("Current Status")),h[e.state]),m.default.createElement(u.default,{className:p.default.status,span:6},m.default.createElement("span",null,t("Last 24H Status")," "),e["".concat(e.serviceName,"24")]?h[e["".concat(e.serviceName,"24")]]:h.up))})))))};a.default=g},4060:function(e,t,a){(t=e.exports=a(74)(!1)).push([e.i,".index__header--2Tct3 {\n color: rgba(0, 0, 0, 0.85);\n font-weight: 500;\n font-size: 16px;\n line-height: 22px;\n}\n.index__list--AK4zu {\n background-color: #fff;\n border: none;\n -webkit-box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.05);\n box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.05);\n}\n.index__list--AK4zu .index__item--2Dqsf {\n height: 76px;\n}\n.index__list--AK4zu .index__item--2Dqsf .index__title--Tai7z {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n color: rgba(0, 0, 0, 0.65);\n font-weight: 400;\n font-size: 16px;\n}\n.index__list--AK4zu .index__item--2Dqsf .index__status--2Ke1i {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n color: rgba(0, 0, 0, 0.65);\n font-weight: 400;\n font-size: 14px;\n}\n.index__container--22t9I {\n height: 100%;\n padding: 16px;\n overflow: auto;\n}\n",""]),t.locals={header:"index__header--2Tct3",list:"index__list--AK4zu",item:"index__item--2Dqsf",title:"index__title--Tai7z",status:"index__status--2Ke1i",container:"index__container--22t9I"}},4061:function(e,t,a){"use strict";var r=a(160),n=a(19),l=a(25),i=a(21);n(t,"__esModule",{value:!0}),t.default=t.OtherService=void 0,a(581);var s=i(a(423)),u=i(a(36)),o=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=v(t);if(a&&a.has(e))return a.get(e);var r={},i=n&&l;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var u=i?l(e,s):null;u&&(u.get||u.set)?n(r,s,u):r[s]=e[s]}r.default=e,a&&a.set(e,r);return r}(a(0)),d=a(406),c=(a(173),i(a(4062))),f=i(a(4063)),m=i(a(4064)),p=i(a(4065));function v(e){if("function"!=typeof r)return null;var t=new r,a=new r;return(v=function(e){return e?a:t})(e)}class h extends o.Component{constructor(e){super(e),(0,u.default)(this,"handleTypeChange",(e=>{this.setState({type:e.target.value})})),(0,u.default)(this,"renderTypeSelect",(()=>{var{type:e}=this.state;return o.default.createElement(s.default.Group,{onChange:this.handleTypeChange,value:e},o.default.createElement(s.default.Button,{value:"mysql"},"MySQL"),o.default.createElement(s.default.Button,{value:"memcache"},"Memcache"),o.default.createElement(s.default.Button,{value:"rabbitmq"},"RabbitMQ"))})),(0,u.default)(this,"renderSelectTab",(()=>{var{type:e}=this.state,t=null;switch(e){case"mysql":t=c.default;break;case"memcache":t=m.default;break;case"rabbitmq":t=f.default;break;default:t=c.default}return o.default.createElement(t,{type:e})})),this.state={type:"mysql"}}render(){return o.default.createElement("div",{className:p.default.container},o.default.createElement("div",{style:{padding:"20px 20px 0 20px"}},this.renderTypeSelect()),o.default.createElement("div",{className:p.default.content},this.renderSelectTab()))}}t.OtherService=h;var g=(0,d.observer)(h);t.default=g},4062:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.chartConfig=void 0;var i=l(r(111)),s=l(r(0)),u=l(r(1263)),o=r(1351),d=r(161),c=l(r(1350)),f=r(1209),m={topCardList:[{title:t("Running Time"),span:6,createFetchParams:{metricKey:"mysqlService.runningTime"},renderContent:e=>{var{data:t}=e;return s.default.createElement("div",{className:c.default["top-content"]},(0,d.formatUsedTime)(1e3*(0,i.default)(t,"[0].y",0)))}},{title:t("Connected Threads"),span:6,createFetchParams:{metricKey:"mysqlService.connectedThreads"}},{title:t("Running Threads"),span:6,createFetchParams:{metricKey:"mysqlService.runningThreads"}},{title:t("Slow Query"),span:6,createFetchParams:{metricKey:"mysqlService.slowQuery"}}],chartCardList:[{title:t("Threads Activity Trends"),createFetchParams:{metricKey:"mysqlService.threadsActivityTrends_connected"},chartProps:{chartType:f.ChartType.ONELINE,scale:{y:{alias:t("Threads Activity Trends")}}}},{title:t("MySQL Actions"),createFetchParams:{metricKey:"mysqlService.mysqlActions"},handleDataParams:{modifyKeys:[t("delete"),t("insert"),t("update")]},chartProps:{chartType:f.ChartType.MULTILINE,scale:{y:{alias:t("MySQL Actions")}}}},{title:t("Slow Query"),createFetchParams:{metricKey:"mysqlService.slowQueryChart"},chartProps:{chartType:f.ChartType.ONELINE,scale:{y:{alias:t("Slow Query")}}}}]};a.chartConfig=m;a.default=e=>{var{type:t}=e;return s.default.createElement(u.default,{type:t,chartConfig:m,fetchNodesFunc:o.getMysqlNodes})}},4063:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.chartConfig=void 0;var i=l(r(27)),s=l(r(229));r(1198);var u=l(r(1199));r(1196);var o=l(r(1197)),d=l(r(111)),c=l(r(0)),f=(r(173),l(r(1263))),m=r(1351),p=r(1209),v=l(r(1350)),h={topCardList:[{title:t("Server Status"),createFetchParams:{metricKey:"rabbitMQService.serviceStatus"},handleDataParams:{formatDataFn:e=>{var t={up:0,down:0},a=(0,d.default)(e[0],"data.result",[]);return(0,i.default)(a).call(a,(e=>{1===(0,s.default)(e.value[1],10)?t.up+=1:t.down+=1})),t}},renderContent:e=>{var{data:a}=e;return c.default.createElement("div",{className:v.default["top-content"]},c.default.createElement(u.default,{style:{width:"100%",textAlign:"center"}},c.default.createElement(o.default,{span:12},a.up+t("Up")),c.default.createElement(o.default,{span:12},a.down+t("Down"))))}},{title:t("Connected Threads"),createFetchParams:{metricKey:"rabbitMQService.totalConnections"}},{title:t("Total Queues"),createFetchParams:{metricKey:"rabbitMQService.totalQueues"}},{title:t("Total Exchanges"),createFetchParams:{metricKey:"rabbitMQService.totalExchanges"}},{title:t("Total Consumers"),createFetchParams:{metricKey:"rabbitMQService.totalConsumers"}}],chartCardList:[{title:t("Published Out"),createFetchParams:{metricKey:"rabbitMQService.publishedOut"},chartProps:{chartType:p.ChartType.ONELINE,scale:{y:{alias:t("Published Out")}}}},{title:t("Published In"),createFetchParams:{metricKey:"rabbitMQService.publishedIn"},chartProps:{chartType:p.ChartType.ONELINE,scale:{y:{alias:t("Published In")}}}},{title:t("Channel"),createFetchParams:{metricKey:"rabbitMQService.channel"},chartProps:{chartType:p.ChartType.ONELINE,scale:{y:{alias:t("Channel")}}}}]};a.chartConfig=h;a.default=e=>{var{type:t}=e;return c.default.createElement(f.default,{type:t,chartConfig:h,fetchNodesFunc:m.getRabbitMQNodes})}},4064:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.chartConfig=void 0;var i=l(r(0)),s=l(r(1263)),u=r(1351),o=r(1209),d=r(1352),c={chartCardList:[{title:t("Current Connections"),createFetchParams:{metricKey:"memcacheService.currentConnections"},chartProps:{chartType:o.ChartType.ONELINE,scale:{y:{alias:t("Current Connections")}}}},{title:t("Total Connections"),createFetchParams:{metricKey:"memcacheService.totalConnections"},chartProps:{chartType:o.ChartType.ONELINE,scale:{y:{alias:t("Total Connections")}}}},{title:t("Read And Write"),createFetchParams:{metricKey:"memcacheService.readWriteBytesTotal"},handleDataParams:{modifyKeys:[t("read"),t("write")]},chartProps:{chartType:o.ChartType.MULTILINE,scale:{y:{formatter:e=>(0,d.getSuitableValue)(e,"traffic",0)}}}},{title:t("Evictions"),createFetchParams:{metricKey:"memcacheService.evictions"},chartProps:{chartType:o.ChartType.ONELINE,scale:{y:{alias:t("Evictions")}}}},{title:t("Items in Cache"),createFetchParams:{metricKey:"memcacheService.itemsInCache"},chartProps:{chartType:o.ChartType.ONELINE,scale:{y:{alias:t("Items in Cache")}}}}]};a.chartConfig=c;a.default=e=>{var{type:t}=e;return i.default.createElement(s.default,{type:t,chartConfig:c,fetchNodesFunc:u.getMemcacheNodes})}},4065:function(e,t,a){var r=a(4066);"string"==typeof r&&(r=[[e.i,r,""]]);var n={hmr:!0,transform:undefined,insertInto:void 0};a(75)(r,n);r.locals&&(e.exports=r.locals)},4066:function(e,t,a){(t=e.exports=a(74)(!1)).push([e.i,".index__header--2QIxy {\n color: rgba(0, 0, 0, 0.85);\n font-weight: 500;\n font-size: 16px;\n line-height: 22px;\n}\n.index__list--2MUu4 {\n background-color: #fff;\n -webkit-box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.05);\n box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.05);\n}\n.index__list--2MUu4 .index__item--vVdTT {\n height: 76px;\n}\n.index__list--2MUu4 .index__item--vVdTT .index__title--13rNn {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n color: rgba(0, 0, 0, 0.65);\n font-weight: 400;\n font-size: 16px;\n}\n.index__list--2MUu4 .index__item--vVdTT .index__status--1Jr4w {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n color: rgba(0, 0, 0, 0.65);\n font-weight: 400;\n font-size: 14px;\n}\n.index__container--12Azg {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n height: 100%;\n}\n.index__container--12Azg .index__content--50gtm {\n -webkit-box-flex: 1;\n -ms-flex-positive: 1;\n flex-grow: 1;\n overflow: auto;\n}\n",""]),t.locals={header:"index__header--2QIxy",list:"index__list--2MUu4",item:"index__item--vVdTT",title:"index__title--13rNn",status:"index__status--1Jr4w",container:"index__container--12Azg",content:"index__content--50gtm"}},4067:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0,a(1198);var l=n(a(1199));a(1196);var i=n(a(1197)),s=n(a(0)),u=n(a(1263)),o=(a(173),n(a(1603))),d=a(1309),c=n(a(1353)),f=n(a(4069)),m=a(4070),p={renderNodeSelect:!1,renderTimeRangeSelect:!1},v=()=>s.default.createElement(u.default,p,s.default.createElement(l.default,{gutter:[16,16],className:c.default.container},s.default.createElement(i.default,{span:24},s.default.createElement(f.default,null)),s.default.createElement(i.default,{span:24},s.default.createElement(l.default,{gutter:[16,16]},s.default.createElement(i.default,{span:12},s.default.createElement(o.default,{topCardList:m.physicalNodeLeftTopCardList})),s.default.createElement(i.default,{span:12},s.default.createElement(o.default,{topCardList:m.physicalNodeRightTopCardList})))),s.default.createElement(i.default,{span:24},s.default.createElement(o.default,{baseTopCardProps:{span:12,createFetchParams:{requestType:"current"},handleDataParams:{formatDataFn:d.handleResponses},visibleHeight:200,renderContent:e=>s.default.createElement("div",{className:c.default["top-content"]},e.data)},topCardList:m.topCardList})),s.default.createElement(i.default,{span:24},s.default.createElement(l.default,{gutter:[16,16]},s.default.createElement(i.default,{span:12},s.default.createElement(o.default,{topCardList:m.storageLeftCardList})),s.default.createElement(i.default,{span:12},s.default.createElement(o.default,{chartCardList:m.storageRightChartList}))))));t.default=v},4068:function(e,t,a){(t=e.exports=a(74)(!1)).push([e.i,".index__container--10N7f .index__card--3LuCF {\n height: 100%;\n padding: 16px;\n color: #000;\n background-color: #fff;\n -webkit-box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.05), 0 0 10px 0 rgba(0, 0, 0, 0.05);\n box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.05), 0 0 10px 0 rgba(0, 0, 0, 0.05);\n}\n.index__container--10N7f .index__card--3LuCF .index__tabs--1jk3S .ant-tabs-tab {\n margin-right: 20px;\n border-bottom: 1px solid #f0f0f0;\n}\n.index__container--10N7f .index__card--3LuCF .index__tabs--1jk3S .ant-tabs-nav::before {\n border-bottom: none;\n}\n.index__container--10N7f .index__alert-card-line--10YeJ {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-orient: vertical;\n -webkit-box-direction: normal;\n -ms-flex-direction: column;\n flex-direction: column;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n}\n.index__container--10N7f .index__alert-card-line--10YeJ .index__number--17oxK {\n color: #e86804;\n font-size: 36px;\n}\n.index__outer--3WpA3 {\n position: relative;\n width: 100%;\n height: 100%;\n overflow: hidden;\n font-size: 14px;\n}\n.index__outer--3WpA3 .index__inner--1jNf7 {\n position: absolute;\n left: 0;\n width: 100%;\n height: 100%;\n overflow-x: hidden;\n overflow-y: scroll;\n}\n.index__outer--3WpA3 .index__inner--1jNf7::-webkit-scrollbar {\n display: none;\n}\n.index__top-content--3X_Di {\n display: -webkit-box;\n display: -ms-flexbox;\n display: flex;\n -webkit-box-align: center;\n -ms-flex-align: center;\n align-items: center;\n -webkit-box-pack: center;\n -ms-flex-pack: center;\n justify-content: center;\n height: 100px;\n font-weight: 500;\n font-size: 24px;\n}\n.index__tabs--1jk3S .ant-tabs-tab {\n margin-right: 20px;\n border-bottom: 1px solid #f0f0f0;\n}\n.index__tabs--1jk3S .ant-tabs-nav::before {\n border-bottom: none;\n}\n",""]),t.locals={container:"index__container--10N7f",card:"index__card--3LuCF",tabs:"index__tabs--1jk3S","alert-card-line":"index__alert-card-line--10YeJ",number:"index__number--17oxK",outer:"index__outer--3WpA3",inner:"index__inner--1jNf7","top-content":"index__top-content--3X_Di"}},4069:function(e,a,r){"use strict";var n=r(160),l=r(19),i=r(25),s=r(21);l(a,"__esModule",{value:!0}),a.default=void 0,r(422);var u=s(r(425));r(1198);var o=s(r(1199));r(1196);var d=s(r(1197));r(337);var c=s(r(338)),f=s(r(51)),m=s(r(27)),p=s(r(174)),v=s(r(57)),h=s(r(65)),g=function(e,t){if(!t&&e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var a=S(t);if(a&&a.has(e))return a.get(e);var r={},n=l&&i;for(var s in e)if("default"!==s&&Object.prototype.hasOwnProperty.call(e,s)){var u=n?i(e,s):null;u&&(u.get||u.set)?l(r,s,u):r[s]=e[s]}r.default=e,a&&a.set(e,r);return r}(r(0)),y=(r(173),s(r(1353))),b=r(1309),_=s(r(119)),x=r(1415),C=r(1295);function S(e){if("function"!=typeof n)return null;var t=new n,a=new n;return(S=function(e){return e?a:t})(e)}function D(e){var{data:a}=e;return g.default.createElement("div",{className:y.default.card},g.default.createElement(o.default,{justify:"space-between"},g.default.createElement("span",null,t("Last week alarm trend")),g.default.createElement("span",null,t("time / 24h"))),g.default.createElement(o.default,{justify:"center",align:"middle",style:{height:272,paddingTop:10}},0===a.length?g.default.createElement(u.default,null):g.default.createElement(w,{data:a})))}function w(e){var{data:t}=e;return g.default.createElement(C.Chart,{padding:[10,20,50,50],autoFit:!0,data:t,scale:{count:{nice:!0}}},g.default.createElement(C.Line,{position:"date*count"}),g.default.createElement(C.Tooltip,{showCrosshairs:!0,lock:!0}))}var E=function(){var e=(0,x.createFetchPrometheusClient)({requestType:"range",metricKey:"monitorOverview.alertInfo"}),a=(0,x.createDataHandler)({formatDataFn:(e,t,a,r)=>{var n=[];return(0,m.default)(e).call(e,((e,l)=>{n.push((0,b.handleResponse)(e,t,a,r[l]))})),n},modifyKeys:["cpu","memory"]}),[r,n]=(0,g.useState)(!0),[l,i]=(0,g.useState)(0),[s,u]=(0,g.useState)(0),[C,S]=(0,g.useState)(function(){for(var e=(0,_.default)().startOf("day"),t=[],a=6;a>=0;a--)t.push({fullDate:e.clone().subtract(a,"day").format("YYYY-MM-DD"),date:e.clone().subtract(a,"day").format("MM-DD"),count:0});return t}()),w=function(){var t=(0,f.default)((function*(t){var r=(0,_.default)(t).endOf("day"),n=(0,_.default)(t).startOf("day"),l=yield e({interval:15,currentRange:[n,r]}),[i,s]=a(l).retData,u=(0,p.default)(i).call(i,((e,t,a)=>a>0&&t.x-i[a-1].x>15?e+1:e),0),o=(0,p.default)(s).call(s,((e,t,a)=>a>0&&t.x-s[a-1].x>15?e+1:e),0);return{date:t,total:u+o,cpuTotal:u,memTotal:o}}));return function(e){return t.apply(this,arguments)}}(),E=function(){var e=(0,f.default)((function*(){n(!0);var e=(0,v.default)(C).call(C,(e=>{var{fullDate:t}=e;return w(t)}));try{var t=yield h.default.all(e);(0,m.default)(t).call(t,((e,a)=>{var{total:r,cpuTotal:n,memTotal:l}=e;a===t.length-1&&(i(n),u(l)),C[a].count=r}))}catch(e){}S([...C]),n(!1)}));return function(){return e.apply(this,arguments)}}();return(0,g.useEffect)((()=>{E()}),[]),r?g.default.createElement(c.default,null):g.default.createElement(o.default,{gutter:[16,16]},g.default.createElement(d.default,{flex:"1 1"},g.default.createElement("div",{className:y.default.card},g.default.createElement(o.default,{style:{height:"100%"}},g.default.createElement(d.default,{span:12,className:y.default["alert-card-line"]},g.default.createElement("div",{className:y.default.number},l),g.default.createElement("div",null,t("Today CPU usage > 80% alert"))),g.default.createElement(d.default,{span:12,className:y.default["alert-card-line"]},g.default.createElement("div",{className:y.default.number},s),g.default.createElement("div",null,t("Today Memory usage > 80% alert")))))),g.default.createElement(d.default,{flex:"0 1 440px"},g.default.createElement(D,{data:C})))};a.default=E},4070:function(e,a,r){"use strict";var n=r(33),l=r(44),i=r(32),s=r(25),u=r(27),o=r(45),d=r(46),c=r(19),f=r(21);c(a,"__esModule",{value:!0}),a.storageRightChartList=a.storageLeftCardList=a.topCardList=a.physicalNodeRightTopCardList=a.physicalNodeLeftTopCardList=void 0;var m=f(r(81)),p=f(r(27)),v=f(r(229)),h=f(r(419)),g=f(r(36));r(1222);var y=f(r(1223));r(1198);var b=f(r(1199)),_=f(r(111)),x=f(r(0)),C=(r(173),r(161)),S=r(1352),D=f(r(1606)),w=r(1309),E=r(1209),I=f(r(140)),P=r(4071),T=f(r(1353));function k(e,t){var a=n(e);if(l){var r=l(e);t&&(r=i(r).call(r,(function(t){return s(e,t).enumerable}))),a.push.apply(a,r)}return a}function N(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)u(a=k(Object(r),!0)).call(a,(function(t){(0,g.default)(e,t,r[t])}));else if(o)d(e,o(r));else{var n;u(n=k(Object(r))).call(n,(function(t){c(e,t,s(r,t))}))}}return e}var M=[{title:t("Physical CPU Usage"),span:12,createFetchParams:{metricKey:"monitorOverview.physicalCPUUsage"},renderContent:e=>{var t,{data:a}=e,r=(0,_.default)(a[0],"y",0),n=(0,_.default)(a[1],"y",0);return x.default.createElement("div",{className:T.default["top-content"]},x.default.createElement("div",null,x.default.createElement(b.default,{style:{alignItems:"baseline",justifyContent:"center"}},x.default.createElement("span",{style:{fontSize:28,fontWeight:600}},(0,C.computePercentage)(r,n)),"%"),x.default.createElement(b.default,{style:{alignItems:"baseline",justifyContent:"center",fontSize:12}},(0,m.default)(t="".concat(r," / ")).call(t,n))))}},{title:t("Total Ram"),span:12,createFetchParams:{metricKey:"monitorOverview.physicalMemoryUsage"},renderContent:e=>{var t,{data:a}=e,r=(0,_.default)(a[0],"y",0),n=(0,_.default)(a[1],"y",0),l=(0,S.getSuitableValue)(r,"memory"),i=(0,S.getSuitableValue)(n,"memory");return x.default.createElement("div",{className:T.default["top-content"]},x.default.createElement("div",null,x.default.createElement(b.default,{style:{alignItems:"baseline",justifyContent:"center"}},x.default.createElement("span",{style:{fontSize:28,fontWeight:600}},(0,C.computePercentage)(r,n)),"%"),x.default.createElement(b.default,{style:{alignItems:"baseline",justifyContent:"center",fontSize:12}},(0,m.default)(t="".concat(l," / ")).call(t,i))))}},{title:t("Physical Storage Usage"),span:24,createFetchParams:{metricKey:"monitorOverview.physicalStorageUsage"},renderContent:e=>{var a,r,n,{data:l}=e,i=(0,_.default)(l[0],"y",0),s=(0,_.default)(l[1],"y",0),u=(0,S.getSuitableValue)(i,"disk"),o=(0,S.getSuitableValue)(s,"disk"),d=(0,C.computePercentage)(i,s);return x.default.createElement("div",{className:T.default["top-content"]},x.default.createElement("div",{style:{width:"100%",height:"100%"}},x.default.createElement(b.default,{style:{justifyContent:"flex-end",height:"50%"}},x.default.createElement("span",{style:{fontSize:12,marginRight:32}},(0,m.default)(a=(0,m.default)(r=(0,m.default)(n="".concat(t("Used")," ")).call(n,u," / ")).call(r,t("Total")," ")).call(a,o))),x.default.createElement(b.default,{style:{height:"50%"}},x.default.createElement(y.default,{style:{width:"95%"},percent:d,strokeColor:d>80?"#FAAD14":"#1890FF",showInfo:100!==d}))))}}];a.physicalNodeLeftTopCardList=M;var L=[{visibleHeight:319,createFetchParams:{requestType:"current",metricKey:"monitorOverview.computeNodeStatus"},handleDataParams:{formatDataFn:e=>{var t=[{type:"up",value:0},{type:"down",value:0}],a=(0,_.default)(e[0],"data.result",[]);return(0,p.default)(a).call(a,(e=>{var a="enabled"===e.metric.adminState?0:1;t[a].value+=(0,v.default)(e.value[1],10)})),t}},title:t("Compute Node status"),renderContent:e=>{var{data:t}=e;return x.default.createElement("div",{style:{height:309}},x.default.createElement(D.default,{data:t}))}}];a.physicalNodeRightTopCardList=L;var F=[{title:t("Host CPU Usage"),span:12,createFetchParams:{metricKey:"monitorOverview.topHostCPUUsage"},handleDataParams:{typeKey:"instance"},renderContent:P.renderTopProgress},{title:t("Host Disk Average IOPS"),span:12,createFetchParams:{metricKey:"monitorOverview.topHostDiskIOPS"},handleDataParams:{formatDataFn:(e,t,a,r)=>{var n=[];return(0,p.default)(e).call(e,((e,t)=>{var a;(0,p.default)(a=e.data.result||[]).call(a,(e=>{n.push({x:e.metric.instance,y:(0,h.default)((0,_.default)(e,"value[1]",0)),type:r[t]})}))})),n},modifyKeys:[t("read"),t("write")]},extra:P.renderTopColumnExtra,renderContent:P.renderTopColumnChart},{title:t("Host Memory Usage"),span:12,createFetchParams:{metricKey:"monitorOverview.topHostMemoryUsage"},handleDataParams:{typeKey:"instance"},renderContent:P.renderTopProgress},{title:t("Host Average Network IO"),span:12,createFetchParams:{metricKey:"monitorOverview.topHostInterface"},handleDataParams:{formatDataFn:(e,t,a,r)=>{var n=[];return(0,p.default)(e).call(e,((e,t)=>{var a;(0,p.default)(a=e.data.result||[]).call(a,(e=>{n.push({x:e.metric.instance,y:(0,h.default)((0,_.default)(e,"value[1]",0)),type:r[t]})}))})),n},modifyKeys:[t("receive"),t("transmit")]},extra:P.renderTopColumnExtra,renderContent:e=>{var t=(0,P.renderTopColumnChart)(e);return x.default.cloneElement(t,N(N({},t.props),{},{scale:{y:{nice:!0,formatter:e=>(0,S.getSuitableValue)(e,"traffic",0)}}}))}}];a.topCardList=F;var A=[{title:t("Storage Cluster Status"),span:24,createFetchParams:{metricKey:"monitorOverview.cephHealthStatus"},renderContent:e=>{var t=(0,_.default)(e.data,"y",0);return x.default.createElement("div",{className:T.default["top-content"],style:{fontSize:28,fontWeight:600,color:S.cephStatusColorMap[t],height:65}},S.cephStatusMap[t])}},{title:t("Storage Cluster Usage"),span:12,createFetchParams:{metricKey:"monitorOverview.cephStorageUsage"},renderContent:e=>{var t,{data:a}=e,r=(0,_.default)(a[0],"y",0),n=(0,_.default)(a[1],"y",0),l=(0,S.getSuitableValue)(r,"disk"),i=(0,S.getSuitableValue)(n,"disk");return x.default.createElement("div",{className:T.default["top-content"]},x.default.createElement("div",null,x.default.createElement(b.default,{style:{alignItems:"baseline",justifyContent:"center"}},x.default.createElement("span",{style:{fontSize:28,fontWeight:600}},(0,C.computePercentage)(r,n)),"%"),x.default.createElement(b.default,{style:{alignItems:"baseline",justifyContent:"center",fontSize:12}},(0,m.default)(t="".concat(l," / ")).call(t,i))))}},{title:t("Disk allocation (GiB)"),span:12,createFetchParams:{metricKey:"monitorOverview.cephStorageAllocate"},renderContent:e=>{var t,{data:a}=e,r=(0,h.default)((0,_.default)(a[1],"y",0).toFixed(2)),n=(0,h.default)((r-(0,_.default)(a[0],"y",0)).toFixed(2));return x.default.createElement("div",{className:T.default["top-content"]},x.default.createElement("div",null,x.default.createElement(b.default,{style:{alignItems:"baseline",justifyContent:"center"}},x.default.createElement("span",{style:{fontSize:28,fontWeight:600}},(0,C.computePercentage)(n,r)),"%"),x.default.createElement(b.default,{style:{alignItems:"baseline",justifyContent:"center",fontSize:12}},(0,m.default)(t="".concat(n," GiB / ")).call(t,r," GiB"))))},hidden:!I.default.checkEndpoint("cinder")}];a.storageLeftCardList=A;var O=[{title:t("Storage Cluster IOPS"),createFetchParams:{requestType:"range",metricKey:"monitorOverview.cephStorageClusterIOPS"},handleDataParams:{formatDataFn:w.handleResponses,modifyKeys:[t("read"),t("write")]},span:24,chartProps:{chartType:E.ChartType.MULTILINE,height:318,scale:{y:{nice:!0}}}}];a.storageRightChartList=O},4071:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.renderTopColumnChart=t.renderTopColumnExtra=t.renderTopProgress=void 0;var l=n(a(57)),i=n(a(32));a(1260);var s=n(a(1261));a(1198);var u=n(a(1199));a(1196);var o=n(a(1197));a(1222);var d=n(a(1223)),c=n(a(111)),f=n(a(0)),m=(a(173),a(1295)),p=n(a(1353));t.renderTopProgress=e=>{var{data:t}=e;return f.default.createElement(u.default,{style:{height:"100%"}},(0,l.default)(t).call(t,(e=>{var t=(0,c.default)(e,"y",0),a=t>80?"#FAAD14":"#1890FF";return f.default.createElement(o.default,{span:24,key:e.type},f.default.createElement("div",null,e.type),f.default.createElement(d.default,{strokeColor:a,percent:t,style:{marginBottom:4},showInfo:100!==t}))})))};t.renderTopColumnExtra=e=>{var{modifyKeys:t,filterChartData:a}=e;return f.default.createElement(s.default,{className:p.default.tabs,defaultActiveKey:t[0],onChange:e=>a((t=>t.type===e))},(0,l.default)(t).call(t,(e=>f.default.createElement(s.default.TabPane,{tab:e,key:e}))))};t.renderTopColumnChart=e=>{var{data:t,modifyKeys:a}=e;return f.default.createElement(m.Chart,{autoFit:!0,data:t.length<=5?t:(0,i.default)(t).call(t,(e=>e.type===a[0])),height:198,scale:{y:{nice:!0}}},f.default.createElement(m.Interval,{position:"x*y",size:20}))}},4072:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l=n(a(413)),i=n(a(4073)),s=e=>(0,l.default)(i.default,e);t.default=s},4073:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l=n(a(1212)),i=n(a(567)),s=n(a(4074)),u=n(a(1609)),o=n(a(4085)),d=n(a(4089)),c=n(a(4093)),f=n(a(4109)),m=n(a(4113)),p="/database",v=[{path:p,component:l.default,routes:[{path:"".concat(p,"/instances"),component:s.default,exact:!0},{path:"".concat(p,"/instances-admin"),component:s.default,exact:!0},{path:"".concat(p,"/instances/create"),component:u.default,exact:!0},{path:"".concat(p,"/backups"),component:o.default,exact:!0},{path:"".concat(p,"/configurations"),component:d.default,exact:!0},{path:"".concat(p,"/instances/detail/:id"),component:c.default,exact:!0},{path:"".concat(p,"/instances-admin/detail/:id"),component:c.default,exact:!0},{path:"".concat(p,"/backups/detail/:id"),component:m.default,exact:!0},{path:"".concat(p,"/configurations/detail/:id"),component:f.default,exact:!0},{path:"*",component:i.default}]}];t.default=v},4074:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Instances=void 0;var i=l(r(57)),s=l(r(0)),u=r(406),o=l(r(1194)),d=l(r(1221)),c=r(1418),f=r(161),m=l(r(1608));class p extends o.default{init(){this.store=d.default}get name(){return t("database instances")}get actionConfigs(){return this.isAdminPage?m.default.actionConfigsAdmin:m.default.actionConfigs}get policy(){return"instance:index"}get aliasPolicy(){return"trove:instance:index"}get searchFilters(){return[{label:t("Name"),name:"name"},{label:t("Version"),name:"version"},{label:t("Status"),name:"status",options:(0,f.getOptions)(c.InstanceStatus)}]}getColumns(){return[{title:t("ID/Name"),dataIndex:"name",routeName:this.getRouteName("databaseInstanceDetail")},{title:t("Project ID/Name"),dataIndex:"project_name",isHideable:!0,hidden:!this.isAdminPage},{title:t("Datastore"),dataIndex:"type"},{title:t("Datastore Version"),dataIndex:"version",isHideable:!0},{title:t("Host"),dataIndex:"ip",render:e=>e&&e.length?s.default.createElement(s.default.Fragment,null,(0,i.default)(e).call(e,(e=>s.default.createElement("div",{key:e},e)))):"-",isHideable:!0},{title:t("Database Disk (GiB)"),dataIndex:"size",isHideable:!0,unit:"GiB"},{title:t("Status"),dataIndex:"status",valueMap:c.InstanceStatus}]}}a.Instances=p;var v=(0,u.inject)("rootStore")((0,u.observer)(p));a.default=v},4075:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(36)),s=r(1193),u=l(r(1221));class o extends s.ConfirmAction{constructor(){super(...arguments),(0,i.default)(this,"allowedCheckFunction",(()=>!0)),(0,i.default)(this,"policy","instance:delete"),(0,i.default)(this,"onSubmit",(e=>u.default.delete({id:e.id})))}get id(){return"delete"}get title(){return t("Delete")}get actionName(){return t("Delete")}get isDanger(){return!0}}a.default=o},4076:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.StepDetails=void 0;var i=l(r(65)),s=l(r(57)),u=l(r(32)),o=l(r(102)),d=l(r(51)),c=l(r(36)),f=l(r(0)),m=r(406),p=l(r(1201)),v=r(34),h=l(r(1221)),g=l(r(1262)),y=l(r(1275));class b extends p.default{constructor(){super(...arguments),(0,c.default)(this,"allowed",(()=>i.default.resolve())),(0,c.default)(this,"onFlavorChange",(e=>{this.updateContext({flavor:e})}))}init(){this.instancesStore=h.default,this.getDatastores(),this.getAvailZones()}get title(){return t("Details *")}get name(){return"Details"}get nameForStateUpdate(){return["flavor","datastore_type"]}get defaultValue(){return{project:this.currentProjectName}}get availableZones(){var e,t;return(0,s.default)(e=(0,u.default)(t=g.default.list.data||[]).call(t,(e=>e.zoneState.available))).call(e,(e=>({value:e.zoneName,label:e.zoneName})))}getAvailZones(){return(0,d.default)((function*(){g.default.fetchListWithoutDetail()}))()}get datastores(){var e;return(0,s.default)(e=h.default.dataList||[]).call(e,(e=>({label:e.name,value:e.name,originData:(0,v.toJS)(e)})))}getDatastores(){return(0,d.default)((function*(){h.default.listDatastores()}))()}get datastoresVersion(){var e,t;if(!this.state.datastore_type)return[];var a=(0,o.default)(e=this.datastores).call(e,(e=>e.label===this.state.datastore_type));return(0,s.default)(t=a.originData.versions||[]).call(t,(e=>({label:e.name,value:e.name})))}getFlavorComponent(){return f.default.createElement(y.default,{onChange:this.onFlavorChange})}get formItems(){return[{name:"project",label:t("Project"),type:"label"},{type:"divider"},{name:"zone",label:t("Availability Zone"),type:"select",placeholder:t("Please select"),options:this.availableZones,required:!0},{name:"instance_name",label:t("Database Instance Name"),type:"input",required:!0},{name:"size",label:t("Database Disk (GiB)"),type:"input-int",min:1,placeholder:t("Size"),required:!0,wrapperCol:{xs:{span:24},sm:{span:18}},onChange:e=>this.updateContext({size:e})},{type:"divider"},{name:"datastore_type",label:t("Datastore Type"),type:"select",options:this.datastores,onChange:()=>{this.resetFormValue(["datastore_version"])},required:!0},{name:"datastore_version",label:t("Datastore Version"),type:"select",options:this.datastoresVersion,required:!0},{type:"divider"},{name:"flavor",label:t("Database Flavor"),component:this.getFlavorComponent(),wrapperCol:{xs:{span:24},sm:{span:18}},required:!0},{name:"locality",label:t("Locality"),type:"select",options:[{label:t("Affinity"),value:"affinity"},{label:t("Anti-Affinity"),value:"anti-affinity"}],tip:t("Specify whether future replicated instances will be created on the same hypervisor (affinity) or on different hypervisors (anti-affinity). This value is ignored if the instance to be launched is a replica.")}]}}a.StepDetails=b;var _=(0,m.inject)("rootStore")((0,m.observer)(b));a.default=_},4077:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.StepNetworking=void 0;var i=l(r(65)),s=l(r(36)),u=r(406),o=l(r(1201));class d extends o.default{constructor(){super(...arguments),(0,s.default)(this,"allowed",(()=>i.default.resolve()))}get title(){return t("Networking *")}get name(){return"Networking"}get defaultValue(){return{project:this.currentProjectName}}get formItems(){return[{name:"project",label:t("Project"),type:"label"},{type:"divider"},{name:"network",label:t("Network"),type:"network-select-table",required:!0}]}}a.StepNetworking=d;var c=(0,u.inject)("rootStore")((0,u.observer)(d));a.default=c},4078:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.StepInitializeDatabases=void 0;var i=l(r(65)),s=l(r(36)),u=r(406),o=l(r(1201)),d=r(556);class c extends o.default{constructor(){super(...arguments),(0,s.default)(this,"allowed",(()=>i.default.resolve()))}get title(){return t("Initialize Databases")}get name(){return"Initialize Databases"}get defaultValue(){return{project:this.currentProjectName}}get formItems(){return[{name:"project",label:t("Project"),type:"label"},{type:"divider"},{name:"initialDatabases",label:t("Initial Databases"),type:"input-name",required:!0,maxLength:64,isDatabaseName:!0},{name:"initialAdminUser",label:t("Initial Admin User"),type:"input-name",required:!0,maxLength:16,isDatabaseUserName:!0},{name:"password",label:t("Password"),type:"input-password",required:!0,otherRule:(0,d.getPasswordOtherRule)("password")},{name:"confirmPassword",label:t("Confirm Password"),type:"input-password",required:!0,dependencies:["password"],otherRule:(0,d.getPasswordOtherRule)("confirmPassword")}]}}a.StepInitializeDatabases=c;var f=(0,u.inject)("rootStore")((0,u.observer)(c));a.default=f},4079:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.StepAdvanced=void 0;var i=l(r(65)),s=l(r(57)),u=l(r(51)),o=l(r(36)),d=r(406),c=l(r(1201)),f=l(r(1221));class m extends c.default{constructor(){super(...arguments),(0,o.default)(this,"allowed",(()=>i.default.resolve()))}init(){this.getConfigurationGroups()}get title(){return t("Initialize Databases")}get name(){return"Initialize Databases"}get configurationGroup(){var e;return(0,s.default)(e=f.default.list.data||[]).call(e,(e=>({label:e.name,value:e.id})))}getConfigurationGroups(){return(0,u.default)((function*(){f.default.listConfigurationGroup()}))()}get formItems(){return[{name:"project",label:t("Project"),type:"label"},{type:"divider"},{name:"configurationGroup",label:t("Configuration Group"),type:"select",options:this.configurationGroup}]}}a.StepAdvanced=m;var p=(0,d.inject)("rootStore")((0,d.observer)(m));a.default=p},4080:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Edit=void 0;var i=l(r(65)),s=l(r(36)),u=r(406),o=r(1193),d=l(r(1221));class c extends o.ModalAction{constructor(){super(...arguments),(0,s.default)(this,"onSubmit",(e=>{var{name:t}=e,a={instance:{name:t}},{id:r}=this.item;return d.default.patch({id:r},a)}))}static allowed(){return i.default.resolve(!0)}get formItems(){return[{name:"name",label:t("Name"),type:"input",required:!0,placeholder:t("Please input name")}]}}a.Edit=c,(0,s.default)(c,"id","edit-instance"),(0,s.default)(c,"title",t("Edit")),(0,s.default)(c,"buttonText",t("Edit")),(0,s.default)(c,"policy","instance:update");var f=(0,u.inject)("rootStore")((0,u.observer)(c));a.default=f},4081:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(36)),s=r(1193),u=r(1195),o=l(r(1221));class d extends s.ConfirmAction{constructor(){super(...arguments),(0,i.default)(this,"policy","instance:restart"),(0,i.default)(this,"allowedCheckFunc",(e=>(0,u.checkStatus)(["active","shutoff","shutdown"],e))),(0,i.default)(this,"onSubmit",(e=>{var{id:t}=e||this.item;return o.default.restart({id:t})}))}get id(){return"restart"}get title(){return t("Restart Database Service")}get isDanger(){return!0}get actionName(){return t("Restart Database Service")}get isAsyncAction(){return!0}}a.default=d},4082:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(36)),s=r(1193),u=r(1195),o=l(r(1221));class d extends s.ConfirmAction{constructor(){super(...arguments),(0,i.default)(this,"policy","instance:stop"),(0,i.default)(this,"allowedCheckFunc",(e=>(0,u.checkStatus)(["active"],e))),(0,i.default)(this,"onSubmit",(e=>{var{id:t}=e||this.item;return o.default.stop({id:t})}))}get id(){return"stop"}get title(){return t("Stop Database Service")}get isDanger(){return!0}get buttonText(){return t("Stop")}get actionName(){return t("Stop Database Service")}get isAsyncAction(){return!0}}a.default=d},4083:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(36)),s=r(1193),u=r(1195),o=l(r(1221));class d extends s.ConfirmAction{constructor(){super(...arguments),(0,i.default)(this,"policy","instance:reboot"),(0,i.default)(this,"allowedCheckFunc",(e=>(0,u.checkStatus)(["active","shutoff","shutdown"],e))),(0,i.default)(this,"onSubmit",(e=>{var{id:t}=e||this.item;return o.default.reboot({id:t})}))}get id(){return"reboot"}get title(){return t("Reboot Database Instance")}get isDanger(){return!0}get actionName(){return t("Reboot Database Instance")}get isAsyncAction(){return!0}}a.default=d},4084:function(e,a,r){"use strict";var n=r(33),l=r(44),i=r(32),s=r(25),u=r(27),o=r(45),d=r(46),c=r(19),f=r(21);c(a,"__esModule",{value:!0}),a.default=a.ResizeVolume=void 0;var m=f(r(81)),p=f(r(65)),v=f(r(51)),h=f(r(36)),g=r(406),y=f(r(1221)),b=f(r(407)),_=r(1193),x=r(1195);function C(e,t){var a=n(e);if(l){var r=l(e);t&&(r=i(r).call(r,(function(t){return s(e,t).enumerable}))),a.push.apply(a,r)}return a}function S(e){for(var t=1;t<arguments.length;t++){var a,r=null!=arguments[t]?arguments[t]:{};if(t%2)u(a=C(Object(r),!0)).call(a,(function(t){(0,h.default)(e,t,r[t])}));else if(o)d(e,o(r));else{var n;u(n=C(Object(r))).call(n,(function(t){c(e,t,s(r,t))}))}}return e}class D extends _.ModalAction{constructor(){super(...arguments),(0,h.default)(this,"onSubmit",(e=>{var{id:t}=this.item,{size:a}=e;return y.default.resizeVolume({id:t,size:a})}))}static get modalSize(){return"large"}getModalSize(){return"large"}init(){this.store=y.default,this.projectStore=b.default,this.getQuota(),this.state.isLoading=!0,this.errorMsg=""}get isQuotaLimited(){var{volumes:{limit:e}={}}=this.projectStore.troveQuota||{};return-1!==e}get maxSize(){var{volumes:{left:e=0}={}}=this.projectStore.troveQuota||{},{size:t=0}=this.item;return e+t}isQuotaEnough(){var{size:e=0}=this.item;return!this.isQuotaLimited||this.maxSize>e}get name(){return t("Resize Volume")}getMinSize(){var{volume:e={}}=this.item,{size:t=1}=e;return t+1}static get disableSubmit(){var{troveQuota:e={}}=b.default;return(e=>{var{volumes:{left:t=0}={}}=e||{};return 0===t})(e)}get showQuota(){return!0}getQuota(){var e=this;return(0,v.default)((function*(){yield e.projectStore.fetchProjectTroveQuota(e.currentProjectId),e.setState({isLoading:!1})}))()}get quotaInfo(){if(this.state.isLoading)return[];var{volumes:e={}}=this.projectStore.troveQuota||{},{size:a=0}=this.state,{left:r=0}=e,{size:n=0}=this.item,l=a-n;return[S(S({},e),{},{add:-1===r||l<=r?l:0,name:"volumeSize",title:t("Database Disk (GiB)"),type:"ring"})]}get isAsyncAction(){return!0}get nameForStateUpdate(){return["size"]}get defaultValue(){var{name:e,volume:t={}}=this.item;return{instance:e,size:this.getMinSize(),oldSize:t.size}}get formItems(){var e;if(this.state.isLoading)return[];if(!this.isQuotaEnough())return[{type:"label",component:t("Quota is not enough for extend volume.")}];var a=this.getMinSize();return[{name:"instance",label:t("Database Instance"),type:"label",iconType:"instance"},{name:"oldSize",label:t("Current Disk (GiB)"),type:"label"},{name:"size",label:t("Database Disk (GiB)"),type:"slider-input",max:this.maxSize,min:a,description:(0,m.default)(e="".concat(a,"GiB-")).call(e,this.maxSize,"GiB"),required:!0,display:this.isQuotaLimited},{name:"size",label:t("Database Disk (GiB)"),type:"input-int",min:a,required:!0,display:!this.isQuotaLimited}]}}a.ResizeVolume=D,(0,h.default)(D,"id","resize-volume"),(0,h.default)(D,"title",t("Resize Volume")),(0,h.default)(D,"policy",["trove:instance:resize_volume","trove:admin"]),(0,h.default)(D,"isActiveOrShutOff",(e=>(0,x.checkStatus)(["active","shutoff"],e))),(0,h.default)(D,"allowed",(e=>p.default.resolve(D.isActiveOrShutOff(e))));var w=(0,g.inject)("rootStore")((0,g.observer)(D));a.default=w},4085:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Backups=void 0;var i=l(r(36)),s=l(r(1194)),u=r(406),o=l(r(1354)),d=l(r(4086));class c extends s.default{constructor(){super(...arguments),(0,i.default)(this,"getColumns",(()=>[{title:t("Name"),dataIndex:"name",routeName:this.getRouteName("databaseBackupDetail")},{title:t("Description"),isHideable:!0,dataIndex:"description"}]))}init(){this.store=o.default}get name(){return t("database backups")}get actionConfigs(){return d.default.actionConfigs}get policy(){return"backup:index"}get searchFilters(){return[{label:t("Name"),name:"name"}]}}a.Backups=c;var f=(0,u.inject)("rootStore")((0,u.observer)(c));a.default=f},4086:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l=n(a(4087)),i=n(a(4088)),s={actionConfigs:{rowActions:{firstAction:i.default},batchActions:[i.default],primaryActions:[l.default]}};t.default=s},4087:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Create=void 0;var i=l(r(65)),s=l(r(57)),u=l(r(51)),o=l(r(36)),d=r(1193),c=r(406),f=l(r(1221)),m=l(r(1354));class p extends d.ModalAction{constructor(){super(...arguments),(0,o.default)(this,"onSubmit",(e=>this.store.create({backup:{description:e.description,instance:e.instance,name:e.name}})))}init(){this.store=m.default,this.getDatabaseInstance()}static get modalSize(){return"middle"}getModalSize(){return"middle"}get name(){return t("Create Database Backup")}static allowed(){return i.default.resolve(!0)}get listInstanceName(){var e;return(0,s.default)(e=f.default.list.data||[]).call(e,(e=>({value:e.id,label:e.name})))}getDatabaseInstance(){return(0,u.default)((function*(){yield f.default.fetchListWithoutDetail()}))()}get formItems(){return[{name:"name",label:t("Name"),type:"input",required:!0},{name:"instance",label:t("Database Instance"),type:"select",options:this.listInstanceName,required:!0},{name:"description",label:t("Description"),type:"input"}]}}a.Create=p,(0,o.default)(p,"id","create-database-backup"),(0,o.default)(p,"title",t("Create Database Backup")),(0,o.default)(p,"policy","backup:create"),(0,o.default)(p,"aliasPolicy","trove:backup:create");var v=(0,c.inject)("rootStore")((0,c.observer)(p));a.default=v},4088:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(36)),s=r(1193),u=l(r(1354));class o extends s.ConfirmAction{constructor(){super(...arguments),(0,i.default)(this,"allowedCheckFunction",(()=>!0)),(0,i.default)(this,"policy","instance:delete"),(0,i.default)(this,"onSubmit",(e=>u.default.delete({id:e.id})))}get id(){return"delete"}get title(){return t("Delete Database Backup")}get actionName(){return t("Delete Database Backup")}get buttonText(){return t("Delete")}get isDanger(){return!0}}a.default=o},4089:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Configurations=void 0;var i=l(r(36)),s=l(r(1194)),u=r(406),o=l(r(1355)),d=l(r(4090));class c extends s.default{constructor(){super(...arguments),(0,i.default)(this,"getColumns",(()=>[{title:t("Configuration Group Name"),dataIndex:"name",routeName:this.getRouteName("configurationsDetail")},{title:t("Description"),isHideable:!0,dataIndex:"description"},{title:t("Datastore"),dataIndex:"datastore"},{title:t("Datastore Version"),dataIndex:"datastoreVersion"}]))}init(){this.store=o.default}get name(){return t("configurations")}get actionConfigs(){return d.default.actionConfigs}get policy(){return"configuration:index"}get searchFilters(){return[{label:t("Name"),name:"name"}]}}a.Configurations=c;var f=(0,u.inject)("rootStore")((0,u.observer)(c));a.default=f},4090:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l=n(a(4091)),i=n(a(4092)),s={actionConfigs:{rowActions:{firstAction:i.default},batchActions:[i.default],primaryActions:[l.default]}};t.default=s},4091:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Create=void 0;var i=l(r(65)),s=l(r(57)),u=l(r(32)),o=l(r(51)),d=l(r(36)),c=r(1193),f=r(406),m=l(r(1221)),p=l(r(1355)),v=r(34);class h extends c.ModalAction{constructor(){super(...arguments),(0,d.default)(this,"onChangeDatastoresTypeChange",(e=>{this.setState({datastore_type:e}),this.resetFormValue(["datastore_version"])})),(0,d.default)(this,"onSubmit",(e=>this.store.create({configuration:{description:e.description,datastore:{type:e.datastore_type,version:e.datastore_version},name:e.name,values:{connect_timeout:200}}})))}init(){this.store=p.default,this.getDatastores(),this.state.datastore_type=null}static get modalSize(){return"middle"}getModalSize(){return"middle"}get name(){return t("Create Configurations")}static allowed(){return i.default.resolve(!0)}getDatastores(){return(0,o.default)((function*(){yield m.default.listDatastores()}))()}get datastores(){var e;return(0,s.default)(e=m.default.dataList||[]).call(e,(e=>({label:e.name,value:e.name,originData:(0,v.toJS)(e)})))}get datastoresVersion(){var e,t;return(0,s.default)(e=(0,u.default)(t=this.datastores).call(t,(e=>e.label===this.state.datastore_type))).call(e,(e=>{var t;return(0,s.default)(t=e.originData.versions).call(t,(e=>({label:e.name,value:e.name})))}))[0]}get formItems(){return[{name:"name",label:t("Name"),type:"input",required:!0},{name:"description",label:t("Description"),type:"input"},{name:"datastore_type",label:t("Datastore Type"),type:"select",options:this.datastores,onChange:e=>{this.onChangeDatastoresTypeChange(e)},required:!0},{name:"datastore_version",label:t("Datastore Version"),type:"select",options:this.datastoresVersion,required:!0}]}}a.Create=h,(0,d.default)(h,"id","create-configurations"),(0,d.default)(h,"title",t("Create Configurations")),(0,d.default)(h,"policy","configuration:create");var g=(0,f.inject)("rootStore")((0,f.observer)(h));a.default=g},4092:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(36)),s=r(1193),u=l(r(1355));class o extends s.ConfirmAction{constructor(){super(...arguments),(0,i.default)(this,"allowedCheckFunction",(()=>!0)),(0,i.default)(this,"policy","instance:delete"),(0,i.default)(this,"onSubmit",(e=>u.default.delete({id:e.id})))}get id(){return"delete"}get title(){return t("Delete Configuration")}get actionName(){return t("Delete Configuration")}get isDanger(){return!0}}a.default=o},4093:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.InstancesDetail=void 0;var i=r(406),s=l(r(1200)),u=l(r(1221)),o=r(1418),d=l(r(4094)),c=l(r(4095)),f=l(r(4100)),m=l(r(4104)),p=l(r(4106)),v=l(r(4108)),h=l(r(1608));class g extends s.default{init(){this.store=u.default}get name(){return t("Backup Detail")}get policy(){return"instance:detail"}get aliasPolicy(){return"trove:instance:detail"}get listUrl(){return this.getRoutePath("databaseInstances")}get detailInfos(){return[{title:t("ID"),dataIndex:"id"},{title:t("Name"),dataIndex:"name"},{title:t("Status"),dataIndex:"status",valueMap:o.InstanceStatus},{title:t("Project ID"),dataIndex:"tenant_id",hidden:!this.isAdminPage}]}get tabs(){return[{title:t("Detail"),key:"general_info",component:d.default},{title:t("Users"),key:"users",component:c.default},{title:t("Databases"),key:"databases",component:f.default},{title:t("Backups"),key:"backups",component:m.default},{title:t("Logs"),key:"logs",component:p.default},{title:t("Defaults"),key:"defaults",component:v.default}]}get actionConfigs(){return this.isAdminPage?h.default.actionConfigsAdmin:h.default.actionConfigs}}a.InstancesDetail=g;var y=(0,i.inject)("rootStore")((0,i.observer)(g));a.default=y},4094:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.BaseDetail=void 0;var i=l(r(57)),s=l(r(0)),u=r(406),o=l(r(1202)),d=r(1418);class c extends o.default{get leftCards(){return[this.baseInfoCard,this.specsCard,this.connectionInfoCard]}get rightCards(){return[this.faultCard]}get baseInfoCard(){var e=[{label:t("Name"),dataIndex:"name"},{label:t("Datastore"),dataIndex:"type"},{label:t("Datastore Version"),dataIndex:"version"},{label:t("Status"),dataIndex:"status",valueMap:d.InstanceStatus},{label:t("Locality"),dataIndex:"locality",valueMap:d.policyType}];return{title:t("Base Info"),options:e}}get specsCard(){var e=[{label:t("Database Flavor"),dataIndex:"flavor",render:e=>this.getLinkRender("flavorDetail",e.name,{id:e.id},null)},{label:t("Volume Size"),dataIndex:"size",unit:"GiB"},{label:t("Created"),dataIndex:"created",valueRender:"toLocalTime"},{label:t("Updated"),dataIndex:"updated",valueRender:"toLocalTime"},{label:t("Service Status Updated"),dataIndex:"service_status_update"}];return{title:t("Specs"),options:e}}get connectionInfoCard(){var e=[{label:t("Host"),dataIndex:"ip",render:e=>e&&e.length?s.default.createElement("span",null,(0,i.default)(e).call(e,(e=>s.default.createElement("div",{key:e},e)))):"-"},{label:t("Database Port"),dataIndex:"type",render:e=>{switch(e){case"mysql":return"3306";case"mongodb":return"27017";case"postgresql":return"5432"}}},{label:t("Connection Examples"),dataIndex:"connection_examples"}];return{title:t("Connection Information"),options:e}}get faultCard(){var e=[{label:t("Created"),dataIndex:"created",valueRender:"toLocalTime"},{label:t("Message"),dataIndex:"fault.message"},{label:t("Message Details"),dataIndex:"fault.details"}];return{title:t("Fault"),labelCol:2,options:e}}}a.BaseDetail=c;var f=(0,u.inject)("rootStore")((0,u.observer)(c));a.default=f},4095:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Users=void 0;var i=l(r(57)),s=l(r(36)),u=l(r(0)),o=l(r(1194)),d=r(406),c=r(1356),f=l(r(4096));class m extends o.default{constructor(){super(...arguments),(0,s.default)(this,"getColumns",(()=>[{title:t("User Name"),dataIndex:"name"},{title:t("Allowed Host"),dataIndex:"host"},{title:t("Databases"),dataIndex:"databases",render:e=>e.length?u.default.createElement("span",null,(0,i.default)(e).call(e,(e=>u.default.createElement("div",{key:e},e)))):"-"}]))}init(){this.store=new c.InstancesUsersStore}get rowKey(){return"name"}get name(){return t("Users")}get actionConfigs(){return this.isAdminPage?f.default.actionConfigsAdmin:f.default.actionConfigs}get policy(){return"instance:extension:user:index"}get hideCustom(){return!0}}a.Users=m;var p=(0,d.inject)("rootStore")((0,d.observer)(m));a.default=p},4096:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l=n(a(4097)),i=n(a(4098)),s=n(a(4099)),u={actionConfigs:{rowActions:{firstAction:l.default,moreActions:[{action:s.default}]},batchActions:[l.default],primaryActions:[i.default]},actionConfigsAdmin:{rowActions:{firstAction:l.default},batchActions:[l.default],primaryActions:[]}};t.default=u},4097:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(36)),s=r(1193),u=l(r(1356));class o extends s.ConfirmAction{constructor(){super(...arguments),(0,i.default)(this,"allowedCheckFunction",(()=>!0)),(0,i.default)(this,"policy","instance:extension:user:delete"),(0,i.default)(this,"onSubmit",(e=>{var{id:t}=this.containerProps.detail,a=e.name||this.item.name;return u.default.deleteUser({id:t,name:a})}))}get id(){return"delete-database-user"}get title(){return t("Delete User")}get actionName(){return t("Delete User")}get isDanger(){return!0}get buttonText(){return t("Delete")}}a.default=o},4098:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.UserCreate=void 0;var i=l(r(57)),s=l(r(65)),u=l(r(51)),o=l(r(36)),d=r(406),c=l(r(1325)),f=l(r(1356)),m=r(1310),p=r(556);class v extends c.default{constructor(){super(...arguments),(0,o.default)(this,"onSubmit",(e=>{var t,{id:a}=this.item;return this.store.create(a,{users:[{databases:(0,i.default)(t=e.database).call(t,(e=>({name:e}))),name:e.userName,password:e.password}]})}))}init(){var e=this;return(0,u.default)((function*(){e.store=f.default,e.databaseStore=new m.InstancesDatabasesStore,yield e.fetchDatabase()}))()}get name(){return t("Create User")}static allowed(){return s.default.resolve(!0)}fetchDatabase(){var{id:e}=this.item;this.databaseStore.fetchList({id:e})}get database(){var e;return(0,i.default)(e=this.databaseStore.list.data||[]).call(e,(e=>({label:e.name,value:e.name,key:e.name})))}get formItems(){return[{name:"userName",label:t("Name"),type:"input-name",required:!0,isDatabaseUserName:!0,maxLength:16},{name:"database",label:t("Database"),type:"select",options:this.database,mode:"multiple",required:!0},{name:"password",label:t("Password"),type:"input-password",required:!0,otherRule:(0,p.getPasswordOtherRule)("password")},{name:"confirmPassword",label:t("Confirm Password"),type:"input-password",required:!0,dependencies:["password"],otherRule:(0,p.getPasswordOtherRule)("confirmPassword")}]}}a.UserCreate=v,(0,o.default)(v,"id","create-user"),(0,o.default)(v,"title",t("Create User")),(0,o.default)(v,"policy","instance:extension:user:create");var h=(0,d.inject)("rootStore")((0,d.observer)(v));a.default=h},4099:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.UserDatabase=void 0;var i=l(r(57)),s=l(r(65)),u=l(r(51)),o=l(r(36)),d=r(406),c=l(r(1325)),f=l(r(1356)),m=r(1310);class p extends c.default{constructor(){super(...arguments),(0,o.default)(this,"onSubmit",((e,t)=>{var a,{detail:{id:r}={}}=t,n={databases:(0,i.default)(a=e.database).call(a,(e=>({name:e})))};return this.store.grantDatabaseAccess({id:r,name:e.name,data:n})}))}init(){this.store=f.default,this.databaseStore=new m.InstancesDatabasesStore,this.fetchDatabase()}get name(){return t("Grant Databases Access")}static allowed(){return s.default.resolve(!0)}fetchDatabase(){var e=this;return(0,u.default)((function*(){var{containerProps:{detail:{id:t}={}}={}}=e.props;yield e.databaseStore.fetchList({id:t}),e.updateDefaultValue()}))()}get database(){var e;return(0,i.default)(e=this.databaseStore.list.data||[]).call(e,(e=>({label:e.name,value:e.name,key:e.name})))}get defaultValue(){var{name:e,databases:t}=this.item;return{name:e,database:t}}get formItems(){return[{name:"name",label:t("Name"),type:"input-name",required:!0,disabled:!0},{name:"database",label:t("Database"),type:"select",options:this.database,mode:"multiple",required:!0,loading:this.databaseStore.list.isLoading,disabled:this.databaseStore.list.isLoading}]}}a.UserDatabase=p,(0,o.default)(p,"id","grant-databases-access"),(0,o.default)(p,"title",t("Grant Databases Access")),(0,o.default)(p,"policy","instance:extension:user_access:update");var v=(0,d.inject)("rootStore")((0,d.observer)(p));a.default=v},4100:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Databases=void 0;var i=l(r(36)),s=l(r(1194)),u=r(406),o=r(1310),d=l(r(4101));class c extends s.default{constructor(){super(...arguments),(0,i.default)(this,"getColumns",(()=>[{title:t("Database Name"),dataIndex:"name"}]))}init(){this.store=new o.InstancesDatabasesStore}get rowKey(){return"name"}get name(){return"Databases"}get policy(){return"instance:extension:database:index"}get actionConfigs(){return this.isAdminPage?d.default.actionConfigsAdmin:d.default.actionConfigs}get hideCustom(){return!0}}a.Databases=c;var f=(0,u.inject)("rootStore")((0,u.observer)(c));a.default=f},4101:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=void 0;var l=n(a(4102)),i=n(a(4103)),s={actionConfigs:{rowActions:{firstAction:l.default},batchActions:[l.default],primaryActions:[i.default]},actionConfigsAdmin:{rowActions:{firstAction:l.default},batchActions:[l.default],primaryActions:[]}};t.default=s},4102:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=void 0;var i=l(r(36)),s=r(1193),u=l(r(1310));class o extends s.ConfirmAction{constructor(){super(...arguments),(0,i.default)(this,"allowedCheckFunction",(()=>!0)),(0,i.default)(this,"policy","instance:extension:database:delete"),(0,i.default)(this,"onSubmit",(e=>{var{id:t}=this.containerProps.detail,a=e.name||this.item.name;return u.default.deleteDatabase({id:t,name:a})}))}get id(){return"delete-database-database"}get title(){return t("Delete Database")}get actionName(){return t("Delete Database")}get isDanger(){return!0}get buttonText(){return t("Delete")}}a.default=o},4103:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.DatabaseCreate=void 0;var i=l(r(65)),s=l(r(36)),u=r(406),o=l(r(1325)),d=l(r(1310));class c extends o.default{constructor(){super(...arguments),(0,s.default)(this,"onSubmit",(e=>{var{id:t}=this.item;return this.store.create(t,{databases:[{character_set:"utf8",collate:"utf8_general_ci",name:e.databaseName}]})}))}init(){this.store=d.default}get name(){return t("Create Database")}static allowed(){return i.default.resolve(!0)}get formItems(){return[{name:"databaseName",label:t("Name"),type:"input-name",required:!0,isDatabaseName:!0,maxLength:64}]}}a.DatabaseCreate=c,(0,s.default)(c,"id","create-database"),(0,s.default)(c,"title",t("Create Database")),(0,s.default)(c,"policy","instance:extension:database:create");var f=(0,u.inject)("rootStore")((0,u.observer)(c));a.default=f},4104:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Backups=void 0;var i=l(r(36)),s=l(r(1194)),u=r(406),o=r(4105);class d extends s.default{constructor(){super(...arguments),(0,i.default)(this,"getColumns",(()=>[{title:t("Name"),dataIndex:"name"},{title:t("Created"),dataIndex:"created"},{title:t("Backup File"),dataIndex:"locationRef"},{title:t("Incremental"),dataIndex:"incremental"},{title:t("Status"),dataIndex:"status"}]))}init(){this.store=new o.InstanceBackupsStore}get name(){return t("Backups")}get policy(){return"instance:backups"}}a.Backups=d;var c=(0,u.inject)("rootStore")((0,u.observer)(d));a.default=c},4105:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=t.InstanceBackupsStore=void 0;var l=n(a(53)),i=n(a(48));class s extends l.default{get client(){return i.default.trove.instances.backups}get responseKey(){return"backup"}get isSubResource(){return!0}get paramsFunc(){return()=>{}}}t.InstanceBackupsStore=s;var u=new s;t.default=u},4106:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Logs=void 0;var i=l(r(36)),s=l(r(1194)),u=r(406),o=r(4107);class d extends s.default{constructor(){super(...arguments),(0,i.default)(this,"getColumns",(()=>[{title:t("Name"),dataIndex:"name"}]))}init(){this.store=new o.InstancesLogStore}get name(){return t("Log")}get policy(){return"instance:guest_log_list"}}a.Logs=d;var c=(0,u.inject)("rootStore")((0,u.observer)(d));a.default=c},4107:function(e,t,a){"use strict";var r=a(19),n=a(21);r(t,"__esModule",{value:!0}),t.default=t.InstancesLogStore=void 0;var l=n(a(53)),i=n(a(48));class s extends l.default{get client(){return i.default.trove.instances.log}get responseKey(){return"logs"}get isSubResource(){return!0}get paramsFunc(){return()=>{}}}t.InstancesLogStore=s;var u=new s;t.default=u},4108:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Defaults=void 0;var i=l(r(111)),s=l(r(1202)),u=r(406);class o extends s.default{get leftCards(){return[this.baseInfoCard]}get baseInfoCard(){var e=[{label:t("Number of Nodes"),dataIndex:"node_groups",render:e=>(0,i.default)(e,["0","count"],"-")}];return{title:t("Defaults"),options:e}}}a.Defaults=o;var d=(0,u.inject)("rootStore")((0,u.observer)(o));a.default=d},4109:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.ConfigurationsDetail=void 0;var i=r(406),s=l(r(1200)),u=l(r(1355)),o=l(r(4110)),d=l(r(4111)),c=l(r(4112));class f extends s.default{init(){this.store=u.default}get name(){return"Configurations Detail"}get listUrl(){return this.getRoutePath("configurations")}get policy(){return"configuration:show"}get detailInfos(){return[{title:t("Name"),dataIndex:"name"}]}get tabs(){return[{title:t("Detail"),key:"general_info",component:o.default},{title:t("Values"),key:"values",component:d.default},{title:t("Instances"),key:"instances",component:c.default}]}}a.ConfigurationsDetail=f;var m=(0,i.inject)("rootStore")((0,i.observer)(f));a.default=m},4110:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.BaseDetail=void 0;var i=r(406),s=l(r(1202));class u extends s.default{get leftCards(){return[this.baseInfoCard]}get baseInfoCard(){var e=[{label:t("Name"),dataIndex:"name"},{label:t("Description"),dataIndex:"description"},{label:t("Datastore"),dataIndex:"datastore_name"},{label:t("Datastore Version"),dataIndex:"datastore_version_name"},{label:t("Created"),dataIndex:"created"},{label:t("Updated"),dataIndex:"updated"}];return{title:t("Base Info"),options:e}}}a.BaseDetail=u;var o=(0,i.inject)("rootStore")((0,i.observer)(u));a.default=o},4111:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Values=void 0;var i=l(r(1202)),s=r(406);class u extends i.default{get leftCards(){return[this.baseInfoCard]}get baseInfoCard(){var e=[{label:t("Values"),dataIndex:"values"}];return{title:t("Defaults"),options:e}}}a.Values=u;var o=(0,s.inject)("rootStore")((0,s.observer)(u));a.default=o},4112:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.Instances=void 0;var i=l(r(1202)),s=r(406);class u extends i.default{get leftCards(){return[this.baseInfoCard]}get baseInfoCard(){var e=[{label:t("Instances"),dataIndex:"instance_count"}];return{title:t("Defaults"),options:e}}}a.Instances=u;var o=(0,s.inject)("rootStore")((0,s.observer)(u));a.default=o},4113:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.BackupsDetail=void 0;var i=r(406),s=l(r(1200)),u=r(1354),o=l(r(4114));class d extends s.default{init(){this.store=new u.BackupsStore}get name(){return t("Database Backup Detail")}get listUrl(){return this.getRoutePath("databaseBackups")}get policy(){return"backup:show"}get detailInfos(){return[{title:t("Name"),dataIndex:"name"},{title:t("Description"),dataIndex:"description"}]}get tabs(){return[{title:t("Detail"),key:"general_info",component:o.default}]}}a.BackupsDetail=d;var c=(0,i.inject)("rootStore")((0,i.observer)(d));a.default=c},4114:function(e,a,r){"use strict";var n=r(19),l=r(21);n(a,"__esModule",{value:!0}),a.default=a.BaseDetail=void 0;var i=r(406),s=l(r(1202));class u extends s.default{get leftCards(){return[this.baseInfoCard]}get baseInfoCard(){var e=[{label:t("Datastore"),dataIndex:"datastore.type"},{label:t("Datastore Version"),dataIndex:"datastore.version"},{label:t("Backup File Location"),dataIndex:"locationRef"},{label:t("Initial Volume Size"),dataIndex:"size"},{label:t("Created"),dataIndex:"created"},{label:t("Updated"),dataIndex:"updated"},{label:t("Status"),dataIndex:"status"}];return{title:t("Base Info"),options:e}}}a.BaseDetail=u;var o=(0,i.inject)("rootStore")((0,i.observer)(u));a.default=o}}]); |