Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Persist OpenLineage event before updating marquez model. #2069

Merged
merged 1 commit into from
Aug 12, 2022

Conversation

fm100
Copy link
Collaborator

@fm100 fm100 commented Aug 11, 2022

Signed-off-by: Minkyu Park minkyu.park.200@gmail.com

Problem

When the RunTransitionListener is invoked, OpenLineage event is not persisted to the database. Because OpenLineage event is the source of truth of all marquez run transition, it would be nice to make it available from RunTransitionListener.

Solution

This PR simply switch the order of the code in order to persist the OpenLineage event first and then update the marquez model.

Checklist

  • You've signed-off your work
  • Your changes are accompanied by tests (if relevant)
  • Your change contains a small diff and is self-contained
  • You've updated any relevant documentation (if relevant)
  • You've updated the CHANGELOG.md with details about your change under the "Unreleased" section (if relevant, depending on the change, this may not be necessary)
  • You've versioned your .sql database schema migration according to Flyway's naming convention (if relevant)
  • You've included a header in any source code files (if relevant)

RunTransitionListener is invoked after updating the marquez model,
but OpenLineage event is not available at that moment. This simply
switch the order of it, that persists OpenLineage event first and
then updates marquez model. With this change, OpenLineage event is
already persisted and available from RunTransitionListener.

Signed-off-by: Minkyu Park <minkyu.park.200@gmail.com>
Copy link
Member

@wslulciuc wslulciuc left a comment

Choose a reason for hiding this comment

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

Totally makes sense! 👍 💯

@wslulciuc wslulciuc enabled auto-merge (squash) August 11, 2022 22:53
@wslulciuc wslulciuc merged commit 626b844 into MarquezProject:main Aug 12, 2022
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.

2 participants