Skip to content

[air] Add rank-partitioned container support - #6841

Merged
vinchenzo-db merged 14 commits into
mainfrom
air-containers
Oct 1, 2026
Merged

vinchenzo-db merged 14 commits into
mainfrom
air-containers

Conversation

@vinchenzo-db

@vinchenzo-db vinchenzo-db commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Changes

Add multi-container support in CLI yaml. Now CLI will support both singleton tasks, as well as multi-container/image multi-node tasks. Included an example yaml.

Top level env vars are merged into each container. Each container now has it's own definition of:

  1. name
  2. command_path
  3. ranks this container is assigned to
  4. docker_image (though docker images are no longer supported in favor of UC images)
  5. unity_catalog_image_path
  6. environment variables

I've also added example docker builds for the RL usecase I'm covering, in case another user wants to reproduce it.

KNOWN GAP:
Jobs page will not show container level workloads because Jobs UI reads from task level command_path to find the training workload, and has no concept of containers yet.

Why

For primarily RL usecase, users may want to combine inference workload with training workload. We want to have a way to support this multi-node multi-image usecase

Tests

Unit tests

E2E test:
Replace placeholder images in example with my own DAR images.

# v.chen at ip-10-90-21-154 in ~/databricks-cli-wt-containers (git:air-containers) [20:40:39]
$ sed \
  -e 's|your_catalog.your_schema.vllm_trl:0.24.0|main.vinchenzo.vllm-trl-e2e:0.24.0|' \
  -e 's|your_catalog.your_schema.trl_vllm:0.24.0|main.vinchenzo.trl-vllm-e2e:0.24.0|' \
  cmd/air/examples/multi-image-example.yaml > /tmp/multi-image-example.yaml

Dry run:

# v.chen at ip-10-90-21-154 in ~/databricks-cli-wt-containers (git:air-containers) [20:40:47]
$ ./databricks air run -f /tmp/multi-image-example.yaml \
  --dry-run -p dbc-04ac0685-8857
Dry run: configuration for "qwen05b_grpo_dar_e2e_5epochs" is valid; not submitting.

Launch run:

# v.chen at ip-10-90-21-154 in ~/databricks-cli-wt-containers (git:air-containers) [20:40:54]
$ ./databricks air run -f /tmp/multi-image-example.yaml -p dbc-04ac0685-8857 
+--------------------------------------------------------------------+
| WARNING: EXPERIMENTAL FEATURE                                      |
|                                                                    |
| This feature is experimental and may change without notice,        |
| including changes that could break existing workflows.             |
| Use it only if you accept these risks.                             |
+--------------------------------------------------------------------+
Submitting experiment: qwen05b_grpo_dar_e2e_5epochs
Submitted workload with Job Run ID: 286153620017076
View job run at: https://dbc-04ac0685-8857.staging.cloud.databricks.com/jobs/runs/286153620017076

Tip: use --watch when submitting a run to stream logs to your terminal.
Stream logs after submission using:
  databricks air logs 286153620017076 -p dbc-04ac0685-8857

Job run: https://dbc-04ac0685-8857.staging.cloud.databricks.com/jobs/runs/286153620017076

Sneak peak at exciting logs:
image

@github-actions github-actions Bot added the AIR Databricks AI Runtime CLI label Sep 24, 2026
@eng-dev-ecosystem-bot

eng-dev-ecosystem-bot commented Sep 24, 2026 •

Copy link
Copy Markdown
Collaborator

Integration test report

Commit: 61f4615

Run: 36928730878

Env ✅​pass 🙈​skip Time
✅​ aws linux 276 17 5:22
✅​ aws windows 278 15 3:05
✅​ azure linux 275 17 5:22
✅​ azure windows 277 15 3:01
✅​ gcp linux 276 17 5:43
✅​ gcp windows 278 15 3:02
Top 6 slowest tests (at least 2 minutes):
duration env testname
4:03 gcp linux TestAccept
3:48 aws linux TestAccept
3:45 azure linux TestAccept
3:03 aws windows TestAccept
2:59 gcp windows TestAccept
2:46 azure windows TestAccept

@vinchenzo-db
vinchenzo-db marked this pull request as ready for review September 30, 2026 21:08
@vinchenzo-db
vinchenzo-db requested review from a team as code owners September 30, 2026 21:08
Comment thread .nextchanges/air/6841.md Outdated

@ben-hansen-db ben-hansen-db left a comment

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.

A couple of comments to address. Nothing blocking

Comment thread cmd/air/runupload.go
items = append(items, uploadItem{secretEnvVarsName, data})
}

