Back to Blog

Configuring the Azure Databricks Copy Activity in Fabric Pipelines - Settings That Matter

November 30, 2026•9 min read•Michael Ridland

Last month I wrote about when the Azure Databricks connector in Fabric makes sense at all. This post is the follow-up for the people who've decided it does and now have to actually configure the thing. Specifically, the Copy activity in a Fabric Data Factory pipeline, with Azure Databricks on one side of it.

The reason this matters for Australian organisations is pretty simple. Lots of mid-sized and large businesses here have a Databricks estate built by a data engineering team, and a Fabric tenant that arrived through the Microsoft licensing conversation. Data needs to cross between them. Sometimes it's curated tables in Unity Catalog that need to land in a Fabric warehouse for Power BI. Sometimes it's the other way, with Fabric-ingested data that needs to get into Databricks for a machine learning workload. The Copy activity is one way to move it, and it has some behaviours that aren't obvious until you're looking at a failed run or an unexpected cluster bill.

Microsoft's reference is Configure Azure Databricks in a Copy activity. Read it alongside this.

The thing to understand first - Databricks does the work

With most connectors, the Copy activity reads data over a database protocol and streams it to the destination. Databricks is different. When you copy data out of or into Databricks, a Databricks cluster runs the actual read or write, exporting to or importing from cloud storage. The Fabric side then picks the data up from (or drops it into) that storage.

That has three consequences people miss:

  1. You pay for Databricks compute during the copy. On top of your Fabric capacity. If the connection points at an all-purpose cluster that's sized for data science work, every pipeline run spins that up or uses it.
  2. Startup time is part of your pipeline time. A cold cluster can take several minutes to start. For a pipeline that copies a small table, the cluster startup can be longer than the copy.
  3. Storage is in the middle. Depending on the destination format and location, you'll either get a direct copy or you'll need to configure staging through an Azure storage account.

Once you understand that a Databricks cluster is doing the heavy lifting, most of the configuration choices make more sense.

Setting up the connection

The connection needs your Databricks workspace URL and an authentication method. You also tell it which cluster to use.

On authentication, use a service principal or managed identity if your setup supports it, and avoid personal access tokens for anything in production. We've cleaned up more than one client environment where the nightly pipeline broke because the engineer whose token it was left the organisation and their account got disabled. Tokens tied to people are a time bomb. If you have to use a token initially, at least issue it from a service principal.

On the cluster, my strong preference is a dedicated job-style cluster or a small cluster configured specifically for pipeline copies, with a sensible auto-termination setting. Don't point Fabric at the shared all-purpose cluster the data scientists use. You'll either fight over capacity or pay for a much bigger cluster than a copy needs. Check with your Databricks admin what cluster policies apply, because Unity Catalog workspaces often restrict which access modes can read governed tables.

Source tab - reading from Databricks

When Databricks is the source, you choose whether you're reading a table or running a query.

For a table, you pick the catalog, schema (database) and table. With Unity Catalog that's the familiar three-level name, catalog.schema.table. For a query, you write Spark SQL, which runs on the cluster.

The advanced options include date and timestamp format settings. These look boring and they are boring, right up until timestamps arrive in your Fabric warehouse shifted by ten or eleven hours. Australian data has the extra joy of daylight saving in some states and not others. Our habit is to keep everything in UTC through the pipeline and only convert to local time at the semantic model or report layer. Set the format explicitly rather than trusting defaults.

As with any source, write a query rather than copying whole tables when you can. Select the columns you need, filter on a change column if one exists, and let the Databricks cluster do the filtering before anything gets exported. Moving less data through storage is the cheapest optimisation available.

Destination tab - writing to Databricks

Writing into Databricks is the less common direction for us, but it comes up. You pick the target table and get a pre-copy script option, which is typically used to truncate or delete a partition before loading.

The important bit here is how the data gets in. Databricks loads from cloud storage. If your source data is already in a supported format in Azure Data Lake Storage Gen2 or Blob Storage, a direct copy may be possible. If not, the Copy activity needs staging, meaning it writes the data to an interim storage location first and then Databricks loads it from there.

Staging - configure it once, properly

Staging is set on the Settings tab. You give it a storage connection and a path. The Copy activity writes interim files there, Databricks reads them, and the files get cleaned up afterwards.

A few things we've learned:

  • Use a dedicated container. Don't stage into the same container that holds real data. When something fails halfway, you want leftover files somewhere obvious and safe to delete.
  • Sort out the permissions on both sides. The Fabric connection needs to write to the staging storage, and the Databricks cluster needs to read from it (or write to it, when Databricks is the source). Most staging failures we see are a permission missing on one side. The error messages don't always tell you which side.
  • Put the storage in the same region. Australia East for everything, ideally. Cross-region staging adds latency and egress charges, and occasionally a data residency question you don't want to explain to a regulator.
  • Add a lifecycle policy. Belt and braces. If cleanup ever fails, a lifecycle rule that deletes files older than a few days keeps the container from silently growing.

Mapping and type handling

The Mapping tab works like any other Copy activity. Import schemas, check the mappings, and be explicit. Databricks types like DECIMAL(38,18), nested STRUCT or ARRAY columns and TIMESTAMP_NTZ can trip up destinations that don't have an equivalent.

For complex types, my advice is to flatten them in a Databricks view or the source query before the copy. Trying to push nested structures through a Copy activity into a Fabric warehouse is an exercise in frustration. A view also gives the Databricks team a clear contract: "this is the shape Fabric consumes", which they can version and test.

Watching the costs

This is where I'd spend a few minutes before going live.

Every pipeline run that touches Databricks costs Databricks compute, Fabric capacity units for the pipeline, and a little bit of storage I/O. For one nightly load that's nothing. For a pipeline that runs every 15 minutes across 30 tables, each starting its own cluster session, it adds up fast. We had a client whose Databricks bill jumped noticeably after a "small" Fabric integration went live, because each table was a separate Copy activity in a ForEach loop and the cluster kept cycling.

Some ways to keep it sane:

  • Batch tables into fewer runs, so the cluster starts once and does several copies.
  • Set auto-termination short enough to avoid idle charges but long enough that a sequence of copies reuses a warm cluster.
  • Question the schedule. Does finance really need data every 15 minutes, or did someone just pick a number?
  • Ask whether you need a copy at all. If the data is already in Delta format in ADLS, a OneLake shortcut might let Fabric read it in place with no copy and no cluster. That's often the better answer, and I'd check it first.

That last point is worth repeating. The Copy activity is one tool. Shortcuts and mirroring are others. If you find yourself copying the same Delta tables from Databricks into Fabric every night just so Power BI can read them, step back and check whether a shortcut does the job.

What's still rough

Honest assessment from client work:

  • Debugging spans two products. When a copy fails, the cause might be in the Fabric pipeline, the Databricks cluster logs or storage permissions. You need someone who can read all three. That's a skills question as much as a technical one.
  • Unity Catalog permission errors can be opaque. A table that the service principal can't see sometimes looks like a table that doesn't exist. Check grants before you start debugging anything else.
  • Cluster startup makes small copies feel slow. For small, frequent loads, it's sometimes cheaper and faster to use a SQL warehouse-based approach or a shortcut instead.
  • Two teams, two sets of opinions. The Databricks team and the Fabric/Power BI team often report to different people. Agree up front who owns the cluster, the views and the pipeline, or you'll be playing ticket ping-pong when something breaks at 6am.

Where we'd start

If you're setting this up now, here's the short order of operations we use:

  1. Decide whether a copy is needed at all, or whether a shortcut covers it.
  2. Create a service principal, grant it the minimum Unity Catalog permissions, and build the connection with it.
  3. Set up a small dedicated cluster with auto-termination.
  4. Configure staging with a dedicated container in the same region, and test permissions both ways.
  5. Build one table end to end with explicit mappings and UTC timestamps.
  6. Look at the first week of Databricks and Fabric costs before rolling out to more tables.

Mixed Databricks and Fabric environments are one of the most common things we work on. If you want a hand designing the integration, our Microsoft Data Factory consultants build these pipelines regularly, and our Microsoft Fabric consultants can help with the bigger platform question of what should live where. If the end goal is better reporting and analytics, have a look at how we approach AI for business intelligence too.

The connector works. It just rewards people who understand that there's a Spark cluster quietly doing the job in the background, and plan for it.