Skip to content

fix(perf): precompile health regexes, share HTTP client, cut hot-path clones - #676

Open
iamquang95 wants to merge 1 commit into
mainfrom
feat/fix-645
Open

fix(perf): precompile health regexes, share HTTP client, cut hot-path clones#676
iamquang95 wants to merge 1 commit into
mainfrom
feat/fix-645

Conversation

@iamquang95

Copy link
Copy Markdown
Collaborator

Fix #645

  • app/health — a regex was compiled per metric series per check tick; now compiled once into a static.
  • cli/test — a new reqwest::Client per probe meant each RTT measurement included its own TCP/TLS handshake; now one shared client.
  • coreDutyType::Display round-tripped through serde_json on every call; now a direct as_str().
  • parsigexdo_recv deep-cloned a ParSignedData (a whole beacon block for proposals) per entry per message; now borrowed.
  • p2p — swapped an allocating .is_empty() check for the existing has_connection.

Behaviour change: request_rtt and relay_ping_test had no request timeout; they now use the 10s one beacon.rs/mev.rs already applied. Sharing a client also means concurrent probes to one host multiplex over a single HTTP/2 connection — only visible in beacon_ping_load_test.

@iamquang95 iamquang95 changed the title perf: precompile health regexes, share HTTP client, cut hot-path clones fix(perf): precompile health regexes, share HTTP client, cut hot-path clones Aug 28, 2026
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.

Minor performance improvements

1 participant