Skip to content

Name resolution on node side for RPC requests #494

@RealJohnSmith

Description

@RealJohnSmith

Description of the issue

I think that read-only RPC requests (e.g., getBalance, getNonce, ...) should allow for name service resolution by a node to same roundtrip (latency) and overhead with handling extra network traffic.

These request could take another parameter in the request. If JSON contains String name it would try to resolve and use this, if it contains address it would use this field as an address. This system guarantees that no name that looks like a valid address can be "accidentally" resolved and data returned for an unexpected target. It also requires explicit action from the client (not to use address field, but name field instead), which implies that the client wants to do this action and otherwise would have to resolve the name and use it in the subsequent request anyway.

When it comes to transactions, they still need a program hash and client would have to request this from the node. Nodes shouldn't allow transactions by named addresses.

Issue-Type (put an x sign in the square brackets)

  • bug report
  • feature request
  • Documentation improvement

Checklist

  • Running latest version of the code.
  • This issue has not been reported earlier.

Your environment

  • OS: Not relevant
  • Go version: Not relevant
  • Release tag/commit of the code: ed50f28

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions