Skip to main content

The data pipeline

A pipeline is a workflow: a graph of jobs that turns raw data from an external system into a result that a cube can serve. Each job does one kind of work and hands its result to the next job.

This page explains what each kind of job is responsible for and how jobs combine. To build a workflow, use the Pipelines pages.

What each job hands on​

JobReadsHands onRead more
Extract jobAn HTTP API, a database, or cloud storageThe raw responses, as CSV, JSON, NDJSON, or ParquetExtractors
Load jobThe responses of one or more Extract jobsOne typed table with a row keyLoaders
Transform jobLoaded tables, and the results of other Transform or Charge jobsOne clean table with a clear meaning per rowTransformers
Charge jobOne transformed tableA charged result with dimensions and measuresChargers

The rules that matter​

Each kind of job has one responsibility​

  • An Extract job only fetches. It does not interpret or clean the data. Requests can pass values to each other, repeat over a list of values such as regions or accounts, and follow pages until no pages remain. Database requests always produce CSV. To reach a protected source, see Connections and authentication.
  • A Load job maps each source field to one typed column of one table. This is the first point where the data has a fixed schema.
  • A Transform job is where you join, filter, and deduplicate with DuckDB SQL, until the table matches the question you want to answer.
  • A Charge job turns that table into dimensions and measures. Rates, pricing, and final allocation belong here, as charging rules.

If you are not sure which job should own a calculation, see Choosing where calculation logic belongs.

Dependencies decide the order​

A workflow is a graph, not a line. A job runs only after every job it depends on has finished. A workflow can therefore branch:

  • Several Extract jobs feed one Load job, so several sources end up in the same table.
  • A Charge job waits for several Transform jobs.

A Charge job with a cube ends the pipeline​

A Charge job that names a cube publishes its result to that cube. From there, reports depend only on the cube, and the cube takes its grain and source fields from the Charge jobs that feed it. See Logical cubes and Linking producers.

Intermediate Charge jobs

A Charge job without a cube is an intermediate step. Its result stays inside the workflow and is not reportable. A later Transform job reads it through {{charged}}, and a later Charge job publishes the final result.

Data arrives when a run executes​

Scheduled and on-demand ingestion

A workflow runs on a schedule or on demand. There is no streaming and no real-time ingestion. See Running and scheduling.

Inputs make one workflow serve many periods​

A workflow takes typed inputs, such as a date range or an account. Each run supplies the values, so one Charge job can process many date windows without a rebuild. Credentials are stored as secrets: the workflow holds only the name of the secret. See Inputs and parameters and Secrets.

You can check a job before it runs in production​

Every job editor has Preview, which runs the job on the draft and shows the result. See Preview workbench.

Reuse job instructions

Each job owns its instructions. To maintain the same instructions in several jobs, use Save as template. See Share instructions as a template.

Example: a workflow with two sources​

Two Extract jobs feed one Load job. The Charge job waits for both Transform jobs and then publishes to the cube.