Skip to main content
Set up Column-Level Lineage Diff on GitLab. First complete the shared Lineage Diff prerequisites. Then choose how it runs:
  • With the GitLab connection (recommended): Paradime runs Lineage Diff after Turbo CI on each merge request. You do not need a pipeline or an access token.
  • From a GitLab pipeline: your .gitlab-ci.yml runs Turbo CI, then asks Paradime for the lineage diff report and posts it.

Run Lineage Diff with the GitLab connection

Prerequisites
  1. Connect GitLab on gitlab.com or GitLab Self-Managed, and pick your dbt™ project as one of the connection’s projects.
  2. Set up Turbo CI with the GitLab connection.
A GitLab pipeline for a merge request commit, with an external stage that holds the Paradime Lineage Diff and Paradime Turbo CI statuses, both passed
When Turbo CI starts on a merge request commit, the Paradime Lineage Diff commit status shows as pending. The first Turbo CI run on that commit that produces a dbt™ manifest computes the diff. If columns changed, Paradime posts one note on the merge request that lists the impacted downstream nodes. On each new commit, Paradime updates the same note instead of adding a new one. If the Turbo CI run is cancelled, for example by a new push, the commit’s Paradime Lineage Diff status shows as cancelled instead of waiting.

Run Lineage Diff from a GitLab pipeline

Generate API keys

Generate a Paradime API key with the Bolt schedules admin capability. Use an Account API key (a prdm_cmp_... Bearer token), and note your workspace token and API endpoint; you will add them as CI/CD variables in a later step.

Generate API keys

Create a Pipeline

Now you will need to create a new .gitlab-ci.yml file in your dbt™️ repository. Copy the code below. This pipeline has two stages:
  1. paradime_turbo_ci — Runs the Turbo CI bolt schedule and exports the BOLT_RUN_ID for the next stage.
  2. lineage_diff_report — Uses the BOLT_RUN_ID to trigger the lineage diff report and posts the result as a comment on the Merge Request.

Create a GitLab Access Token

You will need to create GitLab Access Token with API to enable Comments to be generated when opening a Merge Request. Create a group access token (Only available on GitLab Premium Tier or Higher) Navigate to your GitLab project
  1. Go to Settings > Access Tokens in the left sidebar
  2. Enter a name for your token (e.g., “API Comment Access”)
  3. Select the appropriate scopes:
    • api (for general API access)
    • Specifically for comments, you’ll need at least api scope, which includes the ability to write comments
Create a GitLab personal access token
If using a GitLab personal access token, we suggest creating a new user, called “Paradime” and create the access token attached to this user.
Log in to your GitLab account
  1. Go to your user profile > Preferences > Access Tokens (or navigate to https://gitlab.com/-/profile/personal_access_tokens)
  2. Enter a name for your token (e.g., “API Comment Access”)
  3. Select the appropriate scopes:
    • api (for general API access)
    • Specifically for comments, you’ll need at least api scope, which includes the ability to write comments

Add the API key and Credential in the GitLab variables

Finally you need to add the API key and Credentials generated in the previous step in GitLab CI/CD settings (not in the .gitlab-ci.yml file directly). Set the corresponding values for the following variable names:
  • PARADIME_WORKSPACE_UID
  • PARADIME_API_SECRET
  • PARADIME_API_ENDPOINT
  • GITLAB_TOKEN