Skip to content

Commit

Permalink
Merge branch 'main' into feature-import-export-custom-property
Browse files Browse the repository at this point in the history
  • Loading branch information
Ashish8689 committed Sep 30, 2024
2 parents fd21170 + dcde500 commit f6830cb
Show file tree
Hide file tree
Showing 16 changed files with 230 additions and 24 deletions.
1 change: 1 addition & 0 deletions nativeProject
Submodule nativeProject added at b52246
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
title: Database service setup
slug: /how-to-guides/getting-started/day-1/database-service-setup
collate: true
---

## Setting Up a Database Service for Metadata Extraction
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
title: Day 1
slug: /how-to-guides/getting-started/day-1
collate: true
---

# Getting Started: Day 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ slug: /how-to-guides/getting-started

Welcome to OpenMetadata's unified platform for data discovery, observability, and governance. Our platform centralizes all data context to help you build high-quality data and AI assets. This guide provides the necessary information to set up your OpenMetadata environment in 30 minutes.

## How Does Collate Work?
## How Does OpenMetadata Work?

OpenMetadata is designed to support both technical and non-technical data practitioners across various use cases, including data discovery, lineage, observability, quality, collaboration, governance, and insights.

Expand All @@ -18,7 +18,7 @@ The platform’s native collaboration features support shared workflows, enablin

## Key Features of OpenMetadata

Before we get started, here’s a quick summary of some of Collate’s main features:
Before we get started, here’s a quick summary of some of OpenMetadata’s main features:

### Discovery
- Integrated catalog, data quality, and glossary
Expand Down
13 changes: 13 additions & 0 deletions openmetadata-docs/content/v1.5.x/how-to-guides/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,19 @@ slug: /how-to-guides

# How-to Guides

## Getting Started

Set up and explore OpenMetadata's core features, from basic configuration to advanced functionalities, for a seamless onboarding experience.

{% tilesContainer %}
{% tile
title="Getting Started"
description="Unlock metadata insights for informed business decisions."
link="/how-to-guides/getting-started"
icon="discovery"
/%}
{% /tilesContainer %}

The How-to Guides will give you a walk through on accomplishing the basic to the most advanced things in OpenMetadata. These step-by-step guides will help get an overview of the features and also help explore the various functionalities.

## Features in OpenMetadata
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
title: Database service setup
slug: /how-to-guides/getting-started/day-1/database-service-setup
collate: true
---

## Setting Up a Database Service for Metadata Extraction
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
---
title: Day 1
slug: /how-to-guides/getting-started/day-1
collate: true
---

# Getting Started: Day 1
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ slug: /how-to-guides/getting-started

Welcome to OpenMetadata's unified platform for data discovery, observability, and governance. Our platform centralizes all data context to help you build high-quality data and AI assets. This guide provides the necessary information to set up your OpenMetadata environment in 30 minutes.

## How Does Collate Work?
## How Does OpenMetadata Work?

OpenMetadata is designed to support both technical and non-technical data practitioners across various use cases, including data discovery, lineage, observability, quality, collaboration, governance, and insights.

Expand All @@ -18,7 +18,7 @@ The platform’s native collaboration features support shared workflows, enablin

## Key Features of OpenMetadata

Before we get started, here’s a quick summary of some of Collate’s main features:
Before we get started, here’s a quick summary of some of OpenMetadata’s main features:

### Discovery
- Integrated catalog, data quality, and glossary
Expand Down
13 changes: 13 additions & 0 deletions openmetadata-docs/content/v1.6.x-SNAPSHOT/how-to-guides/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,19 @@ slug: /how-to-guides

# How-to Guides

## Getting Started

Set up and explore OpenMetadata's core features, from basic configuration to advanced functionalities, for a seamless onboarding experience.

{% tilesContainer %}
{% tile
title="Getting Started"
description="Unlock metadata insights for informed business decisions."
link="/how-to-guides/getting-started"
icon="discovery"
/%}
{% /tilesContainer %}

