Skip to content

feat(coprocessor): fhevm-listener, health check#314

Merged
rudy-6-4 merged 1 commit intomainfrom
rudy/feat/fhevm-listener-health
Jun 20, 2025
Merged

feat(coprocessor): fhevm-listener, health check#314
rudy-6-4 merged 1 commit intomainfrom
rudy/feat/fhevm-listener-health

Conversation

@rudy-6-4
Copy link
Copy Markdown
Contributor

No description provided.

@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch 6 times, most recently from 7963c21 to c3d6bf6 Compare June 17, 2025 13:25
@rudy-6-4 rudy-6-4 marked this pull request as ready for review June 17, 2025 13:25
@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch 2 times, most recently from 3b337cf to be780de Compare June 17, 2025 13:50
@rudy-6-4 rudy-6-4 requested review from dartdart26 and goshawk-3 June 17, 2025 13:52
Copy link
Copy Markdown
Collaborator

@dartdart26 dartdart26 left a comment

Choose a reason for hiding this comment

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

Looks good overall. I added some comments that, I think, are worth considering.

@rudy-6-4 rudy-6-4 requested a review from Copilot June 17, 2025 14:32

This comment was marked as outdated.

@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch from be780de to bda0953 Compare June 17, 2025 15:02
@rudy-6-4 rudy-6-4 requested a review from dartdart26 June 17, 2025 15:03
@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch 2 times, most recently from fdde187 to d12f3a1 Compare June 17, 2025 15:04
@rudy-6-4 rudy-6-4 requested a review from Copilot June 17, 2025 15:40

This comment was marked as outdated.

@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch from d12f3a1 to 5d0e6ab Compare June 17, 2025 16:22
@rudy-6-4 rudy-6-4 requested a review from Copilot June 17, 2025 16:22

This comment was marked as outdated.

@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch from 5d0e6ab to d9cb582 Compare June 18, 2025 06:53
@rudy-6-4 rudy-6-4 requested a review from Copilot June 18, 2025 06:53

This comment was marked as outdated.

@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch from d9cb582 to 970a1b2 Compare June 18, 2025 08:05
@rudy-6-4 rudy-6-4 requested a review from Copilot June 18, 2025 08:10

This comment was marked as outdated.

@goshawk-3 goshawk-3 self-requested a review June 19, 2025 08:10
@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch from 970a1b2 to e37d56e Compare June 19, 2025 11:23
@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch from e37d56e to f930f81 Compare June 19, 2025 21:27
@rudy-6-4 rudy-6-4 force-pushed the rudy/feat/fhevm-listener-health branch from f930f81 to d25d316 Compare June 20, 2025 08:41
@rudy-6-4 rudy-6-4 requested a review from Copilot June 20, 2025 08:48
Copy link
Copy Markdown

Copilot AI left a 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 introduces a health-check subsystem to the FHEVM listener, exposing liveness and readiness endpoints, and updates integration tests to validate health behavior.

  • Added a new health_check module with HTTP endpoints for /liveness and /healthz.
  • Integrated HealthCheck startup in main and exposed a health_port CLI flag.
  • Extended integration tests to exercise the new health endpoints.

Reviewed Changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
coprocessor/fhevm-engine/fhevm-listener/tests/integration_test.rs Refactored DB URL constant; added test_health for health-check
coprocessor/fhevm-engine/fhevm-listener/src/lib.rs Imported new health_check module
coprocessor/fhevm-engine/fhevm-listener/src/health_check.rs Entire new health-check implementation
coprocessor/fhevm-engine/fhevm-listener/src/cmd/mod.rs Added health_port arg; wired up HealthCheck in CLI handling
coprocessor/fhevm-engine/fhevm-listener/Cargo.toml Added axum, serde_json, tokio-util, tower-http, reqwest
coprocessor/fhevm-engine/.cargo/deny.toml Whitelisted CDLA-Permissive-2.0 license
Comments suppressed due to low confidence (2)

coprocessor/fhevm-engine/fhevm-listener/src/health_check.rs:60

  • [nitpick] The status message Only connected is ambiguous; a clearer message like Connected or Health checks passed would improve readability.
        self.message = "Only connected".to_string();

coprocessor/fhevm-engine/fhevm-listener/tests/integration_test.rs:252

  • The new health-check test covers only the happy path and node shutdown; consider adding tests for database-connectivity failure and blockchain-connectivity failure to exercise unhealthy branches.
#[tokio::test]

@rudy-6-4 rudy-6-4 merged commit f43a210 into main Jun 20, 2025
110 checks passed
@rudy-6-4 rudy-6-4 deleted the rudy/feat/fhevm-listener-health branch June 20, 2025 13:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants