Skip to content

Remove Consensus Node fallback mechanism to make read-only RPC methods truly cost-free #3713

Closed
@quiet-node

Description

@quiet-node

Description

Currently, the JSON RPC Relay makes queries to both Consensus Node and Mirror Node for various operations. While Mirror Node queries are free, Consensus Node queries incur HBAR costs.

The main issue is that eth RPC methods use Consensus Node as fallbacks when Mirror Node fails, causing:

  • Unpredictable HBAR consumption for read operations
  • Lack of transparency about when costs are incurred
  • Unnecessary dependency on Consensus Node for what should be read-only operations

Goal

Remove all Consensus Node fallbacks from read-only operations to:

  • Eliminate unexpected HBAR costs
  • Make read-only methods truly cost-free
  • Establish clear separation between read operations (free) and write operations (costs HBAR)
  • Complete control over HBAR consumption (limited to eth_sendRawTransaction)

Proposed solution

  1. Improve error handling for Mirror Node failures without falling back to CN
  2. Remove CN queries in the SDKClient class
  3. Optimize Mirror Node calls to make them more reliable

Success criteria

  • All read-only RPC methods operate exclusively through Mirror Node
  • HBAR consumption only occurs through eth_sendRawTransaction
  • Proper error responses when Mirror Node fails instead of CN fallbacks

Metadata

Metadata

Assignees

Labels

Team PromotedIssues to be triaged and discussed by committers, maintainers, to be worked on the following sprintenhancementNew feature or request

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions