-
Notifications
You must be signed in to change notification settings - Fork 612
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add MsgServer
to interchain accounts controller
#2026
Comments
Requires discussion regarding usage of Edit: discussed with @colin-axner and decided the best option is to go with More context in this thread: #2086 (comment) |
Great issue. Using Msg routing is the right approach. BTW, x/authz is also using this mechanism. |
At first glance it makes sense to register messages in the controller chain for However, It may create burden if there is one chain to control many (it would need to register all custom messages and keep track with versions). |
Summary
Add a new
MsgServer
to27-interchain-accounts
which exposes two distinct rpc endpoints:RegisterAccount
SubmitTx
Problem Definition
The current design implemented in
27-interchain-accounts
mandates that a base application referred to as an authentication module is developed in order to provide custom authentication as an entrypoint to interchain accounts. In this approach an application developer is expected to compose their base application (authentication module) with the ICS27controllerKeeper
and leverage the exported APIs exposed for account registration and sending of interchain accounts transactions.Since the release of cosmos-sdk
v0.46.x
, the new design ofx/gov
andx/group
allow for arbitrary message passing via the cosmos-sdk'sMsgServiceRouter
. When a proposal is accepted it allows the state machine to execute an arbitrary number ofsdk.Msg
s. Since this functionality has been introduced it has become clear thatx/gov
andx/group
act as authentication modules with respect to interchain accounts integration.Proposal
Introduce a new
MsgServer
to27-interchain-accounts/controller
and incrementally move towards deprecation of public APIs.This allows for existing app developers to simply change their code from a public API (
RegisterInterchainAccount
/SendTx
) call to message passing, whereby one would compose their app with the cosmos-sdkMsgServiceRouter
and retrieve the handler appropriately based on the messagetypeURL
, as is done in many existing modules such asx/gov
,x/group
as well as27-interchain-accounts/host
. This provides a more standardised approach to integrating with interchain accounts.RegisterAccount
Introduce a new rpc endpoint
RegisterAccount
. This rpc should provide the existing functionality of the exportedRegisterInterchainAccount
function in27-interchain-accounts/controller
.RegisterAccount
rpc and proto message definitions #2051sdk.Msg
interface forMsgRegisterAccount
#2053RegisterAccount
#2055RegisterAccount
rpc #2061SubmitTx
Introduce a new rpc endpoint
SubmitTx
. This rpc should provide the existing functionality of the exportedSendTx
function in27-interchain-accounts/controller
.SendTx
rpc and proto message definitions #2052sdk.Msg
interface forMsgSendTx
#2054SendTx
#2056SendTx
rpc #2062For Admin Use
The text was updated successfully, but these errors were encountered: