diff --git a/openmetadata-service/src/main/java/org/openmetadata/service/search/indexes/DatabaseServiceIndex.java b/openmetadata-service/src/main/java/org/openmetadata/service/search/indexes/DatabaseServiceIndex.java index 888f2e54de1..a26fe38d746 100644 --- a/openmetadata-service/src/main/java/org/openmetadata/service/search/indexes/DatabaseServiceIndex.java +++ b/openmetadata-service/src/main/java/org/openmetadata/service/search/indexes/DatabaseServiceIndex.java @@ -32,7 +32,7 @@ public class DatabaseServiceIndex implements SearchIndex { databaseService.getFullyQualifiedName(), suggest.stream().map(SearchSuggest::getInput).collect(Collectors.toList()))); doc.put("suggest", suggest); - doc.put("entityType", Entity.DASHBOARD_SERVICE); + doc.put("entityType", Entity.DATABASE_SERVICE); if (databaseService.getOwner() != null) { doc.put("owner", getOwnerWithDisplayName(databaseService.getOwner())); } diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Assets/AssetsSelectionModal/AssetSelectionModal.interface.ts b/openmetadata-ui/src/main/resources/ui/src/components/Assets/AssetsSelectionModal/AssetSelectionModal.interface.ts index 79510186b3a..a3fdc561866 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Assets/AssetsSelectionModal/AssetSelectionModal.interface.ts +++ b/openmetadata-ui/src/main/resources/ui/src/components/Assets/AssetsSelectionModal/AssetSelectionModal.interface.ts @@ -29,6 +29,7 @@ import { DatabaseService } from '../../../generated/entity/services/databaseServ import { MessagingService } from '../../../generated/entity/services/messagingService'; import { MlmodelService } from '../../../generated/entity/services/mlmodelService'; import { PipelineService } from '../../../generated/entity/services/pipelineService'; +import { SearchService } from '../../../generated/entity/services/searchService'; import { StorageService } from '../../../generated/entity/services/storageService'; export interface AssetSelectionModalProps { @@ -57,7 +58,8 @@ export type AssetsUnion = | EntityType.PIPELINE_SERVICE | EntityType.MLMODEL_SERVICE | EntityType.STORAGE_SERVICE - | EntityType.DATABASE_SERVICE; + | EntityType.DATABASE_SERVICE + | EntityType.SEARCH_SERVICE; export type MapPatchAPIResponse = { [EntityType.TABLE]: Table; @@ -78,4 +80,5 @@ export type MapPatchAPIResponse = { [EntityType.MLMODEL_SERVICE]: MlmodelService; [EntityType.STORAGE_SERVICE]: StorageService; [EntityType.DATABASE_SERVICE]: DatabaseService; + [EntityType.SEARCH_SERVICE]: SearchService; }; diff --git a/openmetadata-ui/src/main/resources/ui/src/components/DataProducts/DataProductsDetailsPage/DataProductsDetailsPage.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/DataProducts/DataProductsDetailsPage/DataProductsDetailsPage.component.tsx index 396b792b196..d71de103664 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/DataProducts/DataProductsDetailsPage/DataProductsDetailsPage.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/DataProducts/DataProductsDetailsPage/DataProductsDetailsPage.component.tsx @@ -59,6 +59,7 @@ import TabsLabel from '../../../components/TabsLabel/TabsLabel.component'; import { FQN_SEPARATOR_CHAR } from '../../../constants/char.constants'; import { DE_ACTIVE_COLOR } from '../../../constants/constants'; import { EntityField } from '../../../constants/Feeds.constants'; +import { myDataSearchIndex } from '../../../constants/Mydata.constants'; import { EntityType } from '../../../enums/entity.enum'; import { ChangeDescription, @@ -69,7 +70,6 @@ import { Operation } from '../../../generated/entity/policies/policy'; import { Style } from '../../../generated/type/tagLabel'; import { searchData } from '../../../rest/miscAPI'; import { getEntityDeleteMessage } from '../../../utils/CommonUtils'; -import { DomainAssetsSearchIndex } from '../../../utils/DomainUtils'; import { getEntityVersionByField } from '../../../utils/EntityVersionUtils'; import Fqn from '../../../utils/Fqn.js'; import { @@ -221,7 +221,7 @@ const DataProductsDetailsPage = ({ `(dataProducts.fullyQualifiedName:"${fqn}")`, '', '', - DomainAssetsSearchIndex + myDataSearchIndex ); setAssetCount(res.data.hits.total.value ?? 0); diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Domain/DomainDetailsPage/DomainDetailsPage.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Domain/DomainDetailsPage/DomainDetailsPage.component.tsx index e261f67d5b3..41658d1755a 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Domain/DomainDetailsPage/DomainDetailsPage.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Domain/DomainDetailsPage/DomainDetailsPage.component.tsx @@ -63,6 +63,7 @@ import TabsLabel from '../../../components/TabsLabel/TabsLabel.component'; import { FQN_SEPARATOR_CHAR } from '../../../constants/char.constants'; import { DE_ACTIVE_COLOR, ERROR_MESSAGE } from '../../../constants/constants'; import { EntityField } from '../../../constants/Feeds.constants'; +import { myDataSearchIndex } from '../../../constants/Mydata.constants'; import { EntityType } from '../../../enums/entity.enum'; import { SearchIndex } from '../../../enums/search.enum'; import { CreateDataProduct } from '../../../generated/api/domains/createDataProduct'; @@ -77,7 +78,6 @@ import { getEntityDeleteMessage, getIsErrorMatch, } from '../../../utils/CommonUtils'; -import { DomainAssetsSearchIndex } from '../../../utils/DomainUtils'; import { getEntityVersionByField } from '../../../utils/EntityVersionUtils'; import Fqn from '../../../utils/Fqn'; import { DEFAULT_ENTITY_PERMISSION } from '../../../utils/PermissionsUtils'; @@ -264,7 +264,7 @@ const DomainDetailsPage = ({ `(domain.fullyQualifiedName:"${fqn}")`, '', '', - DomainAssetsSearchIndex + myDataSearchIndex ); setAssetCount(res.data.hits.total.value ?? 0); diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DashboardSummary/DashboardSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DashboardSummary/DashboardSummary.component.tsx index 3b68f278d1f..7217437e10b 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DashboardSummary/DashboardSummary.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DashboardSummary/DashboardSummary.component.tsx @@ -102,7 +102,7 @@ function DashboardSummary({ diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DataModelSummary/DataModelSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DataModelSummary/DataModelSummary.component.tsx index a9fdd7750f1..be74f03be33 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DataModelSummary/DataModelSummary.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DataModelSummary/DataModelSummary.component.tsx @@ -74,7 +74,7 @@ const DataModelSummary = ({ diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSchemaSummary/DatabaseSchemaSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSchemaSummary/DatabaseSchemaSummary.component.tsx new file mode 100644 index 00000000000..a5ede402d2c --- /dev/null +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSchemaSummary/DatabaseSchemaSummary.component.tsx @@ -0,0 +1,59 @@ +/* + * Copyright 2023 Collate. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { Col, Divider, Row } from 'antd'; +import React, { useMemo } from 'react'; +import SummaryTagsDescription from '../../../../components/common/SummaryTagsDescription/SummaryTagsDescription.component'; +import SummaryPanelSkeleton from '../../../../components/Skeleton/SummaryPanelSkeleton/SummaryPanelSkeleton.component'; +import { ExplorePageTabs } from '../../../../enums/Explore.enum'; +import { + DRAWER_NAVIGATION_OPTIONS, + getEntityOverview, +} from '../../../../utils/EntityUtils'; +import CommonEntitySummaryInfo from '../CommonEntitySummaryInfo/CommonEntitySummaryInfo'; +import { DatabaseSchemaSummaryProps } from './DatabaseSchemaSummary.interface'; + +const DatabaseSchemaSummary = ({ + entityDetails, + componentType = DRAWER_NAVIGATION_OPTIONS.explore, + tags, + isLoading, +}: DatabaseSchemaSummaryProps) => { + const entityInfo = useMemo( + () => getEntityOverview(ExplorePageTabs.DATABASE_SCHEMA, entityDetails), + [entityDetails] + ); + + return ( + + <> + + + + + + + + + + + + ); +}; + +export default DatabaseSchemaSummary; diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSchemaSummary/DatabaseSchemaSummary.interface.ts b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSchemaSummary/DatabaseSchemaSummary.interface.ts new file mode 100644 index 00000000000..72d2bd21871 --- /dev/null +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSchemaSummary/DatabaseSchemaSummary.interface.ts @@ -0,0 +1,23 @@ +/* + * Copyright 2023 Collate. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { DatabaseSchema } from '../../../../generated/entity/data/databaseSchema'; +import { TagLabel } from '../../../../generated/type/tagLabel'; +import { DRAWER_NAVIGATION_OPTIONS } from '../../../../utils/EntityUtils'; + +export interface DatabaseSchemaSummaryProps { + entityDetails: DatabaseSchema; + componentType?: DRAWER_NAVIGATION_OPTIONS; + tags?: TagLabel[]; + isLoading?: boolean; +} diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSummary/DatabaseSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSummary/DatabaseSummary.component.tsx new file mode 100644 index 00000000000..ed47627156f --- /dev/null +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSummary/DatabaseSummary.component.tsx @@ -0,0 +1,92 @@ +/* + * Copyright 2023 Collate. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { Col, Divider, Row, Typography } from 'antd'; +import React, { useMemo } from 'react'; +import { useTranslation } from 'react-i18next'; +import SummaryTagsDescription from '../../../../components/common/SummaryTagsDescription/SummaryTagsDescription.component'; +import SummaryPanelSkeleton from '../../../../components/Skeleton/SummaryPanelSkeleton/SummaryPanelSkeleton.component'; +import { SummaryEntityType } from '../../../../enums/EntitySummary.enum'; +import { ExplorePageTabs } from '../../../../enums/Explore.enum'; +import { getFormattedEntityData } from '../../../../utils/EntitySummaryPanelUtils'; +import { + DRAWER_NAVIGATION_OPTIONS, + getEntityOverview, +} from '../../../../utils/EntityUtils'; +import CommonEntitySummaryInfo from '../CommonEntitySummaryInfo/CommonEntitySummaryInfo'; +import SummaryList from '../SummaryList/SummaryList.component'; +import { BasicEntityInfo } from '../SummaryList/SummaryList.interface'; +import { DatabaseSummaryProps } from './DatabaseSummary.interface'; + +const DatabaseSummary = ({ + entityDetails, + componentType = DRAWER_NAVIGATION_OPTIONS.explore, + tags, + isLoading, +}: DatabaseSummaryProps) => { + const { t } = useTranslation(); + const entityInfo = useMemo( + () => getEntityOverview(ExplorePageTabs.DATABASE, entityDetails), + [entityDetails] + ); + + const formattedSchemaData: BasicEntityInfo[] = useMemo( + () => + getFormattedEntityData( + SummaryEntityType.SCHEMAFIELD, + entityDetails.databaseSchemas + ), + [entityDetails] + ); + + return ( + + <> + + + + + + + + + + + + + + + + {t('label.schema')} + + + + + + + + + ); +}; + +export default DatabaseSummary; diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSummary/DatabaseSummary.interface.ts b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSummary/DatabaseSummary.interface.ts new file mode 100644 index 00000000000..508b9c5ac1b --- /dev/null +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/DatabaseSummary/DatabaseSummary.interface.ts @@ -0,0 +1,23 @@ +/* + * Copyright 2023 Collate. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { Database } from '../../../../generated/entity/data/database'; +import { TagLabel } from '../../../../generated/type/tagLabel'; +import { DRAWER_NAVIGATION_OPTIONS } from '../../../../utils/EntityUtils'; + +export interface DatabaseSummaryProps { + entityDetails: Database; + componentType?: DRAWER_NAVIGATION_OPTIONS; + tags?: TagLabel[]; + isLoading?: boolean; +} diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/EntitySummaryPanel.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/EntitySummaryPanel.component.tsx index 95e617e2576..bd7a5f01e4e 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/EntitySummaryPanel.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/EntitySummaryPanel.component.tsx @@ -17,10 +17,13 @@ import React, { useEffect, useMemo, useState } from 'react'; import { Link, useParams } from 'react-router-dom'; import { ERROR_PLACEHOLDER_TYPE, SIZE } from '../../../enums/common.enum'; import { EntityType } from '../../../enums/entity.enum'; +import { ExplorePageTabs } from '../../../enums/Explore.enum'; import { Tag } from '../../../generated/entity/classification/tag'; import { Container } from '../../../generated/entity/data/container'; import { Dashboard } from '../../../generated/entity/data/dashboard'; import { DashboardDataModel } from '../../../generated/entity/data/dashboardDataModel'; +import { Database } from '../../../generated/entity/data/database'; +import { DatabaseSchema } from '../../../generated/entity/data/databaseSchema'; import { GlossaryTerm } from '../../../generated/entity/data/glossaryTerm'; import { Mlmodel } from '../../../generated/entity/data/mlmodel'; import { Pipeline } from '../../../generated/entity/data/pipeline'; @@ -29,6 +32,13 @@ import { StoredProcedure } from '../../../generated/entity/data/storedProcedure' import { Table } from '../../../generated/entity/data/table'; import { Topic } from '../../../generated/entity/data/topic'; import { DataProduct } from '../../../generated/entity/domains/dataProduct'; +import { DashboardService } from '../../../generated/entity/services/dashboardService'; +import { DatabaseService } from '../../../generated/entity/services/databaseService'; +import { MessagingService } from '../../../generated/entity/services/messagingService'; +import { MlmodelService } from '../../../generated/entity/services/mlmodelService'; +import { PipelineService } from '../../../generated/entity/services/pipelineService'; +import { SearchService } from '../../../generated/entity/services/searchService'; +import { StorageService } from '../../../generated/entity/services/storageService'; import { getEntityLinkFromType, getEntityName, @@ -44,6 +54,8 @@ import { } from '../../PermissionProvider/PermissionProvider.interface'; import ContainerSummary from './ContainerSummary/ContainerSummary.component'; import DashboardSummary from './DashboardSummary/DashboardSummary.component'; +import DatabaseSchemaSummary from './DatabaseSchemaSummary/DatabaseSchemaSummary.component'; +import DatabaseSummary from './DatabaseSummary/DatabaseSummary.component'; import DataModelSummary from './DataModelSummary/DataModelSummary.component'; import DataProductSummary from './DataProductSummary/DataProductSummary.component'; import { EntitySummaryPanelProps } from './EntitySummaryPanel.interface'; @@ -52,6 +64,7 @@ import GlossaryTermSummary from './GlossaryTermSummary/GlossaryTermSummary.compo import MlModelSummary from './MlModelSummary/MlModelSummary.component'; import PipelineSummary from './PipelineSummary/PipelineSummary.component'; import SearchIndexSummary from './SearchIndexSummary/SearchIndexSummary.component'; +import ServiceSummary from './ServiceSummary/ServiceSummary.component'; import StoredProcedureSummary from './StoredProcedureSummary/StoredProcedureSummary.component'; import TableSummary from './TableSummary/TableSummary.component'; import TagsSummary from './TagsSummary/TagsSummary.component'; @@ -153,6 +166,67 @@ export default function EntitySummaryPanel({ case EntityType.SEARCH_INDEX: return ; + case EntityType.DATABASE: + return ; + + case EntityType.DATABASE_SCHEMA: + return ( + + ); + + case EntityType.DATABASE_SERVICE: + return ( + + ); + case EntityType.MESSAGING_SERVICE: + return ( + + ); + case EntityType.DASHBOARD_SERVICE: + return ( + + ); + case EntityType.PIPELINE_SERVICE: + return ( + + ); + + case EntityType.MLMODEL_SERVICE: + return ( + + ); + + case EntityType.STORAGE_SERVICE: + return ( + + ); + + case EntityType.SEARCH_SERVICE: + return ( + + ); + default: return null; } diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/MlModelSummary/MlModelSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/MlModelSummary/MlModelSummary.component.tsx index 4ae8883904e..275f0f658ac 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/MlModelSummary/MlModelSummary.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/MlModelSummary/MlModelSummary.component.tsx @@ -72,7 +72,7 @@ function MlModelSummary({ diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/PipelineSummary/PipelineSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/PipelineSummary/PipelineSummary.component.tsx index 92fff8a27e1..16298d03db3 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/PipelineSummary/PipelineSummary.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/PipelineSummary/PipelineSummary.component.tsx @@ -68,7 +68,7 @@ function PipelineSummary({ diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/ServiceSummary/ServiceSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/ServiceSummary/ServiceSummary.component.tsx new file mode 100644 index 00000000000..7d6c86e2801 --- /dev/null +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/ServiceSummary/ServiceSummary.component.tsx @@ -0,0 +1,59 @@ +/* + * Copyright 2023 Collate. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { Col, Divider, Row } from 'antd'; +import React, { useMemo } from 'react'; +import SummaryTagsDescription from '../../../../components/common/SummaryTagsDescription/SummaryTagsDescription.component'; +import SummaryPanelSkeleton from '../../../../components/Skeleton/SummaryPanelSkeleton/SummaryPanelSkeleton.component'; +import { + DRAWER_NAVIGATION_OPTIONS, + getEntityOverview, +} from '../../../../utils/EntityUtils'; +import CommonEntitySummaryInfo from '../CommonEntitySummaryInfo/CommonEntitySummaryInfo'; +import { ServiceSummaryProps } from './ServiceSummary.interface'; + +const ServiceSummary = ({ + type, + entityDetails, + componentType = DRAWER_NAVIGATION_OPTIONS.explore, + tags, + isLoading, +}: ServiceSummaryProps) => { + const entityInfo = useMemo( + () => getEntityOverview(type, entityDetails), + [entityDetails] + ); + + return ( + + <> + + + + + + + + + + + + ); +}; + +export default ServiceSummary; diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/ServiceSummary/ServiceSummary.interface.ts b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/ServiceSummary/ServiceSummary.interface.ts new file mode 100644 index 00000000000..67cc15e905c --- /dev/null +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/ServiceSummary/ServiceSummary.interface.ts @@ -0,0 +1,25 @@ +/* + * Copyright 2023 Collate. + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * http://www.apache.org/licenses/LICENSE-2.0 + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { EntityServiceUnion } from '../../../../components/Explore/explore.interface'; +import { ExplorePageTabs } from '../../../../enums/Explore.enum'; +import { TagLabel } from '../../../../generated/type/tagLabel'; +import { DRAWER_NAVIGATION_OPTIONS } from '../../../../utils/EntityUtils'; + +export interface ServiceSummaryProps { + type: ExplorePageTabs; + entityDetails: EntityServiceUnion; + componentType?: DRAWER_NAVIGATION_OPTIONS; + tags?: TagLabel[]; + isLoading?: boolean; +} diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/StoredProcedureSummary/StoredProcedureSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/StoredProcedureSummary/StoredProcedureSummary.component.tsx index db50dd22f6f..7420a919b20 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/StoredProcedureSummary/StoredProcedureSummary.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/StoredProcedureSummary/StoredProcedureSummary.component.tsx @@ -57,7 +57,7 @@ const StoredProcedureSummary = ({ diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/TableSummary/TableSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/TableSummary/TableSummary.component.tsx index 9548a5c98e1..429699d8a9a 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/TableSummary/TableSummary.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/TableSummary/TableSummary.component.tsx @@ -234,7 +234,7 @@ function TableSummary({ diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/TopicSummary/TopicSummary.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/TopicSummary/TopicSummary.component.tsx index 428967ed6f9..5803081cc8d 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/TopicSummary/TopicSummary.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/EntitySummaryPanel/TopicSummary/TopicSummary.component.tsx @@ -158,7 +158,7 @@ function TopicSummary({ diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Explore/explore.interface.ts b/openmetadata-ui/src/main/resources/ui/src/components/Explore/explore.interface.ts index 7094833c576..b7692c85387 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Explore/explore.interface.ts +++ b/openmetadata-ui/src/main/resources/ui/src/components/Explore/explore.interface.ts @@ -28,6 +28,13 @@ import { SearchIndex as SearchIndexEntity } from '../../generated/entity/data/se import { StoredProcedure } from '../../generated/entity/data/storedProcedure'; import { Table } from '../../generated/entity/data/table'; import { Topic } from '../../generated/entity/data/topic'; +import { DashboardService } from '../../generated/entity/services/dashboardService'; +import { DatabaseService } from '../../generated/entity/services/databaseService'; +import { MessagingService } from '../../generated/entity/services/messagingService'; +import { MlmodelService } from '../../generated/entity/services/mlmodelService'; +import { PipelineService } from '../../generated/entity/services/pipelineService'; +import { SearchService } from '../../generated/entity/services/searchService'; +import { StorageService } from '../../generated/entity/services/storageService'; import { Aggregations, SearchResponse } from '../../interface/search.interface'; import { QueryFilterInterface } from '../../pages/explore/ExplorePage.interface'; import { SearchDropdownOption } from '../SearchDropdown/SearchDropdown.interface'; @@ -127,7 +134,14 @@ export type EntityUnion = | Tag | DashboardDataModel | StoredProcedure - | SearchIndexEntity; + | SearchIndexEntity + | DatabaseService + | MessagingService + | DashboardService + | PipelineService + | MlmodelService + | StorageService + | SearchService; export type EntityWithServices = | Topic @@ -140,6 +154,15 @@ export type EntityWithServices = | DatabaseSchema | SearchIndexEntity; +export type EntityServiceUnion = + | DatabaseService + | MessagingService + | DashboardService + | PipelineService + | MlmodelService + | StorageService + | SearchService; + export interface EntityDetailsObjectInterface { details: SearchedDataProps['data'][number]['_source']; } diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx index 1f23049acfa..ca6ca9cd4f2 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Glossary/GlossaryTerms/tabs/AssetsTabs.component.tsx @@ -150,6 +150,16 @@ const AssetsTabs = forwardRef( containerResponse, storedProcedureResponse, dashboardDataModelResponse, + databaseResponse, + databaseSchemaResponse, + searchResponse, + databaseServiceResponse, + messagingServiceResponse, + dashboardServiceResponse, + mlmodelServiceResponse, + pipelineServiceResponse, + storageServiceResponse, + searchServiceResponse, glossaryResponse, ]) => { const counts = { @@ -163,6 +173,25 @@ const AssetsTabs = forwardRef( storedProcedureResponse.data.hits.total.value, [EntityType.DASHBOARD_DATA_MODEL]: dashboardDataModelResponse.data.hits.total.value, + [EntityType.DATABASE]: databaseResponse.data.hits.total.value, + [EntityType.DATABASE_SCHEMA]: + databaseSchemaResponse.data.hits.total.value, + [EntityType.SEARCH_INDEX]: searchResponse.data.hits.total.value, + [EntityType.DATABASE_SERVICE]: + databaseServiceResponse.data.hits.total.value, + [EntityType.MESSAGING_SERVICE]: + messagingServiceResponse.data.hits.total.value, + [EntityType.DASHBOARD_SERVICE]: + dashboardServiceResponse.data.hits.total.value, + [EntityType.MLMODEL_SERVICE]: + mlmodelServiceResponse.data.hits.total.value, + [EntityType.PIPELINE_SERVICE]: + pipelineServiceResponse.data.hits.total.value, + [EntityType.STORAGE_SERVICE]: + storageServiceResponse.data.hits.total.value, + [EntityType.SEARCH_SERVICE]: + searchServiceResponse.data.hits.total.value, + [EntityType.GLOSSARY_TERM]: type !== AssetsOfEntity.GLOSSARY ? glossaryResponse.data.hits.total.value diff --git a/openmetadata-ui/src/main/resources/ui/src/components/Services/Services.tsx b/openmetadata-ui/src/main/resources/ui/src/components/Services/Services.tsx index b9f2da90312..5e121bf9afa 100644 --- a/openmetadata-ui/src/main/resources/ui/src/components/Services/Services.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/components/Services/Services.tsx @@ -93,7 +93,7 @@ const Services = ({ serviceName }: ServicesProps) => { case ServiceCategory.DATABASE_SERVICES: return SearchIndex.DATABASE_SERVICE; case ServiceCategory.DASHBOARD_SERVICES: - return SearchIndex.DASHBOARD_SERCVICE; + return SearchIndex.DASHBOARD_SERVICE; case ServiceCategory.MESSAGING_SERVICES: return SearchIndex.MESSAGING_SERVICE; case ServiceCategory.PIPELINE_SERVICES: diff --git a/openmetadata-ui/src/main/resources/ui/src/constants/Assets.constants.ts b/openmetadata-ui/src/main/resources/ui/src/constants/Assets.constants.ts index dbc70c49711..f7e7855cc9c 100644 --- a/openmetadata-ui/src/main/resources/ui/src/constants/Assets.constants.ts +++ b/openmetadata-ui/src/main/resources/ui/src/constants/Assets.constants.ts @@ -65,6 +65,58 @@ export const AssetsFilterOptions: Array<{ key: EntityType.DASHBOARD_DATA_MODEL, value: SearchIndex.DASHBOARD_DATA_MODEL, }, + { + label: i18n.t('label.database'), + key: EntityType.DATABASE, + value: SearchIndex.DATABASE, + }, + { + label: i18n.t('label.database-schema'), + key: EntityType.DATABASE_SCHEMA, + value: SearchIndex.DATABASE_SCHEMA, + }, + + { + label: i18n.t('label.search-index'), + key: EntityType.SEARCH_INDEX, + value: SearchIndex.SEARCH_INDEX, + }, + { + label: i18n.t('label.database-service'), + key: EntityType.DATABASE_SERVICE, + value: SearchIndex.DATABASE_SERVICE, + }, + { + label: i18n.t('label.messaging-service'), + key: EntityType.MESSAGING_SERVICE, + value: SearchIndex.MESSAGING_SERVICE, + }, + { + label: i18n.t('label.dashboard-service'), + key: EntityType.DASHBOARD_SERVICE, + value: SearchIndex.DASHBOARD_SERVICE, + }, + + { + label: i18n.t('label.pipeline-service'), + key: EntityType.PIPELINE_SERVICE, + value: SearchIndex.PIPELINE_SERVICE, + }, + { + label: i18n.t('label.ml-model-service'), + key: EntityType.MLMODEL_SERVICE, + value: SearchIndex.ML_MODEL_SERVICE, + }, + { + label: i18n.t('label.storage-service'), + key: EntityType.STORAGE_SERVICE, + value: SearchIndex.STORAGE_SERVICE, + }, + { + label: i18n.t('label.search-index-service'), + key: EntityType.SEARCH_SERVICE, + value: SearchIndex.SEARCH_SERVICE, + }, ]; export const ASSETS_INDEXES = [ @@ -76,4 +128,14 @@ export const ASSETS_INDEXES = [ SearchIndex.CONTAINER, SearchIndex.STORED_PROCEDURE, SearchIndex.DASHBOARD_DATA_MODEL, + SearchIndex.DATABASE, + SearchIndex.DATABASE_SCHEMA, + SearchIndex.SEARCH_INDEX, + SearchIndex.DATABASE_SERVICE, + SearchIndex.MESSAGING_SERVICE, + SearchIndex.DASHBOARD_SERVICE, + SearchIndex.ML_MODEL_SERVICE, + SearchIndex.PIPELINE_SERVICE, + SearchIndex.STORAGE_SERVICE, + SearchIndex.SEARCH_SERVICE, ]; diff --git a/openmetadata-ui/src/main/resources/ui/src/constants/Mydata.constants.ts b/openmetadata-ui/src/main/resources/ui/src/constants/Mydata.constants.ts index b96a0d8dd59..289b0673695 100644 --- a/openmetadata-ui/src/main/resources/ui/src/constants/Mydata.constants.ts +++ b/openmetadata-ui/src/main/resources/ui/src/constants/Mydata.constants.ts @@ -15,7 +15,7 @@ import { SearchIndex } from '../enums/search.enum'; export const myDataSearchIndex = // eslint-disable-next-line max-len - `${SearchIndex.TABLE},${SearchIndex.TOPIC},${SearchIndex.DASHBOARD},${SearchIndex.PIPELINE},${SearchIndex.MLMODEL},${SearchIndex.STORED_PROCEDURE},${SearchIndex.DASHBOARD_DATA_MODEL}` as SearchIndex; + `${SearchIndex.TABLE},${SearchIndex.TOPIC},${SearchIndex.DASHBOARD},${SearchIndex.PIPELINE},${SearchIndex.MLMODEL},${SearchIndex.STORED_PROCEDURE},${SearchIndex.DASHBOARD_DATA_MODEL},${SearchIndex.DATABASE},${SearchIndex.DATABASE_SCHEMA},${SearchIndex.DATABASE},${SearchIndex.DATABASE_SERVICE},${SearchIndex.MESSAGING_SERVICE},${SearchIndex.PIPELINE_SERVICE},${SearchIndex.SEARCH_SERVICE},${SearchIndex.DASHBOARD_SERVICE},${SearchIndex.ML_MODEL_SERVICE},${SearchIndex.STORAGE_SERVICE},${SearchIndex.SEARCH_INDEX}` as SearchIndex; export const observerOptions = { root: null, diff --git a/openmetadata-ui/src/main/resources/ui/src/enums/Explore.enum.ts b/openmetadata-ui/src/main/resources/ui/src/enums/Explore.enum.ts index e58a1353989..ff3e1035df7 100644 --- a/openmetadata-ui/src/main/resources/ui/src/enums/Explore.enum.ts +++ b/openmetadata-ui/src/main/resources/ui/src/enums/Explore.enum.ts @@ -28,4 +28,13 @@ export enum ExplorePageTabs { DASHBOARD_DATA_MODEL = 'dashboardDataModel', STORED_PROCEDURE = 'storedProcedure', SEARCH_INDEX = 'searchIndexes', + DATABASE = 'database', + DATABASE_SCHEMA = 'databaseSchema', + DATABASE_SERVICE = 'databaseService', + MESSAGING_SERVICE = 'messagingService', + DASHBOARD_SERVICE = 'dashboardService', + PIPELINE_SERVICE = 'pipelineService', + ML_MODEL_SERVICE = 'mlmodelService', + STORAGE_SERVICE = 'storageService', + SEARCH_INDEX_SERVICE = 'searchIndexService', } diff --git a/openmetadata-ui/src/main/resources/ui/src/enums/search.enum.ts b/openmetadata-ui/src/main/resources/ui/src/enums/search.enum.ts index f5e7b20f05e..82067dba4ab 100644 --- a/openmetadata-ui/src/main/resources/ui/src/enums/search.enum.ts +++ b/openmetadata-ui/src/main/resources/ui/src/enums/search.enum.ts @@ -30,7 +30,7 @@ export enum SearchIndex { MESSAGING_SERVICE = 'messaging_service_search_index', PIPELINE_SERVICE = 'pipeline_service_search_index', SEARCH_SERVICE = 'search_service_search_index', - DASHBOARD_SERCVICE = 'dashboard_service_search_index', + DASHBOARD_SERVICE = 'dashboard_service_search_index', ML_MODEL_SERVICE = 'mlmodel_service_search_index', STORAGE_SERVICE = 'storage_service_search_index', DOMAIN = 'domain_search_index', diff --git a/openmetadata-ui/src/main/resources/ui/src/interface/search.interface.ts b/openmetadata-ui/src/main/resources/ui/src/interface/search.interface.ts index cb4ccd9c571..b7e8bc0e977 100644 --- a/openmetadata-ui/src/main/resources/ui/src/interface/search.interface.ts +++ b/openmetadata-ui/src/main/resources/ui/src/interface/search.interface.ts @@ -185,7 +185,7 @@ export type SearchIndexSearchSourceMapping = { [SearchIndex.DATABASE_SCHEMA]: DataBaseSchemaSearchSource; [SearchIndex.DATABASE]: DatabaseSearchSource; [SearchIndex.DATABASE_SERVICE]: DatabaseServiceSearchSource; - [SearchIndex.DASHBOARD_SERCVICE]: DashboardServiceSearchSource; + [SearchIndex.DASHBOARD_SERVICE]: DashboardServiceSearchSource; [SearchIndex.PIPELINE_SERVICE]: PipelineServiceSearchSource; [SearchIndex.ML_MODEL_SERVICE]: MlModelServiceSearchSource; [SearchIndex.MESSAGING_SERVICE]: MessagingServiceSearchSource; diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json index e233bd54a41..bc8abae173f 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/de-de.json @@ -205,6 +205,7 @@ "dashboard-lowercase-plural": "Dashboards", "dashboard-name": "Dashboard-Name", "dashboard-plural": "Dashboards", + "dashboard-service": "Dashboard Service", "data-aggregate": "Datenaggregat", "data-aggregation": "Datenaggregation", "data-asset": "Daten-Asset", @@ -249,6 +250,7 @@ "database-name": "Datenbankname", "database-plural": "Datenbanken", "database-schema": "Datenbankschema", + "database-service": "Database Service", "database-service-name": "Datenbankdienstname", "date": "Datum", "date-and-time": "Datum & Uhrzeit", @@ -566,6 +568,7 @@ "messaging": "Nachrichtenübermittlung", "messaging-lowercase": "nachrichtenübermittlung", "messaging-plural": "Nachrichtenübermittlungen", + "messaging-service": "Messaging Service", "metadata": "Metadaten", "metadata-ingestion": "Metadateninjektion", "metadata-lowercase": "metadaten", @@ -584,6 +587,7 @@ "ml-model-lowercase": "Künstliches Intelligenzmodell", "ml-model-lowercase-plural": "KI-Modelle", "ml-model-plural": "KI-Modelle", + "ml-model-service": "Ml Model Service", "mode": "Modus", "model": "Modell", "model-name": "Modellname", @@ -690,6 +694,7 @@ "pipeline-lowercase-plural": "pipelines", "pipeline-name": "Pipeline-Name", "pipeline-plural": "Pipelines", + "pipeline-service": "Pipeline Service", "pipeline-state": "Pipeline-Status", "please-enter-value": "Bitte einen Wert für {{name}} eingeben", "please-password-type-first": "Bitte zuerst das Passwort eingeben", @@ -827,6 +832,7 @@ "search-index": "Suchindex", "search-index-ingestion": "Suchindex für die Datenaufnahme", "search-index-plural": "Suchindizes", + "search-index-service": "Search Index Service", "search-index-setting-plural": "Suchindexeinstellungen", "second-plural": "Sekunden", "secret-key": "Geheimschlüssel", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json index 2b27af1cb6e..5cf078ec8c6 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/en-us.json @@ -205,6 +205,7 @@ "dashboard-lowercase-plural": "dashboards", "dashboard-name": "Dashboard Name", "dashboard-plural": "Dashboards", + "dashboard-service": "Dashboard Service", "data-aggregate": "Data Aggregate", "data-aggregation": "Data Aggregation", "data-asset": "Data Asset", @@ -249,6 +250,7 @@ "database-name": "Database Name", "database-plural": "Databases", "database-schema": "Database Schema", + "database-service": "Database Service", "database-service-name": "Database Service Name", "date": "Date", "date-and-time": "Date & Time", @@ -566,6 +568,7 @@ "messaging": "Messaging", "messaging-lowercase": "messaging", "messaging-plural": "Messagings", + "messaging-service": "Messaging Service", "metadata": "Metadata", "metadata-ingestion": "Metadata Ingestion", "metadata-lowercase": "metadata", @@ -584,6 +587,7 @@ "ml-model-lowercase": "ML model", "ml-model-lowercase-plural": "ML models", "ml-model-plural": "ML Models", + "ml-model-service": "Ml Model Service", "mode": "Mode", "model": "Model", "model-name": "Model Name", @@ -690,6 +694,7 @@ "pipeline-lowercase-plural": "pipelines", "pipeline-name": "Pipeline Name", "pipeline-plural": "Pipelines", + "pipeline-service": "Pipeline Service", "pipeline-state": "Pipeline State", "please-enter-value": "Please enter {{name}} value", "please-password-type-first": "Please type password first", @@ -827,6 +832,7 @@ "search-index": "Search Index", "search-index-ingestion": "Search Index Ingestion", "search-index-plural": "Search Indexes", + "search-index-service": "Search Index Service", "search-index-setting-plural": "Search Index Settings", "second-plural": "Seconds", "secret-key": "Secret Key", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json index 69b8752f1a3..ec412202444 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/es-es.json @@ -205,6 +205,7 @@ "dashboard-lowercase-plural": "dashboards", "dashboard-name": "Nombre del dashboard", "dashboard-plural": "Dashboards", + "dashboard-service": "Dashboard Service", "data-aggregate": "Data Aggregate", "data-aggregation": "Data Aggregation", "data-asset": "Activo de datos", @@ -249,6 +250,7 @@ "database-name": "Nombre de la base de datos", "database-plural": "Bases de datos", "database-schema": "Esquema de la base de datos", + "database-service": "Database Service", "database-service-name": "Nombre del servicio de la base de datos", "date": "Fecha", "date-and-time": "Fecha y hora", @@ -566,6 +568,7 @@ "messaging": "Mensajería", "messaging-lowercase": "mensajería", "messaging-plural": "Messagings", + "messaging-service": "Messaging Service", "metadata": "Metadatos", "metadata-ingestion": "Ingesta de Metadatos", "metadata-lowercase": "metadatos", @@ -584,6 +587,7 @@ "ml-model-lowercase": "modelo de ML", "ml-model-lowercase-plural": "modelos de ML", "ml-model-plural": "Modelos de ML", + "ml-model-service": "Ml Model Service", "mode": "Moda", "model": "Model", "model-name": "Nombre del Modelo", @@ -690,6 +694,7 @@ "pipeline-lowercase-plural": "pipelines", "pipeline-name": "Nombre de la pipeline", "pipeline-plural": "Pipelines", + "pipeline-service": "Pipeline Service", "pipeline-state": "Estado de la pipeline", "please-enter-value": "Ingrese el valor de {{name}}", "please-password-type-first": "Ingrese primero la contraseña", @@ -827,6 +832,7 @@ "search-index": "Search Index", "search-index-ingestion": "Search Index Ingestion", "search-index-plural": "Search Indexes", + "search-index-service": "Search Index Service", "search-index-setting-plural": "Search Index Settings", "second-plural": "Segundos", "secret-key": "Clave Secreta", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json index fed8fb81f0e..d1a1140ce9a 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/fr-fr.json @@ -205,6 +205,7 @@ "dashboard-lowercase-plural": "tableaux de bord", "dashboard-name": "Nom du Tableau de Bord", "dashboard-plural": "Tableaux de Bord", + "dashboard-service": "Dashboard Service", "data-aggregate": "Agrégat de Données", "data-aggregation": "Agrégation de Données", "data-asset": "Actif de Données", @@ -249,6 +250,7 @@ "database-name": "Nom de la Base de Données", "database-plural": "Bases de Données", "database-schema": "Schéma de la Base de Données", + "database-service": "Database Service", "database-service-name": "Nom du Service de la Base de Données", "date": "Date", "date-and-time": "Date & Heure", @@ -566,6 +568,7 @@ "messaging": "Messagerie", "messaging-lowercase": "messagerie", "messaging-plural": "Messageries", + "messaging-service": "Messaging Service", "metadata": "Métadonnée", "metadata-ingestion": "Ingestion des Métadonnées", "metadata-lowercase": "métadonnées", @@ -584,6 +587,7 @@ "ml-model-lowercase": "Modèle d'Apprentissage Machine", "ml-model-lowercase-plural": "Modèles d'Apprentissage Machine", "ml-model-plural": "Modèles d'IA", + "ml-model-service": "Ml Model Service", "mode": "Mode", "model": "Modèle", "model-name": "Nom du Modèle", @@ -690,6 +694,7 @@ "pipeline-lowercase-plural": "pipelines", "pipeline-name": "Nom du Pipeline", "pipeline-plural": "Pipelines", + "pipeline-service": "Pipeline Service", "pipeline-state": "État du Pipeline", "please-enter-value": "Merci d'entrer une valeur pour {{name}} ", "please-password-type-first": "Merci d'entrer le mot de passe d'abord", @@ -827,6 +832,7 @@ "search-index": "Index de Recherche", "search-index-ingestion": "Index de Recherche pour l'Ingestion", "search-index-plural": "Indexes de Recherche", + "search-index-service": "Search Index Service", "search-index-setting-plural": "Paramètres des Index de Recherche", "second-plural": "Secondes", "secret-key": "Clé Secrète", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json index 75be6f61372..38d68c56416 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ja-jp.json @@ -205,6 +205,7 @@ "dashboard-lowercase-plural": "dashboards", "dashboard-name": "ダッシュボード名", "dashboard-plural": "ダッシュボード", + "dashboard-service": "Dashboard Service", "data-aggregate": "Data Aggregate", "data-aggregation": "Data Aggregation", "data-asset": "データアセット", @@ -249,6 +250,7 @@ "database-name": "データベース名", "database-plural": "データベース", "database-schema": "データベースのスキーマ", + "database-service": "Database Service", "database-service-name": "データベースサービス名", "date": "日付", "date-and-time": "日付と時間", @@ -566,6 +568,7 @@ "messaging": "メッセージング", "messaging-lowercase": "メッセージング", "messaging-plural": "Messagings", + "messaging-service": "Messaging Service", "metadata": "メタデータ", "metadata-ingestion": "メタデータのインジェスチョン", "metadata-lowercase": "メタデータ", @@ -584,6 +587,7 @@ "ml-model-lowercase": "ML model", "ml-model-lowercase-plural": "ML models", "ml-model-plural": "MLモデル", + "ml-model-service": "Ml Model Service", "mode": "モード", "model": "Model", "model-name": "モデル名", @@ -690,6 +694,7 @@ "pipeline-lowercase-plural": "pipelines", "pipeline-name": "パイプライン名", "pipeline-plural": "パイプライン", + "pipeline-service": "Pipeline Service", "pipeline-state": "パイプラインの状態", "please-enter-value": "{{name}}の値を入力してください", "please-password-type-first": "パスワードを入力してください", @@ -827,6 +832,7 @@ "search-index": "Search Index", "search-index-ingestion": "Search Index Ingestion", "search-index-plural": "Search Indexes", + "search-index-service": "Search Index Service", "search-index-setting-plural": "Search Index Settings", "second-plural": "秒", "secret-key": "Secret Key", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json index 003e8390ed5..ef94eb22740 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/pt-br.json @@ -205,6 +205,7 @@ "dashboard-lowercase-plural": "dashboards", "dashboard-name": "Nome do dashboard", "dashboard-plural": "Dashboards", + "dashboard-service": "Dashboard Service", "data-aggregate": "Data Aggregate", "data-aggregation": "Data Aggregation", "data-asset": "Recurso de dados", @@ -249,6 +250,7 @@ "database-name": "Nome do banco de dados", "database-plural": "Bancos de dados", "database-schema": "Schema do banco de dados", + "database-service": "Database Service", "database-service-name": "Nome do serviço de banco de dados", "date": "data", "date-and-time": "data e hora", @@ -566,6 +568,7 @@ "messaging": "Mensageria", "messaging-lowercase": "mensageria", "messaging-plural": "Messagings", + "messaging-service": "Messaging Service", "metadata": "Metadados", "metadata-ingestion": "Ingestão de metadados", "metadata-lowercase": "Metadados", @@ -584,6 +587,7 @@ "ml-model-lowercase": "ML model", "ml-model-lowercase-plural": "ML models", "ml-model-plural": "Modelos de ML", + "ml-model-service": "Ml Model Service", "mode": "Modo", "model": "Model", "model-name": "Nome do modelo", @@ -690,6 +694,7 @@ "pipeline-lowercase-plural": "pipelines", "pipeline-name": "Nome da pipeline", "pipeline-plural": "Pipelines", + "pipeline-service": "Pipeline Service", "pipeline-state": "Estado da pipeline", "please-enter-value": "Por favor digite o valor de {{name}}", "please-password-type-first": "Por favor, digite a senha primeiro", @@ -827,6 +832,7 @@ "search-index": "Search Index", "search-index-ingestion": "Search Index Ingestion", "search-index-plural": "Search Indexes", + "search-index-service": "Search Index Service", "search-index-setting-plural": "Search Index Settings", "second-plural": "Segundos", "secret-key": "Chave Secreta", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json index 21bd02b123b..33e230842ce 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/ru-ru.json @@ -205,6 +205,7 @@ "dashboard-lowercase-plural": "дашборды", "dashboard-name": "Наименование дашборда", "dashboard-plural": "Дашборды", + "dashboard-service": "Dashboard Service", "data-aggregate": "Сводные данные", "data-aggregation": "Агрегация данных", "data-asset": "Объект данных", @@ -249,6 +250,7 @@ "database-name": "Наименование базы данных", "database-plural": "Базы данных", "database-schema": "Схема базы данных", + "database-service": "Database Service", "database-service-name": "Наименование сервиса базы данных", "date": "Дата", "date-and-time": "Дата & Время", @@ -566,6 +568,7 @@ "messaging": "Обмен сообщениями", "messaging-lowercase": "обмен сообщениями", "messaging-plural": "Обмен сообщениями", + "messaging-service": "Messaging Service", "metadata": "Метаданные", "metadata-ingestion": "Получение метаданных", "metadata-lowercase": "метаданные", @@ -584,6 +587,7 @@ "ml-model-lowercase": "ML модель", "ml-model-lowercase-plural": "ML модели", "ml-model-plural": "ML Модели", + "ml-model-service": "Ml Model Service", "mode": "Режим", "model": "Модель", "model-name": "Наименование модели", @@ -690,6 +694,7 @@ "pipeline-lowercase-plural": "пайплайны", "pipeline-name": "Наименование пайплайна", "pipeline-plural": "Пайплайны", + "pipeline-service": "Pipeline Service", "pipeline-state": "Состояние", "please-enter-value": "Пожалуйста введите значение {{name}} ", "please-password-type-first": "Пожалуйста, сначала введите пароль", @@ -827,6 +832,7 @@ "search-index": "Search Index", "search-index-ingestion": "Получение поискового индекса", "search-index-plural": "Search Indexes", + "search-index-service": "Search Index Service", "search-index-setting-plural": "Search Index Settings", "second-plural": "Секунды", "secret-key": "Секретный ключ", diff --git a/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json b/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json index 4669c5755e6..dc0c8c97f5e 100644 --- a/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json +++ b/openmetadata-ui/src/main/resources/ui/src/locale/languages/zh-cn.json @@ -205,6 +205,7 @@ "dashboard-lowercase-plural": "仪表板", "dashboard-name": "仪表板名称", "dashboard-plural": "仪表板", + "dashboard-service": "Dashboard Service", "data-aggregate": "数据聚合", "data-aggregation": "数据聚合", "data-asset": "数据资产", @@ -249,6 +250,7 @@ "database-name": "数据库名称", "database-plural": "数据库", "database-schema": "数据库结构", + "database-service": "Database Service", "database-service-name": "数据库服务名称", "date": "日期", "date-and-time": "日期和时间", @@ -566,6 +568,7 @@ "messaging": "消息队列", "messaging-lowercase": "消息队列", "messaging-plural": "消息队列", + "messaging-service": "Messaging Service", "metadata": "元数据", "metadata-ingestion": "元数据提取", "metadata-lowercase": "元数据", @@ -584,6 +587,7 @@ "ml-model-lowercase": "ML模型", "ml-model-lowercase-plural": "ML模型", "ml-model-plural": "ML模型", + "ml-model-service": "Ml Model Service", "mode": "模式", "model": "模型", "model-name": "模型名称", @@ -690,6 +694,7 @@ "pipeline-lowercase-plural": "工作流", "pipeline-name": "工作流名称", "pipeline-plural": "工作流", + "pipeline-service": "Pipeline Service", "pipeline-state": "工作流状态", "please-enter-value": "请输入{{name}}值", "please-password-type-first": "请先输入密码", @@ -827,6 +832,7 @@ "search-index": "Search Index", "search-index-ingestion": "搜索索引提取", "search-index-plural": "Search Indexes", + "search-index-service": "Search Index Service", "search-index-setting-plural": "Search Index Settings", "second-plural": "秒", "secret-key": "秘钥", diff --git a/openmetadata-ui/src/main/resources/ui/src/utils/Assets/AssetsUtils.ts b/openmetadata-ui/src/main/resources/ui/src/utils/Assets/AssetsUtils.ts index 1dc09944b4c..93c21937cdf 100644 --- a/openmetadata-ui/src/main/resources/ui/src/utils/Assets/AssetsUtils.ts +++ b/openmetadata-ui/src/main/resources/ui/src/utils/Assets/AssetsUtils.ts @@ -95,6 +95,7 @@ export const getAPIfromSource = ( case EntityType.MLMODEL_SERVICE: case EntityType.STORAGE_SERVICE: case EntityType.DATABASE_SERVICE: + case EntityType.SEARCH_SERVICE: return (id, queryFields) => { const serviceCat = getServiceCategoryFromEntityType(source); @@ -140,6 +141,7 @@ export const getEntityAPIfromSource = ( case EntityType.MLMODEL_SERVICE: case EntityType.STORAGE_SERVICE: case EntityType.DATABASE_SERVICE: + case EntityType.SEARCH_SERVICE: return (id, queryFields) => { const serviceCat = getServiceCategoryFromEntityType(source); @@ -158,6 +160,14 @@ export const getAssetsSearchIndex = (source: AssetsOfEntity) => { [EntityType.CONTAINER]: SearchIndex.CONTAINER, [EntityType.STORED_PROCEDURE]: SearchIndex.STORED_PROCEDURE, [EntityType.DASHBOARD_DATA_MODEL]: SearchIndex.DASHBOARD_DATA_MODEL, + [EntityType.SEARCH_INDEX]: SearchIndex.SEARCH_INDEX, + [EntityType.DATABASE_SERVICE]: SearchIndex.DATABASE_SERVICE, + [EntityType.MESSAGING_SERVICE]: SearchIndex.MESSAGING_SERVICE, + [EntityType.DASHBOARD_SERVICE]: SearchIndex.DASHBOARD_SERVICE, + [EntityType.PIPELINE_SERVICE]: SearchIndex.PIPELINE_SERVICE, + [EntityType.MLMODEL_SERVICE]: SearchIndex.ML_MODEL_SERVICE, + [EntityType.STORAGE_SERVICE]: SearchIndex.STORAGE_SERVICE, + [EntityType.SEARCH_SERVICE]: SearchIndex.SEARCH_SERVICE, }; if ( diff --git a/openmetadata-ui/src/main/resources/ui/src/utils/DomainUtils.tsx b/openmetadata-ui/src/main/resources/ui/src/utils/DomainUtils.tsx index 996f68aa943..2b0acb5df6b 100644 --- a/openmetadata-ui/src/main/resources/ui/src/utils/DomainUtils.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/utils/DomainUtils.tsx @@ -20,7 +20,6 @@ import { NO_DATA_PLACEHOLDER, } from '../constants/constants'; import { EntityField } from '../constants/Feeds.constants'; -import { SearchIndex } from '../enums/search.enum'; import { DataProduct } from '../generated/entity/domains/dataProduct'; import { Domain } from '../generated/entity/domains/domain'; import { ChangeDescription, EntityReference } from '../generated/entity/type'; @@ -110,6 +109,3 @@ export const getUserNames = ( return getOwner(hasPermission, getEntityName(entity.owner), entity.owner); }; - -export const DomainAssetsSearchIndex = - `${SearchIndex.DASHBOARD},${SearchIndex.TABLE},${SearchIndex.TOPIC},${SearchIndex.PIPELINE},${SearchIndex.MLMODEL},${SearchIndex.GLOSSARY},${SearchIndex.CONTAINER}` as SearchIndex; diff --git a/openmetadata-ui/src/main/resources/ui/src/utils/EntityUtils.tsx b/openmetadata-ui/src/main/resources/ui/src/utils/EntityUtils.tsx index 850a2035be5..5129b2e3e33 100644 --- a/openmetadata-ui/src/main/resources/ui/src/utils/EntityUtils.tsx +++ b/openmetadata-ui/src/main/resources/ui/src/utils/EntityUtils.tsx @@ -33,6 +33,7 @@ import { LineagePos, } from '../components/Entity/EntityLineage/EntityLineage.interface'; import { + EntityServiceUnion, EntityUnion, EntityWithServices, } from '../components/Explore/explore.interface'; @@ -96,6 +97,7 @@ import { DataProduct } from '../generated/entity/domains/dataProduct'; import { Edge, EntityLineage } from '../generated/type/entityLineage'; import { EntityReference } from '../generated/type/entityUsage'; import { TagLabel } from '../generated/type/tagLabel'; +import { UsageDetails } from '../generated/type/usageDetails'; import { Votes } from '../generated/type/votes'; import { EntityFieldThreadCount } from '../interface/feed.interface'; import { @@ -188,6 +190,11 @@ export const getOwnerNameWithProfilePic = ( ) : null; +const getUsageData = (usageSummary: UsageDetails | undefined) => + !isNil(usageSummary?.weeklyStats?.percentileRank) + ? getUsagePercentile(usageSummary?.weeklyStats?.percentileRank ?? 0) + : NO_DATA; + const getTableFieldsFromTableDetails = (tableDetails: Table) => { const { fullyQualifiedName, @@ -206,10 +213,6 @@ const getTableFieldsFromTableDetails = (tableDetails: Table) => { const tier = getTierFromTableTags(tags ?? []); - const usage = !isNil(usageSummary?.weeklyStats?.percentileRank) - ? getUsagePercentile(usageSummary?.weeklyStats?.percentileRank ?? 0) - : NO_DATA; - return { fullyQualifiedName, owner, @@ -217,7 +220,7 @@ const getTableFieldsFromTableDetails = (tableDetails: Table) => { database, schema, tier, - usage, + usage: getUsageData(usageSummary), profile, columns, tableType, @@ -742,6 +745,140 @@ const getStoredProcedureOverview = ( return overview; }; +const getDatabaseOverview = (databaseDetails: Database) => { + const { owner, service, tags, usageSummary } = databaseDetails; + + const tier = getTierFromTableTags(tags ?? []); + + const overview = [ + { + name: i18next.t('label.owner'), + value: + getOwnerNameWithProfilePic(owner) ?? + i18next.t('label.no-entity', { + entity: i18next.t('label.owner'), + }), + url: getOwnerValue(owner as EntityReference), + isLink: !isEmpty(owner?.name), + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + + { + name: i18next.t('label.tier'), + value: tier ? tier.split(FQN_SEPARATOR_CHAR)[1] : NO_DATA, + isLink: false, + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + { + name: i18next.t('label.service'), + value: service.fullyQualifiedName || NO_DATA, + url: getServiceDetailsPath( + service.fullyQualifiedName ?? '', + ServiceCategory.DATABASE_SERVICES + ), + isLink: true, + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + + { + name: i18next.t('label.usage'), + value: getUsageData(usageSummary), + isLink: false, + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + ]; + + return overview; +}; + +const getDatabaseSchemaOverview = (databaseSchemaDetails: DatabaseSchema) => { + const { owner, service, tags, usageSummary, database } = + databaseSchemaDetails; + + const tier = getTierFromTableTags(tags ?? []); + + const overview = [ + { + name: i18next.t('label.owner'), + value: + getOwnerNameWithProfilePic(owner) ?? + i18next.t('label.no-entity', { + entity: i18next.t('label.owner'), + }), + url: getOwnerValue(owner as EntityReference), + isLink: !isEmpty(owner?.name), + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + + { + name: i18next.t('label.tier'), + value: tier ? tier.split(FQN_SEPARATOR_CHAR)[1] : NO_DATA, + isLink: false, + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + { + name: i18next.t('label.service'), + value: service.fullyQualifiedName ?? NO_DATA, + url: getServiceDetailsPath( + service.fullyQualifiedName ?? '', + ServiceCategory.DATABASE_SERVICES + ), + isLink: true, + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + { + name: i18next.t('label.database'), + value: database.fullyQualifiedName ?? NO_DATA, + url: getDatabaseDetailsPath(database.fullyQualifiedName ?? ''), + isLink: true, + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + { + name: i18next.t('label.usage'), + value: getUsageData(usageSummary), + isLink: false, + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + ]; + + return overview; +}; + +const getEntityServiceOverview = (serviceDetails: EntityServiceUnion) => { + const { owner, tags, serviceType } = serviceDetails; + + const tier = getTierFromTableTags(tags ?? []); + + const overview = [ + { + name: i18next.t('label.owner'), + value: + getOwnerNameWithProfilePic(owner) ?? + i18next.t('label.no-entity', { + entity: i18next.t('label.owner'), + }), + url: getOwnerValue(owner as EntityReference), + isLink: !isEmpty(owner?.name), + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + + { + name: i18next.t('label.tier'), + value: tier ? tier.split(FQN_SEPARATOR_CHAR)[1] : NO_DATA, + isLink: false, + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + { + name: i18next.t('label.service-type'), + value: serviceType, + isLink: false, + visible: [DRAWER_NAVIGATION_OPTIONS.explore], + }, + ]; + + return overview; +}; + export const getEntityOverview = ( type: string, entityDetail: EntityUnion @@ -778,6 +915,23 @@ export const getEntityOverview = ( return getStoredProcedureOverview(entityDetail as StoredProcedure); } + case ExplorePageTabs.DATABASE: { + return getDatabaseOverview(entityDetail as Database); + } + + case ExplorePageTabs.DATABASE_SCHEMA: { + return getDatabaseSchemaOverview(entityDetail as DatabaseSchema); + } + + case ExplorePageTabs.DATABASE_SERVICE: + case ExplorePageTabs.MESSAGING_SERVICE: + case ExplorePageTabs.DASHBOARD_SERVICE: + case ExplorePageTabs.ML_MODEL_SERVICE: + case ExplorePageTabs.PIPELINE_SERVICE: + case ExplorePageTabs.SEARCH_INDEX_SERVICE: { + return getEntityServiceOverview(entityDetail as EntityServiceUnion); + } + default: return []; } @@ -1160,6 +1314,8 @@ export const getEntityLinkFromType = ( return getContainerDetailPath(fullyQualifiedName); case EntityType.DATABASE: return getDatabaseDetailsPath(fullyQualifiedName); + case EntityType.DATABASE_SCHEMA: + return getDatabaseSchemaDetailsPath(fullyQualifiedName); case EntityType.DATA_PRODUCT: return getDataProductsDetailsPath(getEncodedFqn(fullyQualifiedName)); case EntityType.DASHBOARD_DATA_MODEL: