Skip to content

Fix #6753 - Argo Client PoC implementation - #8595

Closed
pmbrull wants to merge 16 commits into
open-metadata:mainfrom
pmbrull:issue-6753
Closed

pmbrull wants to merge 16 commits into
open-metadata:mainfrom
pmbrull:issue-6753

Conversation

@pmbrull

@pmbrull pmbrull commented Nov 8, 2022 •

Copy link
Copy Markdown
Member

Describe your changes :

Fix #6753

This PR prepares the ground for further work on the Argo Client as a Pipeline Service. It currently can deploy metadata ingestion workflows from the UI.

Notice how we have updated a couple of configs on the openmetadata.yaml about Airflow, by grouping them in pipelineServiceClientConfiguration. We can discuss if this is the right move for 0.13.0 or we want to wait on delivering this.

Happy to discuss! It's super rough so now's the time to chat and change :)

You can find all the followup work here #8586

Type of change :

  • Bug fix
  • Improvement
  • New feature
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation

Frontend Preview (Screenshots) :

For frontend related change, please link screenshots of your changes preview! Optional for backend related changes.

Checklist:

  • I have read the CONTRIBUTING document.
  • I have commented on my code, particularly in hard-to-understand areas.
  • I have added tests that prove my fix is effective or that my feature works.
  • All new and existing tests passed.

Reviewers

@pmbrull
pmbrull requested a review from a team as a code owner November 8, 2022 17:59
@pmbrull
pmbrull temporarily deployed to cypress November 8, 2022 17:59 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 8, 2022 17:59 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 8, 2022 17:59 Inactive
@pmbrull
pmbrull requested a review from a team November 8, 2022 17:59
@pmbrull
pmbrull temporarily deployed to cypress November 8, 2022 17:59 Inactive
SERVER_HOST_API_URL: ${SERVER_HOST_API_URL:-http://openmetadata-server:8585/api}
# OpenMetadata Server Airflow Configuration
AIRFLOW_HOST: ${AIRFLOW_HOST:-http://ingestion:8080}
SERVER_HOST_API_URL: ${SERVER_HOST_API_URL:-http://openmetadata-server:8585/api}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

moved to Pipeline Service Config

@github-actions

github-actions Bot commented Nov 8, 2022

Copy link
Copy Markdown
Contributor

The Java checkstyle failed.

Please run mvn googleformatter:format@reformat-sources in the root of your repository and commit the changes to this PR.
You can also use pre-commit to automate the Java code formatting.

You can install the pre-commit hooks with make install_test precommit_install.

# OpenMetadata Airflow Azure SSO Configuration
OM_AUTH_AIRFLOW_AZURE_CLIENT_SECRET: ${OM_AUTH_AIRFLOW_AZURE_CLIENT_SECRET:-""}
OM_AUTH_AIRFLOW_AZURE_AUTHORITY_URL: ${OM_AUTH_AIRFLOW_AZURE_AUTHORITY_URL:-""}
OM_AUTH_AIRFLOW_AZURE_SCOPES: ${OM_AUTH_AIRFLOW_AZURE_SCOPES:-[]}

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

all these OM_AUTH_* variables are not required anymore as we pick up the Ingestion Bot JWT directly

<artifactId>argo-client-java</artifactId>
<version>v3.4.2</version>
<scope>system</scope>
<systemPath>${project.basedir}/src/main/resources/pipelineServiceClient/argo-client-java-v3.4.2.jar</systemPath>

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the thought process of adding this to the resources directory is that the jar is not available in mavenrepo. Instead, argoproj publishes it as a Github package, and retrieving that through pom and maven repositories requires authenticating to github.

to ease the setup process and do not add noise to the CI, adding the jar locally seems a sensible middle ground

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have we run Snyk after this change to check they don't have any security risk?

: PipelineServiceClientConfiguration.DEFAULT_PIPELINE_SERVICE_CLIENT;

switch (pipelineServiceClientProvider) {
case AIRFLOW:

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

by default we'll use Airflow

}

public static OpenMetadataWorkflowConfig buildUsageWorkflowConfig(IngestionPipeline ingestionPipeline) {
return null;

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

we have open issues to keep implementing these

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: IMHO we could apply a strategy pattern to build the OpenMetadataWorkflowConfig instead of overloading this class with static methods.


@Override
public String runPipeline(String pipelineName) {
return null;

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same, open issues to handle these implementations

*/


package io.argoproj.workflow;

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The java SDK for Argo Workflows is generated automatically from some openapi files. Currently there is a parsing issue of the type Instant that we need to patch by shadowing their JSON implementation and passing a new custom adapter

@cypress

cypress Bot commented Nov 8, 2022 •

Copy link
Copy Markdown



Test summary

151 • 2 • 4 • 0


Run details

Project openmetadata
Status Failed
Commit c453db3
Started Nov 10, 2022 10:13 AM
Ended Nov 10, 2022 10:40 AM
Duration 26:52 💡
OS Linux Ubuntu - 20.04
Browser Chrome 107

View run in Cypress Dashboard ➡️


Failures

Pages/DataQualityAndProfiler.js 1 Failed
1 Data Quality and Profiler should work properly > Add Profiler ingestion
AddNewService/superset.spec.js 1 Failed
1 Superset Ingestion > add and ingest data

This comment has been generated by cypress-bot as a result of this project's GitHub integration settings. You can manage this integration in this project's settings in the Cypress Dashboard

@pmbrull
pmbrull temporarily deployed to cypress November 9, 2022 06:53 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 9, 2022 06:53 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 9, 2022 06:53 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 9, 2022 06:53 Inactive
@github-actions

github-actions Bot commented Nov 9, 2022

Copy link
Copy Markdown
Contributor

The Java checkstyle failed.

Please run mvn googleformatter:format@reformat-sources in the root of your repository and commit the changes to this PR.
You can also use pre-commit to automate the Java code formatting.

You can install the pre-commit hooks with make install_test precommit_install.

@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 06:06 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 06:06 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 06:06 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 06:06 Inactive
@github-actions

Copy link
Copy Markdown
Contributor

The Java checkstyle failed.

Please run mvn googleformatter:format@reformat-sources in the root of your repository and commit the changes to this PR.
You can also use pre-commit to automate the Java code formatting.

You can install the pre-commit hooks with make install_test precommit_install.

@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:05 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:05 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:05 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:05 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:13 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:13 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:13 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:13 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:19 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:19 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:19 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 08:19 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 09:54 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 09:54 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 09:54 Inactive
@pmbrull
pmbrull temporarily deployed to cypress November 10, 2022 09:54 Inactive
@sonarqubecloud

Copy link
Copy Markdown

[open-metadata-ingestion] Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

This branch was previously deployed

1 inactive deployment
cypress — c453db39 Deployed Nov 10, 2022 by pmbrull
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Argo PoC for workflow deployment

2 participants