The How-to Guides will give you a walk through on accomplishing the basic to the most advanced things in OpenMetadata. These step-by-step guides will help get an overview of the features and also help explore the various functionalities.

## Features in OpenMetadata
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,8 @@ test.describe('Observability Alert Flow', () => {
});

test('Pipeline Alert', async ({ page }) => {
test.slow();

const ALERT_NAME = generateAlertName();

await test.step('Create alert', async () => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
import test from '@playwright/test';
import test, { expect } from '@playwright/test';
import { get } from 'lodash';
import { ApiEndpointClass } from '../../support/entity/ApiEndpointClass';
import { ContainerClass } from '../../support/entity/ContainerClass';
Expand Down Expand Up @@ -280,3 +280,85 @@ test('Verify column lineage between table and api endpoint', async ({

await afterAction();
});

test('Verify function data in edge drawer', async ({ browser }) => {
const { page } = await createNewPage(browser);
const { apiContext, afterAction } = await getApiContext(page);
const table1 = new TableClass();
const table2 = new TableClass();

try {
await table1.create(apiContext);
await table2.create(apiContext);
const sourceTableFqn = get(table1, 'entityResponseData.fullyQualifiedName');
const sourceColName = `${sourceTableFqn}.${get(
table1,
'entityResponseData.columns[0].name'
)}`;

const targetTableFqn = get(table2, 'entityResponseData.fullyQualifiedName');
const targetColName = `${targetTableFqn}.${get(
table2,
'entityResponseData.columns[0].name'
)}`;

await addPipelineBetweenNodes(page, table1, table2);
await activateColumnLayer(page);
await addColumnLineage(page, sourceColName, targetColName);

const lineageReq = page.waitForResponse('/api/v1/lineage/getLineage?*');
await page.reload();
const lineageRes = await lineageReq;
const jsonRes = await lineageRes.json();
const edge = jsonRes.edges[0];
const columnData = edge.columns[0];

const newEdge = {
edge: {
fromEntity: {
id: edge.fromEntity.id,
type: edge.fromEntity.type,
},
toEntity: {
id: edge.toEntity.id,
type: edge.toEntity.type,
},
lineageDetails: {
columnsLineage: [
{
fromColumns: [columnData.fromColumns[0]],
function: 'count',
toColumn: columnData.toColumn,
},
],
description: 'test',
},
},
};
await apiContext.put(`/api/v1/lineage`, {
data: newEdge,
});
const lineageReq1 = page.waitForResponse('/api/v1/lineage/getLineage?*');
await page.reload();
await lineageReq1;

await activateColumnLayer(page);
await page
.locator(
`[data-testid="column-edge-${btoa(sourceColName)}-${btoa(
targetColName
)}"]`
)
.dispatchEvent('click');

await page.locator('.edge-info-drawer').isVisible();

await expect(await page.locator('[data-testid="Function"]')).toContainText(
'count'
);
} finally {
await table1.delete(apiContext);
await table2.delete(apiContext);
await afterAction();
}
});
11 changes: 7 additions & 4 deletions openmetadata-ui/src/main/resources/ui/playwright/utils/alert.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ import {
} from '../constant/alert.interface';
import { DELETE_TERM } from '../constant/common';
import { SidebarItem } from '../constant/sidebar';
import { Domain } from '../support/domain/Domain';
import { DashboardClass } from '../support/entity/DashboardClass';
import { UserClass } from '../support/user/UserClass';
import {
clickOutside,
descriptionBox,
Expand Down Expand Up @@ -643,10 +646,10 @@ export const addMultipleFilters = async ({
dashboard,
}: {
page: Page;
user1;
user2;
domain;
dashboard;
user1: UserClass;
user2: UserClass;
domain: Domain;
dashboard: DashboardClass;
}) => {
// Add owner filter
await page.click('[data-testid="add-filters"]');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ import { EntityType } from '../../../enums/entity.enum';
import { Source } from '../../../generated/type/entityLineage';
import { getNameFromFQN } from '../../../utils/CommonUtils';
import {
getColumnFunctionValue,
getColumnSourceTargetHandles,
getLineageDetailsObject,
} from '../../../utils/EntityLineageUtils';
Expand Down Expand Up @@ -66,6 +67,7 @@ const EdgeInfoDrawer = ({
const { source, target, data } = edge;
const { sourceHandle, targetHandle } = getColumnSourceTargetHandles(edge);
const { pipeline, pipelineEntityType } = data?.edge ?? {};
const isColumnLineage = sourceHandle && targetHandle;

let sourceData: Node | undefined, targetData: Node | undefined;
nodes.forEach((node) => {
Expand Down Expand Up @@ -121,7 +123,13 @@ const EdgeInfoDrawer = ({
},
functionInfo: {
key: t('label.function'),
value: data.columnFunctionValue,
value: isColumnLineage
? getColumnFunctionValue(
data?.edge?.columns ?? [],
sourceHandle ?? '',
targetHandle ?? ''
)
: undefined,
},
});
setIsLoading(false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,27 +26,26 @@ import { AxiosError } from 'axios';
import { toLower } from 'lodash';
import React, { FC, useEffect, useMemo, useState } from 'react';
import { useTranslation } from 'react-i18next';
import { ReactComponent as IconBotProfile } from '../../../../assets/svg/bot-profile.svg';
import { ReactComponent as EditIcon } from '../../../../assets/svg/edit-new.svg';
import { TERM_ADMIN } from '../../../../constants/constants';
import { PAGE_SIZE_LARGE, TERM_ADMIN } from '../../../../constants/constants';
import { GlobalSettingOptions } from '../../../../constants/GlobalSettings.constants';
import { useLimitStore } from '../../../../context/LimitsProvider/useLimitsStore';
import { EntityType } from '../../../../enums/entity.enum';
import { Role } from '../../../../generated/entity/teams/role';
import { getRoles } from '../../../../rest/userAPI';
import { getRoles } from '../../../../rest/rolesAPIV1';
import { getEntityName } from '../../../../utils/EntityUtils';
import { getSettingPath } from '../../../../utils/RouterUtils';
import { showErrorToast } from '../../../../utils/ToastUtils';
import DescriptionV1 from '../../../common/EntityDescription/DescriptionV1';
import InheritedRolesCard from '../../../common/InheritedRolesCard/InheritedRolesCard.component';
import RolesCard from '../../../common/RolesCard/RolesCard.component';
import TitleBreadcrumb from '../../../common/TitleBreadcrumb/TitleBreadcrumb.component';
import PageLayoutV1 from '../../../PageLayoutV1/PageLayoutV1';
import AccessTokenCard from '../../Users/AccessTokenCard/AccessTokenCard.component';
import './bot-details.less';
import { BotsDetailProps } from './BotDetails.interfaces';

import { ReactComponent as IconBotProfile } from '../../../../assets/svg/bot-profile.svg';
import { useLimitStore } from '../../../../context/LimitsProvider/useLimitsStore';
import { EntityType } from '../../../../enums/entity.enum';
import DescriptionV1 from '../../../common/EntityDescription/DescriptionV1';
import AccessTokenCard from '../../Users/AccessTokenCard/AccessTokenCard.component';

const BotDetails: FC<BotsDetailProps> = ({
botData,
botUserData,
Expand Down Expand Up @@ -88,7 +87,13 @@ const BotDetails: FC<BotsDetailProps> = ({

const fetchRoles = async () => {
try {
const { data } = await getRoles();
const { data } = await getRoles(
'',
undefined,
undefined,
false,
PAGE_SIZE_LARGE
);
setRoles(data);
} catch (err) {
setRoles([]);
Expand Down
Loading

0 comments on commit f6830cb

Please sign in to comment.