Change dbt label to lowecase and remove dbt remove dbt from Database service (#9447)

This commit is contained in:
Ashish Gupta 2022-12-21 16:53:37 +05:30 committed by GitHub
parent 70d5536745
commit 5641e3d1ac
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
16 changed files with 66 additions and 54 deletions

View File

@ -103,10 +103,10 @@ describe('RedShift Ingestion', () => {
.should('be.visible')
.click();
cy.get('[data-testid="list-item"]')
.contains('Add DBT Ingestion')
.contains('Add dbt Ingestion')
.click();
//Add DBT ingestion
cy.contains('Add DBT Ingestion').should('be.visible');
cy.contains('Add dbt Ingestion').should('be.visible');
cy.get('[data-testid="dbt-source"]')
.should('be.visible')
.select('HTTP Config Source');

View File

@ -289,7 +289,7 @@ const Ingestion: React.FC<IngestionProps> = ({
case PipelineType.Dbt:
name = t('label.add-workflow-ingestion', {
workflow: t('label.dbt-uppercase'),
workflow: t('label.dbt-lowercase'),
});
break;

View File

@ -77,10 +77,10 @@ export const DBTCloudConfig: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="cloud-account-id">
{requiredField('DBT Cloud Account Id')}
{requiredField('dbt Cloud Account Id')}
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
DBT cloud account Id.
dbt cloud account Id.
</p>
<input
className="tw-form-inputs tw-form-inputs-padding"
@ -97,10 +97,10 @@ export const DBTCloudConfig: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="cloud-auth-token">
{requiredField('DBT Cloud Authentication Token')}
{requiredField('dbt Cloud Authentication Token')}
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
DBT cloud account authentication token.
dbt cloud account authentication token.
</p>
<Input.Password
className="tw-form-inputs tw-form-inputs-padding"
@ -117,11 +117,11 @@ export const DBTCloudConfig: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="dbtCloudProjectId">
DBT Cloud Project Id
dbt Cloud Project Id
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
In case of multiple projects in a DBT cloud account, specify the
project&apos;s id from which you want to extract the DBT run artifacts
In case of multiple projects in a dbt cloud account, specify the
project&apos;s id from which you want to extract the dbt run artifacts
</p>
<input
className="tw-form-inputs tw-form-inputs-padding"

View File

@ -57,16 +57,16 @@ export const GCSCreds: Array<DropDownListItem> = [
];
export const reqDBTCloudFields: Record<keyof DbtConfigCloudReq, string> = {
dbtCloudAccountId: 'DBT Cloud Account Id',
dbtCloudAuthToken: 'DBT Cloud Authentication Token',
dbtCloudAccountId: 'dbt Cloud Account Id',
dbtCloudAuthToken: 'dbt Cloud Authentication Token',
};
export const reqDBTLocalFields: Record<string, string> = {
dbtManifestFilePath: 'DBT Manifest File Path',
dbtManifestFilePath: 'dbt Manifest File Path',
};
export const reqDBTHttpFields: Record<string, string> = {
dbtManifestHttpPath: 'DBT Manifest Http Path',
dbtManifestHttpPath: 'dbt Manifest Http Path',
};
export const reqDBTS3Fields: Record<keyof DbtS3CredsReq, string> = {

View File

@ -370,10 +370,10 @@ export const DBTGCSConfig: FunctionComponent<Props> = ({
<Fragment>
<Field>
<label className="tw-block tw-form-label tw-mb-1" htmlFor="gcs-config">
DBT Configuration Source
dbt Configuration Source
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-sm">
Available sources to fetch DBT catalog and manifest files.
Available sources to fetch dbt catalog and manifest files.
</p>
<select
className="tw-form-inputs tw-form-inputs-padding"
@ -400,7 +400,7 @@ export const DBTGCSConfig: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="dbt-bucket-name">
DBT Bucket Name
dbt Bucket Name
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
Name of the bucket where the dbt files are stored.
@ -419,7 +419,7 @@ export const DBTGCSConfig: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="dbt-object-prefix">
DBT Object Prefix
dbt Object Prefix
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
Path of the folder where the dbt files are stored.

View File

@ -76,10 +76,10 @@ export const DBTHttpConfig: FunctionComponent<Props> = ({
<Fragment>
<Field>
<label className="tw-block tw-form-label tw-mb-1" htmlFor="catalog-url">
DBT Catalog HTTP Path
dbt Catalog HTTP Path
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
DBT catalog file to extract dbt models with their column schemas.
dbt catalog file to extract dbt models with their column schemas.
</p>
<input
className="tw-form-inputs tw-form-inputs-padding"
@ -96,10 +96,10 @@ export const DBTHttpConfig: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="manifest-url">
{requiredField('DBT Manifest HTTP Path')}
{requiredField('dbt Manifest HTTP Path')}
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
DBT manifest file path to extract dbt models and associate with
dbt manifest file path to extract dbt models and associate with
tables.
</p>
<input

View File

@ -76,10 +76,10 @@ export const DBTLocalConfig: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="catalog-file">
DBT Catalog File Path
dbt Catalog File Path
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
DBT catalog file to extract dbt models with their column schemas.
dbt catalog file to extract dbt models with their column schemas.
</p>
<input
className="tw-form-inputs tw-form-inputs-padding"
@ -96,10 +96,10 @@ export const DBTLocalConfig: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="manifest-file">
{requiredField('DBT Manifest File Path')}
{requiredField('dbt Manifest File Path')}
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
DBT manifest file path to extract dbt models and associate with
dbt manifest file path to extract dbt models and associate with
tables.
</p>
<input
@ -117,10 +117,10 @@ export const DBTLocalConfig: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="run-result-file">
DBT Run Results File Path
dbt Run Results File Path
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
DBT run results file path to extract the test results information.
dbt run results file path to extract the test results information.
</p>
<input
className="tw-form-inputs tw-form-inputs-padding"

View File

@ -195,7 +195,7 @@ export const DBTS3Config: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="dbt-bucket-name">
DBT Bucket Name
dbt Bucket Name
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
Name of the bucket where the dbt files are stored.
@ -214,7 +214,7 @@ export const DBTS3Config: FunctionComponent<Props> = ({
<label
className="tw-block tw-form-label tw-mb-1"
htmlFor="dbt-object-prefix">
DBT Object Prefix
dbt Object Prefix
</label>
<p className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs">
Path of the folder where the dbt files are stored.

View File

@ -44,7 +44,7 @@ function SwitchField({
<p
className="tw-text-grey-muted tw-mt-1 tw-mb-2 tw-text-xs"
data-testid="switch-description">
Optional configuration to update the description from DBT or not
Optional configuration to update the description from dbt or not
</p>
</Field>
);

View File

@ -24,7 +24,7 @@ export const STEPS_FOR_ADD_INGESTION: Array<StepperStepType> = [
},
{
name: i18next.t('label.configure-entity', {
entity: i18next.t('label.dbt-uppercase'),
entity: i18next.t('label.dbt-lowercase'),
}),
step: 2,
},

View File

@ -150,7 +150,7 @@ export const excludedService = [
MetadataServiceType.OpenMetadata,
];
export const IGNORED_DB_SERVICES: Array<string> = ['QueryLog'];
export const IGNORED_DB_SERVICES: Array<string> = ['QueryLog', 'Dbt'];
export const serviceTypes: Record<ServiceTypes, Array<string>> = {
databaseServices: (Object.values(DatabaseServiceType) as string[])

View File

@ -50,9 +50,9 @@ export const addMetadataIngestionGuide = [
},
{
step: 2,
title: 'Configure DBT Model',
description: `A DBT model provides transformation logic that creates a table from raw data. Lineage traces the path of data across tables, but a DBT model provides specifics.
Select the required DBT source provider and fill in the mandatory fields. Integrate with DBT from OpenMetadata to view the models used to generate tables.`,
title: 'Configure dbt Model',
description: `A dbt model provides transformation logic that creates a table from raw data. Lineage traces the path of data across tables, but a dbt model provides specifics.
Select the required dbt source provider and fill in the mandatory fields. Integrate with dbt from OpenMetadata to view the models used to generate tables.`,
},
{
...schedulingIngestionGuide,
@ -122,14 +122,16 @@ export const addProfilerIngestionGuide = [
export const addDBTIngestionGuide = [
{
step: 2,
title: 'Add DBT Ingestion',
description: `A profiler workflow can be configured and deployed after a metadata ingestion has been set up. Multiple profiler pipelines can be set up for the same database service.
The pipeline feeds the Profiler tab of the Table entity, and also runs the tests configured for that entity. Add a Name, FQN, and define the filter pattern to start.`,
title: 'Add dbt Ingestion',
description: `A dbt workflow can be configured and deployed after a metadata ingestion has been set up.
Multiple dbt pipelines can be set up for the same database service. The pipeline feeds the dbt tab of the
Table entity, creates lineage from dbt nodes and adds tests from dbt. Add the source configuration of the
dbt files to start.`,
},
{ ...schedulingIngestionGuide },
{
step: 5,
title: 'DBT Ingestion Added Successfully',
title: 'dbt Ingestion Added Successfully',
description:
'You are all set! The <Ingestion Pipeline Name> has been successfully deployed. The profiler will run at a regular interval as per the schedule.',
},

View File

@ -301,6 +301,7 @@
"chart-type": "Chart Type",
"query-plural": "Queries",
"dbt-uppercase": "DBT",
"dbt-lowercase": "dbt",
"row-plural": "Rows",
"columns-plural": "Columns",
"algorithm": "Algorithm",
@ -397,7 +398,7 @@
"notification-plural": "Notifications",
"view-all": "View all",
"configure-ingestion": "Configure Ingestion",
"configure-dbt": "Configure DBT",
"configure-dbt": "Configure dbt",
"configure-service": "Configure Service",
"tables": "Tables",
"topics": "Topics",
@ -555,7 +556,7 @@
"select-data-assets": "Select Data Assets",
"profiler-timeout-seconds-label": "Timeout in Seconds",
"add-deploy": "Add & Deploy",
"dbt-Configuration-source": "DBT Configuration Source",
"dbt-Configuration-source": "dbt Configuration Source",
"select-dbt-source": "Select DBT Source",
"no-selected-dbt": "No source selected for DBT Configuration.",
"dbt": "DBT",
@ -599,7 +600,7 @@
"follower-plural": "Followers",
"email-plural": "Emails",
"no-tier": "No Tier",
"dbt-run-result-http-path": "DBT Run Results HTTP Path"
"dbt-run-result-http-path": "dbt Run Results HTTP Path"
},
"message": {
"service-email-required": "Service account Email is required",
@ -719,7 +720,7 @@
"advanced-search-message": "Discover the right data assets using the syntax editor with and/or conditions.",
"profiler-timeout-seconds-message": "Optional number setting the timeout in seconds for the profiler. If the timeout is reached the profiler will wait for any pending queries to terminated its execution.",
"instance-identifier": "Name that identifies this configuration instance uniquely.",
"fetch-dbt-files": "Available sources to fetch DBT catalog and manifest files.",
"fetch-dbt-files": "Available sources to fetch dbt catalog and manifest files.",
"profile-sample-percentage-message": "Set the Profiler value as percentage",
"profile-sample-row-count-message": " Set the Profiler value as row count",
"no-profiler-enabled-summary-message": "Profiler is not enabled for the table.",
@ -728,7 +729,7 @@
"alerts-trigger-description": "Trigger for all data assets or a specific entity.",
"alerts-filter-description": "Specify the change events to narrow the scope of your alerts.",
"length-validator-error": "At least {{length}} {{field}} required",
"dbt-run-result-http-path-message": "DBT run results http path to extract the test results information."
"dbt-run-result-http-path-message": "dbt run results http path to extract the test results information."
},
"server": {
"you-have-not-action-anything-yet": "You have not {{action}} anything yet.",

View File

@ -233,9 +233,7 @@ const AddIngestionPage = () => {
activeTitle: true,
},
{
name: t('label.add-workflow-ingestion', {
workflow: startCase(ingestionType),
}),
name: getIngestionHeadingName(ingestionType, INGESTION_ACTION_TYPE.ADD),
url: '',
activeTitle: true,
},

View File

@ -13,7 +13,7 @@
import { Space } from 'antd';
import { AxiosError } from 'axios';
import { capitalize, startCase } from 'lodash';
import { startCase } from 'lodash';
import { ServiceTypes } from 'Models';
import React, { useEffect, useState } from 'react';
import { useHistory, useParams } from 'react-router-dom';
@ -269,7 +269,10 @@ const EditIngestionPage = () => {
activeTitle: true,
},
{
name: `Edit ${capitalize(ingestionType)} Ingestion`,
name: getIngestionHeadingName(
ingestionType,
INGESTION_ACTION_TYPE.EDIT
),
url: '',
activeTitle: true,
},

View File

@ -13,17 +13,25 @@
import { t } from 'i18next';
import { capitalize, upperCase } from 'lodash';
import { INGESTION_ACTION_TYPE } from '../constants/Ingestions.constant';
import {
INGESTION_ACTION_TYPE,
PIPELINE_TYPE_LOCALISATION,
} from '../constants/Ingestions.constant';
import { PipelineType } from '../generated/api/services/ingestionPipelines/createIngestionPipeline';
export const getIngestionHeadingName = (
ingestionType: string,
type: string
) => {
let ingestionName = capitalize(ingestionType);
let ingestionName = t(
`label.${
PIPELINE_TYPE_LOCALISATION[
ingestionType as keyof typeof PIPELINE_TYPE_LOCALISATION
]
}`
);
if (ingestionType === PipelineType.Dbt) {
ingestionName = upperCase(ingestionType);
ingestionName = t('label.dbt-lowercase');
}
return type === INGESTION_ACTION_TYPE.ADD