CodeRabbit GitHub builts AI code review agent with Cloud Run

By securely and effectively running untrusted code, CodeRabbit, a quickly expanding AI code review tool, is using Google Cloud Run to reduce code review time and errors by half

CodeRabbit required an execution environment that was scalable, affordable, and secure enough to examine and run their clients’ code in order to safely execute untrusted code

Cloud Run services serve as the foundation for CodeRabbit. First, a lightweight Cloud Run service handles incoming webhook events (from GitHub, GitLab, etc.) and verifies subscriptions and billing

Serving as a queue separates webhook handling from code execution. CodeRabbit now handles pull request surges without overloading

Alternative Cloud Run services pull tasks from Cloud Tasks. Every work requires coding evaluation. This service scales according to CPU usage with a  3600-second request timeout and 8 requests per instance

CodeRabbit employs Cloud Run's  second-generation Linux  cgroup-capable microVM. CodeRabbit uses cgroups to restrict jailed processes and Jailkit to isolate processes within Cloud Run instances

An excellent illustration of how to create a safe, scalable, and reasonably priced platform for doing  AI-powered code analysis is CodeRabbit’s usage of Google Cloud Run