for _, container := range cfg.Containers {

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.

The backend looks for hyperparameters.yaml beside each container’s command, but this code uploads it only to the parent launch directory.

We'll need to upload the shared hyperparameters beside every container command.

Comment thread cmd/air/runconfig.go
if err := validateCommand(*container.Command); err != nil {
return fmt.Errorf("%s.command: %w", prefix, err)
}
if len(container.Ranks) == 0 {

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.

Do we have validation for "containers requires at least two entries"?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

no need, with one container it will fan out across all nodes. The reason is because in the future, it makes sense to keep the container format and remove the "singleton" format.

@vinchenzo-db
vinchenzo-db enabled auto-merge October 1, 2026 21:28
@vinchenzo-db
vinchenzo-db added this pull request to the merge queue Oct 1, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Oct 1, 2026
@vinchenzo-db
vinchenzo-db added this pull request to the merge queue Oct 1, 2026
Merged via the queue into main with commit 419b912 Oct 1, 2026
31 checks passed
@vinchenzo-db
vinchenzo-db deleted the air-containers branch October 1, 2026 23:39
deco-sdk-tagging Bot added a commit that referenced this pull request Oct 7, 2026
## Release v1.20.0

### Notable Changes

 * Remove the Terraform deployment engine. `bundle.engine: terraform` and `DATABRICKS_BUNDLE_ENGINE=terraform` now error, and a failed migration of existing Terraform state is reported as an error instead of falling back to Terraform. To keep deploying with Terraform, use Databricks CLI v1.19.x. ([#6888](#6888), [#6889](#6889))

### CLI

 * `databricks aitools install` now supports Kiro, installing Databricks agent skills into its skills directory. ([#6908](#6908))
 * Fixed `databricks api` corrupting integers larger than 2^53 (such as job and pipeline ids) — request bodies and responses now preserve them exactly. ([#6884](#6884))
 * Added `--auth-mode` and `--set <plugin>.<resourceKey>.authMode=obo|sp|both` to `databricks apps init` so AppKit resources can be accessed on behalf of the user, by the service principal, or both. The default stays service principal. ([#6886](#6886))
 * `databricks apps init` now requires a value for every field a service principal resource binding references, prompting for missing values in an interactive terminal and otherwise failing with the `--set` key to use, instead of creating a project with unset variables. ([#6903](#6903))
 * Add `databricks apps init --package-manager <npm|pnpm>` to select the package manager for Node.js templates. Infer the default quietly from template lockfiles and AppKit version, check prerequisites before creating files, and preserve template formatting and pnpm version pins. ([#6902](#6902))
 * Select npm or pnpm from `packageManager` declarations and lockfiles for `apps validate` and project validation during `apps deploy`. ([#6892](#6892))
 * Fix `auth docker host` reporting the credential helper as configured when its executable is missing from `PATH`. ([#6880](#6880))
 * Warn when the CLI binary was built more than 6 months ago and recommend updating. ([#6898](#6898))

### AI Runtime

 * Add an experimental rank-partitioned container images to AI Runtime jobs. ([#6841](#6841))
 * Support snapshot fields directly under `code_source` without requiring `type` or a nested `snapshot` block. ([#6927](#6927))
 * Map AIR priority and Unity Catalog image fields when converting run configurations to bundles. ([#6905](#6905))
 * Add workspace backend validation to `air run --dry-run`. ([#6934](#6934))

### Bundles

 * Warn that `bundle.terraform` is deprecated and has no effect since the Terraform deployment engine was removed. ([#6940](#6940))
 * Direct engine now detects and applies an explicitly configured zero-value boolean or float (e.g. `gcp_attributes.use_preemptible_executors: false`, `azure_attributes.spot_bid_max_price: 0`) added to a resource first deployed without the field, matching the existing handling of an explicit integer zero. ([#6882](#6882))
 * Fix `bundle deployment migrate` failing with "no such file or directory" when the Terraform state has no resources or the configuration no longer declares any of them. ([#6958](#6958))
 * `bundle run` and `pipelines run` now send the per-update `development` parameter for pipelines in development mode targets. Setting `development` on a pipeline is deprecated and now emits a warning; use `mode: development` instead. ([#6863](#6863))
 * Remove the hidden `bundle debug terraform` command. ([#6933](#6933))
 * Add support for `run_as.group_name` at the bundle and target levels for jobs and pipelines. ([#6676](#6676))
 * Fix recreating a secret scope that was deleted outside of the bundle with the direct deployment engine. ([#6970](#6970))
 * Accept title-case booleans (`True`/`False`, as rendered by Azure Pipelines) for boolean variables, and accept the same boolean strings (`yes`/`no`, `on`/`off`, ...) in Python bundles as in YAML. ([#6942](#6942))

### Dependency Updates

 * Bump `github.com/databricks/databricks-sdk-go` from v0.182.0 to v0.185.0. ([#6928](#6928))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AIR Databricks AI Runtime CLI

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants