ydb-embedded-ui 6.6.1 → 6.8.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/package.json +31 -30
- package/dist/src/components/InfoViewer/InfoViewer.d.ts +1 -1
- package/dist/src/components/InfoViewer/InfoViewer.js +2 -1
- package/dist/src/components/InfoViewer/i18n/en.json +2 -1
- package/dist/src/components/InfoViewer/i18n/index.d.ts +1 -1
- package/dist/src/components/InfoViewer/i18n/index.js +1 -2
- package/dist/src/containers/App/App.d.ts +1 -1
- package/dist/src/containers/App/Content.js +1 -1
- package/dist/src/containers/App/appSlots.d.ts +1 -1
- package/dist/src/containers/AppWithClusters/AppWithClusters.js +1 -1
- package/dist/src/containers/AsideNavigation/Navigation.js +1 -3
- package/dist/src/containers/AsideNavigation/i18n/en.json +0 -2
- package/dist/src/containers/AsideNavigation/i18n/index.d.ts +1 -1
- package/dist/src/containers/AsideNavigation/i18n/index.js +1 -2
- package/dist/src/containers/Cluster/i18n/index.d.ts +1 -1
- package/dist/src/containers/Clusters/constants.d.ts +1 -1
- package/dist/src/containers/Header/Header.js +17 -21
- package/dist/src/containers/Header/Header.scss +14 -5
- package/dist/src/containers/Header/breadcrumbs.js +65 -71
- package/dist/src/containers/Heatmap/Heatmap.js +3 -3
- package/dist/src/containers/Nodes/Nodes.js +4 -4
- package/dist/src/containers/Nodes/VirtualNodes.js +2 -2
- package/dist/src/containers/Storage/Storage.js +2 -2
- package/dist/src/containers/Storage/StorageGroups/getStorageGroupsColumns.js +4 -3
- package/dist/src/containers/Tablets/Tablets.js +8 -8
- package/dist/src/containers/TabletsFilters/TabletsFilters.d.ts +2 -57
- package/dist/src/containers/TabletsFilters/TabletsFilters.js +70 -180
- package/dist/src/containers/Tenant/Acl/Acl.d.ts +3 -1
- package/dist/src/containers/Tenant/Acl/Acl.js +85 -69
- package/dist/src/containers/Tenant/Acl/Acl.scss +14 -9
- package/dist/src/containers/Tenant/Diagnostics/Autorefresh/AutorefreshControl.js +4 -5
- package/dist/src/containers/Tenant/Diagnostics/Consumers/Consumers.js +3 -3
- package/dist/src/containers/Tenant/Diagnostics/Describe/Describe.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/Describe/Describe.js +5 -6
- package/dist/src/containers/Tenant/Diagnostics/DetailedOverview/DetailedOverview.d.ts +1 -0
- package/dist/src/containers/Tenant/Diagnostics/DetailedOverview/DetailedOverview.js +3 -5
- package/dist/src/containers/Tenant/Diagnostics/Diagnostics.d.ts +2 -0
- package/dist/src/containers/Tenant/Diagnostics/Diagnostics.js +26 -50
- package/dist/src/containers/Tenant/Diagnostics/Diagnostics.scss +1 -1
- package/dist/src/containers/Tenant/Diagnostics/HotKeys/HotKeys.js +19 -58
- package/dist/src/containers/Tenant/Diagnostics/Network/Network.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/Network/Network.js +5 -5
- package/dist/src/containers/Tenant/Diagnostics/Overview/AsyncReplicationInfo/AsyncReplicationInfo.js +1 -6
- package/dist/src/containers/Tenant/Diagnostics/Overview/ChangefeedInfo/ChangefeedInfo.d.ts +2 -1
- package/dist/src/containers/Tenant/Diagnostics/Overview/ChangefeedInfo/ChangefeedInfo.js +3 -8
- package/dist/src/containers/Tenant/Diagnostics/Overview/Overview.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/Overview/Overview.js +19 -21
- package/dist/src/containers/Tenant/Diagnostics/Overview/TableInfo/TableInfo.js +3 -3
- package/dist/src/containers/Tenant/Diagnostics/Overview/TableInfo/TableInfo.scss +0 -2
- package/dist/src/containers/Tenant/Diagnostics/Overview/TopicInfo/TopicInfo.d.ts +2 -1
- package/dist/src/containers/Tenant/Diagnostics/Overview/TopicInfo/TopicInfo.js +3 -8
- package/dist/src/containers/Tenant/Diagnostics/Overview/TopicStats/TopicStats.d.ts +3 -1
- package/dist/src/containers/Tenant/Diagnostics/Overview/TopicStats/TopicStats.js +5 -5
- package/dist/src/containers/Tenant/Diagnostics/Partitions/Partitions.js +4 -12
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/Healthcheck.scss +48 -57
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/HealthcheckDetails.d.ts +2 -5
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/HealthcheckDetails.js +7 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/HealthcheckPreview.d.ts +1 -6
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/Healthcheck/HealthcheckPreview.js +22 -16
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/MetricsCards/MetricsCards.d.ts +2 -8
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/MetricsCards/MetricsCards.js +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TenantCpu.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TenantCpu.js +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopNodesByCpu.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopNodesByCpu.js +4 -4
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopNodesByLoad.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopNodesByLoad.js +4 -4
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopQueries.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopQueries.js +4 -4
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopShards.d.ts +2 -1
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantCpu/TopShards.js +5 -5
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantDashboard/TenantDashboard.js +3 -3
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantMemory/TenantMemory.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantMemory/TenantMemory.js +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantMemory/TopNodesByMemory.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantMemory/TopNodesByMemory.js +4 -4
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantOverview.js +7 -9
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantStorage/TopGroups.js +3 -3
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantStorage/TopTables.js +3 -3
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/i18n/index.d.ts +1 -1
- package/dist/src/containers/Tenant/Diagnostics/TenantOverview/useHealthcheck.js +1 -1
- package/dist/src/containers/Tenant/Diagnostics/TopQueries/TopQueries.d.ts +2 -2
- package/dist/src/containers/Tenant/Diagnostics/TopQueries/TopQueries.js +5 -5
- package/dist/src/containers/Tenant/Diagnostics/TopShards/TopShards.d.ts +3 -2
- package/dist/src/containers/Tenant/Diagnostics/TopShards/TopShards.js +8 -8
- package/dist/src/containers/Tenant/EntityTitle/EntityTitle.d.ts +6 -0
- package/dist/src/containers/Tenant/EntityTitle/EntityTitle.js +11 -0
- package/dist/src/containers/Tenant/Info/ExternalDataSource/ExternalDataSource.js +0 -6
- package/dist/src/containers/Tenant/Info/ExternalTable/ExternalTable.js +0 -6
- package/dist/src/containers/Tenant/Info/View/View.js +0 -6
- package/dist/src/containers/Tenant/ObjectGeneral/ObjectGeneral.d.ts +2 -1
- package/dist/src/containers/Tenant/ObjectGeneral/ObjectGeneral.js +7 -13
- package/dist/src/containers/Tenant/ObjectSummary/ObjectSummary.d.ts +4 -4
- package/dist/src/containers/Tenant/ObjectSummary/ObjectSummary.js +159 -63
- package/dist/src/containers/Tenant/Query/Issues/Issues.js +6 -5
- package/dist/src/containers/Tenant/Query/Preview/Preview.d.ts +2 -1
- package/dist/src/containers/Tenant/Query/Preview/Preview.js +6 -6
- package/dist/src/containers/Tenant/Query/Query.d.ts +1 -0
- package/dist/src/containers/Tenant/Query/Query.scss +1 -1
- package/dist/src/containers/Tenant/Query/QueryEditor/QueryEditor.d.ts +2 -0
- package/dist/src/containers/Tenant/Query/QueryEditor/QueryEditor.js +9 -22
- package/dist/src/containers/Tenant/Query/i18n/en.json +1 -1
- package/dist/src/containers/Tenant/Schema/SchemaTree/SchemaTree.d.ts +1 -0
- package/dist/src/containers/Tenant/Schema/SchemaTree/SchemaTree.js +11 -19
- package/dist/src/containers/Tenant/Schema/SchemaViewer/SchemaViewer.d.ts +2 -2
- package/dist/src/containers/Tenant/Schema/SchemaViewer/SchemaViewer.js +13 -8
- package/dist/src/containers/Tenant/Schema/SchemaViewer/columns.d.ts +2 -1
- package/dist/src/containers/Tenant/Schema/SchemaViewer/columns.js +21 -2
- package/dist/src/containers/Tenant/Schema/SchemaViewer/i18n/en.json +1 -0
- package/dist/src/containers/Tenant/Schema/SchemaViewer/i18n/index.d.ts +1 -1
- package/dist/src/containers/Tenant/Schema/SchemaViewer/prepareData.js +2 -1
- package/dist/src/containers/Tenant/Schema/SchemaViewer/types.d.ts +1 -0
- package/dist/src/containers/Tenant/Tenant.js +20 -36
- package/dist/src/containers/Tenant/Tenant.scss +4 -0
- package/dist/src/containers/Tenant/TenantNavigation/TenantNavigation.d.ts +2 -0
- package/dist/src/containers/Tenant/TenantNavigation/TenantNavigation.js +19 -0
- package/dist/src/containers/Tenant/TenantNavigation/TenantNavigation.scss +18 -0
- package/dist/src/containers/Tenant/TenantNavigation/useTenantNavigation.d.ts +9 -0
- package/dist/src/containers/Tenant/TenantNavigation/useTenantNavigation.js +44 -0
- package/dist/src/containers/Tenant/i18n/en.json +22 -1
- package/dist/src/containers/Tenant/i18n/index.d.ts +1 -1
- package/dist/src/containers/Tenant/utils/index.d.ts +1 -0
- package/dist/src/containers/Tenant/utils/index.js +6 -0
- package/dist/src/containers/Tenant/utils/queryTemplates.d.ts +4 -0
- package/dist/src/containers/Tenant/utils/queryTemplates.js +32 -0
- package/dist/src/containers/Tenant/utils/schemaActions.js +18 -2
- package/dist/src/containers/UserSettings/Setting.d.ts +7 -9
- package/dist/src/containers/UserSettings/Setting.js +13 -28
- package/dist/src/containers/UserSettings/UserSettings.d.ts +0 -2
- package/dist/src/containers/UserSettings/UserSettings.js +3 -6
- package/dist/src/containers/UserSettings/i18n/en.json +2 -2
- package/dist/src/containers/UserSettings/settings.js +3 -3
- package/dist/src/lib.d.ts +1 -1
- package/dist/src/lib.js +1 -1
- package/dist/src/routes.d.ts +1 -1
- package/dist/src/routes.js +3 -1
- package/dist/src/services/api.d.ts +6 -1
- package/dist/src/services/api.js +24 -3
- package/dist/src/services/settings.d.ts +1 -0
- package/dist/src/services/settings.js +3 -2
- package/dist/src/store/configureStore.d.ts +36 -134
- package/dist/src/store/configureStore.js +2 -15
- package/dist/src/store/defaultStore.d.ts +17 -81
- package/dist/src/store/reducers/api.js +0 -1
- package/dist/src/store/reducers/authentication/authentication.d.ts +51 -243
- package/dist/src/store/reducers/healthcheckInfo/healthcheckInfo.d.ts +196 -849
- package/dist/src/store/reducers/healthcheckInfo/healthcheckInfo.js +3 -3
- package/dist/src/store/reducers/hotKeys/hotKeys.d.ts +6 -25
- package/dist/src/store/reducers/hotKeys/hotKeys.js +36 -49
- package/dist/src/store/reducers/index.d.ts +23 -100
- package/dist/src/store/reducers/index.js +0 -8
- package/dist/src/store/reducers/node/selectors.d.ts +0 -40
- package/dist/src/store/reducers/nodesList.d.ts +0 -40
- package/dist/src/store/reducers/schema/schema.d.ts +13 -149
- package/dist/src/store/reducers/schema/schema.js +45 -90
- package/dist/src/store/reducers/schema/types.d.ts +2 -21
- package/dist/src/store/reducers/schemaAcl/schemaAcl.d.ts +8 -135
- package/dist/src/store/reducers/schemaAcl/schemaAcl.js +18 -44
- package/dist/src/store/reducers/settings/settings.d.ts +17 -23
- package/dist/src/store/reducers/settings/settings.js +40 -33
- package/dist/src/store/reducers/settings/types.d.ts +1 -12
- package/dist/src/store/reducers/tablets.d.ts +288 -41
- package/dist/src/store/reducers/tablets.js +8 -4
- package/dist/src/store/reducers/tabletsFilters.d.ts +11 -164
- package/dist/src/store/reducers/tabletsFilters.js +14 -76
- package/dist/src/store/reducers/tenants/selectors.d.ts +8 -362
- package/dist/src/store/reducers/topic.d.ts +0 -600
- package/dist/src/store/state-url-mapping.js +0 -3
- package/dist/src/styles/mixins.scss +5 -0
- package/dist/src/styles/themes.scss +1 -1
- package/dist/src/types/api/acl.d.ts +2 -1
- package/dist/src/types/api/schema/schema.d.ts +5 -0
- package/dist/src/utils/constants.d.ts +1 -1
- package/dist/src/utils/constants.js +1 -1
- package/dist/src/utils/dataFormatters/dataFormatters.d.ts +2 -1
- package/dist/src/utils/dataFormatters/dataFormatters.js +7 -3
- package/dist/src/utils/hooks/index.d.ts +1 -0
- package/dist/src/utils/hooks/index.js +1 -0
- package/dist/src/utils/hooks/useAutoRefreshInterval.d.ts +1 -0
- package/dist/src/utils/hooks/useAutoRefreshInterval.js +5 -0
- package/dist/src/utils/utils.js +2 -1
- package/package.json +31 -30
- package/dist/src/components/InfoViewer/i18n/ru.json +0 -4
- package/dist/src/components/InfoViewer/schemaOverview/CDCStreamOverview.d.ts +0 -6
- package/dist/src/components/InfoViewer/schemaOverview/CDCStreamOverview.js +0 -17
- package/dist/src/components/InfoViewer/schemaOverview/PersQueueGroupOverview.d.ts +0 -6
- package/dist/src/components/InfoViewer/schemaOverview/PersQueueGroupOverview.js +0 -20
- package/dist/src/components/InfoViewer/schemaOverview/index.d.ts +0 -2
- package/dist/src/components/InfoViewer/schemaOverview/index.js +0 -2
- package/dist/src/containers/AsideNavigation/i18n/ru.json +0 -10
- package/dist/src/containers/AsideNavigation/useNavigationMenuItems.d.ts +0 -2
- package/dist/src/containers/AsideNavigation/useNavigationMenuItems.js +0 -54
- package/dist/src/containers/UserSettings/UserSettings.scss +0 -9
- package/dist/src/store/reducers/host.d.ts +0 -130
- package/dist/src/store/reducers/host.js +0 -26
- package/dist/src/store/reducers/hotKeys/types.d.ts +0 -10
- package/dist/src/store/reducers/hotKeys/types.js +0 -1
- package/dist/src/store/reducers/schemaAcl/types.d.ts +0 -12
- package/dist/src/store/reducers/schemaAcl/types.js +0 -1
- package/dist/src/types/store/host.d.ts +0 -15
- package/dist/src/types/store/host.js +0 -1
package/dist/src/containers/Tenant/Diagnostics/TenantOverview/TenantMemory/TopNodesByMemory.js
CHANGED
@@ -1,19 +1,19 @@
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
2
2
|
import { TENANT_DIAGNOSTICS_TABS_IDS } from '../../../../../store/reducers/tenant/constants';
|
3
3
|
import { topNodesApi } from '../../../../../store/reducers/tenantOverview/topNodes/topNodes';
|
4
|
-
import {
|
4
|
+
import { useAutoRefreshInterval, useSearchQuery } from '../../../../../utils/hooks';
|
5
5
|
import { NODES_COLUMNS_WIDTH_LS_KEY, getTopNodesByMemoryColumns, } from '../../../../Nodes/getNodesColumns';
|
6
6
|
import { TenantTabsGroups, getTenantPath } from '../../../TenantPages';
|
7
7
|
import { TenantOverviewTableLayout } from '../TenantOverviewTableLayout';
|
8
8
|
import { getSectionTitle } from '../getSectionTitle';
|
9
9
|
import i18n from '../i18n';
|
10
|
-
export function TopNodesByMemory({
|
10
|
+
export function TopNodesByMemory({ tenantName, additionalNodesProps }) {
|
11
11
|
const query = useSearchQuery();
|
12
|
-
const
|
12
|
+
const [autoRefreshInterval] = useAutoRefreshInterval();
|
13
13
|
const columns = getTopNodesByMemoryColumns({
|
14
14
|
getNodeRef: additionalNodesProps === null || additionalNodesProps === void 0 ? void 0 : additionalNodesProps.getNodeRef,
|
15
15
|
});
|
16
|
-
const { currentData, isFetching, error } = topNodesApi.useGetTopNodesQuery({ tenant:
|
16
|
+
const { currentData, isFetching, error } = topNodesApi.useGetTopNodesQuery({ tenant: tenantName, sortValue: 'Memory' }, { pollingInterval: autoRefreshInterval });
|
17
17
|
const loading = isFetching && currentData === undefined;
|
18
18
|
const topNodes = currentData;
|
19
19
|
const title = getSectionTitle({
|
@@ -5,7 +5,7 @@ import { TENANT_METRICS_TABS_IDS } from '../../../../store/reducers/tenant/const
|
|
5
5
|
import { tenantApi } from '../../../../store/reducers/tenant/tenant';
|
6
6
|
import { calculateTenantMetrics } from '../../../../store/reducers/tenants/utils';
|
7
7
|
import { TENANT_DEFAULT_TITLE } from '../../../../utils/constants';
|
8
|
-
import { useTypedSelector } from '../../../../utils/hooks';
|
8
|
+
import { useAutoRefreshInterval, useTypedSelector } from '../../../../utils/hooks';
|
9
9
|
import { mapDatabaseTypeToDBName } from '../../utils/schema';
|
10
10
|
import { DefaultOverviewContent } from './DefaultOverviewContent/DefaultOverviewContent';
|
11
11
|
import { HealthcheckDetails } from './Healthcheck/HealthcheckDetails';
|
@@ -13,16 +13,14 @@ import { MetricsCards } from './MetricsCards/MetricsCards';
|
|
13
13
|
import { TenantCpu } from './TenantCpu/TenantCpu';
|
14
14
|
import { TenantMemory } from './TenantMemory/TenantMemory';
|
15
15
|
import { TenantStorage } from './TenantStorage/TenantStorage';
|
16
|
-
import { useHealthcheck } from './useHealthcheck';
|
17
16
|
import { b } from './utils';
|
18
17
|
import './TenantOverview.scss';
|
19
18
|
export function TenantOverview({ tenantName, additionalTenantProps, additionalNodesProps, }) {
|
20
19
|
var _a;
|
21
20
|
const { metricsTab } = useTypedSelector((state) => state.tenant);
|
22
|
-
const
|
23
|
-
const { issueTrees, issuesStatistics, selfCheckResult, loading: healthcheckLoading, error: healthcheckError, refetch: fetchHealthcheck, } = useHealthcheck(tenantName, { autorefresh });
|
21
|
+
const [autoRefreshInterval] = useAutoRefreshInterval();
|
24
22
|
const { currentData: tenant, isFetching } = tenantApi.useGetTenantInfoQuery({ path: tenantName }, {
|
25
|
-
pollingInterval:
|
23
|
+
pollingInterval: autoRefreshInterval,
|
26
24
|
});
|
27
25
|
const tenantLoading = isFetching && tenant === undefined;
|
28
26
|
const { Name, Type, Overall } = tenant || {};
|
@@ -40,16 +38,16 @@ export function TenantOverview({ tenantName, additionalTenantProps, additionalNo
|
|
40
38
|
const renderTabContent = () => {
|
41
39
|
switch (metricsTab) {
|
42
40
|
case TENANT_METRICS_TABS_IDS.cpu: {
|
43
|
-
return _jsx(TenantCpu, {
|
41
|
+
return (_jsx(TenantCpu, { tenantName: tenantName, additionalNodesProps: additionalNodesProps }));
|
44
42
|
}
|
45
43
|
case TENANT_METRICS_TABS_IDS.storage: {
|
46
44
|
return _jsx(TenantStorage, { tenantName: tenantName, metrics: storageMetrics });
|
47
45
|
}
|
48
46
|
case TENANT_METRICS_TABS_IDS.memory: {
|
49
|
-
return _jsx(TenantMemory, {
|
47
|
+
return _jsx(TenantMemory, { tenantName: tenantName });
|
50
48
|
}
|
51
49
|
case TENANT_METRICS_TABS_IDS.healthcheck: {
|
52
|
-
return
|
50
|
+
return _jsx(HealthcheckDetails, { tenantName: tenantName });
|
53
51
|
}
|
54
52
|
default: {
|
55
53
|
return _jsx(DefaultOverviewContent, { database: tenantName });
|
@@ -59,5 +57,5 @@ export function TenantOverview({ tenantName, additionalTenantProps, additionalNo
|
|
59
57
|
if (tenantLoading) {
|
60
58
|
return (_jsx("div", { className: b('loader'), children: _jsx(Loader, { size: "m" }) }));
|
61
59
|
}
|
62
|
-
return (_jsxs("div", { className: b(), children: [_jsxs("div", { className: b('info'), children: [_jsx("div", { className: b('top-label'), children: tenantType }), _jsxs("div", { className: b('top'), children: [renderName(), (_a = additionalTenantProps === null || additionalTenantProps === void 0 ? void 0 : additionalTenantProps.getMonitoringLink) === null || _a === void 0 ? void 0 : _a.call(additionalTenantProps, Name, Type)] }), _jsx(MetricsCards, { poolsCpuStats: poolsStats, memoryStats: memoryStats, blobStorageStats: blobStorageStats, tabletStorageStats: tabletStorageStats,
|
60
|
+
return (_jsxs("div", { className: b(), children: [_jsxs("div", { className: b('info'), children: [_jsx("div", { className: b('top-label'), children: tenantType }), _jsxs("div", { className: b('top'), children: [renderName(), (_a = additionalTenantProps === null || additionalTenantProps === void 0 ? void 0 : additionalTenantProps.getMonitoringLink) === null || _a === void 0 ? void 0 : _a.call(additionalTenantProps, Name, Type)] }), _jsx(MetricsCards, { poolsCpuStats: poolsStats, memoryStats: memoryStats, blobStorageStats: blobStorageStats, tabletStorageStats: tabletStorageStats, tenantName: tenantName })] }), renderTabContent()] }));
|
63
61
|
}
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
2
2
|
import { TENANT_DIAGNOSTICS_TABS_IDS } from '../../../../../store/reducers/tenant/constants';
|
3
3
|
import { topStorageGroupsApi } from '../../../../../store/reducers/tenantOverview/topStorageGroups/topStorageGroups';
|
4
|
-
import {
|
4
|
+
import { useAutoRefreshInterval, useSearchQuery } from '../../../../../utils/hooks';
|
5
5
|
import { STORAGE_GROUPS_COLUMNS_WIDTH_LS_KEY, getStorageTopGroupsColumns, } from '../../../../Storage/StorageGroups/getStorageGroupsColumns';
|
6
6
|
import { TenantTabsGroups, getTenantPath } from '../../../TenantPages';
|
7
7
|
import { TenantOverviewTableLayout } from '../TenantOverviewTableLayout';
|
@@ -9,9 +9,9 @@ import { getSectionTitle } from '../getSectionTitle';
|
|
9
9
|
import i18n from '../i18n';
|
10
10
|
export function TopGroups({ tenant }) {
|
11
11
|
const query = useSearchQuery();
|
12
|
-
const
|
12
|
+
const [autoRefreshInterval] = useAutoRefreshInterval();
|
13
13
|
const columns = getStorageTopGroupsColumns();
|
14
|
-
const { currentData, isFetching, error } = topStorageGroupsApi.useGetTopStorageGroupsQuery({ tenant }, { pollingInterval:
|
14
|
+
const { currentData, isFetching, error } = topStorageGroupsApi.useGetTopStorageGroupsQuery({ tenant }, { pollingInterval: autoRefreshInterval });
|
15
15
|
const loading = isFetching && currentData === undefined;
|
16
16
|
const topGroups = currentData;
|
17
17
|
const title = getSectionTitle({
|
@@ -5,7 +5,7 @@ import { CellWithPopover } from '../../../../../components/CellWithPopover/CellW
|
|
5
5
|
import { LinkToSchemaObject } from '../../../../../components/LinkToSchemaObject/LinkToSchemaObject';
|
6
6
|
import { topTablesApi } from '../../../../../store/reducers/tenantOverview/executeTopTables/executeTopTables';
|
7
7
|
import { formatBytes, getSizeWithSignificantDigits } from '../../../../../utils/bytesParsers';
|
8
|
-
import {
|
8
|
+
import { useAutoRefreshInterval } from '../../../../../utils/hooks';
|
9
9
|
import { parseQueryErrorToString } from '../../../../../utils/query';
|
10
10
|
import { TenantOverviewTableLayout } from '../TenantOverviewTableLayout';
|
11
11
|
import { getSectionTitle } from '../getSectionTitle';
|
@@ -14,8 +14,8 @@ import '../TenantOverview.scss';
|
|
14
14
|
const TOP_TABLES_COLUMNS_WIDTH_LS_KEY = 'topTablesTableColumnsWidth';
|
15
15
|
export function TopTables({ path }) {
|
16
16
|
const location = useLocation();
|
17
|
-
const
|
18
|
-
const { currentData, error, isFetching } = topTablesApi.useGetTopTablesQuery({ path }, { pollingInterval:
|
17
|
+
const [autoRefreshInterval] = useAutoRefreshInterval();
|
18
|
+
const { currentData, error, isFetching } = topTablesApi.useGetTopTablesQuery({ path }, { pollingInterval: autoRefreshInterval });
|
19
19
|
const loading = isFetching && currentData === undefined;
|
20
20
|
const { result: data } = currentData || {};
|
21
21
|
const formatSize = (value) => {
|
@@ -1,2 +1,2 @@
|
|
1
|
-
declare const _default: (key: "nodes" | "queries" | "groups" | "
|
1
|
+
declare const _default: (key: "nodes" | "queries" | "groups" | "no-data" | "top" | "shards" | "tables" | "no-pools-data" | "top-nodes.empty-data" | "top-groups.empty-data" | "by-pools-usage" | "by-cpu-time" | "by-cpu-usage" | "by-load" | "by-memory" | "by-usage" | "by-size" | "cards.cpu-label" | "cards.storage-label" | "cards.memory-label" | "charts.queries-per-second" | "charts.transaction-latency" | "charts.cpu-usage" | "charts.storage-usage" | "charts.memory-usage" | "storage.tablet-storage-title" | "storage.tablet-storage-description" | "storage.db-storage-title" | "storage.db-storage-description", params?: import("@gravity-ui/i18n").Params | undefined) => string;
|
2
2
|
export default _default;
|
@@ -2,7 +2,7 @@ import { healthcheckApi, selectIssuesStatistics, selectIssuesTrees, } from '../.
|
|
2
2
|
import { SelfCheckResult } from '../../../../types/api/healthcheck';
|
3
3
|
import { useTypedSelector } from '../../../../utils/hooks';
|
4
4
|
export const useHealthcheck = (tenantName, { autorefresh } = {}) => {
|
5
|
-
const { currentData: data, isFetching, error, refetch, } = healthcheckApi.useGetHealthcheckInfoQuery(tenantName, {
|
5
|
+
const { currentData: data, isFetching, error, refetch, } = healthcheckApi.useGetHealthcheckInfoQuery({ database: tenantName }, {
|
6
6
|
pollingInterval: autorefresh,
|
7
7
|
});
|
8
8
|
const selfCheckResult = (data === null || data === void 0 ? void 0 : data.self_check_result) || SelfCheckResult.UNSPECIFIED;
|
@@ -1,8 +1,8 @@
|
|
1
1
|
import type { EPathType } from '../../../../types/api/schema';
|
2
2
|
import './TopQueries.scss';
|
3
3
|
interface TopQueriesProps {
|
4
|
-
|
4
|
+
tenantName: string;
|
5
5
|
type?: EPathType;
|
6
6
|
}
|
7
|
-
export declare const TopQueries: ({
|
7
|
+
export declare const TopQueries: ({ tenantName, type }: TopQueriesProps) => import("react/jsx-runtime").JSX.Element;
|
8
8
|
export {};
|
@@ -11,7 +11,7 @@ import { setTopQueriesFilters, topQueriesApi, } from '../../../../store/reducers
|
|
11
11
|
import { TENANT_PAGE, TENANT_PAGES_IDS, TENANT_QUERY_TABS_ID, } from '../../../../store/reducers/tenant/constants';
|
12
12
|
import { cn } from '../../../../utils/cn';
|
13
13
|
import { isSortableTopQueriesProperty } from '../../../../utils/diagnostics';
|
14
|
-
import { useTypedDispatch, useTypedSelector } from '../../../../utils/hooks';
|
14
|
+
import { useAutoRefreshInterval, useTypedDispatch, useTypedSelector } from '../../../../utils/hooks';
|
15
15
|
import { parseQueryErrorToString } from '../../../../utils/query';
|
16
16
|
import { TenantTabsGroups, getTenantPath } from '../../TenantPages';
|
17
17
|
import { QUERY_TABLE_SETTINGS } from '../../utils/constants';
|
@@ -20,16 +20,16 @@ import { TOP_QUERIES_COLUMNS_WIDTH_LS_KEY, getTopQueriesColumns } from './getTop
|
|
20
20
|
import i18n from './i18n';
|
21
21
|
import './TopQueries.scss';
|
22
22
|
const b = cn('kv-top-queries');
|
23
|
-
export const TopQueries = ({
|
23
|
+
export const TopQueries = ({ tenantName, type }) => {
|
24
24
|
const dispatch = useTypedDispatch();
|
25
25
|
const location = useLocation();
|
26
26
|
const history = useHistory();
|
27
|
-
const
|
27
|
+
const [autoRefreshInterval] = useAutoRefreshInterval();
|
28
28
|
const filters = useTypedSelector((state) => state.executeTopQueries);
|
29
29
|
const { currentData, isFetching, error } = topQueriesApi.useGetTopQueriesQuery({
|
30
|
-
database:
|
30
|
+
database: tenantName,
|
31
31
|
filters,
|
32
|
-
}, { pollingInterval:
|
32
|
+
}, { pollingInterval: autoRefreshInterval });
|
33
33
|
const loading = isFetching && currentData === undefined;
|
34
34
|
const { result: data } = currentData || {};
|
35
35
|
const rawColumns = getTopQueriesColumns();
|
@@ -1,8 +1,9 @@
|
|
1
1
|
import type { EPathType } from '../../../../types/api/schema';
|
2
2
|
import './TopShards.scss';
|
3
3
|
interface TopShardsProps {
|
4
|
-
|
4
|
+
tenantName: string;
|
5
|
+
path: string;
|
5
6
|
type?: EPathType;
|
6
7
|
}
|
7
|
-
export declare const TopShards: ({
|
8
|
+
export declare const TopShards: ({ tenantName, path, type }: TopShardsProps) => import("react/jsx-runtime").JSX.Element;
|
8
9
|
export {};
|
@@ -10,7 +10,7 @@ import { cn } from '../../../../utils/cn';
|
|
10
10
|
import { DEFAULT_TABLE_SETTINGS, HOUR_IN_SECONDS } from '../../../../utils/constants';
|
11
11
|
import { formatDateTime } from '../../../../utils/dataFormatters/dataFormatters';
|
12
12
|
import { isSortableTopShardsProperty } from '../../../../utils/diagnostics';
|
13
|
-
import { useTypedDispatch, useTypedSelector } from '../../../../utils/hooks';
|
13
|
+
import { useAutoRefreshInterval, useTypedDispatch, useTypedSelector } from '../../../../utils/hooks';
|
14
14
|
import { parseQueryErrorToString } from '../../../../utils/query';
|
15
15
|
import { isColumnEntityType } from '../../utils/schema';
|
16
16
|
import { Filters } from './Filters';
|
@@ -60,10 +60,10 @@ function fillDateRangeFor(value) {
|
|
60
60
|
value.from = value.to - HOUR_IN_SECONDS * 1000;
|
61
61
|
return value;
|
62
62
|
}
|
63
|
-
export const TopShards = ({
|
63
|
+
export const TopShards = ({ tenantName, path, type }) => {
|
64
64
|
const dispatch = useTypedDispatch();
|
65
65
|
const location = useLocation();
|
66
|
-
const
|
66
|
+
const [autoRefreshInterval] = useAutoRefreshInterval();
|
67
67
|
const storeFilters = useTypedSelector((state) => state.shardsWorkload);
|
68
68
|
// default filters shouldn't propagate into URL until user interacts with the control
|
69
69
|
// redux initial value can't be used, as it synchronizes with URL
|
@@ -79,11 +79,11 @@ export const TopShards = ({ tenantPath, type }) => {
|
|
79
79
|
});
|
80
80
|
const [sortOrder, setSortOrder] = React.useState(tableColumnsNames.CPUCores);
|
81
81
|
const { data: result, isFetching, error, } = shardApi.useSendShardQueryQuery({
|
82
|
-
database:
|
83
|
-
path:
|
82
|
+
database: tenantName,
|
83
|
+
path: path,
|
84
84
|
sortOrder: stringToQuerySortOrder(sortOrder),
|
85
85
|
filters,
|
86
|
-
}, { pollingInterval:
|
86
|
+
}, { pollingInterval: autoRefreshInterval });
|
87
87
|
const loading = isFetching && result === undefined;
|
88
88
|
const { result: data } = result !== null && result !== void 0 ? result : {};
|
89
89
|
const onSort = (newSortOrder) => {
|
@@ -110,7 +110,7 @@ export const TopShards = ({ tenantPath, type }) => {
|
|
110
110
|
setFilters((state) => (Object.assign(Object.assign({}, state), newStateValue)));
|
111
111
|
};
|
112
112
|
const tableColumns = React.useMemo(() => {
|
113
|
-
const rawColumns = getShardsWorkloadColumns(
|
113
|
+
const rawColumns = getShardsWorkloadColumns(tenantName, location);
|
114
114
|
const columns = rawColumns.map((column) => (Object.assign(Object.assign({}, column), { sortable: isSortableTopShardsProperty(column.name) })));
|
115
115
|
if (filters.mode === EShardsWorkloadMode.History) {
|
116
116
|
// after NodeId
|
@@ -129,7 +129,7 @@ export const TopShards = ({ tenantPath, type }) => {
|
|
129
129
|
});
|
130
130
|
}
|
131
131
|
return columns;
|
132
|
-
}, [filters.mode,
|
132
|
+
}, [filters.mode, location, tenantName]);
|
133
133
|
const renderControls = () => {
|
134
134
|
return _jsx(Filters, { value: filters, onChange: handleFiltersChange });
|
135
135
|
};
|
@@ -0,0 +1,6 @@
|
|
1
|
+
import type { TPathDescription } from '../../../types/api/schema';
|
2
|
+
interface EntityTitleProps {
|
3
|
+
data?: TPathDescription;
|
4
|
+
}
|
5
|
+
export declare function EntityTitle({ data }: EntityTitleProps): string | import("react/jsx-runtime").JSX.Element | undefined;
|
6
|
+
export {};
|
@@ -0,0 +1,11 @@
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
|
+
import { Flex, Label } from '@gravity-ui/uikit';
|
3
|
+
import i18n from '../i18n';
|
4
|
+
import { getEntityName, isReadOnlyTable } from '../utils';
|
5
|
+
export function EntityTitle({ data }) {
|
6
|
+
const entityName = getEntityName(data);
|
7
|
+
if (isReadOnlyTable(data)) {
|
8
|
+
return (_jsxs(Flex, { gap: 1, wrap: 'nowrap', children: [entityName, " ", _jsx(Label, { children: i18n('label.read-only') })] }));
|
9
|
+
}
|
10
|
+
return entityName;
|
11
|
+
}
|
@@ -1,10 +1,8 @@
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
2
|
import { EntityStatus } from '../../../../components/EntityStatus/EntityStatus';
|
3
|
-
import { ResponseError } from '../../../../components/Errors/ResponseError';
|
4
3
|
import { InfoViewer } from '../../../../components/InfoViewer';
|
5
4
|
import { formatCommonItem } from '../../../../components/InfoViewer/formatters';
|
6
5
|
import { cn } from '../../../../utils/cn';
|
7
|
-
import { useTypedSelector } from '../../../../utils/hooks';
|
8
6
|
import { getEntityName } from '../../utils';
|
9
7
|
import i18n from '../i18n';
|
10
8
|
import './ExternalDataSource.scss';
|
@@ -38,10 +36,6 @@ const prepareExternalDataSourceInfo = (data) => {
|
|
38
36
|
};
|
39
37
|
const ExternalDataSource = ({ data, prepareData }) => {
|
40
38
|
const entityName = getEntityName(data === null || data === void 0 ? void 0 : data.PathDescription);
|
41
|
-
const { error: schemaError } = useTypedSelector((state) => state.schema);
|
42
|
-
if (schemaError) {
|
43
|
-
return _jsx(ResponseError, { error: schemaError });
|
44
|
-
}
|
45
39
|
if (!data) {
|
46
40
|
return _jsxs("div", { className: "error", children: ["No ", entityName, " data"] });
|
47
41
|
}
|
@@ -1,13 +1,11 @@
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
2
|
import { useLocation } from 'react-router';
|
3
3
|
import { EntityStatus } from '../../../../components/EntityStatus/EntityStatus';
|
4
|
-
import { ResponseError } from '../../../../components/Errors/ResponseError';
|
5
4
|
import { InfoViewer } from '../../../../components/InfoViewer';
|
6
5
|
import { formatCommonItem } from '../../../../components/InfoViewer/formatters';
|
7
6
|
import { LinkWithIcon } from '../../../../components/LinkWithIcon/LinkWithIcon';
|
8
7
|
import { createExternalUILink, parseQuery } from '../../../../routes';
|
9
8
|
import { cn } from '../../../../utils/cn';
|
10
|
-
import { useTypedSelector } from '../../../../utils/hooks';
|
11
9
|
import { getEntityName } from '../../utils';
|
12
10
|
import i18n from '../i18n';
|
13
11
|
import './ExternalTable.scss';
|
@@ -43,10 +41,6 @@ const ExternalTable = ({ data, prepareData }) => {
|
|
43
41
|
const query = parseQuery(location);
|
44
42
|
const pathToDataSource = createExternalUILink(Object.assign(Object.assign({}, query), { schema: (_b = (_a = data === null || data === void 0 ? void 0 : data.PathDescription) === null || _a === void 0 ? void 0 : _a.ExternalTableDescription) === null || _b === void 0 ? void 0 : _b.DataSourcePath }));
|
45
43
|
const entityName = getEntityName(data === null || data === void 0 ? void 0 : data.PathDescription);
|
46
|
-
const { error: schemaError } = useTypedSelector((state) => state.schema);
|
47
|
-
if (schemaError) {
|
48
|
-
return _jsx(ResponseError, { error: schemaError });
|
49
|
-
}
|
50
44
|
if (!data) {
|
51
45
|
return _jsxs("div", { className: "error", children: ["No ", entityName, " data"] });
|
52
46
|
}
|
@@ -1,9 +1,7 @@
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
2
|
import { DefinitionList } from '@gravity-ui/components';
|
3
3
|
import { Text } from '@gravity-ui/uikit';
|
4
|
-
import { ResponseError } from '../../../../components/Errors/ResponseError';
|
5
4
|
import { cn } from '../../../../utils/cn';
|
6
|
-
import { useTypedSelector } from '../../../../utils/hooks';
|
7
5
|
import { getEntityName } from '../../utils';
|
8
6
|
import i18n from '../i18n';
|
9
7
|
const b = cn('ydb-view-info');
|
@@ -21,10 +19,6 @@ const prepareViewItems = (data) => {
|
|
21
19
|
};
|
22
20
|
export function ViewInfo({ data }) {
|
23
21
|
const entityName = getEntityName(data === null || data === void 0 ? void 0 : data.PathDescription);
|
24
|
-
const { error: schemaError } = useTypedSelector((state) => state.schema);
|
25
|
-
if (schemaError) {
|
26
|
-
return _jsx(ResponseError, { error: schemaError });
|
27
|
-
}
|
28
22
|
if (!data) {
|
29
23
|
return _jsxs("div", { className: "error", children: ["No ", entityName, " data"] });
|
30
24
|
}
|
@@ -4,8 +4,9 @@ import './ObjectGeneral.scss';
|
|
4
4
|
interface ObjectGeneralProps {
|
5
5
|
type?: EPathType;
|
6
6
|
tenantName: string;
|
7
|
+
path: string;
|
7
8
|
additionalTenantProps?: AdditionalTenantsProps;
|
8
9
|
additionalNodesProps?: AdditionalNodesProps;
|
9
10
|
}
|
10
|
-
declare function ObjectGeneral(props: ObjectGeneralProps): import("react/jsx-runtime").JSX.Element
|
11
|
+
declare function ObjectGeneral(props: ObjectGeneralProps): import("react/jsx-runtime").JSX.Element;
|
11
12
|
export default ObjectGeneral;
|
@@ -1,33 +1,27 @@
|
|
1
|
-
import { jsx as _jsx } from "react/jsx-runtime";
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
2
2
|
import { useThemeValue } from '@gravity-ui/uikit';
|
3
3
|
import { TENANT_PAGES_IDS } from '../../../store/reducers/tenant/constants';
|
4
4
|
import { cn } from '../../../utils/cn';
|
5
5
|
import { useTypedSelector } from '../../../utils/hooks';
|
6
6
|
import Diagnostics from '../Diagnostics/Diagnostics';
|
7
7
|
import { Query } from '../Query/Query';
|
8
|
+
import { TenantNavigation } from '../TenantNavigation/TenantNavigation';
|
8
9
|
import './ObjectGeneral.scss';
|
9
10
|
const b = cn('object-general');
|
10
11
|
function ObjectGeneral(props) {
|
11
12
|
const theme = useThemeValue();
|
12
13
|
const { tenantPage } = useTypedSelector((state) => state.tenant);
|
13
|
-
const
|
14
|
-
const { type, additionalTenantProps, additionalNodesProps, tenantName } = props;
|
14
|
+
const renderPageContent = () => {
|
15
|
+
const { type, additionalTenantProps, additionalNodesProps, tenantName, path } = props;
|
15
16
|
switch (tenantPage) {
|
16
17
|
case TENANT_PAGES_IDS.query: {
|
17
|
-
return _jsx(Query, {
|
18
|
+
return _jsx(Query, { tenantName: tenantName, path: path, theme: theme, type: type });
|
18
19
|
}
|
19
20
|
default: {
|
20
|
-
return (_jsx(Diagnostics, { type: type, additionalTenantProps: additionalTenantProps, additionalNodesProps: additionalNodesProps }));
|
21
|
+
return (_jsx(Diagnostics, { type: type, tenantName: tenantName, path: path, additionalTenantProps: additionalTenantProps, additionalNodesProps: additionalNodesProps }));
|
21
22
|
}
|
22
23
|
}
|
23
24
|
};
|
24
|
-
|
25
|
-
const { tenantName } = props;
|
26
|
-
if (!tenantName) {
|
27
|
-
return null;
|
28
|
-
}
|
29
|
-
return _jsx("div", { className: b(), children: renderTabContent() });
|
30
|
-
};
|
31
|
-
return renderContent();
|
25
|
+
return (_jsxs("div", { className: b(), children: [_jsx(TenantNavigation, {}), renderPageContent()] }));
|
32
26
|
}
|
33
27
|
export default ObjectGeneral;
|
@@ -1,13 +1,13 @@
|
|
1
|
-
import
|
2
|
-
import { EPathType } from '../../../types/api/schema';
|
1
|
+
import { EPathSubType, EPathType } from '../../../types/api/schema';
|
3
2
|
import './ObjectSummary.scss';
|
4
3
|
interface ObjectSummaryProps {
|
5
4
|
type?: EPathType;
|
6
5
|
subType?: EPathSubType;
|
7
|
-
tenantName
|
6
|
+
tenantName: string;
|
7
|
+
path: string;
|
8
8
|
onCollapseSummary: VoidFunction;
|
9
9
|
onExpandSummary: VoidFunction;
|
10
10
|
isCollapsed: boolean;
|
11
11
|
}
|
12
|
-
export declare function ObjectSummary({ type, subType, tenantName, onCollapseSummary, onExpandSummary, isCollapsed, }: ObjectSummaryProps): import("react/jsx-runtime").JSX.Element
|
12
|
+
export declare function ObjectSummary({ type, subType, tenantName, path, onCollapseSummary, onExpandSummary, isCollapsed, }: ObjectSummaryProps): import("react/jsx-runtime").JSX.Element;
|
13
13
|
export {};
|