diff --git a/package-lock.json b/package-lock.json index 6e215962cc..7dea27a6a9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -54,7 +54,7 @@ "use-query-params": "^2.2.1", "uuid": "^10.0.0", "web-vitals": "^1.1.2", - "ydb-ui-components": "^4.4.0", + "ydb-ui-components": "^4.5.0", "zod": "^3.24.1" }, "devDependencies": { @@ -29115,9 +29115,10 @@ } }, "node_modules/ydb-ui-components": { - "version": "4.4.0", - "resolved": "https://registry.npmjs.org/ydb-ui-components/-/ydb-ui-components-4.4.0.tgz", - "integrity": "sha512-fKHy3jvFPSDNO/mKhguv1eEdXOKugzXNnSqEdehOqIAcFy8PXq5bn8WUThk7sVggBHLpdNL472V1eCUJBQftkA==", + "version": "4.5.0", + "resolved": "https://registry.npmjs.org/ydb-ui-components/-/ydb-ui-components-4.5.0.tgz", + "integrity": "sha512-XefBB6dWHXbtyZ9jaxkmCJM5tl19V6VYrJ0nB2WcERCbb8ZG0GYJgywi5BBqQgOL8wH1Z5iut8WX7sQPcj+WNA==", + "license": "MIT", "dependencies": { "@bem-react/classname": "^1.6.0", "react-list": "^0.8.17", diff --git a/package.json b/package.json index e5e9a9b8c7..e2084a89b8 100644 --- a/package.json +++ b/package.json @@ -56,7 +56,7 @@ "use-query-params": "^2.2.1", "uuid": "^10.0.0", "web-vitals": "^1.1.2", - "ydb-ui-components": "^4.4.0", + "ydb-ui-components": "^4.5.0", "zod": "^3.24.1" }, "scripts": { diff --git a/src/containers/Tenant/Diagnostics/DiagnosticsPages.ts b/src/containers/Tenant/Diagnostics/DiagnosticsPages.ts index 626973b32d..96bb6b46d5 100644 --- a/src/containers/Tenant/Diagnostics/DiagnosticsPages.ts +++ b/src/containers/Tenant/Diagnostics/DiagnosticsPages.ts @@ -133,6 +133,7 @@ const pathTypeToPages: Record = { [EPathType.EPathTypeView]: VIEW_PAGES, [EPathType.EPathTypeReplication]: ASYNC_REPLICATION_PAGES, + [EPathType.EPathTypeResourcePool]: DIR_PAGES, }; export const getPagesByType = (type?: EPathType) => (type && pathTypeToPages[type]) || DIR_PAGES; diff --git a/src/containers/Tenant/Diagnostics/Overview/Overview.tsx b/src/containers/Tenant/Diagnostics/Overview/Overview.tsx index e40427177b..762eca8ea1 100644 --- a/src/containers/Tenant/Diagnostics/Overview/Overview.tsx +++ b/src/containers/Tenant/Diagnostics/Overview/Overview.tsx @@ -66,6 +66,7 @@ function Overview({type, path, database}: OverviewProps) { const pathTypeToComponent: Record React.ReactNode) | undefined> = { [EPathType.EPathTypeInvalid]: undefined, [EPathType.EPathTypeDir]: undefined, + [EPathType.EPathTypeResourcePool]: undefined, [EPathType.EPathTypeTable]: undefined, [EPathType.EPathTypeSubDomain]: undefined, [EPathType.EPathTypeTableIndex]: () => , diff --git a/src/containers/Tenant/ObjectSummary/ObjectSummary.tsx b/src/containers/Tenant/ObjectSummary/ObjectSummary.tsx index 313ab718db..301638bae8 100644 --- a/src/containers/Tenant/ObjectSummary/ObjectSummary.tsx +++ b/src/containers/Tenant/ObjectSummary/ObjectSummary.tsx @@ -221,6 +221,7 @@ export function ObjectSummary({ > = { [EPathType.EPathTypeInvalid]: undefined, [EPathType.EPathTypeDir]: undefined, + [EPathType.EPathTypeResourcePool]: undefined, [EPathType.EPathTypeTable]: () => [ { name: i18n('field_partitions'), diff --git a/src/containers/Tenant/utils/controls.tsx b/src/containers/Tenant/utils/controls.tsx index 606ef3571d..dc6a3c5d4c 100644 --- a/src/containers/Tenant/utils/controls.tsx +++ b/src/containers/Tenant/utils/controls.tsx @@ -64,6 +64,7 @@ export const getSchemaControls = database: undefined, directory: undefined, + resource_pool: undefined, table: openPreview, column_table: openPreview, diff --git a/src/containers/Tenant/utils/schema.ts b/src/containers/Tenant/utils/schema.ts index b68de49709..b468b724aa 100644 --- a/src/containers/Tenant/utils/schema.ts +++ b/src/containers/Tenant/utils/schema.ts @@ -39,6 +39,7 @@ const pathTypeToNodeType: Record [EPathType.EPathTypeView]: 'view', [EPathType.EPathTypeReplication]: 'async_replication', + [EPathType.EPathTypeResourcePool]: 'resource_pool', }; export const nodeTableTypeToPathType: Partial> = { @@ -86,6 +87,7 @@ const pathTypeToEntityName: Record = { [EPathType.EPathTypeView]: 'View', [EPathType.EPathTypeReplication]: 'Async Replication', + [EPathType.EPathTypeResourcePool]: 'Resource Pool', }; export const mapPathTypeToEntityName = ( @@ -126,6 +128,7 @@ const pathTypeToIsTable: Record = { [EPathType.EPathTypePersQueueGroup]: false, [EPathType.EPathTypeExternalDataSource]: false, [EPathType.EPathTypeReplication]: false, + [EPathType.EPathTypeResourcePool]: false, }; //if add entity with tableType, make sure that Schema is available in Diagnostics section @@ -166,6 +169,7 @@ const pathTypeToIsColumn: Record = { [EPathType.EPathTypeView]: false, [EPathType.EPathTypeReplication]: false, + [EPathType.EPathTypeResourcePool]: false, }; export const isColumnEntityType = (type?: EPathType) => (type && pathTypeToIsColumn[type]) ?? false; @@ -191,6 +195,7 @@ const pathTypeToIsDatabase: Record = { [EPathType.EPathTypeView]: false, [EPathType.EPathTypeReplication]: false, + [EPathType.EPathTypeResourcePool]: false, }; export const isDatabaseEntityType = (type?: EPathType) => @@ -221,6 +226,7 @@ const pathTypeToEntityWithMergedImplementation: Record = { [EPathType.EPathTypeView]: false, [EPathType.EPathTypeReplication]: false, + [EPathType.EPathTypeResourcePool]: false, }; export const isEntityWithMergedImplementation = (type?: EPathType) => @@ -244,6 +250,7 @@ const pathTypeToChildless: Record = { [EPathType.EPathTypeExternalTable]: true, [EPathType.EPathTypeView]: true, + [EPathType.EPathTypeResourcePool]: true, [EPathType.EPathTypeReplication]: true, diff --git a/src/containers/Tenant/utils/schemaActions.tsx b/src/containers/Tenant/utils/schemaActions.tsx index 46b1651a81..60c0f4e183 100644 --- a/src/containers/Tenant/utils/schemaActions.tsx +++ b/src/containers/Tenant/utils/schemaActions.tsx @@ -290,6 +290,7 @@ export const getActions = database: DB_SET, directory: DIR_SET, + resource_pool: JUST_COPY, table: ROW_TABLE_SET, column_table: COLUMN_TABLE_SET, diff --git a/src/types/api/schema/schema.ts b/src/types/api/schema/schema.ts index 3ee01cc19b..0742d86015 100644 --- a/src/types/api/schema/schema.ts +++ b/src/types/api/schema/schema.ts @@ -297,6 +297,7 @@ export enum EPathType { EPathTypeView = 'EPathTypeView', EPathTypeReplication = 'EPathTypeReplication', + EPathTypeResourcePool = 'EPathTypeResourcePool', } export enum EPathSubType {