-
Notifications
You must be signed in to change notification settings - Fork 74
Fix health check #428
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Fix health check #428
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. 1 Skipped Deployment
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR refactors the health check system to separately monitor both L2 client and builder client health, with different health status responses based on which component is failing and the current execution mode.
- Added L2 client health monitoring with separate status reporting (ServiceUnavailable vs PartialContent)
- Modified execution mode behavior: disabled/dry-run modes now only check L2 client health
- Added comprehensive test coverage for the new L2 client failure scenarios
Reviewed Changes
Copilot reviewed 3 out of 4 changed files in this pull request and generated 6 comments.
| File | Description |
|---|---|
| crates/rollup-boost/src/server.rs | Passes l2_client to HealthHandle constructor |
| crates/rollup-boost/src/health.rs | Implements dual health checking for L2 and builder clients with distinct failure modes and adds corresponding tests |
| crates/rollup-boost/Cargo.toml | Adds serial_test dependency for test serialization |
| Cargo.lock | Updates lock file with serial_test and its transitive dependencies |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| tokio-util = { version = "0.7.13" } | ||
|
|
||
| [dev-dependencies] | ||
| serial_test = "*" |
Copilot
AI
Oct 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Using '*' for dependency versions is not recommended. Specify an explicit version to ensure reproducible builds and avoid unexpected breaking changes.
| serial_test = "*" | |
| serial_test = "2.0.0" |
| #[tokio::test] | ||
| async fn tick_advances_after_sleep() { | ||
| let mut ts = MonotonicTimestamp::new(); | ||
| let mut ts: MonotonicTimestamp = MonotonicTimestamp::new(); |
Copilot
AI
Oct 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The explicit type annotation : MonotonicTimestamp is redundant since the type can be inferred from MonotonicTimestamp::new(). Remove it for cleaner code.
| let mut ts: MonotonicTimestamp = MonotonicTimestamp::new(); | |
| let mut ts = MonotonicTimestamp::new(); |
| if t.saturating_sub(block.header.timestamp) | ||
| .gt(&self.max_unsafe_interval) | ||
| { | ||
| warn!(target: "rollup_boost::health", curr_unix = %t, unsafe_unix = %block.header.timestamp, "Builder client - unsafe block timestamp is too old updating health status"); |
Copilot
AI
Oct 30, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing comma after 'too old'. The message should read 'too old, updating health status' for proper grammar.
| warn!(target: "rollup_boost::health", curr_unix = %t, unsafe_unix = %block.header.timestamp, "Builder client - unsafe block timestamp is too old updating health status"); | |
| warn!(target: "rollup_boost::health", curr_unix = %t, unsafe_unix = %block.header.timestamp, "Builder client - unsafe block timestamp is too old, updating health status"); |
The health check did not previously check the l2 client health. If the l2 client was unhealthy but the builder was healthy, it would set the service status to Healthy.
It checks the L2 client health first. If execution mode is enabled, it will then check the builder client health