Rebuilding CI for AI-Scale Commit Volume — Gautam Korlam, Sonar
Talk notes · AI Engineer ·A close reading of the source at ai.engineer (also youtube.com): what it says, what it means for someone who builds with AI, and which claims are the publisher’s own.
Software FactoryCoding AgentsGitHub
Problem
Gautam Korlam (co-founder and CTO of Gitar, now a principal engineer at Sonar after Sonar acquired Gitar; before that almost a decade on build and merge infrastructure at Uber) argues that the pipeline around a coding agent was built for human speed, and agents break it (0:00). At Uber, with one giant monorepo and thousands of changes a day, serial merging would have taken up to 20 days to get everything green, while merging everything straight to main left main red all the time (1:01). The fix was SubmitQueue, which tests likely combinations of changes in parallel, ejects a change predicted to break, and lets only passing combinations onto trunk (2:02).
His point: that queue, plus CI and review, is a centralized bottleneck sized for people who produce a few changes an hour. Agents and background workflows now produce several PRs a day each and do not wait their turn, so CI and review queues pile up (3:03). Examples from Gitar, reported and not independent: its own commit rate rose about 10x in three years with the same small team, and the PRs Gitar reviews grew roughly 25% month over month (3:03, 4:04). He also points to GitHub's published PR growth as corroboration, with no figures given.
Approach
He follows the constraints along the path from change to merge:
- Isolated green is not combined green. PRs can each pass CI and still break trunk when merged together, which is the reason for a merge queue (4:04, 5:05).
- Build and test. Rebuilds when compilation breaks, and flaky tests that cannot be reproduced locally, mean retries that can take hours (5:05).
- Review becomes the queue. Teams rubber-stamp because they cannot keep up, and CI logs expire, leaving only an approval stamp with no record of what was checked (6:06).
- Repair loops. On Gitar's platform, at least 13% of PRs had one or more recorded CI failures, each a round trip to read logs, find the cause, fix and push (7:08).
- Make CI fast and shift expensive checks to run after merge or earlier on the agent's machine ("move left").
- Parallelize, shard and cache. His team's Rust-based CI went from about 10 minutes to under a minute for incremental runs once the cache is warm (10:11, 11:11).
- Give review quick passes first; humans review what the AI pass leaves. He says at Uber most of the p90 time to production was review, and most teams still spend more time reviewing than building (11:11, 12:12).
- Auto-approve low-risk changes by policy, such as docs, non-breaking dependency bumps, security patches and internal tooling, with plain-English custom rules. Sensitive areas such as payments or auth need a human approver, and the agent that made a change must not approve it (13:13, 14:14).
Lessons learned
- Korlam: policies have to be enforced beyond CI because code that compiles may still break rules such as HIPAA. His Uber story: the company lost its license to operate in London after a feature-flag change let drivers on without proper checks; afterward every change touching London needed a lineage of controls, and the license came back (9:10, 10:11). It is his account of a past event.
- Keep a durable record on the PR, because CI artifacts expire (15:15, 16:16). His examples (16:16, 17:17): which agent made the PR and where it came from; who or what triggered it; the commit CI trusted and a saved test report, not just a status; how each finding was resolved; a named reason for any override; and an approver who is neither the bot nor the person who prompted it.
- A real catch from Gitar's own repo: a shared test database was safe under normal CI but caused cross-contamination when CI was busy; Gitar flagged it on the PR, fixed it and added the engineer as co-author (12:12, 13:13).
- Measure the whole path from proposed change to accepted change, including recovery and accountability, before counting more generated code as more value (17:17, 18:20).
- Disclosure: Gitar is a product he sells; volume and latency numbers are examples from his systems, not general results.
Theme
Group: AI Coding & Software Factories. Korlam is the CI and merge-queue voice. He extends Manish Kapur and Addy Osmani (card), who say verification is the limit, by showing where the queue jams. He agrees with Matt Pocock (card) on layered checks that are fast and cheap, and with Dex Horthy (card) that review cost stays fixed while output costs nothing. The "agent cannot approve its own change" rule fits Kapur's zero-trust framing. He differs from Quinn Slack (card) and Walden Yan (card), who ship tiny, monitored pushes with little process; Korlam wants records and policy, as regulated companies need.