diff --git a/abci/types/application.go b/abci/types/application.go index 057989e24..a0f8a0826 100644 --- a/abci/types/application.go +++ b/abci/types/application.go @@ -103,7 +103,9 @@ func (BaseApplication) ExtendVote(_ context.Context, req *RequestExtendVote) (*R } func (BaseApplication) VerifyVoteExtension(_ context.Context, req *RequestVerifyVoteExtension) (*ResponseVerifyVoteExtension, error) { - return &ResponseVerifyVoteExtension{Result: OK}, nil + return &ResponseVerifyVoteExtension{ + Status: ResponseVerifyVoteExtension_ACCEPT, + }, nil } func (BaseApplication) FinalizeBlock(_ context.Context, req *RequestFinalizeBlock) (*ResponseFinalizeBlock, error) { diff --git a/proxy/app_conn.go b/proxy/app_conn.go index 6a0dbf474..a9f84e7e6 100644 --- a/proxy/app_conn.go +++ b/proxy/app_conn.go @@ -89,6 +89,16 @@ func (app *appConnConsensus) ProcessProposal(ctx context.Context, req *types.Req return app.appConn.ProcessProposal(ctx, req) } +func (app *appConnConsensus) ExtendVote(ctx context.Context, req *types.RequestExtendVote) (*types.ResponseExtendVote, error) { + defer addTimeSample(app.metrics.MethodTimingSeconds.With("method", "deliver_tx", "type", "async"))() + return app.appConn.ExtendVote(ctx, req) +} + +func (app *appConnConsensus) VerifyVoteExtension(ctx context.Context, req *types.RequestVerifyVoteExtension) (*types.ResponseVerifyVoteExtension, error) { + defer addTimeSample(app.metrics.MethodTimingSeconds.With("method", "deliver_tx", "type", "async"))() + return app.appConn.VerifyVoteExtension(ctx, req) +} + func (app *appConnConsensus) FinalizeBlock(ctx context.Context, req *types.RequestFinalizeBlock) (*types.ResponseFinalizeBlock, error) { defer addTimeSample(app.metrics.MethodTimingSeconds.With("method", "deliver_tx", "type", "async"))() return app.appConn.FinalizeBlock(ctx, req) @@ -99,14 +109,6 @@ func (app *appConnConsensus) Commit(ctx context.Context) (*types.ResponseCommit, return app.appConn.Commit(ctx, &types.RequestCommit{}) } -func (app *appConnConsensus) ExtendVoteSync(req types.RequestExtendVote) (*types.ResponseExtendVote, error) { - return app.appConn.ExtendVoteSync(req) -} - -func (app *appConnConsensus) VerifyVoteExtensionSync(req types.RequestVerifyVoteExtension) (*types.ResponseVerifyVoteExtension, error) { - return app.appConn.VerifyVoteExtensionSync(req) -} - //------------------------------------------------ // Implements AppConnMempool (subset of abcicli.Client) diff --git a/state/execution.go b/state/execution.go index d6d8b3ff6..d563c45c5 100644 --- a/state/execution.go +++ b/state/execution.go @@ -300,7 +300,7 @@ func (blockExec *BlockExecutor) ExtendVote(vote *types.Vote) ([]byte, error) { Height: vote.Height, } - resp, err := blockExec.proxyApp.ExtendVoteSync(req) + resp, err := blockExec.proxyApp.ExtendVote(context.TODO(), &req) if err != nil { panic(fmt.Errorf("ExtendVote call failed: %w", err)) } @@ -315,7 +315,7 @@ func (blockExec *BlockExecutor) VerifyVoteExtension(vote *types.Vote) error { VoteExtension: vote.Extension, } - resp, err := blockExec.proxyApp.VerifyVoteExtensionSync(req) + resp, err := blockExec.proxyApp.VerifyVoteExtension(context.TODO(), &req) if err != nil { panic(fmt.Errorf("VerifyVoteExtension call failed: %w", err)) }