Skip to content

feat: parallel deployment and better readiness check#26

Merged
roderik merged 4 commits intomainfrom
roderik/cus-926-try-out-parallel-deployment-for-besu-validators-again-to
Sep 17, 2025
Merged

feat: parallel deployment and better readiness check#26
roderik merged 4 commits intomainfrom
roderik/cus-926-try-out-parallel-deployment-for-besu-validators-again-to

Conversation

@roderik
Copy link
Copy Markdown
Member

@roderik roderik commented Sep 17, 2025

Summary by Sourcery

Enable parallel rolling updates of validator StatefulSets and tighten readiness checks by updating probe thresholds and frequency

New Features:

  • Enable parallel deployment of validator pods by setting podManagementPolicy to Parallel

Enhancements:

  • Adjust readiness probe to require at least one peer and reduce probe period to 5 seconds

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Summary of Changes

Hello @roderik, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed!

This pull request introduces a significant improvement to the deployment strategy and health checking of network nodes within a Kubernetes environment. By enabling parallel pod management for validator StatefulSets, it aims to accelerate deployment and scaling. Concurrently, it refines the readiness probe configuration to ensure nodes are genuinely operational by requiring at least one peer connection and increasing the frequency of health checks, leading to more robust and responsive deployments.

Highlights

  • Parallel Deployment for Validators: The StatefulSet for validator nodes has been configured to use podManagementPolicy: Parallel. This change allows all pods in the StatefulSet to be created or updated in parallel, rather than sequentially, which can significantly speed up deployment and scaling operations.
  • Enhanced Readiness Check Logic: The readiness probe's HTTP GET path has been updated to require a minimum of one peer (minPeers=1) for a node to be considered ready. Previously, it allowed zero peers, which could lead to nodes being marked ready before fully synchronizing or connecting to the network.
  • Increased Readiness Probe Frequency: The frequency of the readiness probe checks has been doubled, with periodSeconds reduced from 10 to 5. This ensures that the system detects the readiness status of pods more quickly, allowing for faster reaction to changes in pod health.
Using Gemini Code Assist

The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips.

Invoking Gemini

You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.

Feature Command Description
Code Review /gemini review Performs a code review for the current pull request in its current state.
Pull Request Summary /gemini summary Provides a summary of the current pull request in its current state.
Comment @gemini-code-assist Responds in comments when explicitly tagged, both in pull request comments and review comments.
Help /gemini help Displays a list of available commands.

Customization

To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here.

Limitations & Feedback

Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here.

You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension.

Footnotes

  1. Review the Privacy Notices, Generative AI Prohibited Use Policy, Terms of Service, and learn how to configure Gemini Code Assist in GitHub here. Gemini can make mistakes, so double check it and use code with caution.

@github-actions github-actions Bot added the qa:running QA workflow is currently running label Sep 17, 2025
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Sep 17, 2025

To view in Slack, search for: 1758142220.429439

Copy link
Copy Markdown
Contributor

@sourcery-ai sourcery-ai Bot left a comment

Choose a reason for hiding this comment

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

Hey there - I've reviewed your changes - here's some feedback:

  • Consider exposing the readiness probe minPeers and periodSeconds values as chart parameters so users can tune them per environment rather than hardcoding defaults.
  • Verify that setting podManagementPolicy to Parallel for the validator StatefulSet does not introduce race conditions or dependency issues during startup, and document any required initialization ordering.
  • Double-check that requiring minPeers=1 in readiness checks won't prevent pods from becoming ready in low-peer or single-node setups (e.g., dev/test clusters) where no additional peers are available.
Prompt for AI Agents
Please address the comments from this code review:

## Overall Comments
- Consider exposing the readiness probe minPeers and periodSeconds values as chart parameters so users can tune them per environment rather than hardcoding defaults.
- Verify that setting podManagementPolicy to Parallel for the validator StatefulSet does not introduce race conditions or dependency issues during startup, and document any required initialization ordering.
- Double-check that requiring minPeers=1 in readiness checks won't prevent pods from becoming ready in low-peer or single-node setups (e.g., dev/test clusters) where no additional peers are available.

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.

@github-actions github-actions Bot added the status:ready-for-review Pull request is ready for review label Sep 17, 2025
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces parallel deployment for StatefulSets and improves the readiness checks for network nodes. The podManagementPolicy is set to Parallel for validator nodes, which will speed up deployments and scaling. The readiness probe is made more robust by requiring at least one peer (minPeers=1) and more responsive by reducing the check interval to 5 seconds. These changes are well-aligned with best practices for running distributed applications like blockchain nodes on Kubernetes. The documentation and default values have been updated accordingly. The changes are sound and I have not identified any issues.

@github-actions github-actions Bot added qa:success QA workflow passed successfully and removed qa:running QA workflow is currently running labels Sep 17, 2025
@github-actions github-actions Bot added qa:running QA workflow is currently running qa:success QA workflow passed successfully feat New feature and removed qa:success QA workflow passed successfully qa:running QA workflow is currently running labels Sep 17, 2025
@roderik roderik merged commit f2da093 into main Sep 17, 2025
7 checks passed
@roderik roderik deleted the roderik/cus-926-try-out-parallel-deployment-for-besu-validators-again-to branch September 17, 2025 21:09
@github-actions github-actions Bot added status:merged Pull request has been merged and removed status:ready-for-review Pull request is ready for review labels Sep 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feat New feature qa:success QA workflow passed successfully status:merged Pull request has been merged

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant