Skip to content

Compile cmd/air regexps on first use - #7444

Merged
pietern merged 1 commit into
mainfrom
init-time-air
Nov 11, 2026
Merged

pietern merged 1 commit into
mainfrom
init-time-air

Conversation

@pietern

@pietern pietern commented Nov 10, 2026 •

Copy link
Copy Markdown
Contributor

Wraps the 32 package-level regexps in cmd/air in sync.OnceValue. They took 1.2 ms of init time on every CLI invocation (Linux CI), but only air subcommands use them.

Tests: existing tests run all 12 initializers.

This pull request and its description were written by Isaac.

The 32 package-level regexps in cmd/air were compiled on every CLI
invocation (~1 ms of init time on CI), even though they are only used
by air subcommands. Wrap them in sync.OnceValue.

Co-authored-by: Isaac <no-reply@databricks.com>
@pietern
pietern added this pull request to stack #7449 November 10, 2026 15:46
@github-actions github-actions Bot added the AIR Databricks AI Runtime CLI label Nov 10, 2026
@eng-dev-ecosystem-bot

Copy link
Copy Markdown
Collaborator

✅ Integration test report

Commit: 58b177a

Run: 42848049850

Env ✅​pass 🙈​skip Time
✅​ aws linux-2core-8gb 271 15 8:43
✅​ aws-windows-latest-4core-16gb 273 13 5:22
✅​ azure linux-2core-8gb 270 15 6:15
✅​ azure-windows-latest-4core-16gb 272 13 5:05
✅​ gcp linux-2core-8gb 271 15 8:01
✅​ gcp-windows-latest-4core-16gb 273 13 5:36
Top 4 slowest tests (at least 2 minutes):
duration env testname
3:08 aws-windows-latest-4core-16gb TestAccept
3:02 azure-windows-latest-4core-16gb TestAccept
2:56 gcp-windows-latest-4core-16gb TestAccept
2:24 aws linux-2core-8gb TestTelemetryEndpoint

@pietern
pietern marked this pull request as ready for review November 11, 2026 07:50
@pietern
pietern requested review from a team as code owners November 11, 2026 07:50
@pietern
pietern requested a review from rugpanov November 11, 2026 07:50
@pietern
pietern added this pull request to the merge queue Nov 11, 2026
Merged via the queue into main with commit d8e4739 Nov 11, 2026
28 checks passed
@pietern
pietern deleted the init-time-air branch November 11, 2026 10:21
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