Skip to content

[Feature] Remove the dead WalletExtension gRPC service and config #6931

Open

Description

@0xbigapple

Summary

The WalletExtension gRPC service has been registered but not implemented since Odyssey-v3.7 (2020-03): all four of its RPCs return UNIMPLEMENTED. This proposal removes the unused Java implementation, the node.walletExtensionApi configuration item that controls it, and the service WalletExtension definition in api.proto. It also removes the messages that are no longer used without this service: AccountPaginated, TransactionList, TransactionListExtention, TimeMessage, and TimePaginatedMessage.

Problem

Motivation

java-tron still includes a gRPC service, a config switch, and a set of proto RPC definitions that do not work. The in-memory index that once supported these RPCs was removed long ago because it used too many node resources for the value it provided; transaction information by account address is now provided by TronGrid. The config name may make node operators think it controls whether a working API is exposed, while the proto definitions cause SDK code generators to create client stubs for methods that can never succeed.

Current State

  1. Proto definitions: protocol/src/main/protos/api/api.proto still defines four WalletExtension RPCs, all of which take AccountPaginated. GetTransactionsFromThis and GetTransactionsToThis return TransactionList; their *2 versions return TransactionListExtention. These RPCs are the only users of the three message types in any .proto file in the repository. TimePaginatedMessage and the TimeMessage it contains are also unused after their *ByTimestamp RPCs were removed in Rm api #909.
  2. Runtime behavior: RpcApiService.WalletExtensionApi provides no RPC implementation: it extends WalletExtensionGrpc.WalletExtensionImplBase but overrides none of its RPC methods, and its only private helper, transactionList2Extention(), has no callers. Every request therefore uses the generated default handler and returns UNIMPLEMENTED. Registration does not change this behavior. The service is added only on a solidity node when node.walletExtensionApi = true; reference.conf sets the key to false by default, but the bundled framework/src/main/resources/config.conf sets it to true. The old HTTP endpoints were removed with the RPC implementations in Feature/multi_module meger to develop #2533, leaving only unused integration-test helpers.

Limitations or Risks

This does not add a new runtime risk. The main issue is unnecessary confusion. Node operators may think node.walletExtensionApi controls a working API, while generated SDKs still include methods that always return UNIMPLEMENTED. The remaining code and proto definitions also require maintenance.

Proposed Solution

Proposed Design

  1. Remove the Java implementation: Delete the WalletExtensionApi class, its registration branch in RpcApiService.addService(), and the WalletExtensionGrpc import.
  2. Delete the proto definitions: Remove service WalletExtension and its four RPCs from api.proto, together with the five messages listed above.
  3. Remove the configuration item: Delete node.walletExtensionApi from CommonParameter, NodeConfig, Args, and all bundled .conf files. If the old key is still present in an operator config, log a removal warning at startup.
  4. Clean up the remaining unused code: Remove Util.printTransactionList() from main sources, whose only caller is its own unit test; remove the unused WalletExtension test code from GrpcClient, WalletClient, and HttpMethed; and delete the getter/setter assertions for the removed parameter from ParameterTest.

Key Changes

  • Modules: framework, common, protocol, and related test code
  • API / Behavior Surface: The four service WalletExtension RPCs are no longer registered and gRPC reflection no longer lists the service.

Impact

The change has no performance effect other than registering one fewer service at startup. It makes the node configuration and code easier to understand and maintain: it removes a config item that looks like an API switch but does not control a working service, stops generating SDK stubs for methods that can never succeed, and removes unused code from about a dozen files.

Compatibility

  • Breaking Change: Yes

    • Generated code: code generated from java-tron's api.proto or the tronprotocol/protocol mirror that uses the removed definitions no longer compiles. Trident is not affected. wallet-cli has no impact now, since it compiles its own api.proto; when it updates its proto, it needs to clean up the related code as well, e.g. Utils.printTransactionList.
    • node.disabledApi: on a solidity node with walletExtensionApi = true that listed one of these methods in node.disabledApi, the call returned UNAVAILABLE and now returns UNIMPLEMENTED.
  • Default Behavior Change: No.

  • Migration Required: Only for clients that use the removed definitions; no action is required for node operators. Existing walletExtensionApi entries are ignored with a startup warning.

Additional Notes

  • Do you have ideas regarding implementation? Yes
  • Are you willing to implement this feature? Yes

Activity

  1. waynercheung commented on Sep 2, 2026

    @waynercheung
    Collaborator

    Thanks @0xbigapple. I verified the analysis at commit 4a21592f95: the RPC implementations were removed in 127cd78ad1 and have returned UNIMPLEMENTED since Odyssey-v3.7.

    I support removing the Java, config, and protobuf surfaces together as an explicit exception to the deprecation policy in #6921. The exception is reasonable here because the RPCs have been non-functional for six years and were already identified as deprecated in Core Devs Call 60. Please update #6921 to record this decision.

    For the PR, please:

    • Emit a single startup WARN when node.walletExtensionApi is present, since unknown config keys are otherwise ignored.
    • Remove the key from bundled and test configs, and open follow-ups for the affected deployment/container templates.
    • Add a release-note and migration entry, clearly marking the generated-code API break and pointing users to TronGrid.
    • Track the required protocol and wallet-cli cleanup, and add a regression test confirming the gRPC status remains UNIMPLEMENTED.

    Although the runtime status code is unchanged, removing the proto definitions is still a generated-code compatibility break and changes the reflection surface, so the downstream work should be linked before merge.

    No consensus impact; this can target the next regular release. Happy to review the PR.

  2. 0xbigapple commented on Sep 2, 2026

    @0xbigapple
    CollaboratorAuthor

    Thanks @0xbigapple. I verified the analysis at commit 4a21592f95: the RPC implementations were removed in 127cd78ad1 and have returned UNIMPLEMENTED since Odyssey-v3.7.

    I support removing the Java, config, and protobuf surfaces together as an explicit exception to the deprecation policy in #6921. The exception is reasonable here because the RPCs have been non-functional for six years and were already identified as deprecated in Core Devs Call 60. Please update #6921 to record this decision.

    For the PR, please:

    • Emit a single startup WARN when node.walletExtensionApi is present, since unknown config keys are otherwise ignored.
    • Remove the key from bundled and test configs, and open follow-ups for the affected deployment/container templates.
    • Add a release-note and migration entry, clearly marking the generated-code API break and pointing users to TronGrid.
    • Track the required protocol and wallet-cli cleanup, and add a regression test confirming the gRPC status remains UNIMPLEMENTED.

    Although the runtime status code is unchanged, removing the proto definitions is still a generated-code compatibility break and changes the reflection surface, so the downstream work should be linked before merge.

    No consensus impact; this can target the next regular release. Happy to review the PR.

    @waynercheung Thanks for your detailed comments and suggestions. I’ll update the issue #6921 description accordingly.

  3. waynercheung commented on Sep 2, 2026

    @waynercheung
    Collaborator

    @0xbigapple Thanks for confirming. Please link the PR here once #6921 is updated; I’ll review it against the compatibility and downstream requirements above.

  4. removed this from the GreatVoyage-v4.8.3 milestone on Sep 24, 2026
  5. 0xbigapple commented on Oct 10, 2026

    @0xbigapple
    CollaboratorAuthor

    @0xbigapple Thanks for confirming. Please link the PR here once #6921 is updated; I’ll review it against the compatibility and downstream requirements above.

    @waynercheung Downstream check for #6975 (default branch of each repository). None of the items below blocks the PR; all can follow after merge.

    Affected

    • tronprotocol/protocol: api/api.proto still defines service WalletExtension and the removed messages; sync after merge.
    • wallet-cli: no impact now, since it compiles its own copy of api.proto; when updating its proto, clean up the related code as well, e.g. Utils.printTransactionList.
    • tron-docker: walletExtensionApi in conf/main_net_config.conf, conf/nile_net_config.conf, conf/private_net_config_{witness1,witness2,others}.conf, the stress-test config and the toolkit test config.
    • tron-deployment: walletExtensionApi in main_net_config.conf, test_net_config.conf, private_net_config.conf.
    • documentation-zh: the TestNet page's sample config sets walletExtensionApi = true.

    The leftover config key only adds a startup warning after upgrade; nodes still start.

    Not affected

    • trident: compiles its own protos; no WalletExtension definitions; its response.proto keeps an unused copy of TransactionList (no RPC or code references it), which can be dropped but breaks nothing.
    • documentation-en: only listed among the services affected by the v4.8.2 removal of google.api.http mappings; no change needed.
  6. waynercheung commented on Oct 10, 2026

    @waynercheung
    Collaborator

    Thanks for the downstream audit. Agreed these are non-blocking follow-ups. Please open tracking issues/PRs and link them under "Follow up" in #6975. Coordinate the protocol sync and the config/docs updates with v4.8.3; this issue can be closed once the follow-ups are linked. The wallet-cli cleanup can accompany its adoption of the updated proto.

    @317787106 Principle 2 and item 4 in #6921 still describe two-stage deprecation. Please update them before the v4.8.3 release to record the direct-removal exception and the target version, and link #6975 from item 4.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    • Status
      No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions