ydb-embedded-ui 5.2.1 → 5.4.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/components/BasicNodeViewer/BasicNodeViewer.js +1 -1
- package/dist/components/ButtonWithConfirmDialog/ButtonWithConfirmDialog.d.ts +13 -0
- package/dist/components/ButtonWithConfirmDialog/ButtonWithConfirmDialog.js +32 -0
- package/dist/components/CellWithPopover/CellWithPopover.js +1 -11
- package/dist/components/ClipboardButton/ClipboardButton.js +1 -11
- package/dist/components/ComponentsProvider/ComponentsProvider.d.ts +2 -2
- package/dist/components/ComponentsProvider/componentsRegistry.d.ts +1 -1
- package/dist/components/ComponentsProvider/registry.d.ts +3 -3
- package/dist/components/ContentWithPopup/ContentWithPopup.js +1 -11
- package/dist/components/CriticalActionDialog/CriticalActionDialog.d.ts +6 -4
- package/dist/components/CriticalActionDialog/CriticalActionDialog.js +32 -7
- package/dist/components/CriticalActionDialog/CriticalActionDialog.scss +8 -19
- package/dist/components/CriticalActionDialog/i18n/en.json +7 -0
- package/dist/components/CriticalActionDialog/i18n/index.d.ts +1 -0
- package/dist/components/CriticalActionDialog/i18n/index.js +4 -0
- package/dist/components/EnableFullscreenButton/EnableFullscreenButton.js +2 -2
- package/dist/components/EntityStatus/EntityStatus.d.ts +20 -37
- package/dist/components/EntityStatus/EntityStatus.js +17 -66
- package/dist/components/EntityStatus/EntityStatus.scss +1 -57
- package/dist/components/Errors/403/AccessDenied.js +1 -11
- package/dist/components/FormattedBytes/FormattedBytes.d.ts +1 -1
- package/dist/components/FormattedBytes/FormattedBytes.js +1 -11
- package/dist/components/FormattedBytes/utils.d.ts +1 -1
- package/dist/components/Fullscreen/Fullscreen.js +11 -11
- package/dist/components/Illustration/Illustration.js +1 -11
- package/dist/components/InfoViewer/InfoViewer.d.ts +2 -2
- package/dist/components/InfoViewer/InfoViewer.js +1 -1
- package/dist/components/InfoViewer/formatters/cdcStream.d.ts +1 -1
- package/dist/components/InfoViewer/formatters/common.d.ts +1 -1
- package/dist/components/InfoViewer/formatters/pqGroup.d.ts +3 -3
- package/dist/components/InfoViewer/formatters/schema.d.ts +1 -1
- package/dist/components/InfoViewer/formatters/table.d.ts +4 -4
- package/dist/components/InfoViewer/utils.d.ts +3 -3
- package/dist/components/InfoViewerSkeleton/InfoViewerSkeleton.d.ts +7 -0
- package/dist/components/InfoViewerSkeleton/InfoViewerSkeleton.js +7 -0
- package/dist/{containers/Cluster/ClusterInfoSkeleton/ClusterInfoSkeleton.scss → components/InfoViewerSkeleton/InfoViewerSkeleton.scss} +1 -9
- package/dist/components/InternalLink/InternalLink.js +1 -11
- package/dist/components/LinkToSchemaObject/LinkToSchemaObject.js +1 -11
- package/dist/components/LinkWithIcon/LinkWithIcon.d.ts +8 -0
- package/dist/components/LinkWithIcon/LinkWithIcon.js +14 -0
- package/dist/components/{ExternalLinkWithIcon/ExternalLinkWithIcon.scss → LinkWithIcon/LinkWithIcon.scss} +1 -1
- package/dist/components/MetricChart/MetricChart.d.ts +2 -1
- package/dist/components/MetricChart/MetricChart.js +17 -7
- package/dist/components/MetricChart/colors.d.ts +2 -0
- package/dist/components/MetricChart/colors.js +21 -0
- package/dist/components/MetricChart/getChartData.d.ts +2 -1
- package/dist/components/MetricChart/getChartData.js +2 -2
- package/dist/components/MetricChart/getDefaultDataFormatter.d.ts +1 -1
- package/dist/components/MetricChart/getDefaultDataFormatter.js +9 -0
- package/dist/components/MetricChart/i18n/en.json +3 -0
- package/dist/components/MetricChart/i18n/index.d.ts +2 -0
- package/dist/components/MetricChart/i18n/index.js +4 -0
- package/dist/components/MetricChart/reducer.d.ts +1 -1
- package/dist/components/MetricChart/types.d.ts +10 -5
- package/dist/components/NodeHostWrapper/NodeHostWrapper.js +1 -1
- package/dist/components/PDiskInfo/PDiskInfo.d.ts +11 -0
- package/dist/components/PDiskInfo/PDiskInfo.js +71 -0
- package/dist/components/PDiskInfo/PDiskInfo.scss +8 -0
- package/dist/components/PDiskInfo/i18n/en.json +14 -0
- package/dist/components/PDiskInfo/i18n/index.d.ts +1 -0
- package/dist/components/PDiskInfo/i18n/index.js +4 -0
- package/dist/components/PageMeta/PageMeta.d.ts +8 -0
- package/dist/components/PageMeta/PageMeta.js +7 -0
- package/dist/components/PageMeta/PageMeta.scss +10 -0
- package/dist/components/ProgressViewer/ProgressViewer.d.ts +1 -1
- package/dist/components/QueryResultTable/Cell/Cell.js +2 -2
- package/dist/components/QueryResultTable/QueryResultTable.js +1 -11
- package/dist/components/ShortyString/ShortyString.d.ts +1 -1
- package/dist/components/StatusIcon/StatusIcon.d.ts +12 -0
- package/dist/components/StatusIcon/StatusIcon.js +23 -0
- package/dist/components/StatusIcon/StatusIcon.scss +69 -0
- package/dist/components/Tablet/Tablet.scss +1 -1
- package/dist/components/TabletsOverall/TabletsOverall.js +6 -6
- package/dist/components/TabletsStatistic/TabletsStatistic.d.ts +1 -1
- package/dist/components/TabletsStatistic/TabletsStatistic.scss +1 -1
- package/dist/components/Tag/Tag.d.ts +1 -1
- package/dist/components/UsageLabel/UsageLabel.js +1 -11
- package/dist/components/VirtualTable/TableHead.js +2 -2
- package/dist/components/VirtualTable/reducer.d.ts +2 -2
- package/dist/components/VirtualTable/types.d.ts +13 -13
- package/dist/components/slots/types.d.ts +1 -1
- package/dist/containers/App/App.d.ts +1 -1
- package/dist/containers/App/Content.js +10 -4
- package/dist/containers/App/Providers.d.ts +1 -1
- package/dist/containers/App/appSlots.d.ts +6 -0
- package/dist/containers/App/appSlots.js +1 -0
- package/dist/containers/AppWithClusters/AppWithClusters.d.ts +1 -1
- package/dist/containers/AppWithClusters/AppWithClusters.js +1 -1
- package/dist/containers/AsideNavigation/YdbInternalUser/YdbInternalUser.js +2 -3
- package/dist/containers/Authentication/Authentication.js +2 -5
- package/dist/containers/Cluster/Cluster.js +4 -5
- package/dist/containers/Cluster/ClusterInfo/ClusterInfo.js +4 -4
- package/dist/containers/Cluster/ClusterInfo/ClusterInfo.scss +4 -0
- package/dist/containers/Cluster/ClusterInfo/utils.d.ts +1 -1
- package/dist/containers/Cluster/utils.d.ts +2 -2
- package/dist/containers/Clusters/Clusters.js +2 -4
- package/dist/containers/Clusters/Clusters.scss +1 -1
- package/dist/containers/Clusters/constants.d.ts +1 -1
- package/dist/containers/Clusters/useClustersList.js +2 -2
- package/dist/containers/Clusters/useSelectedColumns.d.ts +1 -1
- package/dist/containers/Header/Header.js +4 -5
- package/dist/containers/Header/breadcrumbs.js +28 -5
- package/dist/containers/Header/i18n/en.json +7 -0
- package/dist/containers/Header/i18n/index.d.ts +1 -0
- package/dist/containers/Header/i18n/index.js +4 -0
- package/dist/containers/Heatmap/Heatmap.js +3 -4
- package/dist/containers/Heatmap/HeatmapCanvas/HeatmapCanvas.js +1 -1
- package/dist/containers/Node/Node.js +2 -3
- package/dist/containers/Node/NodeStructure/NodeStructure.d.ts +0 -1
- package/dist/containers/Node/NodeStructure/NodeStructure.js +2 -6
- package/dist/containers/Node/NodeStructure/Pdisk.js +9 -65
- package/dist/containers/Node/NodeStructure/Vdisk.d.ts +1 -1
- package/dist/containers/Node/NodeStructure/Vdisk.js +5 -3
- package/dist/containers/Nodes/Nodes.js +2 -3
- package/dist/containers/Nodes/NodesWrapper.js +1 -11
- package/dist/containers/Nodes/getNodes.js +1 -11
- package/dist/containers/Nodes/getNodesColumns.d.ts +1 -1
- package/dist/containers/PDisk/PDisk.d.ts +3 -0
- package/dist/containers/PDisk/PDisk.js +86 -0
- package/dist/containers/PDisk/PDisk.scss +42 -0
- package/dist/containers/PDisk/PDiskGroups.d.ts +10 -0
- package/dist/containers/PDisk/PDiskGroups.js +20 -0
- package/dist/containers/PDisk/i18n/en.json +8 -0
- package/dist/containers/PDisk/i18n/index.d.ts +1 -0
- package/dist/containers/PDisk/i18n/index.js +4 -0
- package/dist/containers/PDisk/shared.d.ts +10 -0
- package/dist/containers/PDisk/shared.js +2 -0
- package/dist/containers/ReduxTooltip/ReduxTooltip.d.ts +1 -1
- package/dist/containers/ReduxTooltip/ReduxTooltip.js +3 -2
- package/dist/containers/Storage/DiskStateProgressBar/DiskStateProgressBar.d.ts +1 -9
- package/dist/containers/Storage/DiskStateProgressBar/DiskStateProgressBar.js +2 -12
- package/dist/containers/Storage/PDisk/PDisk.d.ts +3 -3
- package/dist/containers/Storage/PDisk/PDisk.js +6 -53
- package/dist/containers/Storage/PDiskPopup/PDiskPopup.d.ts +3 -3
- package/dist/containers/Storage/PDiskPopup/PDiskPopup.js +3 -14
- package/dist/containers/Storage/Storage.js +2 -3
- package/dist/containers/Storage/StorageGroups/getGroups.js +1 -11
- package/dist/containers/Storage/StorageGroups/getStorageGroupsColumns.d.ts +2 -1
- package/dist/containers/Storage/StorageGroups/getStorageGroupsColumns.js +22 -8
- package/dist/containers/Storage/StorageNodes/getNodes.js +1 -11
- package/dist/containers/Storage/StorageNodes/getStorageNodesColumns.js +1 -1
- package/dist/containers/Storage/StorageWrapper.js +1 -11
- package/dist/containers/Storage/UsageFilter/UsageFilter.js +1 -1
- package/dist/containers/Storage/VDisk/VDisk.d.ts +2 -3
- package/dist/containers/Storage/VDisk/VDisk.js +4 -64
- package/dist/containers/Storage/VDiskPopup/VDiskPopup.js +2 -12
- package/dist/containers/Storage/VirtualStorage.js +2 -3
- package/dist/containers/Storage/utils/index.d.ts +1 -3
- package/dist/containers/Storage/utils/index.js +0 -6
- package/dist/containers/Tablet/Tablet.js +4 -5
- package/dist/containers/Tablet/TabletControls/TabletControls.d.ts +3 -2
- package/dist/containers/Tablet/TabletControls/TabletControls.js +2 -49
- package/dist/containers/Tablet/TabletTable/TabletTable.js +1 -1
- package/dist/containers/Tablets/Tablets.js +2 -3
- package/dist/containers/TabletsFilters/TabletsFilters.d.ts +2 -2
- package/dist/containers/Tenant/Acl/Acl.js +2 -3
- package/dist/containers/Tenant/Diagnostics/Consumers/Consumers.js +2 -3
- package/dist/containers/Tenant/Diagnostics/Describe/Describe.js +3 -3
- package/dist/containers/Tenant/Diagnostics/Diagnostics.js +6 -4
- package/dist/containers/Tenant/Diagnostics/DiagnosticsPages.d.ts +2 -2
- package/dist/containers/Tenant/Diagnostics/HotKeys/HotKeys.js +2 -3
- package/dist/containers/Tenant/Diagnostics/Network/Network.d.ts +2 -2
- package/dist/containers/Tenant/Diagnostics/Network/NodeNetwork/NodeNetwork.d.ts +1 -1
- package/dist/containers/Tenant/Diagnostics/Network/NodeNetwork/NodeNetwork.js +7 -5
- package/dist/containers/Tenant/Diagnostics/Network/NodeNetwork/NodeNetwork.scss +1 -1
- package/dist/containers/Tenant/Diagnostics/Overview/Overview.js +9 -5
- package/dist/containers/Tenant/Diagnostics/Overview/TableInfo/prepareTableInfo.d.ts +1 -1
- package/dist/containers/Tenant/Diagnostics/Overview/utils/prepareTopicSchemaInfo.d.ts +1 -1
- package/dist/containers/Tenant/Diagnostics/Partitions/Partitions.js +2 -3
- package/dist/containers/Tenant/Diagnostics/Partitions/columns/columns.js +1 -1
- package/dist/containers/Tenant/Diagnostics/Partitions/utils/index.d.ts +1 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/DefaultOverviewContent/DefaultOverviewContent.d.ts +5 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/DefaultOverviewContent/DefaultOverviewContent.js +2 -2
- package/dist/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/Healthcheck.scss +0 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/HealthcheckDetails.d.ts +2 -2
- package/dist/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/HealthcheckPreview.js +3 -2
- package/dist/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/IssuesViewer/IssueTree.d.ts +2 -2
- package/dist/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/IssuesViewer/IssueTree.js +3 -12
- package/dist/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/IssuesViewer/IssueTreeItem/IssueTreeItem.d.ts +2 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/IssuesViewer/IssueTreeItem/IssueTreeItem.js +1 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TenantCpu.js +1 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopNodesByCpu.js +2 -3
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopNodesByLoad.js +2 -3
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopQueries.js +2 -3
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopShards.js +2 -3
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/cpuDashboardConfig.js +11 -6
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantDashboard/TenantDashboard.d.ts +2 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantDashboard/TenantDashboard.js +2 -2
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantMemory/TenantMemory.js +1 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantMemory/TopNodesByMemory.js +2 -3
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantOverview.js +6 -7
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantOverviewTableLayout.js +1 -11
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantStorage/TenantStorage.js +1 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantStorage/TopGroups.js +2 -3
- package/dist/containers/Tenant/Diagnostics/TenantOverview/TenantStorage/TopTables.js +2 -3
- package/dist/containers/Tenant/Diagnostics/TenantOverview/i18n/en.json +1 -1
- package/dist/containers/Tenant/Diagnostics/TenantOverview/useHealthcheck.d.ts +2 -2
- package/dist/containers/Tenant/Diagnostics/TenantOverview/useHealthcheck.js +3 -4
- package/dist/containers/Tenant/Diagnostics/TopQueries/TopQueries.js +2 -5
- package/dist/containers/Tenant/Diagnostics/TopShards/TopShards.js +2 -3
- package/dist/containers/Tenant/Info/ExternalDataSource/ExternalDataSource.js +1 -1
- package/dist/containers/Tenant/Info/ExternalTable/ExternalTable.js +3 -3
- package/dist/containers/Tenant/ObjectGeneral/ObjectGeneral.d.ts +1 -0
- package/dist/containers/Tenant/ObjectGeneral/ObjectGeneral.js +3 -2
- package/dist/containers/Tenant/ObjectSummary/ObjectSummary.js +2 -3
- package/dist/containers/Tenant/Query/ExecuteResult/ExecuteResult.js +2 -3
- package/dist/containers/Tenant/Query/ExplainResult/ExplainResult.js +3 -3
- package/dist/containers/Tenant/Query/Issues/models.d.ts +1 -1
- package/dist/containers/Tenant/Query/Preview/Preview.js +2 -3
- package/dist/containers/Tenant/Query/QueriesHistory/QueriesHistory.js +2 -3
- package/dist/containers/Tenant/Query/Query.js +2 -3
- package/dist/containers/Tenant/Query/QueryEditor/QueryEditor.js +3 -8
- package/dist/containers/Tenant/Query/QueryEditor/helpers.d.ts +4 -0
- package/dist/containers/Tenant/Query/QueryEditor/helpers.js +17 -0
- package/dist/containers/Tenant/Query/SaveQuery/SaveQuery.js +4 -4
- package/dist/containers/Tenant/Query/SavedQueries/SavedQueries.js +2 -2
- package/dist/containers/Tenant/Schema/SchemaTree/SchemaTree.js +5 -3
- package/dist/containers/Tenant/Tenant.js +24 -8
- package/dist/containers/Tenant/utils/index.d.ts +1 -1
- package/dist/containers/Tenant/utils/schema.d.ts +12 -12
- package/dist/containers/Tenant/utils/schemaActions.d.ts +1 -1
- package/dist/containers/Tenants/Tenants.js +3 -4
- package/dist/containers/UserSettings/Setting.d.ts +1 -1
- package/dist/containers/UserSettings/i18n/en.json +4 -0
- package/dist/containers/UserSettings/i18n/index.d.ts +1 -1
- package/dist/containers/UserSettings/settings.d.ts +4 -1
- package/dist/containers/UserSettings/settings.js +21 -6
- package/dist/containers/Versions/NodesTable/NodesTable.js +1 -1
- package/dist/containers/Versions/Versions.js +2 -3
- package/dist/reportWebVitals.d.ts +1 -1
- package/dist/routes.d.ts +5 -2
- package/dist/routes.js +6 -1
- package/dist/services/api.d.ts +9 -7
- package/dist/services/api.js +16 -13
- package/dist/services/settings.d.ts +1 -1
- package/dist/services/settings.js +2 -1
- package/dist/store/configureStore.d.ts +310 -0
- package/dist/store/configureStore.js +56 -0
- package/dist/store/defaultStore.d.ts +168 -0
- package/dist/store/defaultStore.js +2 -0
- package/dist/store/getUrlData.d.ts +3 -3
- package/dist/store/getUrlData.js +4 -4
- package/dist/store/index.d.ts +3 -97
- package/dist/store/index.js +2 -49
- package/dist/store/reducers/authentication/authentication.d.ts +247 -4
- package/dist/store/reducers/authentication/types.d.ts +1 -1
- package/dist/store/reducers/cluster/cluster.d.ts +83 -2
- package/dist/store/reducers/cluster/types.d.ts +3 -3
- package/dist/store/reducers/clusterNodes/clusterNodes.d.ts +83 -2
- package/dist/store/reducers/clusterNodes/types.d.ts +1 -1
- package/dist/store/reducers/clusters/clusters.d.ts +83 -2
- package/dist/store/reducers/clusters/selectors.d.ts +20 -6
- package/dist/store/reducers/clusters/selectors.js +1 -1
- package/dist/store/reducers/clusters/types.d.ts +1 -1
- package/dist/store/reducers/describe.d.ts +165 -3
- package/dist/store/reducers/describe.js +4 -3
- package/dist/store/reducers/executeQuery.d.ts +83 -2
- package/dist/store/reducers/executeTopQueries/executeTopQueries.d.ts +3 -3
- package/dist/store/reducers/executeTopQueries/types.d.ts +1 -1
- package/dist/store/reducers/explainQuery.d.ts +165 -3
- package/dist/store/reducers/header/header.d.ts +1 -1
- package/dist/store/reducers/header/types.d.ts +7 -4
- package/dist/store/reducers/healthcheckInfo/healthcheckInfo.d.ts +101 -0
- package/dist/store/reducers/{healthcheckInfo.js → healthcheckInfo/healthcheckInfo.js} +2 -2
- package/dist/store/reducers/healthcheckInfo/types.d.ts +19 -0
- package/dist/store/reducers/healthcheckInfo/utils.d.ts +3 -0
- package/dist/store/reducers/healthcheckInfo/utils.js +11 -0
- package/dist/store/reducers/heatmap.d.ts +83 -2
- package/dist/store/reducers/heatmap.js +2 -2
- package/dist/store/reducers/host.d.ts +83 -2
- package/dist/store/reducers/hotKeys/hotKeys.d.ts +1 -1
- package/dist/store/reducers/hotKeys/types.d.ts +1 -1
- package/dist/store/reducers/index.d.ts +95 -45
- package/dist/store/reducers/index.js +4 -2
- package/dist/store/reducers/network/network.d.ts +83 -2
- package/dist/store/reducers/network/types.d.ts +1 -1
- package/dist/store/reducers/node/node.d.ts +165 -3
- package/dist/store/reducers/node/selectors.d.ts +1 -1
- package/dist/store/reducers/node/selectors.js +5 -4
- package/dist/store/reducers/node/types.d.ts +6 -6
- package/dist/store/reducers/nodes/nodes.d.ts +165 -3
- package/dist/store/reducers/nodes/nodes.js +1 -11
- package/dist/store/reducers/nodes/selectors.d.ts +1 -1
- package/dist/store/reducers/nodes/selectors.js +1 -1
- package/dist/store/reducers/nodes/types.d.ts +4 -3
- package/dist/store/reducers/nodes/utils.d.ts +1 -1
- package/dist/store/reducers/nodesList.d.ts +83 -2
- package/dist/store/reducers/olapStats.d.ts +83 -2
- package/dist/store/reducers/overview/overview.d.ts +166 -4
- package/dist/store/reducers/overview/overview.js +3 -3
- package/dist/store/reducers/overview/types.d.ts +6 -5
- package/dist/store/reducers/partitions/partitions.d.ts +83 -2
- package/dist/store/reducers/partitions/types.d.ts +1 -1
- package/dist/store/reducers/partitions/utils.d.ts +2 -2
- package/dist/store/reducers/pdisk/pdisk.d.ts +210 -0
- package/dist/store/reducers/pdisk/pdisk.js +64 -0
- package/dist/store/reducers/pdisk/types.d.ts +23 -0
- package/dist/store/reducers/pdisk/types.js +1 -0
- package/dist/store/reducers/pdisk/utils.d.ts +32 -0
- package/dist/store/reducers/pdisk/utils.js +32 -0
- package/dist/store/reducers/preview.d.ts +82 -1
- package/dist/store/reducers/saveQuery.d.ts +3 -3
- package/dist/store/reducers/schema/schema.d.ts +84 -4
- package/dist/store/reducers/schema/schema.js +4 -4
- package/dist/store/reducers/schema/types.d.ts +3 -3
- package/dist/store/reducers/schemaAcl/schemaAcl.d.ts +83 -2
- package/dist/store/reducers/schemaAcl/types.d.ts +1 -1
- package/dist/store/reducers/settings/settings.d.ts +2 -2
- package/dist/store/reducers/settings/types.d.ts +3 -3
- package/dist/store/reducers/shardsWorkload/shardsWorkload.d.ts +83 -2
- package/dist/store/reducers/shardsWorkload/types.d.ts +1 -1
- package/dist/store/reducers/storage/selectors.d.ts +1 -1
- package/dist/store/reducers/storage/selectors.js +1 -1
- package/dist/store/reducers/storage/storage.d.ts +165 -3
- package/dist/store/reducers/storage/storage.js +1 -11
- package/dist/store/reducers/storage/types.d.ts +10 -10
- package/dist/store/reducers/storage/utils.d.ts +4 -2
- package/dist/store/reducers/storage/utils.js +21 -15
- package/dist/store/reducers/tablet.d.ts +165 -3
- package/dist/store/reducers/tablet.js +1 -1
- package/dist/store/reducers/tablets.d.ts +83 -2
- package/dist/store/reducers/tabletsFilters.d.ts +101 -2
- package/dist/store/reducers/tabletsFilters.js +1 -1
- package/dist/store/reducers/tenant/tenant.d.ts +83 -2
- package/dist/store/reducers/tenant/types.d.ts +6 -6
- package/dist/store/reducers/tenantOverview/executeTopTables/executeTopTables.d.ts +83 -2
- package/dist/store/reducers/tenantOverview/executeTopTables/types.d.ts +1 -1
- package/dist/store/reducers/tenantOverview/topNodesByCpu/topNodesByCpu.d.ts +83 -2
- package/dist/store/reducers/tenantOverview/topNodesByCpu/topNodesByCpu.js +1 -11
- package/dist/store/reducers/tenantOverview/topNodesByCpu/types.d.ts +2 -2
- package/dist/store/reducers/tenantOverview/topNodesByLoad/topNodesByLoad.d.ts +83 -2
- package/dist/store/reducers/tenantOverview/topNodesByLoad/topNodesByLoad.js +1 -11
- package/dist/store/reducers/tenantOverview/topNodesByLoad/types.d.ts +2 -2
- package/dist/store/reducers/tenantOverview/topNodesByMemory/topNodesByMemory.d.ts +83 -2
- package/dist/store/reducers/tenantOverview/topNodesByMemory/topNodesByMemory.js +1 -11
- package/dist/store/reducers/tenantOverview/topNodesByMemory/types.d.ts +2 -2
- package/dist/store/reducers/tenantOverview/topQueries/tenantOverviewTopQueries.d.ts +83 -2
- package/dist/store/reducers/tenantOverview/topQueries/types.d.ts +1 -1
- package/dist/store/reducers/tenantOverview/topShards/tenantOverviewTopShards.d.ts +83 -2
- package/dist/store/reducers/tenantOverview/topShards/types.d.ts +1 -1
- package/dist/store/reducers/tenantOverview/topStorageGroups/topStorageGroups.d.ts +83 -2
- package/dist/store/reducers/tenantOverview/topStorageGroups/topStorageGroups.js +1 -11
- package/dist/store/reducers/tenantOverview/topStorageGroups/types.d.ts +2 -2
- package/dist/store/reducers/tenants/selectors.d.ts +2 -2
- package/dist/store/reducers/tenants/selectors.js +1 -1
- package/dist/store/reducers/tenants/tenants.d.ts +83 -2
- package/dist/store/reducers/tenants/types.d.ts +2 -2
- package/dist/store/reducers/tenants/utils.d.ts +6 -6
- package/dist/store/reducers/tooltip.d.ts +4 -3
- package/dist/store/reducers/tooltip.js +2 -4
- package/dist/store/reducers/topic.d.ts +83 -3
- package/dist/store/reducers/topic.js +1 -1
- package/dist/store/state-url-mapping.d.ts +5 -3
- package/dist/store/state-url-mapping.js +9 -18
- package/dist/store/utils.d.ts +4 -4
- package/dist/types/additionalProps.d.ts +2 -2
- package/dist/types/api/enums.d.ts +1 -0
- package/dist/types/api/enums.js +1 -0
- package/dist/types/api/error.d.ts +1 -1
- package/dist/types/api/nodes.d.ts +1 -1
- package/dist/types/api/nodesList.d.ts +1 -1
- package/dist/types/api/query.d.ts +19 -19
- package/dist/types/api/render.d.ts +6 -3
- package/dist/types/api/storage.d.ts +1 -1
- package/dist/types/api/tablet.d.ts +1 -1
- package/dist/types/common.d.ts +1 -1
- package/dist/types/index.d.ts +1 -1
- package/dist/types/store/describe.d.ts +3 -3
- package/dist/types/store/executeQuery.d.ts +2 -2
- package/dist/types/store/explainQuery.d.ts +3 -3
- package/dist/types/store/heatmap.d.ts +3 -3
- package/dist/types/store/host.d.ts +1 -1
- package/dist/types/store/nodesList.d.ts +2 -2
- package/dist/types/store/olapStats.d.ts +1 -1
- package/dist/types/store/query.d.ts +5 -5
- package/dist/types/store/tablet.d.ts +3 -3
- package/dist/types/store/tablets.d.ts +2 -2
- package/dist/types/store/tooltip.d.ts +3 -5
- package/dist/types/store/topic.d.ts +1 -1
- package/dist/types/versions.d.ts +2 -2
- package/dist/utils/additionalProps.d.ts +1 -1
- package/dist/utils/additionalProps.js +1 -1
- package/dist/utils/bytesParsers/formatBytes.d.ts +2 -2
- package/dist/utils/bytesParsers/formatBytes.js +1 -11
- package/dist/utils/clusterVersionColors.d.ts +1 -1
- package/dist/utils/clusterVersionColors.js +2 -2
- package/dist/utils/constants.d.ts +2 -1
- package/dist/utils/constants.js +5 -4
- package/dist/utils/dataFormatters/dataFormatters.d.ts +12 -11
- package/dist/utils/developerUI/developerUI.d.ts +1 -1
- package/dist/utils/diagnostics.d.ts +2 -2
- package/dist/utils/disks/__test__/calculatePDiskSeverity.test.d.ts +1 -0
- package/dist/utils/disks/__test__/calculatePDiskSeverity.test.js +36 -0
- package/dist/utils/disks/__test__/calculateVDiskSeverity.test.d.ts +1 -0
- package/dist/utils/disks/__test__/calculateVDiskSeverity.test.js +142 -0
- package/dist/utils/disks/calculatePDiskSeverity.d.ts +2 -0
- package/dist/utils/disks/calculatePDiskSeverity.js +18 -0
- package/dist/utils/disks/calculateVDiskSeverity.d.ts +2 -0
- package/dist/utils/disks/calculateVDiskSeverity.js +36 -0
- package/dist/utils/disks/constants.d.ts +25 -0
- package/dist/utils/disks/constants.js +38 -0
- package/dist/utils/disks/getPDiskType.d.ts +7 -0
- package/dist/utils/{pdisk.js → disks/getPDiskType.js} +13 -15
- package/dist/utils/disks/helpers.d.ts +3 -0
- package/dist/utils/disks/helpers.js +10 -0
- package/dist/utils/disks/prepareDisks.d.ts +5 -0
- package/dist/utils/disks/prepareDisks.js +40 -0
- package/dist/utils/disks/types.d.ts +15 -0
- package/dist/utils/disks/types.js +1 -0
- package/dist/utils/hooks/index.d.ts +1 -0
- package/dist/utils/hooks/index.js +1 -0
- package/dist/utils/hooks/useSetting.js +2 -2
- package/dist/utils/hooks/useTableResize.d.ts +3 -3
- package/dist/utils/hooks/useTableSort.d.ts +1 -1
- package/dist/utils/hooks/useTypedDispatch.d.ts +2 -0
- package/dist/utils/hooks/useTypedDispatch.js +2 -0
- package/dist/utils/hooks/useTypedSelector.d.ts +1 -1
- package/dist/utils/index.d.ts +1 -0
- package/dist/utils/index.js +3 -0
- package/dist/utils/monaco.d.ts +1 -0
- package/dist/utils/monaco.js +14 -0
- package/dist/utils/monitoring.d.ts +3 -3
- package/dist/utils/nodes.d.ts +2 -2
- package/dist/utils/prepareBackend.d.ts +2 -2
- package/dist/utils/query.d.ts +2 -2
- package/dist/utils/query.js +1 -11
- package/dist/utils/storage.d.ts +1 -3
- package/dist/utils/storage.js +0 -1
- package/dist/utils/tablet.d.ts +1 -1
- package/dist/utils/timeframes.d.ts +1 -1
- package/dist/utils/typecheckers.d.ts +1 -0
- package/dist/utils/versions/getVersionsColors.d.ts +1 -1
- package/dist/utils/versions/getVersionsColors.js +2 -2
- package/dist/utils/versions/parseNodesToVersionsValues.d.ts +1 -1
- package/dist/utils/yqlSuggestions/constants.d.ts +7 -0
- package/dist/utils/yqlSuggestions/constants.js +696 -0
- package/dist/utils/yqlSuggestions/generateSuggestions.d.ts +27 -0
- package/dist/utils/yqlSuggestions/generateSuggestions.js +252 -0
- package/dist/utils/yqlSuggestions/yqlSuggestions.d.ts +4 -0
- package/dist/utils/yqlSuggestions/yqlSuggestions.js +76 -0
- package/package.json +16 -11
- package/dist/assets/icons/flask.svg +0 -3
- package/dist/assets/icons/star.svg +0 -1
- package/dist/components/ExternalLinkWithIcon/ExternalLinkWithIcon.d.ts +0 -7
- package/dist/components/ExternalLinkWithIcon/ExternalLinkWithIcon.js +0 -9
- package/dist/containers/Cluster/ClusterInfoSkeleton/ClusterInfoSkeleton.d.ts +0 -7
- package/dist/containers/Cluster/ClusterInfoSkeleton/ClusterInfoSkeleton.js +0 -7
- package/dist/containers/Storage/utils/constants.d.ts +0 -2
- package/dist/containers/Storage/utils/constants.js +0 -2
- package/dist/store/reducers/healthcheckInfo.d.ts +0 -21
- package/dist/types/store/healthcheck.d.ts +0 -20
- package/dist/utils/pdisk.d.ts +0 -17
- /package/dist/{types/store/healthcheck.js → store/reducers/healthcheckInfo/types.js} +0 -0
@@ -15,7 +15,7 @@ export declare const COLUMNS_NAMES: {
|
|
15
15
|
readonly DESCRIPTION: "description";
|
16
16
|
readonly BALANCER: "balancer";
|
17
17
|
};
|
18
|
-
export declare const DEFAULT_COLUMNS: ("nodes" | "storage" | "
|
18
|
+
export declare const DEFAULT_COLUMNS: ("nodes" | "storage" | "tenants" | "versions" | "status" | "service" | "title" | "hosts" | "balancer" | "load" | "owner")[];
|
19
19
|
export declare const COLUMNS_TITLES: {
|
20
20
|
readonly title: "Cluster";
|
21
21
|
readonly versions: "Versions";
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import React from 'react';
|
2
|
-
import {
|
2
|
+
import { useTypedDispatch } from '../../utils/hooks';
|
3
3
|
import { fetchClustersList } from '../../store/reducers/clusters/clusters';
|
4
4
|
export function useClustersList() {
|
5
|
-
const dispatch =
|
5
|
+
const dispatch = useTypedDispatch();
|
6
6
|
React.useEffect(() => {
|
7
7
|
dispatch(fetchClustersList());
|
8
8
|
}, [dispatch]);
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { type Column } from '@gravity-ui/react-data-table';
|
2
2
|
import { type TableColumnSetupItem } from '@gravity-ui/uikit/build/esm/components/Table/hoc/withTableSettings/withTableSettings';
|
3
|
-
export declare const useSelectedColumns: <T>(columns: Column<T>[], storageKey: string, columnsTitles: Record<string, string>, defaultColumnsIds: string[], requiredColumnsIds?: string[]
|
3
|
+
export declare const useSelectedColumns: <T>(columns: Column<T>[], storageKey: string, columnsTitles: Record<string, string>, defaultColumnsIds: string[], requiredColumnsIds?: string[]) => {
|
4
4
|
columnsToShow: Column<T>[];
|
5
5
|
columnsToSelect: TableColumnSetupItem[];
|
6
6
|
setColumns: (value: TableColumnSetupItem[]) => void;
|
@@ -1,13 +1,12 @@
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
2
|
import { useEffect, useMemo } from 'react';
|
3
3
|
import { useHistory, useLocation } from 'react-router';
|
4
|
-
import { useDispatch } from 'react-redux';
|
5
4
|
import block from 'bem-cn-lite';
|
6
5
|
import { Breadcrumbs } from '@gravity-ui/uikit';
|
7
|
-
import {
|
6
|
+
import { LinkWithIcon } from '../../components/LinkWithIcon/LinkWithIcon';
|
8
7
|
import { backend, customBackend } from '../../store';
|
9
8
|
import { getClusterInfo } from '../../store/reducers/cluster/cluster';
|
10
|
-
import { useTypedSelector } from '../../utils/hooks';
|
9
|
+
import { useTypedSelector, useTypedDispatch } from '../../utils/hooks';
|
11
10
|
import { DEVELOPER_UI_TITLE } from '../../utils/constants';
|
12
11
|
import { parseQuery } from '../../routes';
|
13
12
|
import { getBreadcrumbs } from './breadcrumbs';
|
@@ -21,7 +20,7 @@ const getInternalLink = (singleClusterMode) => {
|
|
21
20
|
};
|
22
21
|
function Header({ mainPage }) {
|
23
22
|
var _a;
|
24
|
-
const dispatch =
|
23
|
+
const dispatch = useTypedDispatch();
|
25
24
|
const history = useHistory();
|
26
25
|
const location = useLocation();
|
27
26
|
const singleClusterMode = useTypedSelector((state) => state.singleClusterMode);
|
@@ -58,7 +57,7 @@ function Header({ mainPage }) {
|
|
58
57
|
return text;
|
59
58
|
}
|
60
59
|
return (_jsxs("span", Object.assign({ className: b('breadcrumb') }, { children: [_jsx("div", Object.assign({ className: b('breadcrumb__icon') }, { children: icon })), text] })));
|
61
|
-
} }) }), _jsx(
|
60
|
+
} }) }), _jsx(LinkWithIcon, { title: DEVELOPER_UI_TITLE, url: getInternalLink(singleClusterMode) })] })));
|
62
61
|
};
|
63
62
|
return renderHeader();
|
64
63
|
}
|
@@ -2,11 +2,12 @@ import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
2
|
import { NodesRight as ClusterIcon, Database as DatabaseIcon, Cpu as ComputeNodeIcon, HardDrive as StorageNodeIcon, } from '@gravity-ui/icons';
|
3
3
|
import { TENANT_DIAGNOSTICS_TABS_IDS, TENANT_PAGE, TENANT_PAGES_IDS, } from '../../store/reducers/tenant/constants';
|
4
4
|
import { TabletIcon } from '../../components/TabletIcon/TabletIcon';
|
5
|
-
import routes, { createHref } from '../../routes';
|
5
|
+
import routes, { createHref, getPDiskPagePath } from '../../routes';
|
6
6
|
import { CLUSTER_DEFAULT_TITLE, getTabletLabel } from '../../utils/constants';
|
7
7
|
import { getClusterPath } from '../Cluster/utils';
|
8
8
|
import { TenantTabsGroups, getTenantPath } from '../Tenant/TenantPages';
|
9
9
|
import { getDefaultNodePath } from '../Node/NodePages';
|
10
|
+
import { headerKeyset } from './i18n';
|
10
11
|
const prepareTenantName = (tenantName) => {
|
11
12
|
return tenantName.startsWith('/') ? tenantName.slice(1) : tenantName;
|
12
13
|
};
|
@@ -22,7 +23,7 @@ const getClusterBreadcrumbs = (options, query = {}) => {
|
|
22
23
|
};
|
23
24
|
const getTenantBreadcrumbs = (options, query = {}) => {
|
24
25
|
const { tenantName } = options;
|
25
|
-
const text = tenantName ? prepareTenantName(tenantName) : '
|
26
|
+
const text = tenantName ? prepareTenantName(tenantName) : headerKeyset('breadcrumbs.tenant');
|
26
27
|
const link = tenantName ? getTenantPath(Object.assign(Object.assign({}, query), { name: tenantName })) : undefined;
|
27
28
|
return [...getClusterBreadcrumbs(options, query), { text, link, icon: _jsx(DatabaseIcon, {}) }];
|
28
29
|
};
|
@@ -38,7 +39,9 @@ const getNodeBreadcrumbs = (options, query = {}) => {
|
|
38
39
|
else {
|
39
40
|
breadcrumbs = getTenantBreadcrumbs(options, newQuery);
|
40
41
|
}
|
41
|
-
const text = nodeId
|
42
|
+
const text = nodeId
|
43
|
+
? `${headerKeyset('breadcrumbs.node')} ${nodeId}`
|
44
|
+
: headerKeyset('breadcrumbs.node');
|
42
45
|
const link = nodeId ? getDefaultNodePath(nodeId, query) : undefined;
|
43
46
|
const icon = isStorageNode ? _jsx(StorageNodeIcon, {}) : _jsx(ComputeNodeIcon, {});
|
44
47
|
breadcrumbs.push({
|
@@ -48,6 +51,23 @@ const getNodeBreadcrumbs = (options, query = {}) => {
|
|
48
51
|
});
|
49
52
|
return breadcrumbs;
|
50
53
|
};
|
54
|
+
const getPDiskBreadcrumbs = (options, query = {}) => {
|
55
|
+
const { nodeId, pDiskId } = options;
|
56
|
+
const breadcrumbs = getNodeBreadcrumbs({
|
57
|
+
// PDisks relate to storage Nodes, they don't have tenant name
|
58
|
+
tenantName: undefined,
|
59
|
+
nodeId: nodeId,
|
60
|
+
});
|
61
|
+
const text = pDiskId
|
62
|
+
? `${headerKeyset('breadcrumbs.pDisk')} ${pDiskId}`
|
63
|
+
: headerKeyset('breadcrumbs.pDisk');
|
64
|
+
const link = pDiskId && nodeId ? getPDiskPagePath(pDiskId, nodeId, query) : undefined;
|
65
|
+
breadcrumbs.push({
|
66
|
+
text,
|
67
|
+
link,
|
68
|
+
});
|
69
|
+
return breadcrumbs;
|
70
|
+
};
|
51
71
|
const getTabletsBreadcrubms = (options, query = {}) => {
|
52
72
|
const { tenantName, nodeIds } = options;
|
53
73
|
const newQuery = Object.assign(Object.assign({}, query), { [TENANT_PAGE]: TENANT_PAGES_IDS.diagnostics, [TenantTabsGroups.diagnosticsTab]: TENANT_DIAGNOSTICS_TABS_IDS.tablets });
|
@@ -60,14 +80,14 @@ const getTabletsBreadcrubms = (options, query = {}) => {
|
|
60
80
|
breadcrumbs = getClusterBreadcrumbs(options, query);
|
61
81
|
}
|
62
82
|
const link = createHref(routes.tabletsFilters, undefined, Object.assign(Object.assign({}, query), { nodeIds, path: tenantName }));
|
63
|
-
breadcrumbs.push({ text: '
|
83
|
+
breadcrumbs.push({ text: headerKeyset('breadcrumbs.tablets'), link });
|
64
84
|
return breadcrumbs;
|
65
85
|
};
|
66
86
|
const getTabletBreadcrubms = (options, query = {}) => {
|
67
87
|
const { tabletId, tabletType } = options;
|
68
88
|
const breadcrumbs = getTabletsBreadcrubms(options, query);
|
69
89
|
breadcrumbs.push({
|
70
|
-
text: tabletId || '
|
90
|
+
text: tabletId || headerKeyset('breadcrumbs.tablet'),
|
71
91
|
icon: _jsx(TabletIcon, { text: getTabletLabel(tabletType) }),
|
72
92
|
});
|
73
93
|
return breadcrumbs;
|
@@ -83,6 +103,9 @@ export const getBreadcrumbs = (page, options, rawBreadcrumbs = [], query = {}) =
|
|
83
103
|
case 'node': {
|
84
104
|
return [...rawBreadcrumbs, ...getNodeBreadcrumbs(options, query)];
|
85
105
|
}
|
106
|
+
case 'pDisk': {
|
107
|
+
return [...rawBreadcrumbs, ...getPDiskBreadcrumbs(options, query)];
|
108
|
+
}
|
86
109
|
case 'tablets': {
|
87
110
|
return [...rawBreadcrumbs, ...getTabletsBreadcrubms(options, query)];
|
88
111
|
}
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare const headerKeyset: (key: "breadcrumbs.tenant" | "breadcrumbs.node" | "breadcrumbs.pDisk" | "breadcrumbs.tablet" | "breadcrumbs.tablets", params?: import("@gravity-ui/i18n").Params | undefined) => string;
|
@@ -1,12 +1,11 @@
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
2
|
import React, { useCallback, useEffect, useState } from 'react';
|
3
|
-
import { useDispatch } from 'react-redux';
|
4
3
|
import cn from 'bem-cn-lite';
|
5
4
|
import { Checkbox, Select } from '@gravity-ui/uikit';
|
6
5
|
import { getTabletsInfo, setHeatmapOptions } from '../../store/reducers/heatmap';
|
7
6
|
import { showTooltip, hideTooltip } from '../../store/reducers/tooltip';
|
8
7
|
import { formatNumber } from '../../utils/dataFormatters/dataFormatters';
|
9
|
-
import { useAutofetcher, useTypedSelector } from '../../utils/hooks';
|
8
|
+
import { useAutofetcher, useTypedSelector, useTypedDispatch } from '../../utils/hooks';
|
10
9
|
import { Loader } from '../../components/Loader';
|
11
10
|
import { ResponseError } from '../../components/Errors/ResponseError';
|
12
11
|
import { COLORS_RANGE_SIZE, getColorRange, getColorIndex, getCurrentMetricLimits } from './util';
|
@@ -16,7 +15,7 @@ import './Heatmap.scss';
|
|
16
15
|
const b = cn('heatmap');
|
17
16
|
const COLORS_RANGE = getColorRange(COLORS_RANGE_SIZE);
|
18
17
|
export const Heatmap = ({ path }) => {
|
19
|
-
const dispatch =
|
18
|
+
const dispatch = useTypedDispatch();
|
20
19
|
const itemsContainer = React.createRef();
|
21
20
|
const { autorefresh } = useTypedSelector((state) => state.schema);
|
22
21
|
const { loading, wasLoaded, error, sort, heatmap, metrics, currentMetric, data: tablets = [], } = useTypedSelector((state) => state.heatmap);
|
@@ -42,7 +41,7 @@ export const Heatmap = ({ path }) => {
|
|
42
41
|
dispatch(showTooltip(...args));
|
43
42
|
};
|
44
43
|
const onHideTooltip = () => {
|
45
|
-
dispatch(hideTooltip);
|
44
|
+
dispatch(hideTooltip());
|
46
45
|
};
|
47
46
|
const handleMetricChange = (value) => {
|
48
47
|
dispatch(setHeatmapOptions({
|
@@ -19,7 +19,7 @@ export const HeatmapCanvas = (props) => {
|
|
19
19
|
const { columnsCount } = dimensions;
|
20
20
|
const rectX = (index % columnsCount) * (TABLET_SIZE + TABLET_PADDING);
|
21
21
|
const rectY = Math.floor(index / columnsCount) * (TABLET_SIZE + TABLET_PADDING);
|
22
|
-
ctx.fillStyle = tablet.color || '
|
22
|
+
ctx.fillStyle = tablet.color || 'grey';
|
23
23
|
ctx.fillRect(rectX, rectY, TABLET_SIZE, TABLET_SIZE);
|
24
24
|
};
|
25
25
|
}
|
@@ -2,7 +2,6 @@ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
2
|
import { useEffect, useMemo, useRef } from 'react';
|
3
3
|
import { useLocation, useRouteMatch } from 'react-router';
|
4
4
|
import cn from 'bem-cn-lite';
|
5
|
-
import { useDispatch } from 'react-redux';
|
6
5
|
import { Helmet } from 'react-helmet-async';
|
7
6
|
import { Tabs } from '@gravity-ui/uikit';
|
8
7
|
import { Link } from 'react-router-dom';
|
@@ -17,7 +16,7 @@ import { getNodeInfo, resetNode } from '../../store/reducers/node/node';
|
|
17
16
|
import routes, { createHref, parseQuery } from '../../routes';
|
18
17
|
import { setHeaderBreadcrumbs } from '../../store/reducers/header/header';
|
19
18
|
import { AutoFetcher } from '../../utils/autofetcher';
|
20
|
-
import { useTypedSelector } from '../../utils/hooks';
|
19
|
+
import { useTypedSelector, useTypedDispatch } from '../../utils/hooks';
|
21
20
|
import './Node.scss';
|
22
21
|
const b = cn('node');
|
23
22
|
export const STORAGE_ROLE = 'Storage';
|
@@ -25,7 +24,7 @@ const autofetcher = new AutoFetcher();
|
|
25
24
|
function Node(props) {
|
26
25
|
var _a;
|
27
26
|
const container = useRef(null);
|
28
|
-
const dispatch =
|
27
|
+
const dispatch = useTypedDispatch();
|
29
28
|
const location = useLocation();
|
30
29
|
const { loading, wasLoaded, error, data: node } = useTypedSelector((state) => state.node);
|
31
30
|
const match = (_a = useRouteMatch(routes.node)) !== null && _a !== void 0 ? _a : Object.create(null);
|
@@ -1,6 +1,5 @@
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
2
2
|
import { useEffect, useRef } from 'react';
|
3
|
-
import { useDispatch } from 'react-redux';
|
4
3
|
import url from 'url';
|
5
4
|
import { isEmpty } from 'lodash/fp';
|
6
5
|
import cn from 'bem-cn-lite';
|
@@ -8,19 +7,16 @@ import { Loader } from '../.././../components/Loader';
|
|
8
7
|
import { getNodeStructure } from '../../../store/reducers/node/node';
|
9
8
|
import { selectNodeStructure } from '../../../store/reducers/node/selectors';
|
10
9
|
import { AutoFetcher } from '../../../utils/autofetcher';
|
11
|
-
import { useTypedSelector } from '../../../utils/hooks';
|
10
|
+
import { useTypedSelector, useTypedDispatch } from '../../../utils/hooks';
|
12
11
|
import { PDisk } from './Pdisk';
|
13
12
|
import './NodeStructure.scss';
|
14
13
|
const b = cn('kv-node-structure');
|
15
|
-
export function valueIsDefined(value) {
|
16
|
-
return value !== null && value !== undefined;
|
17
|
-
}
|
18
14
|
function generateId({ type, id }) {
|
19
15
|
return `${type}-${id}`;
|
20
16
|
}
|
21
17
|
const autofetcher = new AutoFetcher();
|
22
18
|
function NodeStructure({ nodeId, className }) {
|
23
|
-
const dispatch =
|
19
|
+
const dispatch = useTypedDispatch();
|
24
20
|
const nodeStructure = useTypedSelector(selectNodeStructure);
|
25
21
|
const { loadingStructure, wasLoadedStructure } = useTypedSelector((state) => state.node);
|
26
22
|
const { pdiskId: pdiskIdFromUrl, vdiskId: vdiskIdFromUrl } = url.parse(window.location.href, true).query;
|
@@ -4,19 +4,18 @@ import cn from 'bem-cn-lite';
|
|
4
4
|
import { isEmpty } from 'lodash/fp';
|
5
5
|
import { ArrowToggle, Button, Popover } from '@gravity-ui/uikit';
|
6
6
|
import DataTable from '@gravity-ui/react-data-table';
|
7
|
+
import { EFlag } from '../../../types/api/enums';
|
7
8
|
import { EVDiskState } from '../../../types/api/vdisk';
|
8
|
-
import { bytesToGB } from '../../../utils/utils';
|
9
9
|
import { formatStorageValuesToGb } from '../../../utils/dataFormatters/dataFormatters';
|
10
|
-
import { getPDiskType } from '../../../utils/pdisk';
|
11
10
|
import { DEFAULT_TABLE_SETTINGS } from '../../../utils/constants';
|
12
|
-
import {
|
13
|
-
import
|
14
|
-
import
|
11
|
+
import { valueIsDefined } from '../../../utils';
|
12
|
+
import { createVDiskDeveloperUILink } from '../../../utils/developerUI/developerUI';
|
13
|
+
import { EntityStatus } from '../../../components/EntityStatus/EntityStatus';
|
15
14
|
import { ProgressViewer } from '../../../components/ProgressViewer/ProgressViewer';
|
16
15
|
import { Icon } from '../../../components/Icon';
|
16
|
+
import { PDiskInfo } from '../../../components/PDiskInfo/PDiskInfo';
|
17
17
|
import i18n from '../i18n';
|
18
18
|
import { Vdisk } from './Vdisk';
|
19
|
-
import { valueIsDefined } from './NodeStructure';
|
20
19
|
import { PDiskTitleBadge } from './PDiskTitleBadge';
|
21
20
|
const b = cn('kv-node-structure');
|
22
21
|
var VDiskTableColumnsIds;
|
@@ -59,7 +58,7 @@ function getColumns({ pDiskId, selectedVdiskId, nodeId, }) {
|
|
59
58
|
header: vDiskTableColumnsNames[VDiskTableColumnsIds.VDiskState],
|
60
59
|
width: 70,
|
61
60
|
render: ({ row }) => {
|
62
|
-
return (_jsx(EntityStatus, { status: row.VDiskState === EVDiskState.OK ?
|
61
|
+
return (_jsx(EntityStatus, { status: row.VDiskState === EVDiskState.OK ? EFlag.Green : EFlag.Red }));
|
63
62
|
},
|
64
63
|
sortAccessor: (row) => (row.VDiskState === EVDiskState.OK ? 1 : 0),
|
65
64
|
align: DataTable.CENTER,
|
@@ -90,7 +89,7 @@ function getColumns({ pDiskId, selectedVdiskId, nodeId, }) {
|
|
90
89
|
}
|
91
90
|
export function PDisk({ id, data, selectedVdiskId, nodeId, unfolded: unfoldedFromProps, }) {
|
92
91
|
const [unfolded, setUnfolded] = useState(unfoldedFromProps !== null && unfoldedFromProps !== void 0 ? unfoldedFromProps : false);
|
93
|
-
const { TotalSize = 0, AvailableSize = 0, Device,
|
92
|
+
const { TotalSize = 0, AvailableSize = 0, Device, PDiskId, Type, vDisks } = data;
|
94
93
|
const total = Number(TotalSize);
|
95
94
|
const available = Number(AvailableSize);
|
96
95
|
const onOpenPDiskDetails = () => {
|
@@ -108,62 +107,7 @@ export function PDisk({ id, data, selectedVdiskId, nodeId, unfolded: unfoldedFro
|
|
108
107
|
if (isEmpty(data)) {
|
109
108
|
return _jsx("div", { children: "No information about PDisk" });
|
110
109
|
}
|
111
|
-
|
112
|
-
if (valueIsDefined(PDiskId) && valueIsDefined(nodeId)) {
|
113
|
-
pDiskInternalViewerLink = createPDiskDeveloperUILink({
|
114
|
-
nodeId,
|
115
|
-
pDiskId: PDiskId,
|
116
|
-
});
|
117
|
-
}
|
118
|
-
const pdiskInfo = [
|
119
|
-
{
|
120
|
-
label: 'PDisk Id',
|
121
|
-
value: (_jsxs("div", Object.assign({ className: b('pdisk-id') }, { children: [PDiskId, pDiskInternalViewerLink && (_jsx(Button, Object.assign({ size: "s", className: b('external-button'), href: pDiskInternalViewerLink, target: "_blank", view: "flat-secondary", title: i18n('pdisk.developer-ui-button-title') }, { children: _jsx(Icon, { name: "external" }) })))] }))),
|
122
|
-
},
|
123
|
-
];
|
124
|
-
if (valueIsDefined(Path)) {
|
125
|
-
pdiskInfo.push({ label: 'Path', value: Path });
|
126
|
-
}
|
127
|
-
if (valueIsDefined(Guid)) {
|
128
|
-
pdiskInfo.push({ label: 'GUID', value: Guid });
|
129
|
-
}
|
130
|
-
if (valueIsDefined(Category)) {
|
131
|
-
pdiskInfo.push({ label: 'Category', value: Category });
|
132
|
-
pdiskInfo.push({ label: 'Type', value: getPDiskType(data) });
|
133
|
-
}
|
134
|
-
pdiskInfo.push({
|
135
|
-
label: 'Allocated Size',
|
136
|
-
value: bytesToGB(total - available),
|
137
|
-
});
|
138
|
-
pdiskInfo.push({
|
139
|
-
label: 'Available Size',
|
140
|
-
value: bytesToGB(available),
|
141
|
-
});
|
142
|
-
if (total >= 0 && available >= 0) {
|
143
|
-
pdiskInfo.push({
|
144
|
-
label: 'Size',
|
145
|
-
value: (_jsx(ProgressViewer, { value: total - available, capacity: total, formatValues: formatStorageValuesToGb, colorizeProgress: true, className: b('size') })),
|
146
|
-
});
|
147
|
-
}
|
148
|
-
if (valueIsDefined(State)) {
|
149
|
-
pdiskInfo.push({ label: 'State', value: State });
|
150
|
-
}
|
151
|
-
if (valueIsDefined(Device)) {
|
152
|
-
pdiskInfo.push({
|
153
|
-
label: 'Device',
|
154
|
-
value: _jsx(EntityStatus, { status: Device }),
|
155
|
-
});
|
156
|
-
}
|
157
|
-
if (valueIsDefined(Realtime)) {
|
158
|
-
pdiskInfo.push({
|
159
|
-
label: 'Realtime',
|
160
|
-
value: _jsx(EntityStatus, { status: Realtime }),
|
161
|
-
});
|
162
|
-
}
|
163
|
-
if (valueIsDefined(SerialNumber)) {
|
164
|
-
pdiskInfo.push({ label: 'SerialNumber', value: SerialNumber });
|
165
|
-
}
|
166
|
-
return (_jsxs("div", { children: [_jsx(InfoViewer, { className: b('pdisk-details'), info: pdiskInfo }), _jsxs("div", Object.assign({ className: b('vdisks-container') }, { children: [_jsx("div", Object.assign({ className: b('vdisks-header') }, { children: "VDisks" })), renderVDisks()] }))] }));
|
110
|
+
return (_jsxs("div", { children: [_jsx(PDiskInfo, { pDisk: data, nodeId: nodeId, className: b('pdisk-details') }), _jsxs("div", Object.assign({ className: b('vdisks-container') }, { children: [_jsx("div", Object.assign({ className: b('vdisks-header') }, { children: "VDisks" })), renderVDisks()] }))] }));
|
167
111
|
};
|
168
|
-
return (_jsxs("div", Object.assign({ className: b('pdisk'), id: id }, { children: [_jsxs("div", Object.assign({ className: b('pdisk-header') }, { children: [_jsxs("div", Object.assign({ className: b('pdisk-title-wrapper') }, { children: [_jsx(EntityStatus, { status: Device }), _jsx(PDiskTitleBadge, { label: "PDiskID", value: PDiskId, className: b('pdisk-title-id') }), _jsx(PDiskTitleBadge, { value:
|
112
|
+
return (_jsxs("div", Object.assign({ className: b('pdisk'), id: id }, { children: [_jsxs("div", Object.assign({ className: b('pdisk-header') }, { children: [_jsxs("div", Object.assign({ className: b('pdisk-title-wrapper') }, { children: [_jsx(EntityStatus, { status: Device }), _jsx(PDiskTitleBadge, { label: "PDiskID", value: PDiskId, className: b('pdisk-title-id') }), _jsx(PDiskTitleBadge, { value: Type, className: b('pdisk-title-type') }), _jsx(ProgressViewer, { value: total - available, capacity: total, formatValues: formatStorageValuesToGb, colorizeProgress: true, className: b('pdisk-title-size') }), _jsx(PDiskTitleBadge, { label: "VDisks", value: vDisks.length })] })), _jsx(Button, Object.assign({ onClick: unfolded ? onClosePDiskDetails : onOpenPDiskDetails, view: "flat-secondary" }, { children: _jsx(ArrowToggle, { direction: unfolded ? 'top' : 'bottom' }) }))] })), unfolded && renderPDiskDetails()] })));
|
169
113
|
}
|
@@ -1,3 +1,3 @@
|
|
1
1
|
/// <reference types="react" />
|
2
|
-
import type
|
2
|
+
import { type TVDiskStateInfo } from '../../../types/api/vdisk';
|
3
3
|
export declare function Vdisk({ AllocatedSize, DiskSpace, FrontQueues, Guid, Replicated, VDiskState, VDiskId, VDiskSlotId, Kind, SatisfactionRank, AvailableSize, HasUnreadableBlobs, IncarnationGuid, InstanceGuid, StoragePoolName, ReadThroughput, WriteThroughput, }: TVDiskStateInfo): JSX.Element;
|
@@ -1,12 +1,14 @@
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
2
|
import React from 'react';
|
3
3
|
import cn from 'bem-cn-lite';
|
4
|
+
import { EVDiskState } from '../../../types/api/vdisk';
|
5
|
+
import { EFlag } from '../../../types/api/enums';
|
4
6
|
import { formatStorageValuesToGb, stringifyVdiskId, } from '../../../utils/dataFormatters/dataFormatters';
|
5
7
|
import { bytesToGB, bytesToSpeed } from '../../../utils/utils';
|
6
|
-
import
|
8
|
+
import { valueIsDefined } from '../../../utils';
|
9
|
+
import { EntityStatus } from '../../../components/EntityStatus/EntityStatus';
|
7
10
|
import InfoViewer from '../../../components/InfoViewer/InfoViewer';
|
8
11
|
import { ProgressViewer } from '../../../components/ProgressViewer/ProgressViewer';
|
9
|
-
import { valueIsDefined } from './NodeStructure';
|
10
12
|
const b = cn('kv-node-structure');
|
11
13
|
export function Vdisk({ AllocatedSize, DiskSpace, FrontQueues, Guid, Replicated, VDiskState, VDiskId, VDiskSlotId, Kind, SatisfactionRank, AvailableSize, HasUnreadableBlobs, IncarnationGuid, InstanceGuid, StoragePoolName, ReadThroughput, WriteThroughput, }) {
|
12
14
|
var _a, _b, _c, _d;
|
@@ -80,5 +82,5 @@ export function Vdisk({ AllocatedSize, DiskSpace, FrontQueues, Guid, Replicated,
|
|
80
82
|
label: 'Write Throughput',
|
81
83
|
value: bytesToSpeed(WriteThroughput),
|
82
84
|
});
|
83
|
-
return (_jsxs(React.Fragment, { children: [_jsxs("div", Object.assign({ className: b('row') }, { children: [_jsx("span", Object.assign({ className: b('title') }, { children: "VDisk " })), _jsx(EntityStatus, { status: VDiskState ===
|
85
|
+
return (_jsxs(React.Fragment, { children: [_jsxs("div", Object.assign({ className: b('row') }, { children: [_jsx("span", Object.assign({ className: b('title') }, { children: "VDisk " })), _jsx(EntityStatus, { status: VDiskState === EVDiskState.OK ? EFlag.Green : EFlag.Red, name: stringifyVdiskId(VDiskId) })] })), _jsx("div", Object.assign({ className: b('column') }, { children: _jsx(InfoViewer, { className: b('section'), info: vdiskInfo }) }))] }));
|
84
86
|
}
|
@@ -1,7 +1,6 @@
|
|
1
1
|
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
2
2
|
import { useCallback, useEffect } from 'react';
|
3
3
|
import cn from 'bem-cn-lite';
|
4
|
-
import { useDispatch } from 'react-redux';
|
5
4
|
import DataTable from '@gravity-ui/react-data-table';
|
6
5
|
import { ASCENDING } from '@gravity-ui/react-data-table/build/esm/lib/constants';
|
7
6
|
import { AccessDenied } from '../../components/Errors/403';
|
@@ -13,7 +12,7 @@ import { EntitiesCount } from '../../components/EntitiesCount';
|
|
13
12
|
import { TableWithControlsLayout } from '../../components/TableWithControlsLayout/TableWithControlsLayout';
|
14
13
|
import { ResponseError } from '../../components/Errors/ResponseError';
|
15
14
|
import { DEFAULT_TABLE_SETTINGS, USE_NODES_ENDPOINT_IN_DIAGNOSTICS_KEY } from '../../utils/constants';
|
16
|
-
import { useAutofetcher, useSetting, useTypedSelector, useTableSort } from '../../utils/hooks';
|
15
|
+
import { useAutofetcher, useSetting, useTypedSelector, useTableSort, useTypedDispatch, } from '../../utils/hooks';
|
17
16
|
import { isSortableNodesProperty, isUnavailableNode, NodesUptimeFilterValues, } from '../../utils/nodes';
|
18
17
|
import { getNodes, setNodesUptimeFilter, setSearchValue, resetNodesState, getComputeNodes, setDataWasNotLoaded, setSort, } from '../../store/reducers/nodes/nodes';
|
19
18
|
import { selectFilteredNodes } from '../../store/reducers/nodes/selectors';
|
@@ -23,7 +22,7 @@ import './Nodes.scss';
|
|
23
22
|
import i18n from './i18n';
|
24
23
|
const b = cn('ydb-nodes');
|
25
24
|
export const Nodes = ({ path, additionalNodesProps = {} }) => {
|
26
|
-
const dispatch =
|
25
|
+
const dispatch = useTypedDispatch();
|
27
26
|
const isClusterNodes = !path;
|
28
27
|
// Since Nodes component is used in several places,
|
29
28
|
// we need to reset filters, searchValue and loading state
|
@@ -1,14 +1,4 @@
|
|
1
|
-
|
2
|
-
var t = {};
|
3
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
4
|
-
t[p] = s[p];
|
5
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
6
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
7
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
8
|
-
t[p[i]] = s[p[i]];
|
9
|
-
}
|
10
|
-
return t;
|
11
|
-
};
|
1
|
+
import { __rest } from "tslib";
|
12
2
|
import { jsx as _jsx } from "react/jsx-runtime";
|
13
3
|
import { USE_BACKEND_PARAMS_FOR_TABLES_KEY } from '../../utils/constants';
|
14
4
|
import { useSetting } from '../../utils/hooks';
|
@@ -1,14 +1,4 @@
|
|
1
|
-
|
2
|
-
var t = {};
|
3
|
-
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
|
4
|
-
t[p] = s[p];
|
5
|
-
if (s != null && typeof Object.getOwnPropertySymbols === "function")
|
6
|
-
for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
|
7
|
-
if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
|
8
|
-
t[p[i]] = s[p[i]];
|
9
|
-
}
|
10
|
-
return t;
|
11
|
-
};
|
1
|
+
import { __rest } from "tslib";
|
12
2
|
import { prepareNodesData } from '../../store/reducers/nodes/utils';
|
13
3
|
const getConcurrentId = (limit, offset) => {
|
14
4
|
return `getNodes|offset${offset}|limit${limit}`;
|
@@ -6,7 +6,7 @@ interface GetNodesColumnsProps {
|
|
6
6
|
tabletsPath?: string;
|
7
7
|
getNodeRef?: GetNodeRefFunc;
|
8
8
|
}
|
9
|
-
|
9
|
+
type NodesColumn = VirtualTableColumn<NodesPreparedEntity> & DataTableColumn<NodesPreparedEntity>;
|
10
10
|
export declare function getNodesColumns({ tabletsPath, getNodeRef }: GetNodesColumnsProps): NodesColumn[];
|
11
11
|
export declare function getTopNodesByLoadColumns(getNodeRef?: GetNodeRefFunc): DataTableColumn<NodesPreparedEntity>[];
|
12
12
|
export declare function getTopNodesByCpuColumns(getNodeRef?: GetNodeRefFunc): DataTableColumn<NodesPreparedEntity>[];
|
@@ -0,0 +1,86 @@
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
|
+
import { useCallback, useEffect } from 'react';
|
3
|
+
import { StringParam, useQueryParams } from 'use-query-params';
|
4
|
+
import { Helmet } from 'react-helmet-async';
|
5
|
+
import { Icon } from '@gravity-ui/uikit';
|
6
|
+
import ArrowRotateLeftIcon from '@gravity-ui/icons/svgs/arrow-rotate-left.svg';
|
7
|
+
import { getPDiskData, getPDiskStorage, setPDiskDataWasNotLoaded, } from '../../store/reducers/pdisk/pdisk';
|
8
|
+
import { setHeaderBreadcrumbs } from '../../store/reducers/header/header';
|
9
|
+
import { getNodesList, selectNodesMap } from '../../store/reducers/nodesList';
|
10
|
+
import { useAutofetcher, useTypedDispatch, useTypedSelector } from '../../utils/hooks';
|
11
|
+
import { getSeverityColor } from '../../utils/disks/helpers';
|
12
|
+
import { PageMeta } from '../../components/PageMeta/PageMeta';
|
13
|
+
import { StatusIcon } from '../../components/StatusIcon/StatusIcon';
|
14
|
+
import { PDiskInfo } from '../../components/PDiskInfo/PDiskInfo';
|
15
|
+
import { InfoViewerSkeleton } from '../../components/InfoViewerSkeleton/InfoViewerSkeleton';
|
16
|
+
import { ButtonWithConfirmDialog } from '../../components/ButtonWithConfirmDialog/ButtonWithConfirmDialog';
|
17
|
+
import { PDiskGroups } from './PDiskGroups';
|
18
|
+
import { pdiskPageCn } from './shared';
|
19
|
+
import { pDiskPageKeyset } from './i18n';
|
20
|
+
import './PDisk.scss';
|
21
|
+
export function PDisk() {
|
22
|
+
const dispatch = useTypedDispatch();
|
23
|
+
const nodesMap = useTypedSelector(selectNodesMap);
|
24
|
+
const { pDiskData, groupsData, pDiskLoading, pDiskWasLoaded, groupsLoading, groupsWasLoaded } = useTypedSelector((state) => state.pDisk);
|
25
|
+
const { NodeHost, NodeId, NodeType, NodeDC, Severity } = pDiskData;
|
26
|
+
const [{ nodeId, pDiskId }] = useQueryParams({
|
27
|
+
nodeId: StringParam,
|
28
|
+
pDiskId: StringParam,
|
29
|
+
});
|
30
|
+
useEffect(() => {
|
31
|
+
dispatch(setHeaderBreadcrumbs('pDisk', { nodeId, pDiskId }));
|
32
|
+
}, [dispatch, nodeId, pDiskId]);
|
33
|
+
useEffect(() => {
|
34
|
+
dispatch(getNodesList());
|
35
|
+
}, [dispatch]);
|
36
|
+
const fetchData = useCallback(async (isBackground) => {
|
37
|
+
if (!isBackground) {
|
38
|
+
dispatch(setPDiskDataWasNotLoaded());
|
39
|
+
}
|
40
|
+
if (nodeId && pDiskId) {
|
41
|
+
return Promise.all([
|
42
|
+
dispatch(getPDiskData({ nodeId, pDiskId })),
|
43
|
+
dispatch(getPDiskStorage({ nodeId, pDiskId })),
|
44
|
+
]);
|
45
|
+
}
|
46
|
+
return undefined;
|
47
|
+
}, [dispatch, nodeId, pDiskId]);
|
48
|
+
useAutofetcher(fetchData, [fetchData], true);
|
49
|
+
const handleRestart = async () => {
|
50
|
+
if (nodeId && pDiskId) {
|
51
|
+
return window.api.restartPDisk(nodeId, pDiskId);
|
52
|
+
}
|
53
|
+
return undefined;
|
54
|
+
};
|
55
|
+
const handleAfterRestart = async () => {
|
56
|
+
return fetchData(true);
|
57
|
+
};
|
58
|
+
const renderHelmet = () => {
|
59
|
+
const pDiskPagePart = pDiskId
|
60
|
+
? `${pDiskPageKeyset('pdisk')} ${pDiskId}`
|
61
|
+
: pDiskPageKeyset('pdisk');
|
62
|
+
const nodePagePart = NodeHost ? NodeHost : pDiskPageKeyset('node');
|
63
|
+
return (_jsx(Helmet, { titleTemplate: `%s - ${pDiskPagePart} — ${nodePagePart} — YDB Monitoring`, defaultTitle: `${pDiskPagePart} — ${nodePagePart} — YDB Monitoring` }));
|
64
|
+
};
|
65
|
+
const renderPageMeta = () => {
|
66
|
+
const hostItem = NodeHost ? `${pDiskPageKeyset('fqdn')}: ${NodeHost}` : undefined;
|
67
|
+
const nodeIdItem = NodeId ? `${pDiskPageKeyset('node')}: ${NodeId}` : undefined;
|
68
|
+
return (_jsx(PageMeta, { className: pdiskPageCn('meta'), items: [hostItem, nodeIdItem, NodeType, NodeDC] }));
|
69
|
+
};
|
70
|
+
const renderPageTitle = () => {
|
71
|
+
return (_jsxs("div", Object.assign({ className: pdiskPageCn('title') }, { children: [_jsx("span", Object.assign({ className: pdiskPageCn('title__prefix') }, { children: pDiskPageKeyset('pdisk') })), _jsx(StatusIcon, { status: getSeverityColor(Severity), size: "s" }), pDiskId] })));
|
72
|
+
};
|
73
|
+
const renderControls = () => {
|
74
|
+
return (_jsx("div", Object.assign({ className: pdiskPageCn('controls') }, { children: _jsxs(ButtonWithConfirmDialog, Object.assign({ onConfirmAction: handleRestart, onConfirmActionSuccess: handleAfterRestart, buttonDisabled: !nodeId || !pDiskId, buttonView: "normal", dialogContent: pDiskPageKeyset('restart-pdisk-dialog') }, { children: [_jsx(Icon, { data: ArrowRotateLeftIcon }), pDiskPageKeyset('restart-pdisk-button')] })) })));
|
75
|
+
};
|
76
|
+
const renderInfo = () => {
|
77
|
+
if (pDiskLoading && !pDiskWasLoaded) {
|
78
|
+
return _jsx(InfoViewerSkeleton, { className: pdiskPageCn('info'), rows: 10 });
|
79
|
+
}
|
80
|
+
return (_jsx(PDiskInfo, { pDisk: pDiskData, nodeId: nodeId, className: pdiskPageCn('info'), isPDiskPage: true }));
|
81
|
+
};
|
82
|
+
const renderGroupsTable = () => {
|
83
|
+
return (_jsx(PDiskGroups, { data: groupsData, nodesMap: nodesMap, loading: groupsLoading && !groupsWasLoaded }));
|
84
|
+
};
|
85
|
+
return (_jsxs("div", Object.assign({ className: pdiskPageCn(null) }, { children: [renderHelmet(), renderPageMeta(), renderPageTitle(), renderControls(), renderInfo(), renderGroupsTable()] })));
|
86
|
+
}
|
@@ -0,0 +1,42 @@
|
|
1
|
+
@import '../../styles//mixins.scss';
|
2
|
+
|
3
|
+
.ydb-pdisk-page {
|
4
|
+
position: relative;
|
5
|
+
|
6
|
+
display: flex;
|
7
|
+
overflow: auto;
|
8
|
+
flex-direction: column;
|
9
|
+
|
10
|
+
height: 100%;
|
11
|
+
padding-top: 20px;
|
12
|
+
padding-left: 20px;
|
13
|
+
|
14
|
+
gap: 20px;
|
15
|
+
|
16
|
+
&__meta,
|
17
|
+
&__title,
|
18
|
+
&__info,
|
19
|
+
&__controls,
|
20
|
+
&__groups-title {
|
21
|
+
position: sticky;
|
22
|
+
left: 0;
|
23
|
+
}
|
24
|
+
|
25
|
+
&__title {
|
26
|
+
display: flex;
|
27
|
+
flex-flow: row nowrap;
|
28
|
+
align-items: baseline;
|
29
|
+
|
30
|
+
@include header-2-typography();
|
31
|
+
|
32
|
+
&__prefix {
|
33
|
+
margin-right: 6px;
|
34
|
+
|
35
|
+
color: var(--g-color-text-secondary);
|
36
|
+
}
|
37
|
+
}
|
38
|
+
|
39
|
+
&__groups-title {
|
40
|
+
@include header-1-typography();
|
41
|
+
}
|
42
|
+
}
|
@@ -0,0 +1,10 @@
|
|
1
|
+
/// <reference types="react" />
|
2
|
+
import type { PreparedStorageGroup } from '../../store/reducers/storage/types';
|
3
|
+
import type { NodesMap } from '../../types/store/nodesList';
|
4
|
+
interface PDiskGroupsProps {
|
5
|
+
data: PreparedStorageGroup[];
|
6
|
+
nodesMap?: NodesMap;
|
7
|
+
loading?: boolean;
|
8
|
+
}
|
9
|
+
export declare function PDiskGroups({ data, nodesMap, loading }: PDiskGroupsProps): JSX.Element;
|
10
|
+
export {};
|