Skip to content

Optimize RPC Failover Latency #150

Description

@grantfox-oss

Description

Implement an intelligent, high-availability RPC failover mechanism to maintain protocol liveness.

Problem Statement

The engine currently relies on a static RPC provider. If the provider experiences jitter or downtime, the transaction submission stalls, leading to unnecessary delays in task execution and poor user experience for Guardians.

Technical Requirements

  • Requirement: Maintain a weighted list of secondary RPC providers.
  • Requirement: Implement a health-check monitor that proactively tests endpoints before routing traffic.

Implementation Guide

  • Suggested Approach: Create a background task in src/engine/rpc.rs that maintains a sliding window of successful/failed requests per provider.
  • Branch Strategy: git checkout -b feat/rpc-failover-optimization
  • Affected Areas: src/engine/rpc.rs

Acceptance Criteria

  • Engine switches to secondary provider within <2 seconds of primary failure detection.
  • No dropped transactions during a simulated provider outage.

Security & Audit Considerations

  • Provider list must be fetched from an authenticated and signed source.

Definition of Done

  • Code reviewed
  • CI/CD passed

Metadata

Metadata

Assignees

Labels

GrantFox OSSIssue tracked in GrantFox OSSMaybe RewardedIssue may be eligible for a GrantFox rewardOfficial CampaignCampaign: Official Campaign

Type

No type

Fields

No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions