Skip to content

Add idletimeout for http connection on evm endpoint#89

Merged
RogerKSI merged 3 commits into
mainfrom
reduce-idle-timeout
May 19, 2026
Merged

Add idletimeout for http connection on evm endpoint#89
RogerKSI merged 3 commits into
mainfrom
reduce-idle-timeout

Conversation

@RogerKSI
Copy link
Copy Markdown
Member

Fixed: #XXXX

Implementation details

Please ensure the following requirements are met before submitting a pull request:

  • The pull request is targeted against the correct target branch
  • The pull request is linked to an issue with appropriate discussion and an accepted design OR is linked to a spec that describes the work.
  • The pull request includes a description of the implementation/work done in detail.
  • The pull request includes any and all appropriate unit/integration tests
  • You have added a relevant changelog entry to CHANGELOG_UNRELEASED.md
  • You have re-reviewed the files affected by the pull request (e.g. using the Files changed tab in the Github PR explorer)

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

Adds a custom dial path for EVM RPC endpoints to proactively close idle HTTP keep-alive connections (to reduce stale-connection resets commonly caused by load balancers).

Changes:

  • Introduce dialEVMEndpoint() to use a custom http.Transport with a shorter IdleConnTimeout for HTTP/HTTPS endpoints.
  • Switch Connect() to use dialEVMEndpoint(ctx, endpoint) instead of ethclient.Dial(endpoint).

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread relayer/chains/evm/client.go Outdated
@RogerKSI RogerKSI merged commit 4b47689 into main May 19, 2026
2 checks passed
@RogerKSI RogerKSI deleted the reduce-idle-timeout branch May 19, 2026 06:40
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.

3 participants