From 4316705a28c8751fc827141d0add0a7496d325f5 Mon Sep 17 00:00:00 2001 From: Mikhail Zabaluev Date: Fri, 6 Oct 2023 23:48:25 +0300 Subject: [PATCH] Post-merge fixes for feature/proto-upgrade proto: copy latest changes in CometBFT 0.38 Replicate protobuf changes made for CometBFT 0.38.0 into the appropriate versions of cometbft.* packages. This only touches existing packages, not the newly added service packages which already have versioning in the main branch. proto: replicate services.* packages to cometbft Copy over the definitions from tendermint packages to cometbft namespace and rename references. The versioning for the proto packages themselves is already done in the main branch. proto: redefine RequestExtendVote in abci.v4 Need to change a field to v4.Misbehavior. api: regenerate *.pb.go files from protobuf Regenerate api. Change the RequestExtendVote alias to point to v4 package. Add aliases for HasProposalBlockPart. consensus: update msgs.go to main and fix imports consensus: update msgs_test.go to main consensus: use aliased consts in state_test.go grpc: fix import in BlockResultsService client Regenerate mocks. mempool: set the Type field in CheckTx request Rather than using the default which is now CHECK_TX_TYPE_UNKNOWN, pass the type explicitly. Before the enum normalization, the default value was the same as New. mempool: panic on unexpected type in ABCI CheckTx Backstop an unexpected value of RequestCheckTx.type with a panic rather than silently doing nothing. Small change to mempool test infra All RequestCheckTx created must have filed `Type` set changelog for the new CheckTx type field behavior Add the note that the Type field can no longer be omitted from the proto-generated RequestCheckTx struct, retroactively linked to the GitHub issue about enum renaming changes. --- .../breaking-changes/736-proto-enum-rename.md | 3 + abci/client/grpc_client_test.go | 7 +- abci/client/mocks/client.go | 194 +- abci/client/socket_client_test.go | 12 +- abci/cmd/abci-cli/abci-cli.go | 5 +- abci/example/kvstore/kvstore.go | 4 +- abci/example/kvstore/kvstore_test.go | 9 +- abci/tests/server/client.go | 2 +- abci/types/mocks/application.go | 177 +- abci/types/types.go | 192 +- api/cometbft/abci/v3/types.pb.go | 623 ++++- api/cometbft/abci/v4/types.pb.go | 871 ++++-- api/cometbft/consensus/types.go | 44 +- api/cometbft/consensus/v1/message.go | 31 +- api/cometbft/consensus/v2/message.go | 14 +- api/cometbft/consensus/v2/types.pb.go | 389 ++- api/cometbft/services/block/v1/block.pb.go | 1186 ++++++++ .../services/block/v1/block_service.pb.go | 241 ++ .../block_results/v1/block_results.pb.go | 893 +++++++ .../v1/block_results_service.pb.go | 168 ++ .../services/pruning/v1/pruning.pb.go | 2381 +++++++++++++++++ .../services/pruning/v1/service.pb.go | 431 +++ .../services/version/v1/version.pb.go | 560 ++++ .../services/version/v1/version_service.pb.go | 130 + consensus/mempool_test.go | 3 +- consensus/msgs.go | 11 +- consensus/state_test.go | 36 +- mempool/clist_mempool.go | 16 +- mempool/clist_mempool_test.go | 6 +- mempool/mocks/mempool.go | 8 +- proto/cometbft/abci/v3/types.proto | 12 +- proto/cometbft/abci/v4/types.proto | 20 +- proto/cometbft/consensus/v2/types.proto | 8 + proto/cometbft/services/block/v1/block.proto | 34 + .../services/block/v1/block_service.proto | 21 + .../block_results/v1/block_results.proto | 25 + .../v1/block_results_service.proto | 17 + .../services/pruning/v1/pruning.proto | 58 + .../services/pruning/v1/service.proto | 48 + .../services/version/v1/version.proto | 13 + .../services/version/v1/version_service.proto | 19 + proxy/app_conn_test.go | 10 +- proxy/mocks/app_conn_consensus.go | 88 +- proxy/mocks/app_conn_mempool.go | 24 +- proxy/mocks/app_conn_query.go | 38 +- proxy/mocks/app_conn_snapshot.go | 52 +- rpc/core/mempool.go | 2 +- rpc/grpc/client/block_results_service.go | 4 +- rpc/grpc/client/block_service.go | 7 +- rpc/grpc/client/privileged/pruning_service.go | 2 +- rpc/grpc/client/version_service.go | 2 +- rpc/grpc/server/privileged/privileged.go | 2 +- rpc/grpc/server/server.go | 6 +- .../services/blockresultservice/service.go | 2 +- .../server/services/blockservice/service.go | 7 +- .../server/services/pruningservice/service.go | 2 +- .../server/services/versionservice/service.go | 2 +- state/mocks/store.go | 30 +- state/txindex/mocks/tx_indexer.go | 26 +- 59 files changed, 8376 insertions(+), 852 deletions(-) create mode 100644 api/cometbft/services/block/v1/block.pb.go create mode 100644 api/cometbft/services/block/v1/block_service.pb.go create mode 100644 api/cometbft/services/block_results/v1/block_results.pb.go create mode 100644 api/cometbft/services/block_results/v1/block_results_service.pb.go create mode 100644 api/cometbft/services/pruning/v1/pruning.pb.go create mode 100644 api/cometbft/services/pruning/v1/service.pb.go create mode 100644 api/cometbft/services/version/v1/version.pb.go create mode 100644 api/cometbft/services/version/v1/version_service.pb.go create mode 100644 proto/cometbft/services/block/v1/block.proto create mode 100644 proto/cometbft/services/block/v1/block_service.proto create mode 100644 proto/cometbft/services/block_results/v1/block_results.proto create mode 100644 proto/cometbft/services/block_results/v1/block_results_service.proto create mode 100644 proto/cometbft/services/pruning/v1/pruning.proto create mode 100644 proto/cometbft/services/pruning/v1/service.proto create mode 100644 proto/cometbft/services/version/v1/version.proto create mode 100644 proto/cometbft/services/version/v1/version_service.proto diff --git a/.changelog/unreleased/breaking-changes/736-proto-enum-rename.md b/.changelog/unreleased/breaking-changes/736-proto-enum-rename.md index c726d635028..b85d30f03df 100644 --- a/.changelog/unreleased/breaking-changes/736-proto-enum-rename.md +++ b/.changelog/unreleased/breaking-changes/736-proto-enum-rename.md @@ -1,3 +1,6 @@ - `[abci]` Change the proto-derived enum type and constant aliases to the buf-recommended naming conventions taken up by the `abci/v4` proto package ([\#736](https://github.com/cometbft/cometbft/issues/736)). +- `[proto]` The `Type` enum field is now required to be set to a value other + than the default `CHECK_TX_TYPE_UNKNOWN` for a valid `RequestCheckTx` + ([\#736](https://github.com/cometbft/cometbft/issues/736)). diff --git a/abci/client/grpc_client_test.go b/abci/client/grpc_client_test.go index 95d6e481cd6..2eedecb5f19 100644 --- a/abci/client/grpc_client_test.go +++ b/abci/client/grpc_client_test.go @@ -56,7 +56,12 @@ func TestGRPC(t *testing.T) { // Write requests for counter := 0; counter < numCheckTxs; counter++ { // Send request - response, err := client.CheckTx(context.Background(), &types.RequestCheckTx{Tx: []byte("test")}) + response, err := client.CheckTx( + context.Background(), + &types.RequestCheckTx{ + Tx: []byte("test"), + Type: types.CHECK_TX_TYPE_CHECK, + }) require.NoError(t, err) counter++ if response.Code != 0 { diff --git a/abci/client/mocks/client.go b/abci/client/mocks/client.go index 9035b33d143..1a2ca308bd3 100644 --- a/abci/client/mocks/client.go +++ b/abci/client/mocks/client.go @@ -11,7 +11,13 @@ import ( mock "github.com/stretchr/testify/mock" - types "github.com/cometbft/cometbft/abci/types" + v1 "github.com/cometbft/cometbft/api/cometbft/abci/v1" + + v2 "github.com/cometbft/cometbft/api/cometbft/abci/v2" + + v3 "github.com/cometbft/cometbft/api/cometbft/abci/v3" + + v4 "github.com/cometbft/cometbft/api/cometbft/abci/v4" ) // Client is an autogenerated mock type for the Client type @@ -20,23 +26,23 @@ type Client struct { } // ApplySnapshotChunk provides a mock function with given fields: _a0, _a1 -func (_m *Client) ApplySnapshotChunk(_a0 context.Context, _a1 *types.RequestApplySnapshotChunk) (*types.ResponseApplySnapshotChunk, error) { +func (_m *Client) ApplySnapshotChunk(_a0 context.Context, _a1 *v1.RequestApplySnapshotChunk) (*v4.ResponseApplySnapshotChunk, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseApplySnapshotChunk + var r0 *v4.ResponseApplySnapshotChunk var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestApplySnapshotChunk) (*types.ResponseApplySnapshotChunk, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestApplySnapshotChunk) (*v4.ResponseApplySnapshotChunk, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestApplySnapshotChunk) *types.ResponseApplySnapshotChunk); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestApplySnapshotChunk) *v4.ResponseApplySnapshotChunk); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseApplySnapshotChunk) + r0 = ret.Get(0).(*v4.ResponseApplySnapshotChunk) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestApplySnapshotChunk) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestApplySnapshotChunk) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -46,23 +52,23 @@ func (_m *Client) ApplySnapshotChunk(_a0 context.Context, _a1 *types.RequestAppl } // CheckTx provides a mock function with given fields: _a0, _a1 -func (_m *Client) CheckTx(_a0 context.Context, _a1 *types.RequestCheckTx) (*types.ResponseCheckTx, error) { +func (_m *Client) CheckTx(_a0 context.Context, _a1 *v4.RequestCheckTx) (*v3.ResponseCheckTx, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseCheckTx + var r0 *v3.ResponseCheckTx var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) (*types.ResponseCheckTx, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) (*v3.ResponseCheckTx, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) *types.ResponseCheckTx); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) *v3.ResponseCheckTx); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseCheckTx) + r0 = ret.Get(0).(*v3.ResponseCheckTx) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestCheckTx) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestCheckTx) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -72,15 +78,15 @@ func (_m *Client) CheckTx(_a0 context.Context, _a1 *types.RequestCheckTx) (*type } // CheckTxAsync provides a mock function with given fields: _a0, _a1 -func (_m *Client) CheckTxAsync(_a0 context.Context, _a1 *types.RequestCheckTx) (*abcicli.ReqRes, error) { +func (_m *Client) CheckTxAsync(_a0 context.Context, _a1 *v4.RequestCheckTx) (*abcicli.ReqRes, error) { ret := _m.Called(_a0, _a1) var r0 *abcicli.ReqRes var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) (*abcicli.ReqRes, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) (*abcicli.ReqRes, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) *abcicli.ReqRes); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) *abcicli.ReqRes); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { @@ -88,7 +94,7 @@ func (_m *Client) CheckTxAsync(_a0 context.Context, _a1 *types.RequestCheckTx) ( } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestCheckTx) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestCheckTx) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -98,23 +104,23 @@ func (_m *Client) CheckTxAsync(_a0 context.Context, _a1 *types.RequestCheckTx) ( } // Commit provides a mock function with given fields: _a0, _a1 -func (_m *Client) Commit(_a0 context.Context, _a1 *types.RequestCommit) (*types.ResponseCommit, error) { +func (_m *Client) Commit(_a0 context.Context, _a1 *v1.RequestCommit) (*v3.ResponseCommit, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseCommit + var r0 *v3.ResponseCommit var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCommit) (*types.ResponseCommit, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestCommit) (*v3.ResponseCommit, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCommit) *types.ResponseCommit); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestCommit) *v3.ResponseCommit); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseCommit) + r0 = ret.Get(0).(*v3.ResponseCommit) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestCommit) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestCommit) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -124,19 +130,19 @@ func (_m *Client) Commit(_a0 context.Context, _a1 *types.RequestCommit) (*types. } // Echo provides a mock function with given fields: _a0, _a1 -func (_m *Client) Echo(_a0 context.Context, _a1 string) (*types.ResponseEcho, error) { +func (_m *Client) Echo(_a0 context.Context, _a1 string) (*v1.ResponseEcho, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseEcho + var r0 *v1.ResponseEcho var r1 error - if rf, ok := ret.Get(0).(func(context.Context, string) (*types.ResponseEcho, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, string) (*v1.ResponseEcho, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, string) *types.ResponseEcho); ok { + if rf, ok := ret.Get(0).(func(context.Context, string) *v1.ResponseEcho); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseEcho) + r0 = ret.Get(0).(*v1.ResponseEcho) } } @@ -164,23 +170,23 @@ func (_m *Client) Error() error { } // ExtendVote provides a mock function with given fields: _a0, _a1 -func (_m *Client) ExtendVote(_a0 context.Context, _a1 *types.RequestExtendVote) (*types.ResponseExtendVote, error) { +func (_m *Client) ExtendVote(_a0 context.Context, _a1 *v4.RequestExtendVote) (*v3.ResponseExtendVote, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseExtendVote + var r0 *v3.ResponseExtendVote var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestExtendVote) (*types.ResponseExtendVote, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestExtendVote) (*v3.ResponseExtendVote, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestExtendVote) *types.ResponseExtendVote); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestExtendVote) *v3.ResponseExtendVote); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseExtendVote) + r0 = ret.Get(0).(*v3.ResponseExtendVote) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestExtendVote) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestExtendVote) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -190,23 +196,23 @@ func (_m *Client) ExtendVote(_a0 context.Context, _a1 *types.RequestExtendVote) } // FinalizeBlock provides a mock function with given fields: _a0, _a1 -func (_m *Client) FinalizeBlock(_a0 context.Context, _a1 *types.RequestFinalizeBlock) (*types.ResponseFinalizeBlock, error) { +func (_m *Client) FinalizeBlock(_a0 context.Context, _a1 *v4.RequestFinalizeBlock) (*v3.ResponseFinalizeBlock, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseFinalizeBlock + var r0 *v3.ResponseFinalizeBlock var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestFinalizeBlock) (*types.ResponseFinalizeBlock, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestFinalizeBlock) (*v3.ResponseFinalizeBlock, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestFinalizeBlock) *types.ResponseFinalizeBlock); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestFinalizeBlock) *v3.ResponseFinalizeBlock); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseFinalizeBlock) + r0 = ret.Get(0).(*v3.ResponseFinalizeBlock) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestFinalizeBlock) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestFinalizeBlock) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -230,23 +236,23 @@ func (_m *Client) Flush(_a0 context.Context) error { } // Info provides a mock function with given fields: _a0, _a1 -func (_m *Client) Info(_a0 context.Context, _a1 *types.RequestInfo) (*types.ResponseInfo, error) { +func (_m *Client) Info(_a0 context.Context, _a1 *v2.RequestInfo) (*v1.ResponseInfo, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseInfo + var r0 *v1.ResponseInfo var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInfo) (*types.ResponseInfo, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v2.RequestInfo) (*v1.ResponseInfo, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInfo) *types.ResponseInfo); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v2.RequestInfo) *v1.ResponseInfo); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseInfo) + r0 = ret.Get(0).(*v1.ResponseInfo) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestInfo) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v2.RequestInfo) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -256,23 +262,23 @@ func (_m *Client) Info(_a0 context.Context, _a1 *types.RequestInfo) (*types.Resp } // InitChain provides a mock function with given fields: _a0, _a1 -func (_m *Client) InitChain(_a0 context.Context, _a1 *types.RequestInitChain) (*types.ResponseInitChain, error) { +func (_m *Client) InitChain(_a0 context.Context, _a1 *v3.RequestInitChain) (*v3.ResponseInitChain, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseInitChain + var r0 *v3.ResponseInitChain var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInitChain) (*types.ResponseInitChain, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestInitChain) (*v3.ResponseInitChain, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInitChain) *types.ResponseInitChain); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestInitChain) *v3.ResponseInitChain); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseInitChain) + r0 = ret.Get(0).(*v3.ResponseInitChain) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestInitChain) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v3.RequestInitChain) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -296,23 +302,23 @@ func (_m *Client) IsRunning() bool { } // ListSnapshots provides a mock function with given fields: _a0, _a1 -func (_m *Client) ListSnapshots(_a0 context.Context, _a1 *types.RequestListSnapshots) (*types.ResponseListSnapshots, error) { +func (_m *Client) ListSnapshots(_a0 context.Context, _a1 *v1.RequestListSnapshots) (*v1.ResponseListSnapshots, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseListSnapshots + var r0 *v1.ResponseListSnapshots var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestListSnapshots) (*types.ResponseListSnapshots, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestListSnapshots) (*v1.ResponseListSnapshots, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestListSnapshots) *types.ResponseListSnapshots); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestListSnapshots) *v1.ResponseListSnapshots); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseListSnapshots) + r0 = ret.Get(0).(*v1.ResponseListSnapshots) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestListSnapshots) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestListSnapshots) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -322,23 +328,23 @@ func (_m *Client) ListSnapshots(_a0 context.Context, _a1 *types.RequestListSnaps } // LoadSnapshotChunk provides a mock function with given fields: _a0, _a1 -func (_m *Client) LoadSnapshotChunk(_a0 context.Context, _a1 *types.RequestLoadSnapshotChunk) (*types.ResponseLoadSnapshotChunk, error) { +func (_m *Client) LoadSnapshotChunk(_a0 context.Context, _a1 *v1.RequestLoadSnapshotChunk) (*v1.ResponseLoadSnapshotChunk, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseLoadSnapshotChunk + var r0 *v1.ResponseLoadSnapshotChunk var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestLoadSnapshotChunk) (*types.ResponseLoadSnapshotChunk, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestLoadSnapshotChunk) (*v1.ResponseLoadSnapshotChunk, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestLoadSnapshotChunk) *types.ResponseLoadSnapshotChunk); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestLoadSnapshotChunk) *v1.ResponseLoadSnapshotChunk); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseLoadSnapshotChunk) + r0 = ret.Get(0).(*v1.ResponseLoadSnapshotChunk) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestLoadSnapshotChunk) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestLoadSnapshotChunk) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -348,23 +354,23 @@ func (_m *Client) LoadSnapshotChunk(_a0 context.Context, _a1 *types.RequestLoadS } // OfferSnapshot provides a mock function with given fields: _a0, _a1 -func (_m *Client) OfferSnapshot(_a0 context.Context, _a1 *types.RequestOfferSnapshot) (*types.ResponseOfferSnapshot, error) { +func (_m *Client) OfferSnapshot(_a0 context.Context, _a1 *v1.RequestOfferSnapshot) (*v4.ResponseOfferSnapshot, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseOfferSnapshot + var r0 *v4.ResponseOfferSnapshot var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestOfferSnapshot) (*types.ResponseOfferSnapshot, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestOfferSnapshot) (*v4.ResponseOfferSnapshot, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestOfferSnapshot) *types.ResponseOfferSnapshot); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestOfferSnapshot) *v4.ResponseOfferSnapshot); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseOfferSnapshot) + r0 = ret.Get(0).(*v4.ResponseOfferSnapshot) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestOfferSnapshot) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestOfferSnapshot) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -407,23 +413,23 @@ func (_m *Client) OnStop() { } // PrepareProposal provides a mock function with given fields: _a0, _a1 -func (_m *Client) PrepareProposal(_a0 context.Context, _a1 *types.RequestPrepareProposal) (*types.ResponsePrepareProposal, error) { +func (_m *Client) PrepareProposal(_a0 context.Context, _a1 *v4.RequestPrepareProposal) (*v2.ResponsePrepareProposal, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponsePrepareProposal + var r0 *v2.ResponsePrepareProposal var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestPrepareProposal) (*types.ResponsePrepareProposal, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestPrepareProposal) (*v2.ResponsePrepareProposal, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestPrepareProposal) *types.ResponsePrepareProposal); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestPrepareProposal) *v2.ResponsePrepareProposal); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponsePrepareProposal) + r0 = ret.Get(0).(*v2.ResponsePrepareProposal) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestPrepareProposal) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestPrepareProposal) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -433,23 +439,23 @@ func (_m *Client) PrepareProposal(_a0 context.Context, _a1 *types.RequestPrepare } // ProcessProposal provides a mock function with given fields: _a0, _a1 -func (_m *Client) ProcessProposal(_a0 context.Context, _a1 *types.RequestProcessProposal) (*types.ResponseProcessProposal, error) { +func (_m *Client) ProcessProposal(_a0 context.Context, _a1 *v4.RequestProcessProposal) (*v4.ResponseProcessProposal, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseProcessProposal + var r0 *v4.ResponseProcessProposal var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestProcessProposal) (*types.ResponseProcessProposal, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestProcessProposal) (*v4.ResponseProcessProposal, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestProcessProposal) *types.ResponseProcessProposal); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestProcessProposal) *v4.ResponseProcessProposal); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseProcessProposal) + r0 = ret.Get(0).(*v4.ResponseProcessProposal) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestProcessProposal) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestProcessProposal) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -459,23 +465,23 @@ func (_m *Client) ProcessProposal(_a0 context.Context, _a1 *types.RequestProcess } // Query provides a mock function with given fields: _a0, _a1 -func (_m *Client) Query(_a0 context.Context, _a1 *types.RequestQuery) (*types.ResponseQuery, error) { +func (_m *Client) Query(_a0 context.Context, _a1 *v1.RequestQuery) (*v1.ResponseQuery, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseQuery + var r0 *v1.ResponseQuery var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestQuery) (*types.ResponseQuery, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestQuery) (*v1.ResponseQuery, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestQuery) *types.ResponseQuery); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestQuery) *v1.ResponseQuery); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseQuery) + r0 = ret.Get(0).(*v1.ResponseQuery) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestQuery) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestQuery) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -567,23 +573,23 @@ func (_m *Client) String() string { } // VerifyVoteExtension provides a mock function with given fields: _a0, _a1 -func (_m *Client) VerifyVoteExtension(_a0 context.Context, _a1 *types.RequestVerifyVoteExtension) (*types.ResponseVerifyVoteExtension, error) { +func (_m *Client) VerifyVoteExtension(_a0 context.Context, _a1 *v3.RequestVerifyVoteExtension) (*v4.ResponseVerifyVoteExtension, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseVerifyVoteExtension + var r0 *v4.ResponseVerifyVoteExtension var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestVerifyVoteExtension) (*types.ResponseVerifyVoteExtension, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestVerifyVoteExtension) (*v4.ResponseVerifyVoteExtension, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestVerifyVoteExtension) *types.ResponseVerifyVoteExtension); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestVerifyVoteExtension) *v4.ResponseVerifyVoteExtension); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseVerifyVoteExtension) + r0 = ret.Get(0).(*v4.ResponseVerifyVoteExtension) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestVerifyVoteExtension) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v3.RequestVerifyVoteExtension) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) diff --git a/abci/client/socket_client_test.go b/abci/client/socket_client_test.go index f4bade22934..a916bb212ff 100644 --- a/abci/client/socket_client_test.go +++ b/abci/client/socket_client_test.go @@ -51,7 +51,9 @@ func TestHangingAsyncCalls(t *testing.T) { resp := make(chan error, 1) go func() { // Call CheckTx - reqres, err := c.CheckTxAsync(context.Background(), &types.RequestCheckTx{}) + reqres, err := c.CheckTxAsync(context.Background(), &types.RequestCheckTx{ + Type: types.CHECK_TX_TYPE_CHECK, + }) require.NoError(t, err) // wait 50 ms for all events to travel socket, but // no response yet from server @@ -176,7 +178,9 @@ func TestCallbackInvokedWhenSetLate(t *testing.T) { wg: wg, } _, c := setupClientServer(t, app) - reqRes, err := c.CheckTxAsync(ctx, &types.RequestCheckTx{}) + reqRes, err := c.CheckTxAsync(ctx, &types.RequestCheckTx{ + Type: types.CHECK_TX_TYPE_CHECK, + }) require.NoError(t, err) done := make(chan struct{}) @@ -217,7 +221,9 @@ func TestCallbackInvokedWhenSetEarly(t *testing.T) { wg: wg, } _, c := setupClientServer(t, app) - reqRes, err := c.CheckTxAsync(ctx, &types.RequestCheckTx{}) + reqRes, err := c.CheckTxAsync(ctx, &types.RequestCheckTx{ + Type: types.CHECK_TX_TYPE_CHECK, + }) require.NoError(t, err) done := make(chan struct{}) diff --git a/abci/cmd/abci-cli/abci-cli.go b/abci/cmd/abci-cli/abci-cli.go index 55312a8e874..22679b47e36 100644 --- a/abci/cmd/abci-cli/abci-cli.go +++ b/abci/cmd/abci-cli/abci-cli.go @@ -578,7 +578,10 @@ func cmdCheckTx(cmd *cobra.Command, args []string) error { if err != nil { return err } - res, err := client.CheckTx(cmd.Context(), &types.RequestCheckTx{Tx: txBytes}) + res, err := client.CheckTx(cmd.Context(), &types.RequestCheckTx{ + Tx: txBytes, + Type: types.CHECK_TX_TYPE_CHECK, + }) if err != nil { return err } diff --git a/abci/example/kvstore/kvstore.go b/abci/example/kvstore/kvstore.go index 93db893154a..4b65921a822 100644 --- a/abci/example/kvstore/kvstore.go +++ b/abci/example/kvstore/kvstore.go @@ -169,7 +169,7 @@ func (app *Application) PrepareProposal(ctx context.Context, req *types.RequestP func (app *Application) formatTxs(ctx context.Context, blockData [][]byte) [][]byte { txs := make([][]byte, 0, len(blockData)) for _, tx := range blockData { - if resp, err := app.CheckTx(ctx, &types.RequestCheckTx{Tx: tx}); err == nil && resp.Code == CodeTypeOK { + if resp, err := app.CheckTx(ctx, &types.RequestCheckTx{Tx: tx, Type: types.CHECK_TX_TYPE_CHECK}); err == nil && resp.Code == CodeTypeOK { txs = append(txs, bytes.Replace(tx, []byte(":"), []byte("="), 1)) } } @@ -181,7 +181,7 @@ func (app *Application) formatTxs(ctx context.Context, blockData [][]byte) [][]b func (app *Application) ProcessProposal(ctx context.Context, req *types.RequestProcessProposal) (*types.ResponseProcessProposal, error) { for _, tx := range req.Txs { // As CheckTx is a full validity check we can simply reuse this - if resp, err := app.CheckTx(ctx, &types.RequestCheckTx{Tx: tx}); err != nil || resp.Code != CodeTypeOK { + if resp, err := app.CheckTx(ctx, &types.RequestCheckTx{Tx: tx, Type: types.CHECK_TX_TYPE_CHECK}); err != nil || resp.Code != CodeTypeOK { return &types.ResponseProcessProposal{Status: types.PROCESS_PROPOSAL_STATUS_REJECT}, nil } } diff --git a/abci/example/kvstore/kvstore_test.go b/abci/example/kvstore/kvstore_test.go index 60ef73fe1b8..ac076d6d49b 100644 --- a/abci/example/kvstore/kvstore_test.go +++ b/abci/example/kvstore/kvstore_test.go @@ -33,7 +33,7 @@ func TestKVStoreKV(t *testing.T) { } func testKVStore(ctx context.Context, t *testing.T, app types.Application, tx []byte, key, value string) { - checkTxResp, err := app.CheckTx(ctx, &types.RequestCheckTx{Tx: tx}) + checkTxResp, err := app.CheckTx(ctx, &types.RequestCheckTx{Tx: tx, Type: types.CHECK_TX_TYPE_CHECK}) require.NoError(t, err) require.Equal(t, uint32(0), checkTxResp.Code) @@ -83,7 +83,7 @@ func TestPersistentKVStoreEmptyTX(t *testing.T) { kvstore := NewPersistentApplication(t.TempDir()) tx := []byte("") - reqCheck := types.RequestCheckTx{Tx: tx} + reqCheck := types.RequestCheckTx{Tx: tx, Type: types.CHECK_TX_TYPE_CHECK} resCheck, err := kvstore.CheckTx(ctx, &reqCheck) require.NoError(t, err) require.Equal(t, resCheck.Code, CodeTypeInvalidTxFormat) @@ -224,7 +224,10 @@ func TestCheckTx(t *testing.T) { } for idx, tc := range testCases { - resp, err := kvstore.CheckTx(ctx, &types.RequestCheckTx{Tx: tc.tx}) + resp, err := kvstore.CheckTx(ctx, &types.RequestCheckTx{ + Tx: tc.tx, + Type: types.CHECK_TX_TYPE_CHECK, + }) require.NoError(t, err, idx) fmt.Println(string(tc.tx)) require.Equal(t, tc.expCode, resp.Code, idx) diff --git a/abci/tests/server/client.go b/abci/tests/server/client.go index 80d5334e7fc..66c5df95880 100644 --- a/abci/tests/server/client.go +++ b/abci/tests/server/client.go @@ -95,7 +95,7 @@ func ProcessProposal(ctx context.Context, client abcicli.Client, txBytes [][]byt } func CheckTx(ctx context.Context, client abcicli.Client, txBytes []byte, codeExp uint32, dataExp []byte) error { - res, _ := client.CheckTx(ctx, &types.RequestCheckTx{Tx: txBytes}) + res, _ := client.CheckTx(ctx, &types.RequestCheckTx{Tx: txBytes, Type: types.CHECK_TX_TYPE_CHECK}) code, data, log := res.Code, res.Data, res.Log if code != codeExp { fmt.Println("Failed test: CheckTx") diff --git a/abci/types/mocks/application.go b/abci/types/mocks/application.go index 86b30d2404c..1981d342633 100644 --- a/abci/types/mocks/application.go +++ b/abci/types/mocks/application.go @@ -5,8 +5,15 @@ package mocks import ( context "context" - types "github.com/cometbft/cometbft/abci/types" mock "github.com/stretchr/testify/mock" + + v1 "github.com/cometbft/cometbft/api/cometbft/abci/v1" + + v2 "github.com/cometbft/cometbft/api/cometbft/abci/v2" + + v3 "github.com/cometbft/cometbft/api/cometbft/abci/v3" + + v4 "github.com/cometbft/cometbft/api/cometbft/abci/v4" ) // Application is an autogenerated mock type for the Application type @@ -15,23 +22,23 @@ type Application struct { } // ApplySnapshotChunk provides a mock function with given fields: _a0, _a1 -func (_m *Application) ApplySnapshotChunk(_a0 context.Context, _a1 *types.RequestApplySnapshotChunk) (*types.ResponseApplySnapshotChunk, error) { +func (_m *Application) ApplySnapshotChunk(_a0 context.Context, _a1 *v1.RequestApplySnapshotChunk) (*v4.ResponseApplySnapshotChunk, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseApplySnapshotChunk + var r0 *v4.ResponseApplySnapshotChunk var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestApplySnapshotChunk) (*types.ResponseApplySnapshotChunk, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestApplySnapshotChunk) (*v4.ResponseApplySnapshotChunk, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestApplySnapshotChunk) *types.ResponseApplySnapshotChunk); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestApplySnapshotChunk) *v4.ResponseApplySnapshotChunk); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseApplySnapshotChunk) + r0 = ret.Get(0).(*v4.ResponseApplySnapshotChunk) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestApplySnapshotChunk) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestApplySnapshotChunk) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -41,23 +48,23 @@ func (_m *Application) ApplySnapshotChunk(_a0 context.Context, _a1 *types.Reques } // CheckTx provides a mock function with given fields: _a0, _a1 -func (_m *Application) CheckTx(_a0 context.Context, _a1 *types.RequestCheckTx) (*types.ResponseCheckTx, error) { +func (_m *Application) CheckTx(_a0 context.Context, _a1 *v4.RequestCheckTx) (*v3.ResponseCheckTx, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseCheckTx + var r0 *v3.ResponseCheckTx var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) (*types.ResponseCheckTx, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) (*v3.ResponseCheckTx, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) *types.ResponseCheckTx); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) *v3.ResponseCheckTx); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseCheckTx) + r0 = ret.Get(0).(*v3.ResponseCheckTx) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestCheckTx) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestCheckTx) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -67,23 +74,23 @@ func (_m *Application) CheckTx(_a0 context.Context, _a1 *types.RequestCheckTx) ( } // Commit provides a mock function with given fields: _a0, _a1 -func (_m *Application) Commit(_a0 context.Context, _a1 *types.RequestCommit) (*types.ResponseCommit, error) { +func (_m *Application) Commit(_a0 context.Context, _a1 *v1.RequestCommit) (*v3.ResponseCommit, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseCommit + var r0 *v3.ResponseCommit var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCommit) (*types.ResponseCommit, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestCommit) (*v3.ResponseCommit, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCommit) *types.ResponseCommit); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestCommit) *v3.ResponseCommit); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseCommit) + r0 = ret.Get(0).(*v3.ResponseCommit) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestCommit) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestCommit) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -93,23 +100,23 @@ func (_m *Application) Commit(_a0 context.Context, _a1 *types.RequestCommit) (*t } // ExtendVote provides a mock function with given fields: _a0, _a1 -func (_m *Application) ExtendVote(_a0 context.Context, _a1 *types.RequestExtendVote) (*types.ResponseExtendVote, error) { +func (_m *Application) ExtendVote(_a0 context.Context, _a1 *v4.RequestExtendVote) (*v3.ResponseExtendVote, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseExtendVote + var r0 *v3.ResponseExtendVote var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestExtendVote) (*types.ResponseExtendVote, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestExtendVote) (*v3.ResponseExtendVote, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestExtendVote) *types.ResponseExtendVote); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestExtendVote) *v3.ResponseExtendVote); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseExtendVote) + r0 = ret.Get(0).(*v3.ResponseExtendVote) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestExtendVote) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestExtendVote) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -119,23 +126,23 @@ func (_m *Application) ExtendVote(_a0 context.Context, _a1 *types.RequestExtendV } // FinalizeBlock provides a mock function with given fields: _a0, _a1 -func (_m *Application) FinalizeBlock(_a0 context.Context, _a1 *types.RequestFinalizeBlock) (*types.ResponseFinalizeBlock, error) { +func (_m *Application) FinalizeBlock(_a0 context.Context, _a1 *v4.RequestFinalizeBlock) (*v3.ResponseFinalizeBlock, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseFinalizeBlock + var r0 *v3.ResponseFinalizeBlock var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestFinalizeBlock) (*types.ResponseFinalizeBlock, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestFinalizeBlock) (*v3.ResponseFinalizeBlock, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestFinalizeBlock) *types.ResponseFinalizeBlock); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestFinalizeBlock) *v3.ResponseFinalizeBlock); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseFinalizeBlock) + r0 = ret.Get(0).(*v3.ResponseFinalizeBlock) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestFinalizeBlock) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestFinalizeBlock) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -145,23 +152,23 @@ func (_m *Application) FinalizeBlock(_a0 context.Context, _a1 *types.RequestFina } // Info provides a mock function with given fields: _a0, _a1 -func (_m *Application) Info(_a0 context.Context, _a1 *types.RequestInfo) (*types.ResponseInfo, error) { +func (_m *Application) Info(_a0 context.Context, _a1 *v2.RequestInfo) (*v1.ResponseInfo, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseInfo + var r0 *v1.ResponseInfo var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInfo) (*types.ResponseInfo, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v2.RequestInfo) (*v1.ResponseInfo, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInfo) *types.ResponseInfo); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v2.RequestInfo) *v1.ResponseInfo); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseInfo) + r0 = ret.Get(0).(*v1.ResponseInfo) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestInfo) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v2.RequestInfo) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -171,23 +178,23 @@ func (_m *Application) Info(_a0 context.Context, _a1 *types.RequestInfo) (*types } // InitChain provides a mock function with given fields: _a0, _a1 -func (_m *Application) InitChain(_a0 context.Context, _a1 *types.RequestInitChain) (*types.ResponseInitChain, error) { +func (_m *Application) InitChain(_a0 context.Context, _a1 *v3.RequestInitChain) (*v3.ResponseInitChain, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseInitChain + var r0 *v3.ResponseInitChain var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInitChain) (*types.ResponseInitChain, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestInitChain) (*v3.ResponseInitChain, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInitChain) *types.ResponseInitChain); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestInitChain) *v3.ResponseInitChain); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseInitChain) + r0 = ret.Get(0).(*v3.ResponseInitChain) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestInitChain) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v3.RequestInitChain) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -197,23 +204,23 @@ func (_m *Application) InitChain(_a0 context.Context, _a1 *types.RequestInitChai } // ListSnapshots provides a mock function with given fields: _a0, _a1 -func (_m *Application) ListSnapshots(_a0 context.Context, _a1 *types.RequestListSnapshots) (*types.ResponseListSnapshots, error) { +func (_m *Application) ListSnapshots(_a0 context.Context, _a1 *v1.RequestListSnapshots) (*v1.ResponseListSnapshots, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseListSnapshots + var r0 *v1.ResponseListSnapshots var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestListSnapshots) (*types.ResponseListSnapshots, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestListSnapshots) (*v1.ResponseListSnapshots, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestListSnapshots) *types.ResponseListSnapshots); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestListSnapshots) *v1.ResponseListSnapshots); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseListSnapshots) + r0 = ret.Get(0).(*v1.ResponseListSnapshots) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestListSnapshots) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestListSnapshots) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -223,23 +230,23 @@ func (_m *Application) ListSnapshots(_a0 context.Context, _a1 *types.RequestList } // LoadSnapshotChunk provides a mock function with given fields: _a0, _a1 -func (_m *Application) LoadSnapshotChunk(_a0 context.Context, _a1 *types.RequestLoadSnapshotChunk) (*types.ResponseLoadSnapshotChunk, error) { +func (_m *Application) LoadSnapshotChunk(_a0 context.Context, _a1 *v1.RequestLoadSnapshotChunk) (*v1.ResponseLoadSnapshotChunk, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseLoadSnapshotChunk + var r0 *v1.ResponseLoadSnapshotChunk var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestLoadSnapshotChunk) (*types.ResponseLoadSnapshotChunk, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestLoadSnapshotChunk) (*v1.ResponseLoadSnapshotChunk, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestLoadSnapshotChunk) *types.ResponseLoadSnapshotChunk); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestLoadSnapshotChunk) *v1.ResponseLoadSnapshotChunk); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseLoadSnapshotChunk) + r0 = ret.Get(0).(*v1.ResponseLoadSnapshotChunk) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestLoadSnapshotChunk) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestLoadSnapshotChunk) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -249,23 +256,23 @@ func (_m *Application) LoadSnapshotChunk(_a0 context.Context, _a1 *types.Request } // OfferSnapshot provides a mock function with given fields: _a0, _a1 -func (_m *Application) OfferSnapshot(_a0 context.Context, _a1 *types.RequestOfferSnapshot) (*types.ResponseOfferSnapshot, error) { +func (_m *Application) OfferSnapshot(_a0 context.Context, _a1 *v1.RequestOfferSnapshot) (*v4.ResponseOfferSnapshot, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseOfferSnapshot + var r0 *v4.ResponseOfferSnapshot var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestOfferSnapshot) (*types.ResponseOfferSnapshot, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestOfferSnapshot) (*v4.ResponseOfferSnapshot, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestOfferSnapshot) *types.ResponseOfferSnapshot); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestOfferSnapshot) *v4.ResponseOfferSnapshot); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseOfferSnapshot) + r0 = ret.Get(0).(*v4.ResponseOfferSnapshot) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestOfferSnapshot) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestOfferSnapshot) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -275,23 +282,23 @@ func (_m *Application) OfferSnapshot(_a0 context.Context, _a1 *types.RequestOffe } // PrepareProposal provides a mock function with given fields: _a0, _a1 -func (_m *Application) PrepareProposal(_a0 context.Context, _a1 *types.RequestPrepareProposal) (*types.ResponsePrepareProposal, error) { +func (_m *Application) PrepareProposal(_a0 context.Context, _a1 *v4.RequestPrepareProposal) (*v2.ResponsePrepareProposal, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponsePrepareProposal + var r0 *v2.ResponsePrepareProposal var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestPrepareProposal) (*types.ResponsePrepareProposal, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestPrepareProposal) (*v2.ResponsePrepareProposal, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestPrepareProposal) *types.ResponsePrepareProposal); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestPrepareProposal) *v2.ResponsePrepareProposal); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponsePrepareProposal) + r0 = ret.Get(0).(*v2.ResponsePrepareProposal) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestPrepareProposal) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestPrepareProposal) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -301,23 +308,23 @@ func (_m *Application) PrepareProposal(_a0 context.Context, _a1 *types.RequestPr } // ProcessProposal provides a mock function with given fields: _a0, _a1 -func (_m *Application) ProcessProposal(_a0 context.Context, _a1 *types.RequestProcessProposal) (*types.ResponseProcessProposal, error) { +func (_m *Application) ProcessProposal(_a0 context.Context, _a1 *v4.RequestProcessProposal) (*v4.ResponseProcessProposal, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseProcessProposal + var r0 *v4.ResponseProcessProposal var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestProcessProposal) (*types.ResponseProcessProposal, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestProcessProposal) (*v4.ResponseProcessProposal, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestProcessProposal) *types.ResponseProcessProposal); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestProcessProposal) *v4.ResponseProcessProposal); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseProcessProposal) + r0 = ret.Get(0).(*v4.ResponseProcessProposal) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestProcessProposal) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestProcessProposal) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -327,23 +334,23 @@ func (_m *Application) ProcessProposal(_a0 context.Context, _a1 *types.RequestPr } // Query provides a mock function with given fields: _a0, _a1 -func (_m *Application) Query(_a0 context.Context, _a1 *types.RequestQuery) (*types.ResponseQuery, error) { +func (_m *Application) Query(_a0 context.Context, _a1 *v1.RequestQuery) (*v1.ResponseQuery, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseQuery + var r0 *v1.ResponseQuery var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestQuery) (*types.ResponseQuery, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestQuery) (*v1.ResponseQuery, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestQuery) *types.ResponseQuery); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestQuery) *v1.ResponseQuery); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseQuery) + r0 = ret.Get(0).(*v1.ResponseQuery) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestQuery) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestQuery) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -353,23 +360,23 @@ func (_m *Application) Query(_a0 context.Context, _a1 *types.RequestQuery) (*typ } // VerifyVoteExtension provides a mock function with given fields: _a0, _a1 -func (_m *Application) VerifyVoteExtension(_a0 context.Context, _a1 *types.RequestVerifyVoteExtension) (*types.ResponseVerifyVoteExtension, error) { +func (_m *Application) VerifyVoteExtension(_a0 context.Context, _a1 *v3.RequestVerifyVoteExtension) (*v4.ResponseVerifyVoteExtension, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseVerifyVoteExtension + var r0 *v4.ResponseVerifyVoteExtension var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestVerifyVoteExtension) (*types.ResponseVerifyVoteExtension, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestVerifyVoteExtension) (*v4.ResponseVerifyVoteExtension, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestVerifyVoteExtension) *types.ResponseVerifyVoteExtension); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestVerifyVoteExtension) *v4.ResponseVerifyVoteExtension); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseVerifyVoteExtension) + r0 = ret.Get(0).(*v4.ResponseVerifyVoteExtension) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestVerifyVoteExtension) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v3.RequestVerifyVoteExtension) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) diff --git a/abci/types/types.go b/abci/types/types.go index a1d26828d53..b00f692b50c 100644 --- a/abci/types/types.go +++ b/abci/types/types.go @@ -12,95 +12,107 @@ import ( v4 "github.com/cometbft/cometbft/api/cometbft/abci/v4" ) -type Request = v4.Request -type RequestEcho = v1.RequestEcho -type RequestFlush = v1.RequestFlush -type RequestInfo = v2.RequestInfo -type RequestInitChain = v3.RequestInitChain -type RequestQuery = v1.RequestQuery -type RequestCheckTx = v4.RequestCheckTx -type RequestCommit = v1.RequestCommit -type RequestListSnapshots = v1.RequestListSnapshots -type RequestOfferSnapshot = v1.RequestOfferSnapshot -type RequestLoadSnapshotChunk = v1.RequestLoadSnapshotChunk -type RequestApplySnapshotChunk = v1.RequestApplySnapshotChunk -type RequestPrepareProposal = v4.RequestPrepareProposal -type RequestProcessProposal = v4.RequestProcessProposal -type RequestExtendVote = v3.RequestExtendVote -type RequestVerifyVoteExtension = v3.RequestVerifyVoteExtension -type RequestFinalizeBlock = v4.RequestFinalizeBlock +type ( + Request = v4.Request + RequestEcho = v1.RequestEcho + RequestFlush = v1.RequestFlush + RequestInfo = v2.RequestInfo + RequestInitChain = v3.RequestInitChain + RequestQuery = v1.RequestQuery + RequestCheckTx = v4.RequestCheckTx + RequestCommit = v1.RequestCommit + RequestListSnapshots = v1.RequestListSnapshots + RequestOfferSnapshot = v1.RequestOfferSnapshot + RequestLoadSnapshotChunk = v1.RequestLoadSnapshotChunk + RequestApplySnapshotChunk = v1.RequestApplySnapshotChunk + RequestPrepareProposal = v4.RequestPrepareProposal + RequestProcessProposal = v4.RequestProcessProposal + RequestExtendVote = v4.RequestExtendVote + RequestVerifyVoteExtension = v3.RequestVerifyVoteExtension + RequestFinalizeBlock = v4.RequestFinalizeBlock +) // Discriminated Request variants are defined in the latest proto package. -type Request_Echo = v4.Request_Echo -type Request_Flush = v4.Request_Flush -type Request_Info = v4.Request_Info -type Request_InitChain = v4.Request_InitChain -type Request_Query = v4.Request_Query -type Request_CheckTx = v4.Request_CheckTx -type Request_Commit = v4.Request_Commit -type Request_ListSnapshots = v4.Request_ListSnapshots -type Request_OfferSnapshot = v4.Request_OfferSnapshot -type Request_LoadSnapshotChunk = v4.Request_LoadSnapshotChunk -type Request_ApplySnapshotChunk = v4.Request_ApplySnapshotChunk -type Request_PrepareProposal = v4.Request_PrepareProposal -type Request_ProcessProposal = v4.Request_ProcessProposal -type Request_ExtendVote = v4.Request_ExtendVote -type Request_VerifyVoteExtension = v4.Request_VerifyVoteExtension -type Request_FinalizeBlock = v4.Request_FinalizeBlock - -type Response = v4.Response -type ResponseException = v1.ResponseException -type ResponseEcho = v1.ResponseEcho -type ResponseFlush = v1.ResponseFlush -type ResponseInfo = v1.ResponseInfo -type ResponseInitChain = v3.ResponseInitChain -type ResponseQuery = v1.ResponseQuery -type ResponseCheckTx = v3.ResponseCheckTx -type ResponseCommit = v3.ResponseCommit -type ResponseListSnapshots = v1.ResponseListSnapshots -type ResponseOfferSnapshot = v4.ResponseOfferSnapshot -type ResponseLoadSnapshotChunk = v1.ResponseLoadSnapshotChunk -type ResponseApplySnapshotChunk = v4.ResponseApplySnapshotChunk -type ResponsePrepareProposal = v2.ResponsePrepareProposal -type ResponseProcessProposal = v4.ResponseProcessProposal -type ResponseExtendVote = v3.ResponseExtendVote -type ResponseVerifyVoteExtension = v4.ResponseVerifyVoteExtension -type ResponseFinalizeBlock = v3.ResponseFinalizeBlock +type ( + Request_Echo = v4.Request_Echo + Request_Flush = v4.Request_Flush + Request_Info = v4.Request_Info + Request_InitChain = v4.Request_InitChain + Request_Query = v4.Request_Query + Request_CheckTx = v4.Request_CheckTx + Request_Commit = v4.Request_Commit + Request_ListSnapshots = v4.Request_ListSnapshots + Request_OfferSnapshot = v4.Request_OfferSnapshot + Request_LoadSnapshotChunk = v4.Request_LoadSnapshotChunk + Request_ApplySnapshotChunk = v4.Request_ApplySnapshotChunk + Request_PrepareProposal = v4.Request_PrepareProposal + Request_ProcessProposal = v4.Request_ProcessProposal + Request_ExtendVote = v4.Request_ExtendVote + Request_VerifyVoteExtension = v4.Request_VerifyVoteExtension + Request_FinalizeBlock = v4.Request_FinalizeBlock +) + +type ( + Response = v4.Response + ResponseException = v1.ResponseException + ResponseEcho = v1.ResponseEcho + ResponseFlush = v1.ResponseFlush + ResponseInfo = v1.ResponseInfo + ResponseInitChain = v3.ResponseInitChain + ResponseQuery = v1.ResponseQuery + ResponseCheckTx = v3.ResponseCheckTx + ResponseCommit = v3.ResponseCommit + ResponseListSnapshots = v1.ResponseListSnapshots + ResponseOfferSnapshot = v4.ResponseOfferSnapshot + ResponseLoadSnapshotChunk = v1.ResponseLoadSnapshotChunk + ResponseApplySnapshotChunk = v4.ResponseApplySnapshotChunk + ResponsePrepareProposal = v2.ResponsePrepareProposal + ResponseProcessProposal = v4.ResponseProcessProposal + ResponseExtendVote = v3.ResponseExtendVote + ResponseVerifyVoteExtension = v4.ResponseVerifyVoteExtension + ResponseFinalizeBlock = v3.ResponseFinalizeBlock +) // Discriminated Response variants are defined in the latest proto package. -type Response_Exception = v4.Response_Exception -type Response_Echo = v4.Response_Echo -type Response_Flush = v4.Response_Flush -type Response_Info = v4.Response_Info -type Response_InitChain = v4.Response_InitChain -type Response_Query = v4.Response_Query -type Response_CheckTx = v4.Response_CheckTx -type Response_Commit = v4.Response_Commit -type Response_ListSnapshots = v4.Response_ListSnapshots -type Response_OfferSnapshot = v4.Response_OfferSnapshot -type Response_LoadSnapshotChunk = v4.Response_LoadSnapshotChunk -type Response_ApplySnapshotChunk = v4.Response_ApplySnapshotChunk -type Response_PrepareProposal = v4.Response_PrepareProposal -type Response_ProcessProposal = v4.Response_ProcessProposal -type Response_ExtendVote = v4.Response_ExtendVote -type Response_VerifyVoteExtension = v4.Response_VerifyVoteExtension -type Response_FinalizeBlock = v4.Response_FinalizeBlock - -type CommitInfo = v3.CommitInfo -type ExecTxResult = v3.ExecTxResult -type ExtendedCommitInfo = v3.ExtendedCommitInfo -type ExtendedVoteInfo = v3.ExtendedVoteInfo -type Event = v2.Event -type EventAttribute = v2.EventAttribute -type Misbehavior = v4.Misbehavior -type Snapshot = v1.Snapshot -type TxResult = v3.TxResult -type Validator = v1.Validator -type ValidatorUpdate = v1.ValidatorUpdate -type VoteInfo = v3.VoteInfo - -type ABCIClient = v4.ABCIClient -type ABCIServer = v4.ABCIServer +type ( + Response_Exception = v4.Response_Exception + Response_Echo = v4.Response_Echo + Response_Flush = v4.Response_Flush + Response_Info = v4.Response_Info + Response_InitChain = v4.Response_InitChain + Response_Query = v4.Response_Query + Response_CheckTx = v4.Response_CheckTx + Response_Commit = v4.Response_Commit + Response_ListSnapshots = v4.Response_ListSnapshots + Response_OfferSnapshot = v4.Response_OfferSnapshot + Response_LoadSnapshotChunk = v4.Response_LoadSnapshotChunk + Response_ApplySnapshotChunk = v4.Response_ApplySnapshotChunk + Response_PrepareProposal = v4.Response_PrepareProposal + Response_ProcessProposal = v4.Response_ProcessProposal + Response_ExtendVote = v4.Response_ExtendVote + Response_VerifyVoteExtension = v4.Response_VerifyVoteExtension + Response_FinalizeBlock = v4.Response_FinalizeBlock +) + +type ( + CommitInfo = v3.CommitInfo + ExecTxResult = v3.ExecTxResult + ExtendedCommitInfo = v3.ExtendedCommitInfo + ExtendedVoteInfo = v3.ExtendedVoteInfo + Event = v2.Event + EventAttribute = v2.EventAttribute + Misbehavior = v4.Misbehavior + Snapshot = v1.Snapshot + TxResult = v3.TxResult + Validator = v1.Validator + ValidatorUpdate = v1.ValidatorUpdate + VoteInfo = v3.VoteInfo +) + +type ( + ABCIClient = v4.ABCIClient + ABCIServer = v4.ABCIServer +) func NewABCIClient(cc grpc.ClientConn) ABCIClient { return v4.NewABCIClient(cc) @@ -178,10 +190,12 @@ type jsonRoundTripper interface { json.Unmarshaler } -var _ jsonRoundTripper = (*ResponseCommit)(nil) -var _ jsonRoundTripper = (*ResponseQuery)(nil) -var _ jsonRoundTripper = (*ExecTxResult)(nil) -var _ jsonRoundTripper = (*ResponseCheckTx)(nil) +var ( + _ jsonRoundTripper = (*ResponseCommit)(nil) + _ jsonRoundTripper = (*ResponseQuery)(nil) + _ jsonRoundTripper = (*ExecTxResult)(nil) + _ jsonRoundTripper = (*ResponseCheckTx)(nil) +) var _ jsonRoundTripper = (*EventAttribute)(nil) diff --git a/api/cometbft/abci/v3/types.pb.go b/api/cometbft/abci/v3/types.pb.go index 0a550d56f07..09295fb829d 100644 --- a/api/cometbft/abci/v3/types.pb.go +++ b/api/cometbft/abci/v3/types.pb.go @@ -627,10 +627,18 @@ func (m *RequestProcessProposal) GetProposerAddress() []byte { // Extends a vote with application-injected data type RequestExtendVote struct { - // the hash of the block that this vote may be referring to + // the hash of the block that this vote may be referring to Hash []byte `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"` // the height of the extended vote Height int64 `protobuf:"varint,2,opt,name=height,proto3" json:"height,omitempty"` + // info of the block that this vote may be referring to + Time time.Time `protobuf:"bytes,3,opt,name=time,proto3,stdtime" json:"time"` + Txs [][]byte `protobuf:"bytes,4,rep,name=txs,proto3" json:"txs,omitempty"` + ProposedLastCommit CommitInfo `protobuf:"bytes,5,opt,name=proposed_last_commit,json=proposedLastCommit,proto3" json:"proposed_last_commit"` + Misbehavior []v2.Misbehavior `protobuf:"bytes,6,rep,name=misbehavior,proto3" json:"misbehavior"` + NextValidatorsHash []byte `protobuf:"bytes,7,opt,name=next_validators_hash,json=nextValidatorsHash,proto3" json:"next_validators_hash,omitempty"` + // address of the public key of the original proposer of the block. + ProposerAddress []byte `protobuf:"bytes,8,opt,name=proposer_address,json=proposerAddress,proto3" json:"proposer_address,omitempty"` } func (m *RequestExtendVote) Reset() { *m = RequestExtendVote{} } @@ -680,6 +688,48 @@ func (m *RequestExtendVote) GetHeight() int64 { return 0 } +func (m *RequestExtendVote) GetTime() time.Time { + if m != nil { + return m.Time + } + return time.Time{} +} + +func (m *RequestExtendVote) GetTxs() [][]byte { + if m != nil { + return m.Txs + } + return nil +} + +func (m *RequestExtendVote) GetProposedLastCommit() CommitInfo { + if m != nil { + return m.ProposedLastCommit + } + return CommitInfo{} +} + +func (m *RequestExtendVote) GetMisbehavior() []v2.Misbehavior { + if m != nil { + return m.Misbehavior + } + return nil +} + +func (m *RequestExtendVote) GetNextValidatorsHash() []byte { + if m != nil { + return m.NextValidatorsHash + } + return nil +} + +func (m *RequestExtendVote) GetProposerAddress() []byte { + if m != nil { + return m.ProposerAddress + } + return nil +} + // Verify the vote extension type RequestVerifyVoteExtension struct { // the hash of the block that this received vote corresponds to @@ -1429,7 +1479,7 @@ type ResponseFinalizeBlock struct { // set of block events emmitted as part of executing the block Events []v2.Event `protobuf:"bytes,1,rep,name=events,proto3" json:"events,omitempty"` // the result of executing each transaction including the events - // the particular transction emitted. This should match the order + // the particular transaction emitted. This should match the order // of the transactions delivered in the block itself TxResults []*ExecTxResult `protobuf:"bytes,2,rep,name=tx_results,json=txResults,proto3" json:"tx_results,omitempty"` // a list of updates to the validator set. These will reflect the validator set at current height + 2. @@ -1945,145 +1995,147 @@ func init() { func init() { proto.RegisterFile("cometbft/abci/v3/types.proto", fileDescriptor_28d3e1944f7831e9) } var fileDescriptor_28d3e1944f7831e9 = []byte{ - // 2203 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x5a, 0xcd, 0x73, 0xdb, 0xc6, - 0x15, 0x27, 0xf8, 0x25, 0xf2, 0x89, 0x94, 0xa0, 0x95, 0x9c, 0x30, 0x88, 0x2b, 0xdb, 0x4c, 0x93, - 0x3a, 0x4d, 0x4a, 0xd5, 0x52, 0x26, 0x69, 0xd3, 0x26, 0x19, 0x4b, 0xa1, 0x43, 0xc9, 0x89, 0xad, - 0xc2, 0xb2, 0x32, 0xe3, 0x69, 0x07, 0x59, 0x01, 0x4b, 0x12, 0x35, 0x48, 0x20, 0xc0, 0x92, 0xa5, - 0x7a, 0xeb, 0x25, 0x87, 0x9e, 0x72, 0xe9, 0xa5, 0xd3, 0x6b, 0x7b, 0xe9, 0xdf, 0xd0, 0x6b, 0x27, - 0xa7, 0x36, 0xc7, 0x9e, 0xd2, 0x8e, 0x7d, 0xeb, 0xa1, 0xb7, 0xde, 0x3b, 0xbb, 0x58, 0x80, 0x00, - 0x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 0xfe, 0xbf, 0x1f, 0x4b, 0xff, 0xab, 0xe9, 0x79, 0x4f, 0x60, 0x9b, 0x98, 0xff, 0xbf, 0x15, 0xe4, - 0xff, 0x2b, 0x59, 0x93, 0x5e, 0x20, 0x00, 0xef, 0x46, 0x08, 0x40, 0x9d, 0xdb, 0xde, 0x48, 0x1f, - 0x3c, 0x81, 0x01, 0xbc, 0x1d, 0x32, 0x80, 0x46, 0x32, 0x7d, 0x88, 0x58, 0x2f, 0x52, 0x80, 0xe3, - 0x25, 0x0a, 0xe0, 0x67, 0xec, 0xdf, 0x49, 0x9f, 0x7d, 0x06, 0x07, 0x38, 0x5e, 0xe2, 0x00, 0x6b, - 0x59, 0x88, 0x19, 0x24, 0xe0, 0x67, 0xc9, 0x24, 0xe0, 0x82, 0x2c, 0x5d, 0x4c, 0x34, 0x1f, 0x0b, - 0xf8, 0x24, 0x85, 0x05, 0xc8, 0xc9, 0xd9, 0xea, 0x1c, 0x3f, 0x37, 0x0d, 0x38, 0x4d, 0xa0, 0x01, - 0x7e, 0xbe, 0xfe, 0x6a, 0x12, 0x3f, 0xf5, 0xd1, 0x73, 0xf0, 0x80, 0xd3, 0x04, 0x1e, 0x80, 0xb2, - 0x71, 0x33, 0x89, 0xc0, 0x07, 0x71, 0x22, 0xb0, 0x99, 0x96, 0x44, 0xcd, 0xef, 0x7e, 0x0a, 0x13, - 0xd0, 0xd3, 0x98, 0x80, 0x9f, 0xac, 0x7f, 0x2f, 0x1d, 0xf2, 0x12, 0x54, 0xe0, 0x78, 0x89, 0x0a, - 0x5c, 0x49, 0x76, 0xb8, 0x39, 0x7a, 0x7e, 0x2e, 0x50, 0x91, 0xab, 0x47, 0xe5, 0x5a, 0x4d, 0xae, - 0xfb, 0x2c, 0xe0, 0xa8, 0x5c, 0x5b, 0x95, 0x1b, 0xed, 0x3f, 0x4b, 0xec, 0x45, 0x5e, 0x88, 0x06, - 0x89, 0x79, 0xbb, 0xf4, 0x75, 0xe5, 0xed, 0xc5, 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, 0x8e, 0xe8, 0x63, 0x80, 0x48, 0x12, 0x9b, 0xa7, 0x52, 0xa4, 0xe4, 0x62, 0x91, 0xc8, - 0x85, 0xcd, 0xa4, 0xfc, 0xf6, 0x52, 0x95, 0x23, 0xe5, 0x72, 0xec, 0x92, 0x79, 0x77, 0x3c, 0x55, - 0xcd, 0x59, 0x4a, 0x52, 0xf2, 0xf2, 0xcc, 0xfd, 0xbb, 0x5f, 0x3c, 0xd9, 0x96, 0xbe, 0x7c, 0xb2, - 0x2d, 0xfd, 0xe3, 0xc9, 0xb6, 0xf4, 0xf9, 0xd3, 0xed, 0xc2, 0x97, 0x4f, 0xb7, 0x0b, 0x7f, 0x7b, - 0xba, 0x5d, 0x78, 0x74, 0x6b, 0x60, 0xd2, 0xe1, 0xe4, 0x8c, 0x01, 0xed, 0x84, 0x25, 0xf9, 0x79, - 0x65, 0xdf, 0x31, 0x77, 0x16, 0xff, 0x34, 0x70, 0x56, 0xe5, 0xbf, 0x15, 0xee, 0xfd, 0x27, 0x00, - 0x00, 0xff, 0xff, 0x72, 0x8d, 0xdd, 0x11, 0x4f, 0x20, 0x00, 0x00, + // 2225 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x9a, 0x4f, 0x73, 0xdb, 0xc6, + 0x15, 0xc0, 0x09, 0x12, 0xa4, 0xc8, 0x27, 0x52, 0x82, 0x56, 0x72, 0xc2, 0x20, 0xa9, 0x6c, 0x33, + 0x4d, 0xea, 0x34, 0x29, 0x55, 0x4b, 0x99, 0xa4, 0x4d, 0x9b, 0x74, 0x2c, 0x45, 0x0e, 0x25, 0x27, + 0xb6, 0x0a, 0xcb, 0xca, 0x8c, 0xa7, 0x1d, 0x64, 0x05, 0x2c, 0x45, 0xd4, 0x20, 0x81, 0x00, 0x4b, + 0x96, 0xea, 0xad, 0x87, 0xe6, 0xd0, 0x53, 0x2e, 0xbd, 0x74, 0x7a, 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 0x45, 0x3f, 0x64, 0xc3, 0xda, 0x02, 0xb4, 0xa1, 0x4b, 0xbc, 0x96, 0xa9, + 0x97, 0xa1, 0x41, 0xe4, 0x00, 0x5a, 0x44, 0x38, 0x74, 0x99, 0xd7, 0x33, 0xf5, 0x52, 0x74, 0x88, + 0xfa, 0xb0, 0x3a, 0xff, 0x60, 0x50, 0xf8, 0x39, 0x4d, 0x2d, 0x8e, 0x8a, 0x41, 0x3b, 0x49, 0xa4, + 0x2b, 0xfc, 0xbe, 0xa6, 0x16, 0x47, 0x47, 0xf4, 0x31, 0x40, 0xec, 0x12, 0x5b, 0xe4, 0xc1, 0x4d, + 0x2d, 0x44, 0x91, 0xc8, 0x83, 0xf5, 0xb4, 0xfb, 0xed, 0xa5, 0x1e, 0xe0, 0xd4, 0xcb, 0xd1, 0x25, + 0x8b, 0xee, 0xe4, 0x55, 0xb5, 0xe0, 0x8b, 0x9c, 0x5a, 0x94, 0x33, 0x77, 0xef, 0x7c, 0xf1, 0x78, + 0x53, 0xfa, 0xf2, 0xf1, 0xa6, 0xf4, 0xb7, 0xc7, 0x9b, 0xd2, 0xe7, 0x4f, 0x36, 0x4b, 0x5f, 0x3e, + 0xd9, 0x2c, 0xfd, 0xe5, 0xc9, 0x66, 0xe9, 0xe1, 0xcd, 0x33, 0x8b, 0x0e, 0xc6, 0xa7, 0xcc, 0xd1, + 0x56, 0xf4, 0xcf, 0x86, 0xd9, 0x1f, 0x24, 0x5c, 0x6b, 0x6b, 0xfe, 0xbf, 0x17, 0xa7, 0x35, 0xfe, + 0x5b, 0xe1, 0xce, 0xbf, 0x02, 0x00, 0x00, 0xff, 0xff, 0x42, 0x00, 0xeb, 0x64, 0x96, 0x21, 0x00, + 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -3358,6 +3410,61 @@ func (m *RequestExtendVote) MarshalToSizedBuffer(dAtA []byte) (int, error) { _ = i var l int _ = l + if len(m.ProposerAddress) > 0 { + i -= len(m.ProposerAddress) + copy(dAtA[i:], m.ProposerAddress) + i = encodeVarintTypes(dAtA, i, uint64(len(m.ProposerAddress))) + i-- + dAtA[i] = 0x42 + } + if len(m.NextValidatorsHash) > 0 { + i -= len(m.NextValidatorsHash) + copy(dAtA[i:], m.NextValidatorsHash) + i = encodeVarintTypes(dAtA, i, uint64(len(m.NextValidatorsHash))) + i-- + dAtA[i] = 0x3a + } + if len(m.Misbehavior) > 0 { + for iNdEx := len(m.Misbehavior) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Misbehavior[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTypes(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x32 + } + } + { + size, err := m.ProposedLastCommit.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTypes(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x2a + if len(m.Txs) > 0 { + for iNdEx := len(m.Txs) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Txs[iNdEx]) + copy(dAtA[i:], m.Txs[iNdEx]) + i = encodeVarintTypes(dAtA, i, uint64(len(m.Txs[iNdEx]))) + i-- + dAtA[i] = 0x22 + } + } + n24, err24 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time):]) + if err24 != nil { + return 0, err24 + } + i -= n24 + i = encodeVarintTypes(dAtA, i, uint64(n24)) + i-- + dAtA[i] = 0x1a if m.Height != 0 { i = encodeVarintTypes(dAtA, i, uint64(m.Height)) i-- @@ -3456,12 +3563,12 @@ func (m *RequestFinalizeBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) { i-- dAtA[i] = 0x3a } - n23, err23 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time):]) - if err23 != nil { - return 0, err23 + n25, err25 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time):]) + if err25 != nil { + return 0, err25 } - i -= n23 - i = encodeVarintTypes(dAtA, i, uint64(n23)) + i -= n25 + i = encodeVarintTypes(dAtA, i, uint64(n25)) i-- dAtA[i] = 0x32 if m.Height != 0 { @@ -4862,6 +4969,30 @@ func (m *RequestExtendVote) Size() (n int) { if m.Height != 0 { n += 1 + sovTypes(uint64(m.Height)) } + l = github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time) + n += 1 + l + sovTypes(uint64(l)) + if len(m.Txs) > 0 { + for _, b := range m.Txs { + l = len(b) + n += 1 + l + sovTypes(uint64(l)) + } + } + l = m.ProposedLastCommit.Size() + n += 1 + l + sovTypes(uint64(l)) + if len(m.Misbehavior) > 0 { + for _, e := range m.Misbehavior { + l = e.Size() + n += 1 + l + sovTypes(uint64(l)) + } + } + l = len(m.NextValidatorsHash) + if l > 0 { + n += 1 + l + sovTypes(uint64(l)) + } + l = len(m.ProposerAddress) + if l > 0 { + n += 1 + l + sovTypes(uint64(l)) + } return n } @@ -6940,6 +7071,206 @@ func (m *RequestExtendVote) Unmarshal(dAtA []byte) error { break } } + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Time", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(&m.Time, dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Txs", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Txs = append(m.Txs, make([]byte, postIndex-iNdEx)) + copy(m.Txs[len(m.Txs)-1], dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ProposedLastCommit", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ProposedLastCommit.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Misbehavior", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Misbehavior = append(m.Misbehavior, v2.Misbehavior{}) + if err := m.Misbehavior[len(m.Misbehavior)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field NextValidatorsHash", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.NextValidatorsHash = append(m.NextValidatorsHash[:0], dAtA[iNdEx:postIndex]...) + if m.NextValidatorsHash == nil { + m.NextValidatorsHash = []byte{} + } + iNdEx = postIndex + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ProposerAddress", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ProposerAddress = append(m.ProposerAddress[:0], dAtA[iNdEx:postIndex]...) + if m.ProposerAddress == nil { + m.ProposerAddress = []byte{} + } + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) diff --git a/api/cometbft/abci/v4/types.pb.go b/api/cometbft/abci/v4/types.pb.go index 0e61a118c20..56a4da983e8 100644 --- a/api/cometbft/abci/v4/types.pb.go +++ b/api/cometbft/abci/v4/types.pb.go @@ -44,20 +44,20 @@ type CheckTxType int32 const ( CHECK_TX_TYPE_UNKNOWN CheckTxType = 0 - CHECK_TX_TYPE_CHECK CheckTxType = 2 CHECK_TX_TYPE_RECHECK CheckTxType = 1 + CHECK_TX_TYPE_CHECK CheckTxType = 2 ) var CheckTxType_name = map[int32]string{ 0: "CHECK_TX_TYPE_UNKNOWN", - 2: "CHECK_TX_TYPE_CHECK", 1: "CHECK_TX_TYPE_RECHECK", + 2: "CHECK_TX_TYPE_CHECK", } var CheckTxType_value = map[string]int32{ "CHECK_TX_TYPE_UNKNOWN": 0, - "CHECK_TX_TYPE_CHECK": 2, "CHECK_TX_TYPE_RECHECK": 1, + "CHECK_TX_TYPE_CHECK": 2, } func (x CheckTxType) String() string { @@ -330,7 +330,7 @@ type Request_ProcessProposal struct { ProcessProposal *RequestProcessProposal `protobuf:"bytes,17,opt,name=process_proposal,json=processProposal,proto3,oneof" json:"process_proposal,omitempty"` } type Request_ExtendVote struct { - ExtendVote *v3.RequestExtendVote `protobuf:"bytes,18,opt,name=extend_vote,json=extendVote,proto3,oneof" json:"extend_vote,omitempty"` + ExtendVote *RequestExtendVote `protobuf:"bytes,18,opt,name=extend_vote,json=extendVote,proto3,oneof" json:"extend_vote,omitempty"` } type Request_VerifyVoteExtension struct { VerifyVoteExtension *v3.RequestVerifyVoteExtension `protobuf:"bytes,19,opt,name=verify_vote_extension,json=verifyVoteExtension,proto3,oneof" json:"verify_vote_extension,omitempty"` @@ -454,7 +454,7 @@ func (m *Request) GetProcessProposal() *RequestProcessProposal { return nil } -func (m *Request) GetExtendVote() *v3.RequestExtendVote { +func (m *Request) GetExtendVote() *RequestExtendVote { if x, ok := m.GetValue().(*Request_ExtendVote); ok { return x.ExtendVote } @@ -755,6 +755,111 @@ func (m *RequestProcessProposal) GetProposerAddress() []byte { return nil } +// Extends a vote with application-injected data +type RequestExtendVote struct { + // the hash of the block that this vote may be referring to + Hash []byte `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"` + // the height of the extended vote + Height int64 `protobuf:"varint,2,opt,name=height,proto3" json:"height,omitempty"` + // info of the block that this vote may be referring to + Time time.Time `protobuf:"bytes,3,opt,name=time,proto3,stdtime" json:"time"` + Txs [][]byte `protobuf:"bytes,4,rep,name=txs,proto3" json:"txs,omitempty"` + ProposedLastCommit v3.CommitInfo `protobuf:"bytes,5,opt,name=proposed_last_commit,json=proposedLastCommit,proto3" json:"proposed_last_commit"` + Misbehavior []Misbehavior `protobuf:"bytes,6,rep,name=misbehavior,proto3" json:"misbehavior"` + NextValidatorsHash []byte `protobuf:"bytes,7,opt,name=next_validators_hash,json=nextValidatorsHash,proto3" json:"next_validators_hash,omitempty"` + // address of the public key of the original proposer of the block. + ProposerAddress []byte `protobuf:"bytes,8,opt,name=proposer_address,json=proposerAddress,proto3" json:"proposer_address,omitempty"` +} + +func (m *RequestExtendVote) Reset() { *m = RequestExtendVote{} } +func (m *RequestExtendVote) String() string { return proto.CompactTextString(m) } +func (*RequestExtendVote) ProtoMessage() {} +func (*RequestExtendVote) Descriptor() ([]byte, []int) { + return fileDescriptor_4f8c051f33f91260, []int{4} +} +func (m *RequestExtendVote) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *RequestExtendVote) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_RequestExtendVote.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *RequestExtendVote) XXX_Merge(src proto.Message) { + xxx_messageInfo_RequestExtendVote.Merge(m, src) +} +func (m *RequestExtendVote) XXX_Size() int { + return m.Size() +} +func (m *RequestExtendVote) XXX_DiscardUnknown() { + xxx_messageInfo_RequestExtendVote.DiscardUnknown(m) +} + +var xxx_messageInfo_RequestExtendVote proto.InternalMessageInfo + +func (m *RequestExtendVote) GetHash() []byte { + if m != nil { + return m.Hash + } + return nil +} + +func (m *RequestExtendVote) GetHeight() int64 { + if m != nil { + return m.Height + } + return 0 +} + +func (m *RequestExtendVote) GetTime() time.Time { + if m != nil { + return m.Time + } + return time.Time{} +} + +func (m *RequestExtendVote) GetTxs() [][]byte { + if m != nil { + return m.Txs + } + return nil +} + +func (m *RequestExtendVote) GetProposedLastCommit() v3.CommitInfo { + if m != nil { + return m.ProposedLastCommit + } + return v3.CommitInfo{} +} + +func (m *RequestExtendVote) GetMisbehavior() []Misbehavior { + if m != nil { + return m.Misbehavior + } + return nil +} + +func (m *RequestExtendVote) GetNextValidatorsHash() []byte { + if m != nil { + return m.NextValidatorsHash + } + return nil +} + +func (m *RequestExtendVote) GetProposerAddress() []byte { + if m != nil { + return m.ProposerAddress + } + return nil +} + type RequestFinalizeBlock struct { Txs [][]byte `protobuf:"bytes,1,rep,name=txs,proto3" json:"txs,omitempty"` DecidedLastCommit v3.CommitInfo `protobuf:"bytes,2,opt,name=decided_last_commit,json=decidedLastCommit,proto3" json:"decided_last_commit"` @@ -772,7 +877,7 @@ func (m *RequestFinalizeBlock) Reset() { *m = RequestFinalizeBlock{} } func (m *RequestFinalizeBlock) String() string { return proto.CompactTextString(m) } func (*RequestFinalizeBlock) ProtoMessage() {} func (*RequestFinalizeBlock) Descriptor() ([]byte, []int) { - return fileDescriptor_4f8c051f33f91260, []int{4} + return fileDescriptor_4f8c051f33f91260, []int{5} } func (m *RequestFinalizeBlock) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -883,7 +988,7 @@ func (m *Response) Reset() { *m = Response{} } func (m *Response) String() string { return proto.CompactTextString(m) } func (*Response) ProtoMessage() {} func (*Response) Descriptor() ([]byte, []int) { - return fileDescriptor_4f8c051f33f91260, []int{5} + return fileDescriptor_4f8c051f33f91260, []int{6} } func (m *Response) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1145,7 +1250,7 @@ func (m *ResponseOfferSnapshot) Reset() { *m = ResponseOfferSnapshot{} } func (m *ResponseOfferSnapshot) String() string { return proto.CompactTextString(m) } func (*ResponseOfferSnapshot) ProtoMessage() {} func (*ResponseOfferSnapshot) Descriptor() ([]byte, []int) { - return fileDescriptor_4f8c051f33f91260, []int{6} + return fileDescriptor_4f8c051f33f91260, []int{7} } func (m *ResponseOfferSnapshot) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1191,7 +1296,7 @@ func (m *ResponseApplySnapshotChunk) Reset() { *m = ResponseApplySnapsho func (m *ResponseApplySnapshotChunk) String() string { return proto.CompactTextString(m) } func (*ResponseApplySnapshotChunk) ProtoMessage() {} func (*ResponseApplySnapshotChunk) Descriptor() ([]byte, []int) { - return fileDescriptor_4f8c051f33f91260, []int{7} + return fileDescriptor_4f8c051f33f91260, []int{8} } func (m *ResponseApplySnapshotChunk) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1249,7 +1354,7 @@ func (m *ResponseProcessProposal) Reset() { *m = ResponseProcessProposal func (m *ResponseProcessProposal) String() string { return proto.CompactTextString(m) } func (*ResponseProcessProposal) ProtoMessage() {} func (*ResponseProcessProposal) Descriptor() ([]byte, []int) { - return fileDescriptor_4f8c051f33f91260, []int{8} + return fileDescriptor_4f8c051f33f91260, []int{9} } func (m *ResponseProcessProposal) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1293,7 +1398,7 @@ func (m *ResponseVerifyVoteExtension) Reset() { *m = ResponseVerifyVoteE func (m *ResponseVerifyVoteExtension) String() string { return proto.CompactTextString(m) } func (*ResponseVerifyVoteExtension) ProtoMessage() {} func (*ResponseVerifyVoteExtension) Descriptor() ([]byte, []int) { - return fileDescriptor_4f8c051f33f91260, []int{9} + return fileDescriptor_4f8c051f33f91260, []int{10} } func (m *ResponseVerifyVoteExtension) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1347,7 +1452,7 @@ func (m *Misbehavior) Reset() { *m = Misbehavior{} } func (m *Misbehavior) String() string { return proto.CompactTextString(m) } func (*Misbehavior) ProtoMessage() {} func (*Misbehavior) Descriptor() ([]byte, []int) { - return fileDescriptor_4f8c051f33f91260, []int{10} + return fileDescriptor_4f8c051f33f91260, []int{11} } func (m *Misbehavior) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -1422,6 +1527,7 @@ func init() { proto.RegisterType((*RequestCheckTx)(nil), "cometbft.abci.v4.RequestCheckTx") proto.RegisterType((*RequestPrepareProposal)(nil), "cometbft.abci.v4.RequestPrepareProposal") proto.RegisterType((*RequestProcessProposal)(nil), "cometbft.abci.v4.RequestProcessProposal") + proto.RegisterType((*RequestExtendVote)(nil), "cometbft.abci.v4.RequestExtendVote") proto.RegisterType((*RequestFinalizeBlock)(nil), "cometbft.abci.v4.RequestFinalizeBlock") proto.RegisterType((*Response)(nil), "cometbft.abci.v4.Response") proto.RegisterType((*ResponseOfferSnapshot)(nil), "cometbft.abci.v4.ResponseOfferSnapshot") @@ -1434,134 +1540,136 @@ func init() { func init() { proto.RegisterFile("cometbft/abci/v4/types.proto", fileDescriptor_4f8c051f33f91260) } var fileDescriptor_4f8c051f33f91260 = []byte{ - // 2022 bytes of a gzipped FileDescriptorProto + // 2060 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xec, 0x59, 0xcb, 0x6f, 0xe3, 0xc6, - 0x19, 0xd7, 0x83, 0xb6, 0xe5, 0xcf, 0x2f, 0x7a, 0x6c, 0x27, 0x0c, 0x77, 0x63, 0x7b, 0xe5, 0x6c, - 0x76, 0xe3, 0x4d, 0xe5, 0xae, 0xd7, 0x6d, 0xda, 0x02, 0x69, 0x20, 0x69, 0xe9, 0xc8, 0x8f, 0x95, - 0xd4, 0x11, 0xad, 0xc4, 0x41, 0x0b, 0x86, 0x92, 0x46, 0x16, 0xbb, 0xb4, 0xa8, 0x88, 0x94, 0x2b, - 0xf7, 0xdc, 0x16, 0x45, 0x4e, 0x39, 0x17, 0x28, 0x50, 0xa0, 0xe8, 0xb5, 0xff, 0x41, 0xef, 0xb9, - 0x35, 0xc7, 0x9e, 0xda, 0x62, 0xf7, 0x6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0xae, 0x66, 0x29, - 0xcd, 0x8e, 0xaa, 0x75, 0x85, 0x39, 0x46, 0xcd, 0x7a, 0xa9, 0xcf, 0xc6, 0x54, 0xcd, 0x2a, 0x52, - 0x64, 0x29, 0x81, 0x17, 0x35, 0xf7, 0x0b, 0x9d, 0xf1, 0x57, 0x03, 0xd2, 0xbf, 0x15, 0xe6, 0x23, - 0x66, 0xfc, 0x33, 0x8a, 0xa2, 0x33, 0x66, 0x70, 0xf4, 0x31, 0x64, 0x9a, 0x1d, 0xd2, 0x7c, 0xa9, - 0x58, 0x43, 0x21, 0xc3, 0xa8, 0xbb, 0x5e, 0xea, 0x91, 0x4b, 0x2d, 0x52, 0xa0, 0x3c, 0x2c, 0x25, - 0xf0, 0x42, 0xd3, 0xfe, 0x88, 0x7e, 0x0c, 0xf3, 0x4d, 0xe3, 0xfa, 0x5a, 0xb3, 0x84, 0x25, 0x46, - 0xde, 0x09, 0x1d, 0xb7, 0xc8, 0x60, 0xa5, 0x04, 0x76, 0x08, 0xa8, 0x02, 0xab, 0xba, 0x66, 0x5a, - 0x8a, 0xd9, 0x55, 0x7b, 0x66, 0xc7, 0xb0, 0x4c, 0x61, 0x99, 0x49, 0xbc, 0x1f, 0x2a, 0x71, 0xae, - 0x99, 0x56, 0xcd, 0x45, 0x97, 0x12, 0x78, 0x45, 0x9f, 0x6c, 0xa0, 0x82, 0x46, 0xbb, 0x4d, 0xfa, - 0x23, 0x45, 0x61, 0x25, 0x42, 0xb0, 0x42, 0xe1, 0xae, 0x00, 0x15, 0x34, 0x26, 0x1b, 0xd0, 0xcf, - 0x61, 0x43, 0x37, 0xd4, 0xd6, 0x48, 0x4f, 0x69, 0x76, 0x06, 0xdd, 0x97, 0xc2, 0x2a, 0x53, 0xdd, - 0x0f, 0x9f, 0xa6, 0xa1, 0xb6, 0x5c, 0x8d, 0x22, 0x65, 0x94, 0x12, 0x78, 0x5d, 0xf7, 0x36, 0x22, - 0x05, 0x36, 0xd5, 0x5e, 0x4f, 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x8d, 0x51, 0x30, 0x2a, 0x00, 0x68, 0x5d, 0xcd, + 0x54, 0x1a, 0x6d, 0x55, 0xeb, 0x0a, 0x73, 0x8c, 0x9a, 0x71, 0x53, 0x0f, 0x47, 0x54, 0xcd, 0x2c, + 0x50, 0x64, 0x31, 0x86, 0x17, 0x34, 0xe7, 0x0f, 0xed, 0xf1, 0x17, 0x37, 0xa4, 0x7f, 0x27, 0xa4, + 0x42, 0x7a, 0xfc, 0x33, 0x8a, 0xa2, 0x3d, 0x66, 0x70, 0xf4, 0x21, 0xa4, 0x1b, 0x6d, 0xd2, 0x78, + 0xa1, 0x98, 0x03, 0x21, 0xcd, 0xa8, 0x3b, 0x6e, 0xea, 0x91, 0x43, 0x2d, 0x50, 0xa0, 0x3c, 0x28, + 0xc6, 0xf0, 0x7c, 0xc3, 0xfa, 0x89, 0x7e, 0x0c, 0xa9, 0x86, 0x7e, 0x7d, 0xad, 0x99, 0xc2, 0x22, + 0x23, 0x6f, 0x07, 0xb6, 0x5b, 0x60, 0xb0, 0x62, 0x0c, 0xdb, 0x04, 0x54, 0x86, 0x95, 0x8e, 0x66, + 0x98, 0x8a, 0xd1, 0x55, 0x7b, 0x46, 0x5b, 0x37, 0x0d, 0x61, 0x89, 0x49, 0xbc, 0x1b, 0x28, 0x71, + 0xae, 0x19, 0x66, 0xd5, 0x41, 0x17, 0x63, 0x78, 0xb9, 0x33, 0x5e, 0x40, 0x05, 0xf5, 0x56, 0x8b, + 0xf4, 0x87, 0x8a, 0xc2, 0x72, 0x88, 0x60, 0x99, 0xc2, 0x1d, 0x01, 0x2a, 0xa8, 0x8f, 0x17, 0xa0, + 0x9f, 0xc3, 0x7a, 0x47, 0x57, 0x9b, 0x43, 0x3d, 0xa5, 0xd1, 0xbe, 0xe9, 0xbe, 0x10, 0x56, 0x98, + 0xea, 0x5e, 0x70, 0x37, 0x75, 0xb5, 0xe9, 0x68, 0x14, 0x28, 0xa3, 0x18, 0xc3, 0x6b, 0x1d, 0x77, + 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d4, 0x44, + 0x04, 0x75, 0x60, 0xcd, 0x93, 0x42, 0xa0, 0x19, 0x9e, 0x09, 0xc4, 0x59, 0x72, 0x13, 0xa4, 0x03, + 0xf2, 0xb1, 0x7c, 0xb3, 0x3c, 0x1b, 0x88, 0x33, 0xe5, 0x2a, 0xa8, 0x05, 0xab, 0xee, 0xfb, 0xe1, + 0xc8, 0xef, 0x08, 0x62, 0xf4, 0xc4, 0xc5, 0x6a, 0x67, 0xd2, 0x1b, 0x46, 0x7e, 0x58, 0x10, 0xa3, + 0x27, 0x32, 0xe8, 0x13, 0x80, 0xb1, 0x5b, 0xbc, 0x28, 0x2f, 0x0d, 0x62, 0xa4, 0x9c, 0x06, 0xf5, + 0x61, 0xdd, 0xcf, 0x80, 0xce, 0xf4, 0xf2, 0x20, 0xce, 0x96, 0xeb, 0xd0, 0xd5, 0x3d, 0x79, 0x15, + 0x16, 0xf1, 0x29, 0x42, 0x8c, 0x9a, 0xf5, 0xe4, 0xcf, 0xbe, 0x79, 0xb9, 0x15, 0xff, 0xf6, 0xe5, + 0x56, 0xfc, 0x5f, 0x2f, 0xb7, 0xe2, 0x5f, 0xbf, 0xda, 0x8a, 0x7d, 0xfb, 0x6a, 0x2b, 0xf6, 0xf7, + 0x57, 0x5b, 0xb1, 0xcf, 0x9e, 0x5e, 0x69, 0x66, 0xfb, 0xa6, 0x4e, 0x85, 0xf6, 0x87, 0xaf, 0xb9, + 0xa3, 0x67, 0xdd, 0x9e, 0xb6, 0xef, 0x7e, 0x4f, 0xae, 0xa7, 0x98, 0x23, 0x3d, 0xfc, 0x4f, 0x00, + 0x00, 0x00, 0xff, 0xff, 0xc2, 0xc3, 0xa5, 0xad, 0x6a, 0x1e, 0x00, 0x00, } // Reference imports to suppress errors if they are not otherwise used. @@ -1589,7 +1697,7 @@ type ABCIClient interface { ApplySnapshotChunk(ctx context.Context, in *v1.RequestApplySnapshotChunk, opts ...grpc.CallOption) (*ResponseApplySnapshotChunk, error) PrepareProposal(ctx context.Context, in *RequestPrepareProposal, opts ...grpc.CallOption) (*v2.ResponsePrepareProposal, error) ProcessProposal(ctx context.Context, in *RequestProcessProposal, opts ...grpc.CallOption) (*ResponseProcessProposal, error) - ExtendVote(ctx context.Context, in *v3.RequestExtendVote, opts ...grpc.CallOption) (*v3.ResponseExtendVote, error) + ExtendVote(ctx context.Context, in *RequestExtendVote, opts ...grpc.CallOption) (*v3.ResponseExtendVote, error) VerifyVoteExtension(ctx context.Context, in *v3.RequestVerifyVoteExtension, opts ...grpc.CallOption) (*ResponseVerifyVoteExtension, error) FinalizeBlock(ctx context.Context, in *RequestFinalizeBlock, opts ...grpc.CallOption) (*v3.ResponseFinalizeBlock, error) } @@ -1719,7 +1827,7 @@ func (c *aBCIClient) ProcessProposal(ctx context.Context, in *RequestProcessProp return out, nil } -func (c *aBCIClient) ExtendVote(ctx context.Context, in *v3.RequestExtendVote, opts ...grpc.CallOption) (*v3.ResponseExtendVote, error) { +func (c *aBCIClient) ExtendVote(ctx context.Context, in *RequestExtendVote, opts ...grpc.CallOption) (*v3.ResponseExtendVote, error) { out := new(v3.ResponseExtendVote) err := c.cc.Invoke(ctx, "/cometbft.abci.v4.ABCI/ExtendVote", in, out, opts...) if err != nil { @@ -1761,7 +1869,7 @@ type ABCIServer interface { ApplySnapshotChunk(context.Context, *v1.RequestApplySnapshotChunk) (*ResponseApplySnapshotChunk, error) PrepareProposal(context.Context, *RequestPrepareProposal) (*v2.ResponsePrepareProposal, error) ProcessProposal(context.Context, *RequestProcessProposal) (*ResponseProcessProposal, error) - ExtendVote(context.Context, *v3.RequestExtendVote) (*v3.ResponseExtendVote, error) + ExtendVote(context.Context, *RequestExtendVote) (*v3.ResponseExtendVote, error) VerifyVoteExtension(context.Context, *v3.RequestVerifyVoteExtension) (*ResponseVerifyVoteExtension, error) FinalizeBlock(context.Context, *RequestFinalizeBlock) (*v3.ResponseFinalizeBlock, error) } @@ -1809,7 +1917,7 @@ func (*UnimplementedABCIServer) PrepareProposal(ctx context.Context, req *Reques func (*UnimplementedABCIServer) ProcessProposal(ctx context.Context, req *RequestProcessProposal) (*ResponseProcessProposal, error) { return nil, status.Errorf(codes.Unimplemented, "method ProcessProposal not implemented") } -func (*UnimplementedABCIServer) ExtendVote(ctx context.Context, req *v3.RequestExtendVote) (*v3.ResponseExtendVote, error) { +func (*UnimplementedABCIServer) ExtendVote(ctx context.Context, req *RequestExtendVote) (*v3.ResponseExtendVote, error) { return nil, status.Errorf(codes.Unimplemented, "method ExtendVote not implemented") } func (*UnimplementedABCIServer) VerifyVoteExtension(ctx context.Context, req *v3.RequestVerifyVoteExtension) (*ResponseVerifyVoteExtension, error) { @@ -2058,7 +2166,7 @@ func _ABCI_ProcessProposal_Handler(srv interface{}, ctx context.Context, dec fun } func _ABCI_ExtendVote_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { - in := new(v3.RequestExtendVote) + in := new(RequestExtendVote) if err := dec(in); err != nil { return nil, err } @@ -2070,7 +2178,7 @@ func _ABCI_ExtendVote_Handler(srv interface{}, ctx context.Context, dec func(int FullMethod: "/cometbft.abci.v4.ABCI/ExtendVote", } handler := func(ctx context.Context, req interface{}) (interface{}, error) { - return srv.(ABCIServer).ExtendVote(ctx, req.(*v3.RequestExtendVote)) + return srv.(ABCIServer).ExtendVote(ctx, req.(*RequestExtendVote)) } return interceptor(ctx, in, info, handler) } @@ -2775,6 +2883,96 @@ func (m *RequestProcessProposal) MarshalToSizedBuffer(dAtA []byte) (int, error) return len(dAtA) - i, nil } +func (m *RequestExtendVote) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *RequestExtendVote) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *RequestExtendVote) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.ProposerAddress) > 0 { + i -= len(m.ProposerAddress) + copy(dAtA[i:], m.ProposerAddress) + i = encodeVarintTypes(dAtA, i, uint64(len(m.ProposerAddress))) + i-- + dAtA[i] = 0x42 + } + if len(m.NextValidatorsHash) > 0 { + i -= len(m.NextValidatorsHash) + copy(dAtA[i:], m.NextValidatorsHash) + i = encodeVarintTypes(dAtA, i, uint64(len(m.NextValidatorsHash))) + i-- + dAtA[i] = 0x3a + } + if len(m.Misbehavior) > 0 { + for iNdEx := len(m.Misbehavior) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.Misbehavior[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTypes(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x32 + } + } + { + size, err := m.ProposedLastCommit.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTypes(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x2a + if len(m.Txs) > 0 { + for iNdEx := len(m.Txs) - 1; iNdEx >= 0; iNdEx-- { + i -= len(m.Txs[iNdEx]) + copy(dAtA[i:], m.Txs[iNdEx]) + i = encodeVarintTypes(dAtA, i, uint64(len(m.Txs[iNdEx]))) + i-- + dAtA[i] = 0x22 + } + } + n22, err22 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time):]) + if err22 != nil { + return 0, err22 + } + i -= n22 + i = encodeVarintTypes(dAtA, i, uint64(n22)) + i-- + dAtA[i] = 0x1a + if m.Height != 0 { + i = encodeVarintTypes(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x10 + } + if len(m.Hash) > 0 { + i -= len(m.Hash) + copy(dAtA[i:], m.Hash) + i = encodeVarintTypes(dAtA, i, uint64(len(m.Hash))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + func (m *RequestFinalizeBlock) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -2809,12 +3007,12 @@ func (m *RequestFinalizeBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) { i-- dAtA[i] = 0x3a } - n21, err21 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time):]) - if err21 != nil { - return 0, err21 + n23, err23 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time):]) + if err23 != nil { + return 0, err23 } - i -= n21 - i = encodeVarintTypes(dAtA, i, uint64(n21)) + i -= n23 + i = encodeVarintTypes(dAtA, i, uint64(n23)) i-- dAtA[i] = 0x32 if m.Height != 0 { @@ -3324,20 +3522,20 @@ func (m *ResponseApplySnapshotChunk) MarshalToSizedBuffer(dAtA []byte) (int, err } } if len(m.RefetchChunks) > 0 { - dAtA41 := make([]byte, len(m.RefetchChunks)*10) - var j40 int + dAtA43 := make([]byte, len(m.RefetchChunks)*10) + var j42 int for _, num := range m.RefetchChunks { for num >= 1<<7 { - dAtA41[j40] = uint8(uint64(num)&0x7f | 0x80) + dAtA43[j42] = uint8(uint64(num)&0x7f | 0x80) num >>= 7 - j40++ + j42++ } - dAtA41[j40] = uint8(num) - j40++ + dAtA43[j42] = uint8(num) + j42++ } - i -= j40 - copy(dAtA[i:], dAtA41[:j40]) - i = encodeVarintTypes(dAtA, i, uint64(j40)) + i -= j42 + copy(dAtA[i:], dAtA43[:j42]) + i = encodeVarintTypes(dAtA, i, uint64(j42)) i-- dAtA[i] = 0x12 } @@ -3430,12 +3628,12 @@ func (m *Misbehavior) MarshalToSizedBuffer(dAtA []byte) (int, error) { i-- dAtA[i] = 0x28 } - n42, err42 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time):]) - if err42 != nil { - return 0, err42 + n44, err44 := github_com_cosmos_gogoproto_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time):]) + if err44 != nil { + return 0, err44 } - i -= n42 - i = encodeVarintTypes(dAtA, i, uint64(n42)) + i -= n44 + i = encodeVarintTypes(dAtA, i, uint64(n44)) i-- dAtA[i] = 0x22 if m.Height != 0 { @@ -3771,6 +3969,46 @@ func (m *RequestProcessProposal) Size() (n int) { return n } +func (m *RequestExtendVote) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Hash) + if l > 0 { + n += 1 + l + sovTypes(uint64(l)) + } + if m.Height != 0 { + n += 1 + sovTypes(uint64(m.Height)) + } + l = github_com_cosmos_gogoproto_types.SizeOfStdTime(m.Time) + n += 1 + l + sovTypes(uint64(l)) + if len(m.Txs) > 0 { + for _, b := range m.Txs { + l = len(b) + n += 1 + l + sovTypes(uint64(l)) + } + } + l = m.ProposedLastCommit.Size() + n += 1 + l + sovTypes(uint64(l)) + if len(m.Misbehavior) > 0 { + for _, e := range m.Misbehavior { + l = e.Size() + n += 1 + l + sovTypes(uint64(l)) + } + } + l = len(m.NextValidatorsHash) + if l > 0 { + n += 1 + l + sovTypes(uint64(l)) + } + l = len(m.ProposerAddress) + if l > 0 { + n += 1 + l + sovTypes(uint64(l)) + } + return n +} + func (m *RequestFinalizeBlock) Size() (n int) { if m == nil { return 0 @@ -4629,7 +4867,7 @@ func (m *Request) Unmarshal(dAtA []byte) error { if postIndex > l { return io.ErrUnexpectedEOF } - v := &v3.RequestExtendVote{} + v := &RequestExtendVote{} if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { return err } @@ -5420,6 +5658,309 @@ func (m *RequestProcessProposal) Unmarshal(dAtA []byte) error { } return nil } +func (m *RequestExtendVote) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: RequestExtendVote: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: RequestExtendVote: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Hash", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Hash = append(m.Hash[:0], dAtA[iNdEx:postIndex]...) + if m.Hash == nil { + m.Hash = []byte{} + } + iNdEx = postIndex + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Time", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := github_com_cosmos_gogoproto_types.StdTimeUnmarshal(&m.Time, dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Txs", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Txs = append(m.Txs, make([]byte, postIndex-iNdEx)) + copy(m.Txs[len(m.Txs)-1], dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ProposedLastCommit", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if err := m.ProposedLastCommit.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Misbehavior", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Misbehavior = append(m.Misbehavior, Misbehavior{}) + if err := m.Misbehavior[len(m.Misbehavior)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 7: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field NextValidatorsHash", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.NextValidatorsHash = append(m.NextValidatorsHash[:0], dAtA[iNdEx:postIndex]...) + if m.NextValidatorsHash == nil { + m.NextValidatorsHash = []byte{} + } + iNdEx = postIndex + case 8: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ProposerAddress", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ProposerAddress = append(m.ProposerAddress[:0], dAtA[iNdEx:postIndex]...) + if m.ProposerAddress == nil { + m.ProposerAddress = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipTypes(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTypes + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *RequestFinalizeBlock) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 diff --git a/api/cometbft/consensus/types.go b/api/cometbft/consensus/types.go index 907fa1f3b00..1bcdd5e0c9b 100644 --- a/api/cometbft/consensus/types.go +++ b/api/cometbft/consensus/types.go @@ -6,23 +6,29 @@ import ( v2 "github.com/cometbft/cometbft/api/cometbft/consensus/v2" ) -type Message = v2.Message -type Message_BlockPart = v2.Message_BlockPart -type Message_HasVote = v2.Message_HasVote -type Message_NewRoundStep = v2.Message_NewRoundStep -type Message_NewValidBlock = v2.Message_NewValidBlock -type Message_Proposal = v2.Message_Proposal -type Message_ProposalPol = v2.Message_ProposalPol -type Message_Vote = v2.Message_Vote -type Message_VoteSetBits = v2.Message_VoteSetBits -type Message_VoteSetMaj23 = v2.Message_VoteSetMaj23 +type ( + Message = v2.Message + Message_BlockPart = v2.Message_BlockPart + Message_HasVote = v2.Message_HasVote + Message_NewRoundStep = v2.Message_NewRoundStep + Message_NewValidBlock = v2.Message_NewValidBlock + Message_Proposal = v2.Message_Proposal + Message_ProposalPol = v2.Message_ProposalPol + Message_Vote = v2.Message_Vote + Message_VoteSetBits = v2.Message_VoteSetBits + Message_VoteSetMaj23 = v2.Message_VoteSetMaj23 + Message_HasProposalBlockPart = v2.Message_HasProposalBlockPart +) -type BlockPart = v1.BlockPart -type HasVote = v1.HasVote -type NewRoundStep = v1.NewRoundStep -type NewValidBlock = v1.NewValidBlock -type Proposal = v1.Proposal -type ProposalPOL = v1.ProposalPOL -type Vote = v2.Vote -type VoteSetBits = v1.VoteSetBits -type VoteSetMaj23 = v1.VoteSetMaj23 +type ( + BlockPart = v1.BlockPart + HasProposalBlockPart = v2.HasProposalBlockPart + HasVote = v1.HasVote + NewRoundStep = v1.NewRoundStep + NewValidBlock = v1.NewValidBlock + Proposal = v1.Proposal + ProposalPOL = v1.ProposalPOL + Vote = v2.Vote + VoteSetBits = v1.VoteSetBits + VoteSetMaj23 = v1.VoteSetMaj23 +) diff --git a/api/cometbft/consensus/v1/message.go b/api/cometbft/consensus/v1/message.go index c5db7089f61..10ace14ef23 100644 --- a/api/cometbft/consensus/v1/message.go +++ b/api/cometbft/consensus/v1/message.go @@ -8,22 +8,22 @@ import ( "github.com/cometbft/cometbft/p2p" ) -var _ p2p.Wrapper = &VoteSetBits{} -var _ p2p.Wrapper = &VoteSetMaj23{} -var _ p2p.Wrapper = &Vote{} -var _ p2p.Wrapper = &ProposalPOL{} -var _ p2p.Wrapper = &Proposal{} -var _ p2p.Wrapper = &NewValidBlock{} -var _ p2p.Wrapper = &NewRoundStep{} -var _ p2p.Wrapper = &HasVote{} -var _ p2p.Wrapper = &HasProposalBlockPart{} -var _ p2p.Wrapper = &BlockPart{} +var ( + _ p2p.Wrapper = &VoteSetBits{} + _ p2p.Wrapper = &VoteSetMaj23{} + _ p2p.Wrapper = &Vote{} + _ p2p.Wrapper = &ProposalPOL{} + _ p2p.Wrapper = &Proposal{} + _ p2p.Wrapper = &NewValidBlock{} + _ p2p.Wrapper = &NewRoundStep{} + _ p2p.Wrapper = &HasVote{} + _ p2p.Wrapper = &BlockPart{} +) func (m *VoteSetBits) Wrap() proto.Message { cm := &Message{} cm.Sum = &Message_VoteSetBits{VoteSetBits: m} return cm - } func (m *VoteSetMaj23) Wrap() proto.Message { @@ -38,12 +38,6 @@ func (m *HasVote) Wrap() proto.Message { return cm } -func (m *HasProposalBlockPart) Wrap() proto.Message { - cm := &Message{} - cm.Sum = &Message_HasProposalBlockPart{HasProposalBlockPart: m} - return cm -} - func (m *Vote) Wrap() proto.Message { cm := &Message{} cm.Sum = &Message_Vote{Vote: m} @@ -105,9 +99,6 @@ func (m *Message) Unwrap() (proto.Message, error) { case *Message_HasVote: return m.GetHasVote(), nil - case *Message_HasProposalBlockPart: - return m.GetHasProposalBlockPart(), nil - case *Message_VoteSetMaj23: return m.GetVoteSetMaj23(), nil diff --git a/api/cometbft/consensus/v2/message.go b/api/cometbft/consensus/v2/message.go index 82e4614c771..19f9b4384af 100644 --- a/api/cometbft/consensus/v2/message.go +++ b/api/cometbft/consensus/v2/message.go @@ -8,7 +8,10 @@ import ( "github.com/cometbft/cometbft/p2p" ) -var _ p2p.Wrapper = &Vote{} +var ( + _ p2p.Wrapper = &Vote{} + _ p2p.Wrapper = &HasProposalBlockPart{} +) func (m *Vote) Wrap() proto.Message { cm := &Message{} @@ -16,6 +19,12 @@ func (m *Vote) Wrap() proto.Message { return cm } +func (m *HasProposalBlockPart) Wrap() proto.Message { + cm := &Message{} + cm.Sum = &Message_HasProposalBlockPart{HasProposalBlockPart: m} + return cm +} + // Unwrap implements the p2p Wrapper interface and unwraps a wrapped consensus // proto message. func (m *Message) Unwrap() (proto.Message, error) { @@ -41,6 +50,9 @@ func (m *Message) Unwrap() (proto.Message, error) { case *Message_HasVote: return m.GetHasVote(), nil + case *Message_HasProposalBlockPart: + return m.GetHasProposalBlockPart(), nil + case *Message_VoteSetMaj23: return m.GetVoteSetMaj23(), nil diff --git a/api/cometbft/consensus/v2/types.pb.go b/api/cometbft/consensus/v2/types.pb.go index b401280e9c9..27743eff73e 100644 --- a/api/cometbft/consensus/v2/types.pb.go +++ b/api/cometbft/consensus/v2/types.pb.go @@ -69,6 +69,67 @@ func (m *Vote) GetVote() *v3.Vote { return nil } +// HasProposalBlockPart is sent to indicate that a particular proposal block part has been received. +type HasProposalBlockPart struct { + Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` + Round int32 `protobuf:"varint,2,opt,name=round,proto3" json:"round,omitempty"` + Index int32 `protobuf:"varint,3,opt,name=index,proto3" json:"index,omitempty"` +} + +func (m *HasProposalBlockPart) Reset() { *m = HasProposalBlockPart{} } +func (m *HasProposalBlockPart) String() string { return proto.CompactTextString(m) } +func (*HasProposalBlockPart) ProtoMessage() {} +func (*HasProposalBlockPart) Descriptor() ([]byte, []int) { + return fileDescriptor_1fbfa7f975842dd1, []int{1} +} +func (m *HasProposalBlockPart) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *HasProposalBlockPart) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_HasProposalBlockPart.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *HasProposalBlockPart) XXX_Merge(src proto.Message) { + xxx_messageInfo_HasProposalBlockPart.Merge(m, src) +} +func (m *HasProposalBlockPart) XXX_Size() int { + return m.Size() +} +func (m *HasProposalBlockPart) XXX_DiscardUnknown() { + xxx_messageInfo_HasProposalBlockPart.DiscardUnknown(m) +} + +var xxx_messageInfo_HasProposalBlockPart proto.InternalMessageInfo + +func (m *HasProposalBlockPart) GetHeight() int64 { + if m != nil { + return m.Height + } + return 0 +} + +func (m *HasProposalBlockPart) GetRound() int32 { + if m != nil { + return m.Round + } + return 0 +} + +func (m *HasProposalBlockPart) GetIndex() int32 { + if m != nil { + return m.Index + } + return 0 +} + type Message struct { // Types that are valid to be assigned to Sum: // *Message_NewRoundStep @@ -80,6 +141,7 @@ type Message struct { // *Message_HasVote // *Message_VoteSetMaj23 // *Message_VoteSetBits + // *Message_HasProposalBlockPart Sum isMessage_Sum `protobuf_oneof:"sum"` } @@ -87,7 +149,7 @@ func (m *Message) Reset() { *m = Message{} } func (m *Message) String() string { return proto.CompactTextString(m) } func (*Message) ProtoMessage() {} func (*Message) Descriptor() ([]byte, []int) { - return fileDescriptor_1fbfa7f975842dd1, []int{1} + return fileDescriptor_1fbfa7f975842dd1, []int{2} } func (m *Message) XXX_Unmarshal(b []byte) error { return m.Unmarshal(b) @@ -149,16 +211,20 @@ type Message_VoteSetMaj23 struct { type Message_VoteSetBits struct { VoteSetBits *v1.VoteSetBits `protobuf:"bytes,9,opt,name=vote_set_bits,json=voteSetBits,proto3,oneof" json:"vote_set_bits,omitempty"` } +type Message_HasProposalBlockPart struct { + HasProposalBlockPart *HasProposalBlockPart `protobuf:"bytes,10,opt,name=has_proposal_block_part,json=hasProposalBlockPart,proto3,oneof" json:"has_proposal_block_part,omitempty"` +} -func (*Message_NewRoundStep) isMessage_Sum() {} -func (*Message_NewValidBlock) isMessage_Sum() {} -func (*Message_Proposal) isMessage_Sum() {} -func (*Message_ProposalPol) isMessage_Sum() {} -func (*Message_BlockPart) isMessage_Sum() {} -func (*Message_Vote) isMessage_Sum() {} -func (*Message_HasVote) isMessage_Sum() {} -func (*Message_VoteSetMaj23) isMessage_Sum() {} -func (*Message_VoteSetBits) isMessage_Sum() {} +func (*Message_NewRoundStep) isMessage_Sum() {} +func (*Message_NewValidBlock) isMessage_Sum() {} +func (*Message_Proposal) isMessage_Sum() {} +func (*Message_ProposalPol) isMessage_Sum() {} +func (*Message_BlockPart) isMessage_Sum() {} +func (*Message_Vote) isMessage_Sum() {} +func (*Message_HasVote) isMessage_Sum() {} +func (*Message_VoteSetMaj23) isMessage_Sum() {} +func (*Message_VoteSetBits) isMessage_Sum() {} +func (*Message_HasProposalBlockPart) isMessage_Sum() {} func (m *Message) GetSum() isMessage_Sum { if m != nil { @@ -230,6 +296,13 @@ func (m *Message) GetVoteSetBits() *v1.VoteSetBits { return nil } +func (m *Message) GetHasProposalBlockPart() *HasProposalBlockPart { + if x, ok := m.GetSum().(*Message_HasProposalBlockPart); ok { + return x.HasProposalBlockPart + } + return nil +} + // XXX_OneofWrappers is for the internal use of the proto package. func (*Message) XXX_OneofWrappers() []interface{} { return []interface{}{ @@ -242,46 +315,53 @@ func (*Message) XXX_OneofWrappers() []interface{} { (*Message_HasVote)(nil), (*Message_VoteSetMaj23)(nil), (*Message_VoteSetBits)(nil), + (*Message_HasProposalBlockPart)(nil), } } func init() { proto.RegisterType((*Vote)(nil), "cometbft.consensus.v2.Vote") + proto.RegisterType((*HasProposalBlockPart)(nil), "cometbft.consensus.v2.HasProposalBlockPart") proto.RegisterType((*Message)(nil), "cometbft.consensus.v2.Message") } func init() { proto.RegisterFile("cometbft/consensus/v2/types.proto", fileDescriptor_1fbfa7f975842dd1) } var fileDescriptor_1fbfa7f975842dd1 = []byte{ - // 448 bytes of a gzipped FileDescriptorProto - 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x93, 0xc1, 0x6e, 0xd3, 0x30, - 0x18, 0xc7, 0x1d, 0xd6, 0xad, 0x9d, 0xb7, 0x81, 0x64, 0x09, 0x11, 0x0d, 0x11, 0x46, 0xe1, 0x80, - 0x84, 0x94, 0xa8, 0x89, 0xc4, 0x05, 0x71, 0xa0, 0x17, 0x2c, 0xc1, 0x46, 0x94, 0x49, 0x3b, 0x70, - 0xb1, 0x9c, 0xce, 0xac, 0x81, 0x34, 0xb6, 0x62, 0xc7, 0x13, 0x6f, 0xc1, 0x63, 0x71, 0xdc, 0x91, - 0x23, 0x6a, 0x1f, 0x04, 0x64, 0x37, 0x09, 0x39, 0x24, 0xe5, 0xe6, 0xcf, 0xf9, 0xff, 0x7e, 0x76, - 0xfc, 0xe9, 0x83, 0xcf, 0x16, 0x7c, 0xc5, 0x54, 0xfa, 0x45, 0x05, 0x0b, 0x5e, 0x48, 0x56, 0xc8, - 0x4a, 0x06, 0x3a, 0x0c, 0xd4, 0x77, 0xc1, 0xa4, 0x2f, 0x4a, 0xae, 0x38, 0x7a, 0xd8, 0x44, 0xfc, - 0x36, 0xe2, 0xeb, 0xf0, 0xb4, 0x97, 0x9c, 0x75, 0xc9, 0xd3, 0x27, 0x6d, 0xc4, 0xee, 0x06, 0x3a, - 0xea, 0x7e, 0x9e, 0x46, 0x70, 0x74, 0xc5, 0x15, 0x43, 0xaf, 0xe0, 0x48, 0x73, 0xc5, 0x5c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0xd8, 0x62, 0xde, 0xc0, 0x99, 0x98, 0xca, 0x9a, 0x1c, 0x2f, 0xb7, - 0x4b, 0xd3, 0x57, 0x03, 0x12, 0xc9, 0x14, 0x59, 0xd1, 0xaf, 0x61, 0xe4, 0x4e, 0x76, 0xf6, 0xd5, - 0x40, 0x97, 0x4c, 0x9d, 0x9b, 0xa8, 0xe9, 0xab, 0xee, 0xd4, 0x08, 0xc3, 0x93, 0x56, 0x96, 0x66, - 0x4a, 0xba, 0x87, 0x3b, 0x5f, 0xb2, 0x76, 0xcd, 0x33, 0x25, 0xcd, 0x4b, 0xea, 0x7f, 0xe5, 0x7c, - 0x1f, 0xee, 0xc9, 0x6a, 0x35, 0x8f, 0x7f, 0xae, 0x3d, 0xe7, 0x6e, 0xed, 0x39, 0xbf, 0xd7, 0x9e, - 0xf3, 0x63, 0xe3, 0x81, 0xbb, 0x8d, 0x07, 0x7e, 0x6d, 0x3c, 0xf0, 0xf9, 0xf5, 0x4d, 0xa6, 0x96, - 0x55, 0x6a, 0xcc, 0x41, 0x67, 0x3a, 0xea, 0x05, 0x15, 0x59, 0xd0, 0x3b, 0x6d, 0xe9, 0x81, 0x9d, - 0x87, 0xe8, 0x6f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x81, 0xa1, 0x1b, 0xee, 0x8d, 0x03, 0x00, 0x00, + // 520 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x54, 0x4f, 0x6f, 0xd3, 0x30, + 0x1c, 0x75, 0x58, 0xff, 0xcd, 0xdd, 0x40, 0xb2, 0x0a, 0x8b, 0x86, 0x08, 0xa5, 0x70, 0x98, 0x34, + 0x29, 0x51, 0x53, 0x89, 0x0b, 0xe2, 0x40, 0x2f, 0x58, 0x82, 0x8d, 0xc8, 0x93, 0x76, 0xd8, 0x25, + 0x72, 0x5a, 0xd3, 0x04, 0xd2, 0x38, 0x8a, 0xdd, 0x0c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, 0x3a, 0x59, 0x6a, 0xcd, 0x23, 0x29, 0x94, 0x93, 0xf9, 0xbf, 0x12, + 0x2d, 0xe1, 0x89, 0x9a, 0xa9, 0x8a, 0xa5, 0x66, 0x2b, 0xd4, 0x9a, 0xe7, 0x2d, 0xce, 0x34, 0x3d, + 0x06, 0x0c, 0xc8, 0x28, 0x6c, 0xe8, 0xcf, 0xbb, 0xf0, 0x40, 0x6c, 0xd6, 0x73, 0xef, 0xe7, 0xd6, + 0x32, 0xee, 0xb6, 0x96, 0xf1, 0x7b, 0x6b, 0x19, 0x3f, 0x76, 0x16, 0xb8, 0xdb, 0x59, 0xe0, 0xd7, + 0xce, 0x02, 0x37, 0xaf, 0x57, 0x91, 0x0c, 0x37, 0x81, 0xda, 0xcb, 0xa9, 0xbd, 0xef, 0x72, 0x41, + 0xd3, 0xc8, 0x69, 0xfc, 0x5f, 0x04, 0x3d, 0xfd, 0xa2, 0x67, 0x7f, 0x03, 0x00, 0x00, 0xff, 0xff, + 0xfb, 0x08, 0x84, 0x02, 0x4f, 0x04, 0x00, 0x00, } func (m *Vote) Marshal() (dAtA []byte, err error) { @@ -319,6 +399,44 @@ func (m *Vote) MarshalToSizedBuffer(dAtA []byte) (int, error) { return len(dAtA) - i, nil } +func (m *HasProposalBlockPart) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *HasProposalBlockPart) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *HasProposalBlockPart) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Index != 0 { + i = encodeVarintTypes(dAtA, i, uint64(m.Index)) + i-- + dAtA[i] = 0x18 + } + if m.Round != 0 { + i = encodeVarintTypes(dAtA, i, uint64(m.Round)) + i-- + dAtA[i] = 0x10 + } + if m.Height != 0 { + i = encodeVarintTypes(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + func (m *Message) Marshal() (dAtA []byte, err error) { size := m.Size() dAtA = make([]byte, size) @@ -540,6 +658,27 @@ func (m *Message_VoteSetBits) MarshalToSizedBuffer(dAtA []byte) (int, error) { } return len(dAtA) - i, nil } +func (m *Message_HasProposalBlockPart) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *Message_HasProposalBlockPart) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + if m.HasProposalBlockPart != nil { + { + size, err := m.HasProposalBlockPart.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintTypes(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x52 + } + return len(dAtA) - i, nil +} func encodeVarintTypes(dAtA []byte, offset int, v uint64) int { offset -= sovTypes(v) base := offset @@ -564,6 +703,24 @@ func (m *Vote) Size() (n int) { return n } +func (m *HasProposalBlockPart) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovTypes(uint64(m.Height)) + } + if m.Round != 0 { + n += 1 + sovTypes(uint64(m.Round)) + } + if m.Index != 0 { + n += 1 + sovTypes(uint64(m.Index)) + } + return n +} + func (m *Message) Size() (n int) { if m == nil { return 0 @@ -684,6 +841,18 @@ func (m *Message_VoteSetBits) Size() (n int) { } return n } +func (m *Message_HasProposalBlockPart) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.HasProposalBlockPart != nil { + l = m.HasProposalBlockPart.Size() + n += 1 + l + sovTypes(uint64(l)) + } + return n +} func sovTypes(x uint64) (n int) { return (math_bits.Len64(x|1) + 6) / 7 @@ -777,6 +946,113 @@ func (m *Vote) Unmarshal(dAtA []byte) error { } return nil } +func (m *HasProposalBlockPart) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: HasProposalBlockPart: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: HasProposalBlockPart: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Round", wireType) + } + m.Round = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Round |= int32(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType) + } + m.Index = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Index |= int32(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipTypes(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthTypes + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} func (m *Message) Unmarshal(dAtA []byte) error { l := len(dAtA) iNdEx := 0 @@ -1121,6 +1397,41 @@ func (m *Message) Unmarshal(dAtA []byte) error { } m.Sum = &Message_VoteSetBits{v} iNdEx = postIndex + case 10: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field HasProposalBlockPart", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowTypes + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthTypes + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthTypes + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + v := &HasProposalBlockPart{} + if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + m.Sum = &Message_HasProposalBlockPart{v} + iNdEx = postIndex default: iNdEx = preIndex skippy, err := skipTypes(dAtA[iNdEx:]) diff --git a/api/cometbft/services/block/v1/block.pb.go b/api/cometbft/services/block/v1/block.pb.go new file mode 100644 index 00000000000..17f001a7703 --- /dev/null +++ b/api/cometbft/services/block/v1/block.pb.go @@ -0,0 +1,1186 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: cometbft/services/block/v1/block.proto + +package v1 + +import ( + fmt "fmt" + v1 "github.com/cometbft/cometbft/api/cometbft/types/v1" + v3 "github.com/cometbft/cometbft/api/cometbft/types/v3" + proto "github.com/cosmos/gogoproto/proto" + io "io" + math "math" + math_bits "math/bits" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +type GetByHeightRequest struct { + // The height of the block requested. If set to 0, the latest height will be returned. + Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` +} + +func (m *GetByHeightRequest) Reset() { *m = GetByHeightRequest{} } +func (m *GetByHeightRequest) String() string { return proto.CompactTextString(m) } +func (*GetByHeightRequest) ProtoMessage() {} +func (*GetByHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_a30eb8f0c11b1783, []int{0} +} +func (m *GetByHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetByHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetByHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetByHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetByHeightRequest.Merge(m, src) +} +func (m *GetByHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *GetByHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetByHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetByHeightRequest proto.InternalMessageInfo + +func (m *GetByHeightRequest) GetHeight() int64 { + if m != nil { + return m.Height + } + return 0 +} + +type GetByHeightResponse struct { + BlockId *v1.BlockID `protobuf:"bytes,1,opt,name=block_id,json=blockId,proto3" json:"block_id,omitempty"` + Block *v3.Block `protobuf:"bytes,2,opt,name=block,proto3" json:"block,omitempty"` +} + +func (m *GetByHeightResponse) Reset() { *m = GetByHeightResponse{} } +func (m *GetByHeightResponse) String() string { return proto.CompactTextString(m) } +func (*GetByHeightResponse) ProtoMessage() {} +func (*GetByHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_a30eb8f0c11b1783, []int{1} +} +func (m *GetByHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetByHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetByHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetByHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetByHeightResponse.Merge(m, src) +} +func (m *GetByHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *GetByHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetByHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetByHeightResponse proto.InternalMessageInfo + +func (m *GetByHeightResponse) GetBlockId() *v1.BlockID { + if m != nil { + return m.BlockId + } + return nil +} + +func (m *GetByHeightResponse) GetBlock() *v3.Block { + if m != nil { + return m.Block + } + return nil +} + +type GetLatestRequest struct { +} + +func (m *GetLatestRequest) Reset() { *m = GetLatestRequest{} } +func (m *GetLatestRequest) String() string { return proto.CompactTextString(m) } +func (*GetLatestRequest) ProtoMessage() {} +func (*GetLatestRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_a30eb8f0c11b1783, []int{2} +} +func (m *GetLatestRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetLatestRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetLatestRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetLatestRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetLatestRequest.Merge(m, src) +} +func (m *GetLatestRequest) XXX_Size() int { + return m.Size() +} +func (m *GetLatestRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetLatestRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetLatestRequest proto.InternalMessageInfo + +type GetLatestResponse struct { + BlockId *v1.BlockID `protobuf:"bytes,1,opt,name=block_id,json=blockId,proto3" json:"block_id,omitempty"` + Block *v3.Block `protobuf:"bytes,2,opt,name=block,proto3" json:"block,omitempty"` +} + +func (m *GetLatestResponse) Reset() { *m = GetLatestResponse{} } +func (m *GetLatestResponse) String() string { return proto.CompactTextString(m) } +func (*GetLatestResponse) ProtoMessage() {} +func (*GetLatestResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_a30eb8f0c11b1783, []int{3} +} +func (m *GetLatestResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetLatestResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetLatestResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetLatestResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetLatestResponse.Merge(m, src) +} +func (m *GetLatestResponse) XXX_Size() int { + return m.Size() +} +func (m *GetLatestResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetLatestResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetLatestResponse proto.InternalMessageInfo + +func (m *GetLatestResponse) GetBlockId() *v1.BlockID { + if m != nil { + return m.BlockId + } + return nil +} + +func (m *GetLatestResponse) GetBlock() *v3.Block { + if m != nil { + return m.Block + } + return nil +} + +// GetLatestHeightRequest - empty message since no parameter is required +type GetLatestHeightRequest struct { +} + +func (m *GetLatestHeightRequest) Reset() { *m = GetLatestHeightRequest{} } +func (m *GetLatestHeightRequest) String() string { return proto.CompactTextString(m) } +func (*GetLatestHeightRequest) ProtoMessage() {} +func (*GetLatestHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_a30eb8f0c11b1783, []int{4} +} +func (m *GetLatestHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetLatestHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetLatestHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetLatestHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetLatestHeightRequest.Merge(m, src) +} +func (m *GetLatestHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *GetLatestHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetLatestHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetLatestHeightRequest proto.InternalMessageInfo + +// GetLatestHeightResponse provides the height of the latest committed block. +type GetLatestHeightResponse struct { + // The height of the latest committed block. Will be 0 if no data has been + // committed yet. + Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` +} + +func (m *GetLatestHeightResponse) Reset() { *m = GetLatestHeightResponse{} } +func (m *GetLatestHeightResponse) String() string { return proto.CompactTextString(m) } +func (*GetLatestHeightResponse) ProtoMessage() {} +func (*GetLatestHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_a30eb8f0c11b1783, []int{5} +} +func (m *GetLatestHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetLatestHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetLatestHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetLatestHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetLatestHeightResponse.Merge(m, src) +} +func (m *GetLatestHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *GetLatestHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetLatestHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetLatestHeightResponse proto.InternalMessageInfo + +func (m *GetLatestHeightResponse) GetHeight() int64 { + if m != nil { + return m.Height + } + return 0 +} + +func init() { + proto.RegisterType((*GetByHeightRequest)(nil), "cometbft.services.block.v1.GetByHeightRequest") + proto.RegisterType((*GetByHeightResponse)(nil), "cometbft.services.block.v1.GetByHeightResponse") + proto.RegisterType((*GetLatestRequest)(nil), "cometbft.services.block.v1.GetLatestRequest") + proto.RegisterType((*GetLatestResponse)(nil), "cometbft.services.block.v1.GetLatestResponse") + proto.RegisterType((*GetLatestHeightRequest)(nil), "cometbft.services.block.v1.GetLatestHeightRequest") + proto.RegisterType((*GetLatestHeightResponse)(nil), "cometbft.services.block.v1.GetLatestHeightResponse") +} + +func init() { + proto.RegisterFile("cometbft/services/block/v1/block.proto", fileDescriptor_a30eb8f0c11b1783) +} + +var fileDescriptor_a30eb8f0c11b1783 = []byte{ + // 290 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x4b, 0xce, 0xcf, 0x4d, + 0x2d, 0x49, 0x4a, 0x2b, 0xd1, 0x2f, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0x2d, 0xd6, 0x4f, 0xca, + 0xc9, 0x4f, 0xce, 0xd6, 0x2f, 0x33, 0x84, 0x30, 0xf4, 0x0a, 0x8a, 0xf2, 0x4b, 0xf2, 0x85, 0xa4, + 0x60, 0xea, 0xf4, 0x60, 0xea, 0xf4, 0x20, 0xd2, 0x65, 0x86, 0x52, 0xb2, 0x70, 0x33, 0x4a, 0x2a, + 0x0b, 0x52, 0x8b, 0x41, 0x5a, 0xc1, 0x0c, 0x88, 0x56, 0x4c, 0x69, 0x63, 0x64, 0x93, 0x95, 0x74, + 0xb8, 0x84, 0xdc, 0x53, 0x4b, 0x9c, 0x2a, 0x3d, 0x52, 0x33, 0xd3, 0x33, 0x4a, 0x82, 0x52, 0x0b, + 0x4b, 0x53, 0x8b, 0x4b, 0x84, 0xc4, 0xb8, 0xd8, 0x32, 0xc0, 0x02, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, + 0xcc, 0x41, 0x50, 0x9e, 0x52, 0x0d, 0x97, 0x30, 0x8a, 0xea, 0xe2, 0x82, 0xfc, 0xbc, 0xe2, 0x54, + 0x21, 0x53, 0x2e, 0x0e, 0xb0, 0x99, 0xf1, 0x99, 0x29, 0x60, 0x0d, 0xdc, 0x46, 0x52, 0x7a, 0x70, + 0x17, 0x43, 0x1c, 0x53, 0x66, 0xa8, 0xe7, 0x04, 0x52, 0xe2, 0xe9, 0x12, 0xc4, 0x0e, 0x56, 0xeb, + 0x99, 0x22, 0xa4, 0xc7, 0xc5, 0x0a, 0x66, 0x4a, 0x30, 0x81, 0xf5, 0x48, 0x60, 0xe8, 0x31, 0x86, + 0xe8, 0x09, 0x82, 0x28, 0x53, 0x12, 0xe2, 0x12, 0x70, 0x4f, 0x2d, 0xf1, 0x49, 0x2c, 0x49, 0x2d, + 0x86, 0xb9, 0x54, 0xa9, 0x8a, 0x4b, 0x10, 0x49, 0x8c, 0xbe, 0xee, 0x91, 0xe0, 0x12, 0x83, 0xdb, + 0x8d, 0x12, 0x7e, 0x4a, 0x86, 0x5c, 0xe2, 0x18, 0x32, 0x50, 0xb7, 0xe1, 0x08, 0x5a, 0xa7, 0xf0, + 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, + 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, 0x96, 0x63, 0x88, 0xb2, 0x4d, 0xcf, 0x2c, 0xc9, 0x28, + 0x4d, 0x02, 0xb9, 0x46, 0x1f, 0x1e, 0x99, 0x70, 0x06, 0x38, 0x1a, 0xf5, 0x71, 0xa7, 0xa3, 0x24, + 0x36, 0xb0, 0x0a, 0x63, 0x40, 0x00, 0x00, 0x00, 0xff, 0xff, 0x52, 0x8e, 0xee, 0x85, 0x6c, 0x02, + 0x00, 0x00, +} + +func (m *GetByHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetByHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetByHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Height != 0 { + i = encodeVarintBlock(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *GetByHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetByHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetByHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Block != nil { + { + size, err := m.Block.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintBlock(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if m.BlockId != nil { + { + size, err := m.BlockId.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintBlock(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *GetLatestRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetLatestRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetLatestRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetLatestResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetLatestResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetLatestResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Block != nil { + { + size, err := m.Block.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintBlock(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + if m.BlockId != nil { + { + size, err := m.BlockId.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintBlock(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func (m *GetLatestHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetLatestHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetLatestHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetLatestHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetLatestHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetLatestHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Height != 0 { + i = encodeVarintBlock(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func encodeVarintBlock(dAtA []byte, offset int, v uint64) int { + offset -= sovBlock(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *GetByHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovBlock(uint64(m.Height)) + } + return n +} + +func (m *GetByHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.BlockId != nil { + l = m.BlockId.Size() + n += 1 + l + sovBlock(uint64(l)) + } + if m.Block != nil { + l = m.Block.Size() + n += 1 + l + sovBlock(uint64(l)) + } + return n +} + +func (m *GetLatestRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetLatestResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.BlockId != nil { + l = m.BlockId.Size() + n += 1 + l + sovBlock(uint64(l)) + } + if m.Block != nil { + l = m.Block.Size() + n += 1 + l + sovBlock(uint64(l)) + } + return n +} + +func (m *GetLatestHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetLatestHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovBlock(uint64(m.Height)) + } + return n +} + +func sovBlock(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 +} +func sozBlock(x uint64) (n int) { + return sovBlock(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (m *GetByHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetByHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetByHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipBlock(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthBlock + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetByHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetByHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetByHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field BlockId", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthBlock + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthBlock + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.BlockId == nil { + m.BlockId = &v1.BlockID{} + } + if err := m.BlockId.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Block", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthBlock + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthBlock + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Block == nil { + m.Block = &v3.Block{} + } + if err := m.Block.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipBlock(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthBlock + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetLatestRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetLatestRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetLatestRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipBlock(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthBlock + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetLatestResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetLatestResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetLatestResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field BlockId", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthBlock + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthBlock + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.BlockId == nil { + m.BlockId = &v1.BlockID{} + } + if err := m.BlockId.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Block", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthBlock + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthBlock + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.Block == nil { + m.Block = &v3.Block{} + } + if err := m.Block.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipBlock(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthBlock + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetLatestHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetLatestHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetLatestHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipBlock(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthBlock + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetLatestHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetLatestHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetLatestHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlock + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipBlock(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthBlock + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipBlock(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + depth := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowBlock + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowBlock + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + case 1: + iNdEx += 8 + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowBlock + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if length < 0 { + return 0, ErrInvalidLengthBlock + } + iNdEx += length + case 3: + depth++ + case 4: + if depth == 0 { + return 0, ErrUnexpectedEndOfGroupBlock + } + depth-- + case 5: + iNdEx += 4 + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + if iNdEx < 0 { + return 0, ErrInvalidLengthBlock + } + if depth == 0 { + return iNdEx, nil + } + } + return 0, io.ErrUnexpectedEOF +} + +var ( + ErrInvalidLengthBlock = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowBlock = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupBlock = fmt.Errorf("proto: unexpected end of group") +) diff --git a/api/cometbft/services/block/v1/block_service.pb.go b/api/cometbft/services/block/v1/block_service.pb.go new file mode 100644 index 00000000000..bd724f87b7a --- /dev/null +++ b/api/cometbft/services/block/v1/block_service.pb.go @@ -0,0 +1,241 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: cometbft/services/block/v1/block_service.proto + +package v1 + +import ( + context "context" + fmt "fmt" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" + math "math" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +func init() { + proto.RegisterFile("cometbft/services/block/v1/block_service.proto", fileDescriptor_5768ae424af71eff) +} + +var fileDescriptor_5768ae424af71eff = []byte{ + // 235 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x4b, 0xce, 0xcf, 0x4d, + 0x2d, 0x49, 0x4a, 0x2b, 0xd1, 0x2f, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0x2d, 0xd6, 0x4f, 0xca, + 0xc9, 0x4f, 0xce, 0xd6, 0x2f, 0x33, 0x84, 0x30, 0xe2, 0xa1, 0xe2, 0x7a, 0x05, 0x45, 0xf9, 0x25, + 0xf9, 0x42, 0x52, 0x30, 0xf5, 0x7a, 0x30, 0xf5, 0x7a, 0x60, 0x65, 0x7a, 0x65, 0x86, 0x52, 0x6a, + 0x84, 0xcc, 0x82, 0x98, 0x61, 0xf4, 0x8c, 0x89, 0x8b, 0xc7, 0x09, 0xc4, 0x0f, 0x86, 0x28, 0x13, + 0xca, 0xe3, 0xe2, 0x76, 0x4f, 0x2d, 0x71, 0xaa, 0xf4, 0x48, 0xcd, 0x4c, 0xcf, 0x28, 0x11, 0xd2, + 0xd3, 0xc3, 0x6d, 0x89, 0x1e, 0x92, 0xc2, 0xa0, 0xd4, 0xc2, 0xd2, 0xd4, 0xe2, 0x12, 0x29, 0x7d, + 0xa2, 0xd5, 0x17, 0x17, 0xe4, 0xe7, 0x15, 0xa7, 0x0a, 0x65, 0x70, 0x71, 0xba, 0xa7, 0x96, 0xf8, + 0x24, 0x96, 0xa4, 0x16, 0x97, 0x08, 0xe9, 0x10, 0xd0, 0x0d, 0x51, 0x06, 0xb3, 0x4b, 0x97, 0x48, + 0xd5, 0x50, 0x9b, 0x6a, 0xb8, 0xf8, 0xe1, 0x82, 0x50, 0xdf, 0x19, 0x11, 0x65, 0x02, 0xaa, 0x0f, + 0x8d, 0x49, 0xd2, 0x03, 0xb1, 0xdb, 0x80, 0xd1, 0x29, 0xfc, 0xc4, 0x23, 0x39, 0xc6, 0x0b, 0x8f, + 0xe4, 0x18, 0x1f, 0x3c, 0x92, 0x63, 0x9c, 0xf0, 0x58, 0x8e, 0xe1, 0xc2, 0x63, 0x39, 0x86, 0x1b, + 0x8f, 0xe5, 0x18, 0xa2, 0x6c, 0xd3, 0x33, 0x4b, 0x32, 0x4a, 0x93, 0x40, 0xc6, 0xea, 0xc3, 0x63, + 0x0d, 0xce, 0x00, 0x47, 0x93, 0x3e, 0xee, 0xd8, 0x4c, 0x62, 0x03, 0xab, 0x30, 0x06, 0x04, 0x00, + 0x00, 0xff, 0xff, 0x90, 0x85, 0xdb, 0xd8, 0x3e, 0x02, 0x00, 0x00, +} + +// Reference imports to suppress errors if they are not otherwise used. +var _ context.Context +var _ grpc.ClientConn + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +const _ = grpc.SupportPackageIsVersion4 + +// BlockServiceClient is the client API for BlockService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. +type BlockServiceClient interface { + // GetBlock retrieves the block information at a particular height. + GetByHeight(ctx context.Context, in *GetByHeightRequest, opts ...grpc.CallOption) (*GetByHeightResponse, error) + // GetLatest retrieves the latest block. + GetLatest(ctx context.Context, in *GetLatestRequest, opts ...grpc.CallOption) (*GetLatestResponse, error) + // GetLatestHeight returns a stream of the latest block heights committed by + // the network. This is a long-lived stream that is only terminated by the + // server if an error occurs. The caller is expected to handle such + // disconnections and automatically reconnect. + GetLatestHeight(ctx context.Context, in *GetLatestHeightRequest, opts ...grpc.CallOption) (BlockService_GetLatestHeightClient, error) +} + +type blockServiceClient struct { + cc grpc1.ClientConn +} + +func NewBlockServiceClient(cc grpc1.ClientConn) BlockServiceClient { + return &blockServiceClient{cc} +} + +func (c *blockServiceClient) GetByHeight(ctx context.Context, in *GetByHeightRequest, opts ...grpc.CallOption) (*GetByHeightResponse, error) { + out := new(GetByHeightResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.block.v1.BlockService/GetByHeight", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *blockServiceClient) GetLatest(ctx context.Context, in *GetLatestRequest, opts ...grpc.CallOption) (*GetLatestResponse, error) { + out := new(GetLatestResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.block.v1.BlockService/GetLatest", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *blockServiceClient) GetLatestHeight(ctx context.Context, in *GetLatestHeightRequest, opts ...grpc.CallOption) (BlockService_GetLatestHeightClient, error) { + stream, err := c.cc.NewStream(ctx, &_BlockService_serviceDesc.Streams[0], "/cometbft.services.block.v1.BlockService/GetLatestHeight", opts...) + if err != nil { + return nil, err + } + x := &blockServiceGetLatestHeightClient{stream} + if err := x.ClientStream.SendMsg(in); err != nil { + return nil, err + } + if err := x.ClientStream.CloseSend(); err != nil { + return nil, err + } + return x, nil +} + +type BlockService_GetLatestHeightClient interface { + Recv() (*GetLatestHeightResponse, error) + grpc.ClientStream +} + +type blockServiceGetLatestHeightClient struct { + grpc.ClientStream +} + +func (x *blockServiceGetLatestHeightClient) Recv() (*GetLatestHeightResponse, error) { + m := new(GetLatestHeightResponse) + if err := x.ClientStream.RecvMsg(m); err != nil { + return nil, err + } + return m, nil +} + +// BlockServiceServer is the server API for BlockService service. +type BlockServiceServer interface { + // GetBlock retrieves the block information at a particular height. + GetByHeight(context.Context, *GetByHeightRequest) (*GetByHeightResponse, error) + // GetLatest retrieves the latest block. + GetLatest(context.Context, *GetLatestRequest) (*GetLatestResponse, error) + // GetLatestHeight returns a stream of the latest block heights committed by + // the network. This is a long-lived stream that is only terminated by the + // server if an error occurs. The caller is expected to handle such + // disconnections and automatically reconnect. + GetLatestHeight(*GetLatestHeightRequest, BlockService_GetLatestHeightServer) error +} + +// UnimplementedBlockServiceServer can be embedded to have forward compatible implementations. +type UnimplementedBlockServiceServer struct { +} + +func (*UnimplementedBlockServiceServer) GetByHeight(ctx context.Context, req *GetByHeightRequest) (*GetByHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetByHeight not implemented") +} +func (*UnimplementedBlockServiceServer) GetLatest(ctx context.Context, req *GetLatestRequest) (*GetLatestResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetLatest not implemented") +} +func (*UnimplementedBlockServiceServer) GetLatestHeight(req *GetLatestHeightRequest, srv BlockService_GetLatestHeightServer) error { + return status.Errorf(codes.Unimplemented, "method GetLatestHeight not implemented") +} + +func RegisterBlockServiceServer(s grpc1.Server, srv BlockServiceServer) { + s.RegisterService(&_BlockService_serviceDesc, srv) +} + +func _BlockService_GetByHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetByHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlockServiceServer).GetByHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.block.v1.BlockService/GetByHeight", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlockServiceServer).GetByHeight(ctx, req.(*GetByHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _BlockService_GetLatest_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetLatestRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlockServiceServer).GetLatest(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.block.v1.BlockService/GetLatest", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlockServiceServer).GetLatest(ctx, req.(*GetLatestRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _BlockService_GetLatestHeight_Handler(srv interface{}, stream grpc.ServerStream) error { + m := new(GetLatestHeightRequest) + if err := stream.RecvMsg(m); err != nil { + return err + } + return srv.(BlockServiceServer).GetLatestHeight(m, &blockServiceGetLatestHeightServer{stream}) +} + +type BlockService_GetLatestHeightServer interface { + Send(*GetLatestHeightResponse) error + grpc.ServerStream +} + +type blockServiceGetLatestHeightServer struct { + grpc.ServerStream +} + +func (x *blockServiceGetLatestHeightServer) Send(m *GetLatestHeightResponse) error { + return x.ServerStream.SendMsg(m) +} + +var _BlockService_serviceDesc = grpc.ServiceDesc{ + ServiceName: "cometbft.services.block.v1.BlockService", + HandlerType: (*BlockServiceServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "GetByHeight", + Handler: _BlockService_GetByHeight_Handler, + }, + { + MethodName: "GetLatest", + Handler: _BlockService_GetLatest_Handler, + }, + }, + Streams: []grpc.StreamDesc{ + { + StreamName: "GetLatestHeight", + Handler: _BlockService_GetLatestHeight_Handler, + ServerStreams: true, + }, + }, + Metadata: "cometbft/services/block/v1/block_service.proto", +} diff --git a/api/cometbft/services/block_results/v1/block_results.pb.go b/api/cometbft/services/block_results/v1/block_results.pb.go new file mode 100644 index 00000000000..4c0f588acf5 --- /dev/null +++ b/api/cometbft/services/block_results/v1/block_results.pb.go @@ -0,0 +1,893 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: cometbft/services/block_results/v1/block_results.proto + +package v1 + +import ( + fmt "fmt" + v1 "github.com/cometbft/cometbft/api/cometbft/abci/v1" + v2 "github.com/cometbft/cometbft/api/cometbft/abci/v2" + v3 "github.com/cometbft/cometbft/api/cometbft/abci/v3" + v31 "github.com/cometbft/cometbft/api/cometbft/types/v3" + proto "github.com/cosmos/gogoproto/proto" + io "io" + math "math" + math_bits "math/bits" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +type GetBlockResultsRequest struct { + Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` +} + +func (m *GetBlockResultsRequest) Reset() { *m = GetBlockResultsRequest{} } +func (m *GetBlockResultsRequest) String() string { return proto.CompactTextString(m) } +func (*GetBlockResultsRequest) ProtoMessage() {} +func (*GetBlockResultsRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3fd862496bf20f1b, []int{0} +} +func (m *GetBlockResultsRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetBlockResultsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetBlockResultsRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetBlockResultsRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetBlockResultsRequest.Merge(m, src) +} +func (m *GetBlockResultsRequest) XXX_Size() int { + return m.Size() +} +func (m *GetBlockResultsRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetBlockResultsRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetBlockResultsRequest proto.InternalMessageInfo + +func (m *GetBlockResultsRequest) GetHeight() int64 { + if m != nil { + return m.Height + } + return 0 +} + +type GetLatestBlockResultsRequest struct { +} + +func (m *GetLatestBlockResultsRequest) Reset() { *m = GetLatestBlockResultsRequest{} } +func (m *GetLatestBlockResultsRequest) String() string { return proto.CompactTextString(m) } +func (*GetLatestBlockResultsRequest) ProtoMessage() {} +func (*GetLatestBlockResultsRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_3fd862496bf20f1b, []int{1} +} +func (m *GetLatestBlockResultsRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetLatestBlockResultsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetLatestBlockResultsRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetLatestBlockResultsRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetLatestBlockResultsRequest.Merge(m, src) +} +func (m *GetLatestBlockResultsRequest) XXX_Size() int { + return m.Size() +} +func (m *GetLatestBlockResultsRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetLatestBlockResultsRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetLatestBlockResultsRequest proto.InternalMessageInfo + +type GetBlockResultsResponse struct { + Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` + TxsResults []*v3.ExecTxResult `protobuf:"bytes,2,rep,name=txs_results,json=txsResults,proto3" json:"txs_results,omitempty"` + FinalizeBlockEvents []*v2.Event `protobuf:"bytes,3,rep,name=finalize_block_events,json=finalizeBlockEvents,proto3" json:"finalize_block_events,omitempty"` + ValidatorUpdates []*v1.ValidatorUpdate `protobuf:"bytes,4,rep,name=validator_updates,json=validatorUpdates,proto3" json:"validator_updates,omitempty"` + ConsensusParamUpdates *v31.ConsensusParams `protobuf:"bytes,5,opt,name=consensus_param_updates,json=consensusParamUpdates,proto3" json:"consensus_param_updates,omitempty"` + AppHash []byte `protobuf:"bytes,6,opt,name=app_hash,json=appHash,proto3" json:"app_hash,omitempty"` +} + +func (m *GetBlockResultsResponse) Reset() { *m = GetBlockResultsResponse{} } +func (m *GetBlockResultsResponse) String() string { return proto.CompactTextString(m) } +func (*GetBlockResultsResponse) ProtoMessage() {} +func (*GetBlockResultsResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_3fd862496bf20f1b, []int{2} +} +func (m *GetBlockResultsResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetBlockResultsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetBlockResultsResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetBlockResultsResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetBlockResultsResponse.Merge(m, src) +} +func (m *GetBlockResultsResponse) XXX_Size() int { + return m.Size() +} +func (m *GetBlockResultsResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetBlockResultsResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetBlockResultsResponse proto.InternalMessageInfo + +func (m *GetBlockResultsResponse) GetHeight() int64 { + if m != nil { + return m.Height + } + return 0 +} + +func (m *GetBlockResultsResponse) GetTxsResults() []*v3.ExecTxResult { + if m != nil { + return m.TxsResults + } + return nil +} + +func (m *GetBlockResultsResponse) GetFinalizeBlockEvents() []*v2.Event { + if m != nil { + return m.FinalizeBlockEvents + } + return nil +} + +func (m *GetBlockResultsResponse) GetValidatorUpdates() []*v1.ValidatorUpdate { + if m != nil { + return m.ValidatorUpdates + } + return nil +} + +func (m *GetBlockResultsResponse) GetConsensusParamUpdates() *v31.ConsensusParams { + if m != nil { + return m.ConsensusParamUpdates + } + return nil +} + +func (m *GetBlockResultsResponse) GetAppHash() []byte { + if m != nil { + return m.AppHash + } + return nil +} + +func init() { + proto.RegisterType((*GetBlockResultsRequest)(nil), "cometbft.services.block_results.v1.GetBlockResultsRequest") + proto.RegisterType((*GetLatestBlockResultsRequest)(nil), "cometbft.services.block_results.v1.GetLatestBlockResultsRequest") + proto.RegisterType((*GetBlockResultsResponse)(nil), "cometbft.services.block_results.v1.GetBlockResultsResponse") +} + +func init() { + proto.RegisterFile("cometbft/services/block_results/v1/block_results.proto", fileDescriptor_3fd862496bf20f1b) +} + +var fileDescriptor_3fd862496bf20f1b = []byte{ + // 421 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x92, 0xcf, 0x6e, 0xd3, 0x40, + 0x10, 0xc6, 0x63, 0x02, 0x01, 0x6d, 0x38, 0x80, 0x51, 0x1b, 0x83, 0xaa, 0x55, 0xf0, 0x29, 0xa7, + 0x35, 0x49, 0x24, 0xae, 0x48, 0x45, 0x51, 0x91, 0x40, 0x08, 0xad, 0x80, 0x43, 0x2f, 0xd6, 0xda, + 0x9d, 0xd6, 0x16, 0xae, 0xbd, 0x78, 0xd6, 0x2b, 0xc3, 0x03, 0x70, 0xe6, 0xb1, 0x38, 0xf6, 0xc8, + 0x11, 0x25, 0x2f, 0x82, 0x76, 0xfd, 0x07, 0xb9, 0x01, 0x7a, 0xb3, 0xbf, 0x6f, 0xbe, 0xdf, 0xee, + 0xcc, 0x0e, 0x79, 0x1e, 0x17, 0x97, 0xa0, 0xa2, 0x73, 0x15, 0x20, 0x94, 0x3a, 0x8d, 0x01, 0x83, + 0x28, 0x2b, 0xe2, 0x4f, 0x61, 0x09, 0x58, 0x65, 0x0a, 0x03, 0xbd, 0x1c, 0x0a, 0x4c, 0x96, 0x85, + 0x2a, 0x5c, 0xbf, 0xcb, 0xb1, 0x2e, 0xc7, 0x86, 0x65, 0x7a, 0xf9, 0xe4, 0xa8, 0x67, 0x8b, 0x28, + 0x4e, 0x0d, 0x49, 0x7d, 0x91, 0xd0, 0x12, 0xf6, 0xdc, 0xd5, 0x7f, 0xdd, 0xf5, 0xc0, 0xa5, 0xbd, + 0x6b, 0x55, 0x63, 0x4b, 0x51, 0x8a, 0xcb, 0xd6, 0xf7, 0x9f, 0x91, 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x3e, + 0x17, 0x3f, 0x88, 0x07, 0x42, 0xc7, 0x7e, 0x4c, 0xee, 0x09, 0x29, 0xc3, 0x44, 0x60, 0xe2, 0x4d, + 0xe6, 0xce, 0xe2, 0x3e, 0xbf, 0x2b, 0xa4, 0x7c, 0x25, 0x30, 0x39, 0x0e, 0x7f, 0x6c, 0xa9, 0x73, + 0xb5, 0xa5, 0xce, 0xaf, 0x2d, 0x75, 0xbe, 0xef, 0xe8, 0xe8, 0x6a, 0x47, 0x47, 0x3f, 0x77, 0x74, + 0x74, 0xba, 0xb9, 0x48, 0x55, 0x52, 0x45, 0xe6, 0xd4, 0xa0, 0xdf, 0x8f, 0xfe, 0xc3, 0x2e, 0x46, + 0x70, 0xf3, 0xb6, 0x47, 0x13, 0x5b, 0xb9, 0xfe, 0x1d, 0x00, 0x00, 0xff, 0xff, 0xbf, 0x95, 0x8d, + 0x75, 0x1a, 0x03, 0x00, 0x00, +} + +func (m *GetBlockResultsRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetBlockResultsRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetBlockResultsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Height != 0 { + i = encodeVarintBlockResults(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *GetLatestBlockResultsRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetLatestBlockResultsRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetLatestBlockResultsRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetBlockResultsResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetBlockResultsResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetBlockResultsResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if len(m.AppHash) > 0 { + i -= len(m.AppHash) + copy(dAtA[i:], m.AppHash) + i = encodeVarintBlockResults(dAtA, i, uint64(len(m.AppHash))) + i-- + dAtA[i] = 0x32 + } + if m.ConsensusParamUpdates != nil { + { + size, err := m.ConsensusParamUpdates.MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintBlockResults(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x2a + } + if len(m.ValidatorUpdates) > 0 { + for iNdEx := len(m.ValidatorUpdates) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.ValidatorUpdates[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintBlockResults(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x22 + } + } + if len(m.FinalizeBlockEvents) > 0 { + for iNdEx := len(m.FinalizeBlockEvents) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.FinalizeBlockEvents[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintBlockResults(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x1a + } + } + if len(m.TxsResults) > 0 { + for iNdEx := len(m.TxsResults) - 1; iNdEx >= 0; iNdEx-- { + { + size, err := m.TxsResults[iNdEx].MarshalToSizedBuffer(dAtA[:i]) + if err != nil { + return 0, err + } + i -= size + i = encodeVarintBlockResults(dAtA, i, uint64(size)) + } + i-- + dAtA[i] = 0x12 + } + } + if m.Height != 0 { + i = encodeVarintBlockResults(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func encodeVarintBlockResults(dAtA []byte, offset int, v uint64) int { + offset -= sovBlockResults(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *GetBlockResultsRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovBlockResults(uint64(m.Height)) + } + return n +} + +func (m *GetLatestBlockResultsRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetBlockResultsResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovBlockResults(uint64(m.Height)) + } + if len(m.TxsResults) > 0 { + for _, e := range m.TxsResults { + l = e.Size() + n += 1 + l + sovBlockResults(uint64(l)) + } + } + if len(m.FinalizeBlockEvents) > 0 { + for _, e := range m.FinalizeBlockEvents { + l = e.Size() + n += 1 + l + sovBlockResults(uint64(l)) + } + } + if len(m.ValidatorUpdates) > 0 { + for _, e := range m.ValidatorUpdates { + l = e.Size() + n += 1 + l + sovBlockResults(uint64(l)) + } + } + if m.ConsensusParamUpdates != nil { + l = m.ConsensusParamUpdates.Size() + n += 1 + l + sovBlockResults(uint64(l)) + } + l = len(m.AppHash) + if l > 0 { + n += 1 + l + sovBlockResults(uint64(l)) + } + return n +} + +func sovBlockResults(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 +} +func sozBlockResults(x uint64) (n int) { + return sovBlockResults(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (m *GetBlockResultsRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetBlockResultsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetBlockResultsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipBlockResults(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthBlockResults + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetLatestBlockResultsRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetLatestBlockResultsRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetLatestBlockResultsRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipBlockResults(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthBlockResults + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetBlockResultsResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetBlockResultsResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetBlockResultsResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= int64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field TxsResults", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthBlockResults + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthBlockResults + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.TxsResults = append(m.TxsResults, &v3.ExecTxResult{}) + if err := m.TxsResults[len(m.TxsResults)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 3: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field FinalizeBlockEvents", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthBlockResults + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthBlockResults + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.FinalizeBlockEvents = append(m.FinalizeBlockEvents, &v2.Event{}) + if err := m.FinalizeBlockEvents[len(m.FinalizeBlockEvents)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 4: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ValidatorUpdates", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthBlockResults + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthBlockResults + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.ValidatorUpdates = append(m.ValidatorUpdates, &v1.ValidatorUpdate{}) + if err := m.ValidatorUpdates[len(m.ValidatorUpdates)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 5: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field ConsensusParamUpdates", wireType) + } + var msglen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + msglen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if msglen < 0 { + return ErrInvalidLengthBlockResults + } + postIndex := iNdEx + msglen + if postIndex < 0 { + return ErrInvalidLengthBlockResults + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + if m.ConsensusParamUpdates == nil { + m.ConsensusParamUpdates = &v31.ConsensusParams{} + } + if err := m.ConsensusParamUpdates.Unmarshal(dAtA[iNdEx:postIndex]); err != nil { + return err + } + iNdEx = postIndex + case 6: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field AppHash", wireType) + } + var byteLen int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowBlockResults + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + byteLen |= int(b&0x7F) << shift + if b < 0x80 { + break + } + } + if byteLen < 0 { + return ErrInvalidLengthBlockResults + } + postIndex := iNdEx + byteLen + if postIndex < 0 { + return ErrInvalidLengthBlockResults + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.AppHash = append(m.AppHash[:0], dAtA[iNdEx:postIndex]...) + if m.AppHash == nil { + m.AppHash = []byte{} + } + iNdEx = postIndex + default: + iNdEx = preIndex + skippy, err := skipBlockResults(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthBlockResults + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipBlockResults(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + depth := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowBlockResults + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowBlockResults + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + case 1: + iNdEx += 8 + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowBlockResults + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if length < 0 { + return 0, ErrInvalidLengthBlockResults + } + iNdEx += length + case 3: + depth++ + case 4: + if depth == 0 { + return 0, ErrUnexpectedEndOfGroupBlockResults + } + depth-- + case 5: + iNdEx += 4 + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + if iNdEx < 0 { + return 0, ErrInvalidLengthBlockResults + } + if depth == 0 { + return iNdEx, nil + } + } + return 0, io.ErrUnexpectedEOF +} + +var ( + ErrInvalidLengthBlockResults = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowBlockResults = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupBlockResults = fmt.Errorf("proto: unexpected end of group") +) diff --git a/api/cometbft/services/block_results/v1/block_results_service.pb.go b/api/cometbft/services/block_results/v1/block_results_service.pb.go new file mode 100644 index 00000000000..6046ec7a889 --- /dev/null +++ b/api/cometbft/services/block_results/v1/block_results_service.pb.go @@ -0,0 +1,168 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: cometbft/services/block_results/v1/block_results_service.proto + +package v1 + +import ( + context "context" + fmt "fmt" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" + math "math" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +func init() { + proto.RegisterFile("cometbft/services/block_results/v1/block_results_service.proto", fileDescriptor_03cd7b7c1632b595) +} + +var fileDescriptor_03cd7b7c1632b595 = []byte{ + // 218 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xb2, 0x4b, 0xce, 0xcf, 0x4d, + 0x2d, 0x49, 0x4a, 0x2b, 0xd1, 0x2f, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0x2d, 0xd6, 0x4f, 0xca, + 0xc9, 0x4f, 0xce, 0x8e, 0x2f, 0x4a, 0x2d, 0x2e, 0xcd, 0x29, 0x29, 0xd6, 0x2f, 0x33, 0x44, 0x15, + 0x88, 0x87, 0xaa, 0xd3, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x52, 0x82, 0xe9, 0xd7, 0x83, 0xe9, + 0xd7, 0x43, 0x51, 0xae, 0x57, 0x66, 0x28, 0x65, 0x46, 0xaa, 0x1d, 0x10, 0xb3, 0x8d, 0x76, 0x33, + 0x71, 0x09, 0x3b, 0x81, 0xc4, 0x83, 0x20, 0xc2, 0xc1, 0x10, 0xdd, 0x42, 0x5d, 0x8c, 0x5c, 0xfc, + 0xee, 0xa9, 0x25, 0xc8, 0x52, 0x42, 0x56, 0x7a, 0x84, 0x1d, 0xa2, 0x87, 0xa6, 0x29, 0x28, 0xb5, + 0xb0, 0x34, 0xb5, 0xb8, 0x44, 0xca, 0x9a, 0x2c, 0xbd, 0xc5, 0x05, 0xf9, 0x79, 0xc5, 0xa9, 0x42, + 0xd3, 0x18, 0xb9, 0x44, 0xdd, 0x53, 0x4b, 0x7c, 0x12, 0x4b, 0x52, 0x8b, 0x51, 0x9d, 0xe4, 0x40, + 0xa4, 0xb1, 0x98, 0x5a, 0xa9, 0xe1, 0x30, 0xa7, 0xf8, 0x13, 0x8f, 0xe4, 0x18, 0x2f, 0x3c, 0x92, + 0x63, 0x7c, 0xf0, 0x48, 0x8e, 0x71, 0xc2, 0x63, 0x39, 0x86, 0x0b, 0x8f, 0xe5, 0x18, 0x6e, 0x3c, + 0x96, 0x63, 0x88, 0x72, 0x4d, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0x02, 0x19, 0xae, 0x0f, 0x8f, 0x1a, + 0x38, 0x03, 0x1c, 0xf6, 0xfa, 0x84, 0xa3, 0x2c, 0x89, 0x0d, 0xac, 0xd2, 0x18, 0x10, 0x00, 0x00, + 0xff, 0xff, 0x09, 0xe2, 0x0f, 0x9d, 0x43, 0x02, 0x00, 0x00, +} + +// Reference imports to suppress errors if they are not otherwise used. +var _ context.Context +var _ grpc.ClientConn + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +const _ = grpc.SupportPackageIsVersion4 + +// BlockResultsServiceClient is the client API for BlockResultsService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. +type BlockResultsServiceClient interface { + // GetBlockResults returns the BlockResults of the requested height. + GetBlockResults(ctx context.Context, in *GetBlockResultsRequest, opts ...grpc.CallOption) (*GetBlockResultsResponse, error) + // GetLatestBlockResults returns the BlockResults of the latest committed height. + GetLatestBlockResults(ctx context.Context, in *GetLatestBlockResultsRequest, opts ...grpc.CallOption) (*GetBlockResultsResponse, error) +} + +type blockResultsServiceClient struct { + cc grpc1.ClientConn +} + +func NewBlockResultsServiceClient(cc grpc1.ClientConn) BlockResultsServiceClient { + return &blockResultsServiceClient{cc} +} + +func (c *blockResultsServiceClient) GetBlockResults(ctx context.Context, in *GetBlockResultsRequest, opts ...grpc.CallOption) (*GetBlockResultsResponse, error) { + out := new(GetBlockResultsResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.block_results.v1.BlockResultsService/GetBlockResults", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *blockResultsServiceClient) GetLatestBlockResults(ctx context.Context, in *GetLatestBlockResultsRequest, opts ...grpc.CallOption) (*GetBlockResultsResponse, error) { + out := new(GetBlockResultsResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.block_results.v1.BlockResultsService/GetLatestBlockResults", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// BlockResultsServiceServer is the server API for BlockResultsService service. +type BlockResultsServiceServer interface { + // GetBlockResults returns the BlockResults of the requested height. + GetBlockResults(context.Context, *GetBlockResultsRequest) (*GetBlockResultsResponse, error) + // GetLatestBlockResults returns the BlockResults of the latest committed height. + GetLatestBlockResults(context.Context, *GetLatestBlockResultsRequest) (*GetBlockResultsResponse, error) +} + +// UnimplementedBlockResultsServiceServer can be embedded to have forward compatible implementations. +type UnimplementedBlockResultsServiceServer struct { +} + +func (*UnimplementedBlockResultsServiceServer) GetBlockResults(ctx context.Context, req *GetBlockResultsRequest) (*GetBlockResultsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetBlockResults not implemented") +} +func (*UnimplementedBlockResultsServiceServer) GetLatestBlockResults(ctx context.Context, req *GetLatestBlockResultsRequest) (*GetBlockResultsResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetLatestBlockResults not implemented") +} + +func RegisterBlockResultsServiceServer(s grpc1.Server, srv BlockResultsServiceServer) { + s.RegisterService(&_BlockResultsService_serviceDesc, srv) +} + +func _BlockResultsService_GetBlockResults_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetBlockResultsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlockResultsServiceServer).GetBlockResults(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.block_results.v1.BlockResultsService/GetBlockResults", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlockResultsServiceServer).GetBlockResults(ctx, req.(*GetBlockResultsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _BlockResultsService_GetLatestBlockResults_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetLatestBlockResultsRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(BlockResultsServiceServer).GetLatestBlockResults(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.block_results.v1.BlockResultsService/GetLatestBlockResults", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(BlockResultsServiceServer).GetLatestBlockResults(ctx, req.(*GetLatestBlockResultsRequest)) + } + return interceptor(ctx, in, info, handler) +} + +var _BlockResultsService_serviceDesc = grpc.ServiceDesc{ + ServiceName: "cometbft.services.block_results.v1.BlockResultsService", + HandlerType: (*BlockResultsServiceServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "GetBlockResults", + Handler: _BlockResultsService_GetBlockResults_Handler, + }, + { + MethodName: "GetLatestBlockResults", + Handler: _BlockResultsService_GetLatestBlockResults_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "cometbft/services/block_results/v1/block_results_service.proto", +} diff --git a/api/cometbft/services/pruning/v1/pruning.pb.go b/api/cometbft/services/pruning/v1/pruning.pb.go new file mode 100644 index 00000000000..fde12bfeff8 --- /dev/null +++ b/api/cometbft/services/pruning/v1/pruning.pb.go @@ -0,0 +1,2381 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: cometbft/services/pruning/v1/pruning.proto + +package cometbft_services_pruning_v1 + +import ( + fmt "fmt" + proto "github.com/cosmos/gogoproto/proto" + io "io" + math "math" + math_bits "math/bits" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +type SetBlockRetainHeightRequest struct { + Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` +} + +func (m *SetBlockRetainHeightRequest) Reset() { *m = SetBlockRetainHeightRequest{} } +func (m *SetBlockRetainHeightRequest) String() string { return proto.CompactTextString(m) } +func (*SetBlockRetainHeightRequest) ProtoMessage() {} +func (*SetBlockRetainHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{0} +} +func (m *SetBlockRetainHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SetBlockRetainHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SetBlockRetainHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SetBlockRetainHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SetBlockRetainHeightRequest.Merge(m, src) +} +func (m *SetBlockRetainHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *SetBlockRetainHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_SetBlockRetainHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_SetBlockRetainHeightRequest proto.InternalMessageInfo + +func (m *SetBlockRetainHeightRequest) GetHeight() uint64 { + if m != nil { + return m.Height + } + return 0 +} + +type SetBlockRetainHeightResponse struct { +} + +func (m *SetBlockRetainHeightResponse) Reset() { *m = SetBlockRetainHeightResponse{} } +func (m *SetBlockRetainHeightResponse) String() string { return proto.CompactTextString(m) } +func (*SetBlockRetainHeightResponse) ProtoMessage() {} +func (*SetBlockRetainHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{1} +} +func (m *SetBlockRetainHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SetBlockRetainHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SetBlockRetainHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SetBlockRetainHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_SetBlockRetainHeightResponse.Merge(m, src) +} +func (m *SetBlockRetainHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *SetBlockRetainHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_SetBlockRetainHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_SetBlockRetainHeightResponse proto.InternalMessageInfo + +type GetBlockRetainHeightRequest struct { +} + +func (m *GetBlockRetainHeightRequest) Reset() { *m = GetBlockRetainHeightRequest{} } +func (m *GetBlockRetainHeightRequest) String() string { return proto.CompactTextString(m) } +func (*GetBlockRetainHeightRequest) ProtoMessage() {} +func (*GetBlockRetainHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{2} +} +func (m *GetBlockRetainHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetBlockRetainHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetBlockRetainHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetBlockRetainHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetBlockRetainHeightRequest.Merge(m, src) +} +func (m *GetBlockRetainHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *GetBlockRetainHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetBlockRetainHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetBlockRetainHeightRequest proto.InternalMessageInfo + +type GetBlockRetainHeightResponse struct { + // The retain height set by the application. + AppRetainHeight uint64 `protobuf:"varint,1,opt,name=app_retain_height,json=appRetainHeight,proto3" json:"app_retain_height,omitempty"` + // The retain height set via the pruning service (e.g. by the data + // companion) specifically for blocks. + PruningServiceRetainHeight uint64 `protobuf:"varint,2,opt,name=pruning_service_retain_height,json=pruningServiceRetainHeight,proto3" json:"pruning_service_retain_height,omitempty"` +} + +func (m *GetBlockRetainHeightResponse) Reset() { *m = GetBlockRetainHeightResponse{} } +func (m *GetBlockRetainHeightResponse) String() string { return proto.CompactTextString(m) } +func (*GetBlockRetainHeightResponse) ProtoMessage() {} +func (*GetBlockRetainHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{3} +} +func (m *GetBlockRetainHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetBlockRetainHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetBlockRetainHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetBlockRetainHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetBlockRetainHeightResponse.Merge(m, src) +} +func (m *GetBlockRetainHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *GetBlockRetainHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetBlockRetainHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetBlockRetainHeightResponse proto.InternalMessageInfo + +func (m *GetBlockRetainHeightResponse) GetAppRetainHeight() uint64 { + if m != nil { + return m.AppRetainHeight + } + return 0 +} + +func (m *GetBlockRetainHeightResponse) GetPruningServiceRetainHeight() uint64 { + if m != nil { + return m.PruningServiceRetainHeight + } + return 0 +} + +type SetBlockResultsRetainHeightRequest struct { + Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` +} + +func (m *SetBlockResultsRetainHeightRequest) Reset() { *m = SetBlockResultsRetainHeightRequest{} } +func (m *SetBlockResultsRetainHeightRequest) String() string { return proto.CompactTextString(m) } +func (*SetBlockResultsRetainHeightRequest) ProtoMessage() {} +func (*SetBlockResultsRetainHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{4} +} +func (m *SetBlockResultsRetainHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SetBlockResultsRetainHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SetBlockResultsRetainHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SetBlockResultsRetainHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SetBlockResultsRetainHeightRequest.Merge(m, src) +} +func (m *SetBlockResultsRetainHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *SetBlockResultsRetainHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_SetBlockResultsRetainHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_SetBlockResultsRetainHeightRequest proto.InternalMessageInfo + +func (m *SetBlockResultsRetainHeightRequest) GetHeight() uint64 { + if m != nil { + return m.Height + } + return 0 +} + +type SetBlockResultsRetainHeightResponse struct { +} + +func (m *SetBlockResultsRetainHeightResponse) Reset() { *m = SetBlockResultsRetainHeightResponse{} } +func (m *SetBlockResultsRetainHeightResponse) String() string { return proto.CompactTextString(m) } +func (*SetBlockResultsRetainHeightResponse) ProtoMessage() {} +func (*SetBlockResultsRetainHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{5} +} +func (m *SetBlockResultsRetainHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SetBlockResultsRetainHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SetBlockResultsRetainHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SetBlockResultsRetainHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_SetBlockResultsRetainHeightResponse.Merge(m, src) +} +func (m *SetBlockResultsRetainHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *SetBlockResultsRetainHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_SetBlockResultsRetainHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_SetBlockResultsRetainHeightResponse proto.InternalMessageInfo + +type GetBlockResultsRetainHeightRequest struct { +} + +func (m *GetBlockResultsRetainHeightRequest) Reset() { *m = GetBlockResultsRetainHeightRequest{} } +func (m *GetBlockResultsRetainHeightRequest) String() string { return proto.CompactTextString(m) } +func (*GetBlockResultsRetainHeightRequest) ProtoMessage() {} +func (*GetBlockResultsRetainHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{6} +} +func (m *GetBlockResultsRetainHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetBlockResultsRetainHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetBlockResultsRetainHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetBlockResultsRetainHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetBlockResultsRetainHeightRequest.Merge(m, src) +} +func (m *GetBlockResultsRetainHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *GetBlockResultsRetainHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetBlockResultsRetainHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetBlockResultsRetainHeightRequest proto.InternalMessageInfo + +type GetBlockResultsRetainHeightResponse struct { + // The retain height set by the pruning service (e.g. by the data + // companion) specifically for block results. + PruningServiceRetainHeight uint64 `protobuf:"varint,1,opt,name=pruning_service_retain_height,json=pruningServiceRetainHeight,proto3" json:"pruning_service_retain_height,omitempty"` +} + +func (m *GetBlockResultsRetainHeightResponse) Reset() { *m = GetBlockResultsRetainHeightResponse{} } +func (m *GetBlockResultsRetainHeightResponse) String() string { return proto.CompactTextString(m) } +func (*GetBlockResultsRetainHeightResponse) ProtoMessage() {} +func (*GetBlockResultsRetainHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{7} +} +func (m *GetBlockResultsRetainHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetBlockResultsRetainHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetBlockResultsRetainHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetBlockResultsRetainHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetBlockResultsRetainHeightResponse.Merge(m, src) +} +func (m *GetBlockResultsRetainHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *GetBlockResultsRetainHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetBlockResultsRetainHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetBlockResultsRetainHeightResponse proto.InternalMessageInfo + +func (m *GetBlockResultsRetainHeightResponse) GetPruningServiceRetainHeight() uint64 { + if m != nil { + return m.PruningServiceRetainHeight + } + return 0 +} + +type SetTxIndexerRetainHeightRequest struct { + Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` +} + +func (m *SetTxIndexerRetainHeightRequest) Reset() { *m = SetTxIndexerRetainHeightRequest{} } +func (m *SetTxIndexerRetainHeightRequest) String() string { return proto.CompactTextString(m) } +func (*SetTxIndexerRetainHeightRequest) ProtoMessage() {} +func (*SetTxIndexerRetainHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{8} +} +func (m *SetTxIndexerRetainHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SetTxIndexerRetainHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SetTxIndexerRetainHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SetTxIndexerRetainHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SetTxIndexerRetainHeightRequest.Merge(m, src) +} +func (m *SetTxIndexerRetainHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *SetTxIndexerRetainHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_SetTxIndexerRetainHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_SetTxIndexerRetainHeightRequest proto.InternalMessageInfo + +func (m *SetTxIndexerRetainHeightRequest) GetHeight() uint64 { + if m != nil { + return m.Height + } + return 0 +} + +type SetTxIndexerRetainHeightResponse struct { +} + +func (m *SetTxIndexerRetainHeightResponse) Reset() { *m = SetTxIndexerRetainHeightResponse{} } +func (m *SetTxIndexerRetainHeightResponse) String() string { return proto.CompactTextString(m) } +func (*SetTxIndexerRetainHeightResponse) ProtoMessage() {} +func (*SetTxIndexerRetainHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{9} +} +func (m *SetTxIndexerRetainHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SetTxIndexerRetainHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SetTxIndexerRetainHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SetTxIndexerRetainHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_SetTxIndexerRetainHeightResponse.Merge(m, src) +} +func (m *SetTxIndexerRetainHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *SetTxIndexerRetainHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_SetTxIndexerRetainHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_SetTxIndexerRetainHeightResponse proto.InternalMessageInfo + +type GetTxIndexerRetainHeightRequest struct { +} + +func (m *GetTxIndexerRetainHeightRequest) Reset() { *m = GetTxIndexerRetainHeightRequest{} } +func (m *GetTxIndexerRetainHeightRequest) String() string { return proto.CompactTextString(m) } +func (*GetTxIndexerRetainHeightRequest) ProtoMessage() {} +func (*GetTxIndexerRetainHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{10} +} +func (m *GetTxIndexerRetainHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetTxIndexerRetainHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetTxIndexerRetainHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetTxIndexerRetainHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetTxIndexerRetainHeightRequest.Merge(m, src) +} +func (m *GetTxIndexerRetainHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *GetTxIndexerRetainHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetTxIndexerRetainHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetTxIndexerRetainHeightRequest proto.InternalMessageInfo + +type GetTxIndexerRetainHeightResponse struct { + Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` +} + +func (m *GetTxIndexerRetainHeightResponse) Reset() { *m = GetTxIndexerRetainHeightResponse{} } +func (m *GetTxIndexerRetainHeightResponse) String() string { return proto.CompactTextString(m) } +func (*GetTxIndexerRetainHeightResponse) ProtoMessage() {} +func (*GetTxIndexerRetainHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{11} +} +func (m *GetTxIndexerRetainHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetTxIndexerRetainHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetTxIndexerRetainHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetTxIndexerRetainHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetTxIndexerRetainHeightResponse.Merge(m, src) +} +func (m *GetTxIndexerRetainHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *GetTxIndexerRetainHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetTxIndexerRetainHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetTxIndexerRetainHeightResponse proto.InternalMessageInfo + +func (m *GetTxIndexerRetainHeightResponse) GetHeight() uint64 { + if m != nil { + return m.Height + } + return 0 +} + +type SetBlockIndexerRetainHeightRequest struct { + Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` +} + +func (m *SetBlockIndexerRetainHeightRequest) Reset() { *m = SetBlockIndexerRetainHeightRequest{} } +func (m *SetBlockIndexerRetainHeightRequest) String() string { return proto.CompactTextString(m) } +func (*SetBlockIndexerRetainHeightRequest) ProtoMessage() {} +func (*SetBlockIndexerRetainHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{12} +} +func (m *SetBlockIndexerRetainHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SetBlockIndexerRetainHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SetBlockIndexerRetainHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SetBlockIndexerRetainHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_SetBlockIndexerRetainHeightRequest.Merge(m, src) +} +func (m *SetBlockIndexerRetainHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *SetBlockIndexerRetainHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_SetBlockIndexerRetainHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_SetBlockIndexerRetainHeightRequest proto.InternalMessageInfo + +func (m *SetBlockIndexerRetainHeightRequest) GetHeight() uint64 { + if m != nil { + return m.Height + } + return 0 +} + +type SetBlockIndexerRetainHeightResponse struct { +} + +func (m *SetBlockIndexerRetainHeightResponse) Reset() { *m = SetBlockIndexerRetainHeightResponse{} } +func (m *SetBlockIndexerRetainHeightResponse) String() string { return proto.CompactTextString(m) } +func (*SetBlockIndexerRetainHeightResponse) ProtoMessage() {} +func (*SetBlockIndexerRetainHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{13} +} +func (m *SetBlockIndexerRetainHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *SetBlockIndexerRetainHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_SetBlockIndexerRetainHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *SetBlockIndexerRetainHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_SetBlockIndexerRetainHeightResponse.Merge(m, src) +} +func (m *SetBlockIndexerRetainHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *SetBlockIndexerRetainHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_SetBlockIndexerRetainHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_SetBlockIndexerRetainHeightResponse proto.InternalMessageInfo + +type GetBlockIndexerRetainHeightRequest struct { +} + +func (m *GetBlockIndexerRetainHeightRequest) Reset() { *m = GetBlockIndexerRetainHeightRequest{} } +func (m *GetBlockIndexerRetainHeightRequest) String() string { return proto.CompactTextString(m) } +func (*GetBlockIndexerRetainHeightRequest) ProtoMessage() {} +func (*GetBlockIndexerRetainHeightRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{14} +} +func (m *GetBlockIndexerRetainHeightRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetBlockIndexerRetainHeightRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetBlockIndexerRetainHeightRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetBlockIndexerRetainHeightRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetBlockIndexerRetainHeightRequest.Merge(m, src) +} +func (m *GetBlockIndexerRetainHeightRequest) XXX_Size() int { + return m.Size() +} +func (m *GetBlockIndexerRetainHeightRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetBlockIndexerRetainHeightRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetBlockIndexerRetainHeightRequest proto.InternalMessageInfo + +type GetBlockIndexerRetainHeightResponse struct { + Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` +} + +func (m *GetBlockIndexerRetainHeightResponse) Reset() { *m = GetBlockIndexerRetainHeightResponse{} } +func (m *GetBlockIndexerRetainHeightResponse) String() string { return proto.CompactTextString(m) } +func (*GetBlockIndexerRetainHeightResponse) ProtoMessage() {} +func (*GetBlockIndexerRetainHeightResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_14bf9cf2a477c5d2, []int{15} +} +func (m *GetBlockIndexerRetainHeightResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetBlockIndexerRetainHeightResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetBlockIndexerRetainHeightResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetBlockIndexerRetainHeightResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetBlockIndexerRetainHeightResponse.Merge(m, src) +} +func (m *GetBlockIndexerRetainHeightResponse) XXX_Size() int { + return m.Size() +} +func (m *GetBlockIndexerRetainHeightResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetBlockIndexerRetainHeightResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetBlockIndexerRetainHeightResponse proto.InternalMessageInfo + +func (m *GetBlockIndexerRetainHeightResponse) GetHeight() uint64 { + if m != nil { + return m.Height + } + return 0 +} + +func init() { + proto.RegisterType((*SetBlockRetainHeightRequest)(nil), "cometbft.services.pruning.v1.SetBlockRetainHeightRequest") + proto.RegisterType((*SetBlockRetainHeightResponse)(nil), "cometbft.services.pruning.v1.SetBlockRetainHeightResponse") + proto.RegisterType((*GetBlockRetainHeightRequest)(nil), "cometbft.services.pruning.v1.GetBlockRetainHeightRequest") + proto.RegisterType((*GetBlockRetainHeightResponse)(nil), "cometbft.services.pruning.v1.GetBlockRetainHeightResponse") + proto.RegisterType((*SetBlockResultsRetainHeightRequest)(nil), "cometbft.services.pruning.v1.SetBlockResultsRetainHeightRequest") + proto.RegisterType((*SetBlockResultsRetainHeightResponse)(nil), "cometbft.services.pruning.v1.SetBlockResultsRetainHeightResponse") + proto.RegisterType((*GetBlockResultsRetainHeightRequest)(nil), "cometbft.services.pruning.v1.GetBlockResultsRetainHeightRequest") + proto.RegisterType((*GetBlockResultsRetainHeightResponse)(nil), "cometbft.services.pruning.v1.GetBlockResultsRetainHeightResponse") + proto.RegisterType((*SetTxIndexerRetainHeightRequest)(nil), "cometbft.services.pruning.v1.SetTxIndexerRetainHeightRequest") + proto.RegisterType((*SetTxIndexerRetainHeightResponse)(nil), "cometbft.services.pruning.v1.SetTxIndexerRetainHeightResponse") + proto.RegisterType((*GetTxIndexerRetainHeightRequest)(nil), "cometbft.services.pruning.v1.GetTxIndexerRetainHeightRequest") + proto.RegisterType((*GetTxIndexerRetainHeightResponse)(nil), "cometbft.services.pruning.v1.GetTxIndexerRetainHeightResponse") + proto.RegisterType((*SetBlockIndexerRetainHeightRequest)(nil), "cometbft.services.pruning.v1.SetBlockIndexerRetainHeightRequest") + proto.RegisterType((*SetBlockIndexerRetainHeightResponse)(nil), "cometbft.services.pruning.v1.SetBlockIndexerRetainHeightResponse") + proto.RegisterType((*GetBlockIndexerRetainHeightRequest)(nil), "cometbft.services.pruning.v1.GetBlockIndexerRetainHeightRequest") + proto.RegisterType((*GetBlockIndexerRetainHeightResponse)(nil), "cometbft.services.pruning.v1.GetBlockIndexerRetainHeightResponse") +} + +func init() { + proto.RegisterFile("cometbft/services/pruning/v1/pruning.proto", fileDescriptor_14bf9cf2a477c5d2) +} + +var fileDescriptor_14bf9cf2a477c5d2 = []byte{ + // 328 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x4a, 0xce, 0xcf, 0x4d, + 0x2d, 0x49, 0x4a, 0x2b, 0xd1, 0x2f, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0x2d, 0xd6, 0x2f, 0x28, + 0x2a, 0xcd, 0xcb, 0xcc, 0x4b, 0xd7, 0x2f, 0x33, 0x84, 0x31, 0xf5, 0x0a, 0x8a, 0xf2, 0x4b, 0xf2, + 0x85, 0x64, 0x60, 0x6a, 0xf5, 0x60, 0x6a, 0xf5, 0x60, 0x0a, 0xca, 0x0c, 0x95, 0x4c, 0xb9, 0xa4, + 0x83, 0x53, 0x4b, 0x9c, 0x72, 0xf2, 0x93, 0xb3, 0x83, 0x52, 0x4b, 0x12, 0x33, 0xf3, 0x3c, 0x52, + 0x33, 0xd3, 0x33, 0x4a, 0x82, 0x52, 0x0b, 0x4b, 0x53, 0x8b, 0x4b, 0x84, 0xc4, 0xb8, 0xd8, 0x32, + 0xc0, 0x02, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0x2c, 0x41, 0x50, 0x9e, 0x92, 0x1c, 0x97, 0x0c, 0x76, + 0x6d, 0xc5, 0x05, 0xf9, 0x79, 0xc5, 0xa9, 0x4a, 0xb2, 0x5c, 0xd2, 0xee, 0xb8, 0x8d, 0x55, 0xea, + 0x65, 0xe4, 0x92, 0x71, 0xc7, 0xa3, 0x5f, 0x48, 0x8b, 0x4b, 0x30, 0xb1, 0xa0, 0x20, 0xbe, 0x08, + 0x2c, 0x17, 0x8f, 0xe2, 0x04, 0xfe, 0xc4, 0x82, 0x02, 0x64, 0x3d, 0x42, 0x8e, 0x5c, 0xb2, 0x50, + 0x0f, 0xc5, 0x43, 0x7d, 0x88, 0xa6, 0x8f, 0x09, 0xac, 0x4f, 0x0a, 0xaa, 0x28, 0x18, 0xa2, 0x06, + 0xd9, 0x08, 0x25, 0x1b, 0x2e, 0x25, 0x84, 0x77, 0x8a, 0x4b, 0x73, 0x4a, 0x8a, 0x49, 0x09, 0x0c, + 0x55, 0x2e, 0x65, 0xbc, 0xba, 0xa1, 0x61, 0xa2, 0xc2, 0xa5, 0xe4, 0x4e, 0xd0, 0x12, 0xa5, 0x0c, + 0x2e, 0x65, 0x77, 0xc2, 0x86, 0x11, 0xf6, 0x34, 0x23, 0x41, 0x4f, 0x5b, 0x72, 0xc9, 0x07, 0xa7, + 0x96, 0x84, 0x54, 0x78, 0xe6, 0xa5, 0xa4, 0x56, 0xa4, 0x16, 0x91, 0xe2, 0x63, 0x25, 0x2e, 0x05, + 0xdc, 0x5a, 0xa1, 0xde, 0x55, 0xe4, 0x92, 0x77, 0xc7, 0x6f, 0xbc, 0x92, 0x15, 0x97, 0x82, 0x3b, + 0x01, 0x63, 0x70, 0x3a, 0x01, 0x29, 0xca, 0xc8, 0xf0, 0x00, 0x52, 0x94, 0xe1, 0xf3, 0x03, 0x52, + 0x94, 0xe1, 0xf1, 0x86, 0x2d, 0x22, 0xca, 0xc8, 0xf0, 0x89, 0x93, 0xc4, 0x89, 0x47, 0x72, 0x8c, + 0x17, 0x1e, 0xc9, 0x31, 0x3e, 0x78, 0x24, 0xc7, 0x38, 0xe1, 0xb1, 0x1c, 0xc3, 0x85, 0xc7, 0x72, + 0x0c, 0x37, 0x1e, 0xcb, 0x31, 0x24, 0xb1, 0x81, 0x73, 0xb0, 0x31, 0x20, 0x00, 0x00, 0xff, 0xff, + 0xfc, 0xe3, 0x82, 0x21, 0xef, 0x03, 0x00, 0x00, +} + +func (m *SetBlockRetainHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SetBlockRetainHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SetBlockRetainHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Height != 0 { + i = encodeVarintPruning(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *SetBlockRetainHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SetBlockRetainHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SetBlockRetainHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetBlockRetainHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetBlockRetainHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetBlockRetainHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetBlockRetainHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetBlockRetainHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetBlockRetainHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.PruningServiceRetainHeight != 0 { + i = encodeVarintPruning(dAtA, i, uint64(m.PruningServiceRetainHeight)) + i-- + dAtA[i] = 0x10 + } + if m.AppRetainHeight != 0 { + i = encodeVarintPruning(dAtA, i, uint64(m.AppRetainHeight)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *SetBlockResultsRetainHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SetBlockResultsRetainHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SetBlockResultsRetainHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Height != 0 { + i = encodeVarintPruning(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *SetBlockResultsRetainHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SetBlockResultsRetainHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SetBlockResultsRetainHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetBlockResultsRetainHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetBlockResultsRetainHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetBlockResultsRetainHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetBlockResultsRetainHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetBlockResultsRetainHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetBlockResultsRetainHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.PruningServiceRetainHeight != 0 { + i = encodeVarintPruning(dAtA, i, uint64(m.PruningServiceRetainHeight)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *SetTxIndexerRetainHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SetTxIndexerRetainHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SetTxIndexerRetainHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Height != 0 { + i = encodeVarintPruning(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *SetTxIndexerRetainHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SetTxIndexerRetainHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SetTxIndexerRetainHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetTxIndexerRetainHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetTxIndexerRetainHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetTxIndexerRetainHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetTxIndexerRetainHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetTxIndexerRetainHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetTxIndexerRetainHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Height != 0 { + i = encodeVarintPruning(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *SetBlockIndexerRetainHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SetBlockIndexerRetainHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SetBlockIndexerRetainHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Height != 0 { + i = encodeVarintPruning(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func (m *SetBlockIndexerRetainHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *SetBlockIndexerRetainHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *SetBlockIndexerRetainHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetBlockIndexerRetainHeightRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetBlockIndexerRetainHeightRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetBlockIndexerRetainHeightRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetBlockIndexerRetainHeightResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetBlockIndexerRetainHeightResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetBlockIndexerRetainHeightResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Height != 0 { + i = encodeVarintPruning(dAtA, i, uint64(m.Height)) + i-- + dAtA[i] = 0x8 + } + return len(dAtA) - i, nil +} + +func encodeVarintPruning(dAtA []byte, offset int, v uint64) int { + offset -= sovPruning(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *SetBlockRetainHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovPruning(uint64(m.Height)) + } + return n +} + +func (m *SetBlockRetainHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetBlockRetainHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetBlockRetainHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.AppRetainHeight != 0 { + n += 1 + sovPruning(uint64(m.AppRetainHeight)) + } + if m.PruningServiceRetainHeight != 0 { + n += 1 + sovPruning(uint64(m.PruningServiceRetainHeight)) + } + return n +} + +func (m *SetBlockResultsRetainHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovPruning(uint64(m.Height)) + } + return n +} + +func (m *SetBlockResultsRetainHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetBlockResultsRetainHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetBlockResultsRetainHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.PruningServiceRetainHeight != 0 { + n += 1 + sovPruning(uint64(m.PruningServiceRetainHeight)) + } + return n +} + +func (m *SetTxIndexerRetainHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovPruning(uint64(m.Height)) + } + return n +} + +func (m *SetTxIndexerRetainHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetTxIndexerRetainHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetTxIndexerRetainHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovPruning(uint64(m.Height)) + } + return n +} + +func (m *SetBlockIndexerRetainHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovPruning(uint64(m.Height)) + } + return n +} + +func (m *SetBlockIndexerRetainHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetBlockIndexerRetainHeightRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetBlockIndexerRetainHeightResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + if m.Height != 0 { + n += 1 + sovPruning(uint64(m.Height)) + } + return n +} + +func sovPruning(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 +} +func sozPruning(x uint64) (n int) { + return sovPruning(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (m *SetBlockRetainHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SetBlockRetainHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SetBlockRetainHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SetBlockRetainHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SetBlockRetainHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SetBlockRetainHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetBlockRetainHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetBlockRetainHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetBlockRetainHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetBlockRetainHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetBlockRetainHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetBlockRetainHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field AppRetainHeight", wireType) + } + m.AppRetainHeight = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.AppRetainHeight |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 2: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field PruningServiceRetainHeight", wireType) + } + m.PruningServiceRetainHeight = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.PruningServiceRetainHeight |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SetBlockResultsRetainHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SetBlockResultsRetainHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SetBlockResultsRetainHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SetBlockResultsRetainHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SetBlockResultsRetainHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SetBlockResultsRetainHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetBlockResultsRetainHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetBlockResultsRetainHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetBlockResultsRetainHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetBlockResultsRetainHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetBlockResultsRetainHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetBlockResultsRetainHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field PruningServiceRetainHeight", wireType) + } + m.PruningServiceRetainHeight = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.PruningServiceRetainHeight |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SetTxIndexerRetainHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SetTxIndexerRetainHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SetTxIndexerRetainHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SetTxIndexerRetainHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SetTxIndexerRetainHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SetTxIndexerRetainHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetTxIndexerRetainHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetTxIndexerRetainHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetTxIndexerRetainHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetTxIndexerRetainHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetTxIndexerRetainHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetTxIndexerRetainHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SetBlockIndexerRetainHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SetBlockIndexerRetainHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SetBlockIndexerRetainHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *SetBlockIndexerRetainHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: SetBlockIndexerRetainHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: SetBlockIndexerRetainHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetBlockIndexerRetainHeightRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetBlockIndexerRetainHeightRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetBlockIndexerRetainHeightRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetBlockIndexerRetainHeightResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetBlockIndexerRetainHeightResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetBlockIndexerRetainHeightResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType) + } + m.Height = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowPruning + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Height |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipPruning(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthPruning + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipPruning(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + depth := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowPruning + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowPruning + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + case 1: + iNdEx += 8 + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowPruning + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if length < 0 { + return 0, ErrInvalidLengthPruning + } + iNdEx += length + case 3: + depth++ + case 4: + if depth == 0 { + return 0, ErrUnexpectedEndOfGroupPruning + } + depth-- + case 5: + iNdEx += 4 + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + if iNdEx < 0 { + return 0, ErrInvalidLengthPruning + } + if depth == 0 { + return iNdEx, nil + } + } + return 0, io.ErrUnexpectedEOF +} + +var ( + ErrInvalidLengthPruning = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowPruning = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupPruning = fmt.Errorf("proto: unexpected end of group") +) diff --git a/api/cometbft/services/pruning/v1/service.pb.go b/api/cometbft/services/pruning/v1/service.pb.go new file mode 100644 index 00000000000..746af0cb42a --- /dev/null +++ b/api/cometbft/services/pruning/v1/service.pb.go @@ -0,0 +1,431 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: cometbft/services/pruning/v1/service.proto + +package cometbft_services_pruning_v1 + +import ( + context "context" + fmt "fmt" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" + math "math" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +func init() { + proto.RegisterFile("cometbft/services/pruning/v1/service.proto", fileDescriptor_58672b711a903587) +} + +var fileDescriptor_58672b711a903587 = []byte{ + // 298 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x4a, 0xce, 0xcf, 0x4d, + 0x2d, 0x49, 0x4a, 0x2b, 0xd1, 0x2f, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0x2d, 0xd6, 0x2f, 0x28, + 0x2a, 0xcd, 0xcb, 0xcc, 0x4b, 0xd7, 0x2f, 0x33, 0x84, 0x89, 0xe9, 0x15, 0x14, 0xe5, 0x97, 0xe4, + 0x0b, 0xc9, 0xc0, 0xd4, 0xea, 0xc1, 0xd4, 0xea, 0x41, 0xd5, 0xea, 0x95, 0x19, 0x4a, 0xe1, 0x37, + 0x09, 0xa6, 0x10, 0x6c, 0x92, 0xd1, 0x1f, 0x4e, 0x2e, 0xbe, 0x00, 0x88, 0x48, 0x30, 0x44, 0xb1, + 0x50, 0x2f, 0x23, 0x97, 0x48, 0x70, 0x6a, 0x89, 0x53, 0x4e, 0x7e, 0x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0x6e, 0x3c, 0x96, 0x63, 0x48, 0x62, 0x03, 0x97, 0x8f, 0xc6, 0x80, 0x00, 0x00, 0x00, + 0xff, 0xff, 0x7b, 0x8e, 0x2b, 0x5d, 0x97, 0x05, 0x00, 0x00, +} + +// Reference imports to suppress errors if they are not otherwise used. +var _ context.Context +var _ grpc.ClientConn + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +const _ = grpc.SupportPackageIsVersion4 + +// PruningServiceClient is the client API for PruningService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. +type PruningServiceClient interface { + // SetBlockRetainHeightRequest indicates to the node that it can safely + // prune all block data up to the specified retain height. + // + // The lower of this retain height and that set by the application in its + // Commit response will be used by the node to determine which heights' data + // can be pruned. + SetBlockRetainHeight(ctx context.Context, in *SetBlockRetainHeightRequest, opts ...grpc.CallOption) (*SetBlockRetainHeightResponse, error) + // GetBlockRetainHeight returns information about the retain height + // parameters used by the node to influence block retention/pruning. + GetBlockRetainHeight(ctx context.Context, in *GetBlockRetainHeightRequest, opts ...grpc.CallOption) (*GetBlockRetainHeightResponse, error) + // SetBlockResultsRetainHeightRequest indicates to the node that it can + // safely prune all block results data up to the specified height. + // + // The node will always store the block results for the latest height to + // help facilitate crash recovery. + SetBlockResultsRetainHeight(ctx context.Context, in *SetBlockResultsRetainHeightRequest, opts ...grpc.CallOption) (*SetBlockResultsRetainHeightResponse, error) + // GetBlockResultsRetainHeight returns information about the retain height + // parameters used by the node to influence block results retention/pruning. + GetBlockResultsRetainHeight(ctx context.Context, in *GetBlockResultsRetainHeightRequest, opts ...grpc.CallOption) (*GetBlockResultsRetainHeightResponse, error) + // SetTxIndexerRetainHeightRequest indicates to the node that it can safely + // prune all tx indices up to the specified retain height. + SetTxIndexerRetainHeight(ctx context.Context, in *SetTxIndexerRetainHeightRequest, opts ...grpc.CallOption) (*SetTxIndexerRetainHeightResponse, error) + // GetTxIndexerRetainHeight returns information about the retain height + // parameters used by the node to influence TxIndexer pruning + GetTxIndexerRetainHeight(ctx context.Context, in *GetTxIndexerRetainHeightRequest, opts ...grpc.CallOption) (*GetTxIndexerRetainHeightResponse, error) + // SetBlockIndexerRetainHeightRequest indicates to the node that it can safely + // prune all block indices up to the specified retain height. + SetBlockIndexerRetainHeight(ctx context.Context, in *SetBlockIndexerRetainHeightRequest, opts ...grpc.CallOption) (*SetBlockIndexerRetainHeightResponse, error) + // GetBlockIndexerRetainHeight returns information about the retain height + // parameters used by the node to influence BlockIndexer pruning + GetBlockIndexerRetainHeight(ctx context.Context, in *GetBlockIndexerRetainHeightRequest, opts ...grpc.CallOption) (*GetBlockIndexerRetainHeightResponse, error) +} + +type pruningServiceClient struct { + cc grpc1.ClientConn +} + +func NewPruningServiceClient(cc grpc1.ClientConn) PruningServiceClient { + return &pruningServiceClient{cc} +} + +func (c *pruningServiceClient) SetBlockRetainHeight(ctx context.Context, in *SetBlockRetainHeightRequest, opts ...grpc.CallOption) (*SetBlockRetainHeightResponse, error) { + out := new(SetBlockRetainHeightResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.pruning.v1.PruningService/SetBlockRetainHeight", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *pruningServiceClient) GetBlockRetainHeight(ctx context.Context, in *GetBlockRetainHeightRequest, opts ...grpc.CallOption) (*GetBlockRetainHeightResponse, error) { + out := new(GetBlockRetainHeightResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.pruning.v1.PruningService/GetBlockRetainHeight", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *pruningServiceClient) SetBlockResultsRetainHeight(ctx context.Context, in *SetBlockResultsRetainHeightRequest, opts ...grpc.CallOption) (*SetBlockResultsRetainHeightResponse, error) { + out := new(SetBlockResultsRetainHeightResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.pruning.v1.PruningService/SetBlockResultsRetainHeight", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *pruningServiceClient) GetBlockResultsRetainHeight(ctx context.Context, in *GetBlockResultsRetainHeightRequest, opts ...grpc.CallOption) (*GetBlockResultsRetainHeightResponse, error) { + out := new(GetBlockResultsRetainHeightResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.pruning.v1.PruningService/GetBlockResultsRetainHeight", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *pruningServiceClient) SetTxIndexerRetainHeight(ctx context.Context, in *SetTxIndexerRetainHeightRequest, opts ...grpc.CallOption) (*SetTxIndexerRetainHeightResponse, error) { + out := new(SetTxIndexerRetainHeightResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.pruning.v1.PruningService/SetTxIndexerRetainHeight", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *pruningServiceClient) GetTxIndexerRetainHeight(ctx context.Context, in *GetTxIndexerRetainHeightRequest, opts ...grpc.CallOption) (*GetTxIndexerRetainHeightResponse, error) { + out := new(GetTxIndexerRetainHeightResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.pruning.v1.PruningService/GetTxIndexerRetainHeight", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *pruningServiceClient) SetBlockIndexerRetainHeight(ctx context.Context, in *SetBlockIndexerRetainHeightRequest, opts ...grpc.CallOption) (*SetBlockIndexerRetainHeightResponse, error) { + out := new(SetBlockIndexerRetainHeightResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.pruning.v1.PruningService/SetBlockIndexerRetainHeight", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +func (c *pruningServiceClient) GetBlockIndexerRetainHeight(ctx context.Context, in *GetBlockIndexerRetainHeightRequest, opts ...grpc.CallOption) (*GetBlockIndexerRetainHeightResponse, error) { + out := new(GetBlockIndexerRetainHeightResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.pruning.v1.PruningService/GetBlockIndexerRetainHeight", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// PruningServiceServer is the server API for PruningService service. +type PruningServiceServer interface { + // SetBlockRetainHeightRequest indicates to the node that it can safely + // prune all block data up to the specified retain height. + // + // The lower of this retain height and that set by the application in its + // Commit response will be used by the node to determine which heights' data + // can be pruned. + SetBlockRetainHeight(context.Context, *SetBlockRetainHeightRequest) (*SetBlockRetainHeightResponse, error) + // GetBlockRetainHeight returns information about the retain height + // parameters used by the node to influence block retention/pruning. + GetBlockRetainHeight(context.Context, *GetBlockRetainHeightRequest) (*GetBlockRetainHeightResponse, error) + // SetBlockResultsRetainHeightRequest indicates to the node that it can + // safely prune all block results data up to the specified height. + // + // The node will always store the block results for the latest height to + // help facilitate crash recovery. + SetBlockResultsRetainHeight(context.Context, *SetBlockResultsRetainHeightRequest) (*SetBlockResultsRetainHeightResponse, error) + // GetBlockResultsRetainHeight returns information about the retain height + // parameters used by the node to influence block results retention/pruning. + GetBlockResultsRetainHeight(context.Context, *GetBlockResultsRetainHeightRequest) (*GetBlockResultsRetainHeightResponse, error) + // SetTxIndexerRetainHeightRequest indicates to the node that it can safely + // prune all tx indices up to the specified retain height. + SetTxIndexerRetainHeight(context.Context, *SetTxIndexerRetainHeightRequest) (*SetTxIndexerRetainHeightResponse, error) + // GetTxIndexerRetainHeight returns information about the retain height + // parameters used by the node to influence TxIndexer pruning + GetTxIndexerRetainHeight(context.Context, *GetTxIndexerRetainHeightRequest) (*GetTxIndexerRetainHeightResponse, error) + // SetBlockIndexerRetainHeightRequest indicates to the node that it can safely + // prune all block indices up to the specified retain height. + SetBlockIndexerRetainHeight(context.Context, *SetBlockIndexerRetainHeightRequest) (*SetBlockIndexerRetainHeightResponse, error) + // GetBlockIndexerRetainHeight returns information about the retain height + // parameters used by the node to influence BlockIndexer pruning + GetBlockIndexerRetainHeight(context.Context, *GetBlockIndexerRetainHeightRequest) (*GetBlockIndexerRetainHeightResponse, error) +} + +// UnimplementedPruningServiceServer can be embedded to have forward compatible implementations. +type UnimplementedPruningServiceServer struct { +} + +func (*UnimplementedPruningServiceServer) SetBlockRetainHeight(ctx context.Context, req *SetBlockRetainHeightRequest) (*SetBlockRetainHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SetBlockRetainHeight not implemented") +} +func (*UnimplementedPruningServiceServer) GetBlockRetainHeight(ctx context.Context, req *GetBlockRetainHeightRequest) (*GetBlockRetainHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetBlockRetainHeight not implemented") +} +func (*UnimplementedPruningServiceServer) SetBlockResultsRetainHeight(ctx context.Context, req *SetBlockResultsRetainHeightRequest) (*SetBlockResultsRetainHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SetBlockResultsRetainHeight not implemented") +} +func (*UnimplementedPruningServiceServer) GetBlockResultsRetainHeight(ctx context.Context, req *GetBlockResultsRetainHeightRequest) (*GetBlockResultsRetainHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetBlockResultsRetainHeight not implemented") +} +func (*UnimplementedPruningServiceServer) SetTxIndexerRetainHeight(ctx context.Context, req *SetTxIndexerRetainHeightRequest) (*SetTxIndexerRetainHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SetTxIndexerRetainHeight not implemented") +} +func (*UnimplementedPruningServiceServer) GetTxIndexerRetainHeight(ctx context.Context, req *GetTxIndexerRetainHeightRequest) (*GetTxIndexerRetainHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetTxIndexerRetainHeight not implemented") +} +func (*UnimplementedPruningServiceServer) SetBlockIndexerRetainHeight(ctx context.Context, req *SetBlockIndexerRetainHeightRequest) (*SetBlockIndexerRetainHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method SetBlockIndexerRetainHeight not implemented") +} +func (*UnimplementedPruningServiceServer) GetBlockIndexerRetainHeight(ctx context.Context, req *GetBlockIndexerRetainHeightRequest) (*GetBlockIndexerRetainHeightResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetBlockIndexerRetainHeight not implemented") +} + +func RegisterPruningServiceServer(s grpc1.Server, srv PruningServiceServer) { + s.RegisterService(&_PruningService_serviceDesc, srv) +} + +func _PruningService_SetBlockRetainHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(SetBlockRetainHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(PruningServiceServer).SetBlockRetainHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.pruning.v1.PruningService/SetBlockRetainHeight", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(PruningServiceServer).SetBlockRetainHeight(ctx, req.(*SetBlockRetainHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _PruningService_GetBlockRetainHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetBlockRetainHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(PruningServiceServer).GetBlockRetainHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.pruning.v1.PruningService/GetBlockRetainHeight", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(PruningServiceServer).GetBlockRetainHeight(ctx, req.(*GetBlockRetainHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _PruningService_SetBlockResultsRetainHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(SetBlockResultsRetainHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(PruningServiceServer).SetBlockResultsRetainHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.pruning.v1.PruningService/SetBlockResultsRetainHeight", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(PruningServiceServer).SetBlockResultsRetainHeight(ctx, req.(*SetBlockResultsRetainHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _PruningService_GetBlockResultsRetainHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetBlockResultsRetainHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(PruningServiceServer).GetBlockResultsRetainHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.pruning.v1.PruningService/GetBlockResultsRetainHeight", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(PruningServiceServer).GetBlockResultsRetainHeight(ctx, req.(*GetBlockResultsRetainHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _PruningService_SetTxIndexerRetainHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(SetTxIndexerRetainHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(PruningServiceServer).SetTxIndexerRetainHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.pruning.v1.PruningService/SetTxIndexerRetainHeight", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(PruningServiceServer).SetTxIndexerRetainHeight(ctx, req.(*SetTxIndexerRetainHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _PruningService_GetTxIndexerRetainHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetTxIndexerRetainHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(PruningServiceServer).GetTxIndexerRetainHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.pruning.v1.PruningService/GetTxIndexerRetainHeight", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(PruningServiceServer).GetTxIndexerRetainHeight(ctx, req.(*GetTxIndexerRetainHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _PruningService_SetBlockIndexerRetainHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(SetBlockIndexerRetainHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(PruningServiceServer).SetBlockIndexerRetainHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.pruning.v1.PruningService/SetBlockIndexerRetainHeight", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(PruningServiceServer).SetBlockIndexerRetainHeight(ctx, req.(*SetBlockIndexerRetainHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +func _PruningService_GetBlockIndexerRetainHeight_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetBlockIndexerRetainHeightRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(PruningServiceServer).GetBlockIndexerRetainHeight(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.pruning.v1.PruningService/GetBlockIndexerRetainHeight", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(PruningServiceServer).GetBlockIndexerRetainHeight(ctx, req.(*GetBlockIndexerRetainHeightRequest)) + } + return interceptor(ctx, in, info, handler) +} + +var _PruningService_serviceDesc = grpc.ServiceDesc{ + ServiceName: "cometbft.services.pruning.v1.PruningService", + HandlerType: (*PruningServiceServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "SetBlockRetainHeight", + Handler: _PruningService_SetBlockRetainHeight_Handler, + }, + { + MethodName: "GetBlockRetainHeight", + Handler: _PruningService_GetBlockRetainHeight_Handler, + }, + { + MethodName: "SetBlockResultsRetainHeight", + Handler: _PruningService_SetBlockResultsRetainHeight_Handler, + }, + { + MethodName: "GetBlockResultsRetainHeight", + Handler: _PruningService_GetBlockResultsRetainHeight_Handler, + }, + { + MethodName: "SetTxIndexerRetainHeight", + Handler: _PruningService_SetTxIndexerRetainHeight_Handler, + }, + { + MethodName: "GetTxIndexerRetainHeight", + Handler: _PruningService_GetTxIndexerRetainHeight_Handler, + }, + { + MethodName: "SetBlockIndexerRetainHeight", + Handler: _PruningService_SetBlockIndexerRetainHeight_Handler, + }, + { + MethodName: "GetBlockIndexerRetainHeight", + Handler: _PruningService_GetBlockIndexerRetainHeight_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "cometbft/services/pruning/v1/service.proto", +} diff --git a/api/cometbft/services/version/v1/version.pb.go b/api/cometbft/services/version/v1/version.pb.go new file mode 100644 index 00000000000..68d0c2c79fd --- /dev/null +++ b/api/cometbft/services/version/v1/version.pb.go @@ -0,0 +1,560 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: cometbft/services/version/v1/version.proto + +package v1 + +import ( + fmt "fmt" + proto "github.com/cosmos/gogoproto/proto" + io "io" + math "math" + math_bits "math/bits" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +type GetVersionRequest struct { +} + +func (m *GetVersionRequest) Reset() { *m = GetVersionRequest{} } +func (m *GetVersionRequest) String() string { return proto.CompactTextString(m) } +func (*GetVersionRequest) ProtoMessage() {} +func (*GetVersionRequest) Descriptor() ([]byte, []int) { + return fileDescriptor_0d34df0ab45614ed, []int{0} +} +func (m *GetVersionRequest) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetVersionRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetVersionRequest.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetVersionRequest) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetVersionRequest.Merge(m, src) +} +func (m *GetVersionRequest) XXX_Size() int { + return m.Size() +} +func (m *GetVersionRequest) XXX_DiscardUnknown() { + xxx_messageInfo_GetVersionRequest.DiscardUnknown(m) +} + +var xxx_messageInfo_GetVersionRequest proto.InternalMessageInfo + +type GetVersionResponse struct { + Node string `protobuf:"bytes,1,opt,name=node,proto3" json:"node,omitempty"` + Abci string `protobuf:"bytes,2,opt,name=abci,proto3" json:"abci,omitempty"` + P2P uint64 `protobuf:"varint,3,opt,name=p2p,proto3" json:"p2p,omitempty"` + Block uint64 `protobuf:"varint,4,opt,name=block,proto3" json:"block,omitempty"` +} + +func (m *GetVersionResponse) Reset() { *m = GetVersionResponse{} } +func (m *GetVersionResponse) String() string { return proto.CompactTextString(m) } +func (*GetVersionResponse) ProtoMessage() {} +func (*GetVersionResponse) Descriptor() ([]byte, []int) { + return fileDescriptor_0d34df0ab45614ed, []int{1} +} +func (m *GetVersionResponse) XXX_Unmarshal(b []byte) error { + return m.Unmarshal(b) +} +func (m *GetVersionResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { + if deterministic { + return xxx_messageInfo_GetVersionResponse.Marshal(b, m, deterministic) + } else { + b = b[:cap(b)] + n, err := m.MarshalToSizedBuffer(b) + if err != nil { + return nil, err + } + return b[:n], nil + } +} +func (m *GetVersionResponse) XXX_Merge(src proto.Message) { + xxx_messageInfo_GetVersionResponse.Merge(m, src) +} +func (m *GetVersionResponse) XXX_Size() int { + return m.Size() +} +func (m *GetVersionResponse) XXX_DiscardUnknown() { + xxx_messageInfo_GetVersionResponse.DiscardUnknown(m) +} + +var xxx_messageInfo_GetVersionResponse proto.InternalMessageInfo + +func (m *GetVersionResponse) GetNode() string { + if m != nil { + return m.Node + } + return "" +} + +func (m *GetVersionResponse) GetAbci() string { + if m != nil { + return m.Abci + } + return "" +} + +func (m *GetVersionResponse) GetP2P() uint64 { + if m != nil { + return m.P2P + } + return 0 +} + +func (m *GetVersionResponse) GetBlock() uint64 { + if m != nil { + return m.Block + } + return 0 +} + +func init() { + proto.RegisterType((*GetVersionRequest)(nil), "cometbft.services.version.v1.GetVersionRequest") + proto.RegisterType((*GetVersionResponse)(nil), "cometbft.services.version.v1.GetVersionResponse") +} + +func init() { + proto.RegisterFile("cometbft/services/version/v1/version.proto", fileDescriptor_0d34df0ab45614ed) +} + +var fileDescriptor_0d34df0ab45614ed = []byte{ + // 217 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x4a, 0xce, 0xcf, 0x4d, + 0x2d, 0x49, 0x4a, 0x2b, 0xd1, 0x2f, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0x2d, 0xd6, 0x2f, 0x4b, + 0x2d, 0x2a, 0xce, 0xcc, 0xcf, 0xd3, 0x2f, 0x33, 0x84, 0x31, 0xf5, 0x0a, 0x8a, 0xf2, 0x4b, 0xf2, + 0x85, 0x64, 0x60, 0x6a, 0xf5, 0x60, 0x6a, 0xf5, 0x60, 0x0a, 0xca, 0x0c, 0x95, 0x84, 0xb9, 0x04, + 0xdd, 0x53, 0x4b, 0xc2, 0x20, 0x02, 0x41, 0xa9, 0x85, 0xa5, 0xa9, 0xc5, 0x25, 0x4a, 0x29, 0x5c, + 0x42, 0xc8, 0x82, 0xc5, 0x05, 0xf9, 0x79, 0xc5, 0xa9, 0x42, 0x42, 0x5c, 0x2c, 0x79, 0xf9, 0x29, + 0xa9, 0x12, 0x8c, 0x0a, 0x8c, 0x1a, 0x9c, 0x41, 0x60, 0x36, 0x48, 0x2c, 0x31, 0x29, 0x39, 0x53, + 0x82, 0x09, 0x22, 0x06, 0x62, 0x0b, 0x09, 0x70, 0x31, 0x17, 0x18, 0x15, 0x48, 0x30, 0x2b, 0x30, + 0x6a, 0xb0, 0x04, 0x81, 0x98, 0x42, 0x22, 0x5c, 0xac, 0x49, 0x39, 0xf9, 0xc9, 0xd9, 0x12, 0x2c, + 0x60, 0x31, 0x08, 0xc7, 0x29, 0xf2, 0xc4, 0x23, 0x39, 0xc6, 0x0b, 0x8f, 0xe4, 0x18, 0x1f, 0x3c, + 0x92, 0x63, 0x9c, 0xf0, 0x58, 0x8e, 0xe1, 0xc2, 0x63, 0x39, 0x86, 0x1b, 0x8f, 0xe5, 0x18, 0xa2, + 0xec, 0xd3, 0x33, 0x4b, 0x32, 0x4a, 0x93, 0xf4, 0x92, 0xf3, 0x73, 0xf5, 0xe1, 0x3e, 0x85, 0x33, + 0xc0, 0xde, 0xd2, 0xc7, 0x17, 0x02, 0x49, 0x6c, 0x60, 0x35, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, + 0xff, 0x91, 0x11, 0x56, 0x16, 0x28, 0x01, 0x00, 0x00, +} + +func (m *GetVersionRequest) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetVersionRequest) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetVersionRequest) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + return len(dAtA) - i, nil +} + +func (m *GetVersionResponse) Marshal() (dAtA []byte, err error) { + size := m.Size() + dAtA = make([]byte, size) + n, err := m.MarshalToSizedBuffer(dAtA[:size]) + if err != nil { + return nil, err + } + return dAtA[:n], nil +} + +func (m *GetVersionResponse) MarshalTo(dAtA []byte) (int, error) { + size := m.Size() + return m.MarshalToSizedBuffer(dAtA[:size]) +} + +func (m *GetVersionResponse) MarshalToSizedBuffer(dAtA []byte) (int, error) { + i := len(dAtA) + _ = i + var l int + _ = l + if m.Block != 0 { + i = encodeVarintVersion(dAtA, i, uint64(m.Block)) + i-- + dAtA[i] = 0x20 + } + if m.P2P != 0 { + i = encodeVarintVersion(dAtA, i, uint64(m.P2P)) + i-- + dAtA[i] = 0x18 + } + if len(m.Abci) > 0 { + i -= len(m.Abci) + copy(dAtA[i:], m.Abci) + i = encodeVarintVersion(dAtA, i, uint64(len(m.Abci))) + i-- + dAtA[i] = 0x12 + } + if len(m.Node) > 0 { + i -= len(m.Node) + copy(dAtA[i:], m.Node) + i = encodeVarintVersion(dAtA, i, uint64(len(m.Node))) + i-- + dAtA[i] = 0xa + } + return len(dAtA) - i, nil +} + +func encodeVarintVersion(dAtA []byte, offset int, v uint64) int { + offset -= sovVersion(v) + base := offset + for v >= 1<<7 { + dAtA[offset] = uint8(v&0x7f | 0x80) + v >>= 7 + offset++ + } + dAtA[offset] = uint8(v) + return base +} +func (m *GetVersionRequest) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + return n +} + +func (m *GetVersionResponse) Size() (n int) { + if m == nil { + return 0 + } + var l int + _ = l + l = len(m.Node) + if l > 0 { + n += 1 + l + sovVersion(uint64(l)) + } + l = len(m.Abci) + if l > 0 { + n += 1 + l + sovVersion(uint64(l)) + } + if m.P2P != 0 { + n += 1 + sovVersion(uint64(m.P2P)) + } + if m.Block != 0 { + n += 1 + sovVersion(uint64(m.Block)) + } + return n +} + +func sovVersion(x uint64) (n int) { + return (math_bits.Len64(x|1) + 6) / 7 +} +func sozVersion(x uint64) (n int) { + return sovVersion(uint64((x << 1) ^ uint64((int64(x) >> 63)))) +} +func (m *GetVersionRequest) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowVersion + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetVersionRequest: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetVersionRequest: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + default: + iNdEx = preIndex + skippy, err := skipVersion(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthVersion + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func (m *GetVersionResponse) Unmarshal(dAtA []byte) error { + l := len(dAtA) + iNdEx := 0 + for iNdEx < l { + preIndex := iNdEx + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowVersion + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + fieldNum := int32(wire >> 3) + wireType := int(wire & 0x7) + if wireType == 4 { + return fmt.Errorf("proto: GetVersionResponse: wiretype end group for non-group") + } + if fieldNum <= 0 { + return fmt.Errorf("proto: GetVersionResponse: illegal tag %d (wire type %d)", fieldNum, wire) + } + switch fieldNum { + case 1: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Node", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowVersion + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthVersion + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthVersion + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Node = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 2: + if wireType != 2 { + return fmt.Errorf("proto: wrong wireType = %d for field Abci", wireType) + } + var stringLen uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowVersion + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + stringLen |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + intStringLen := int(stringLen) + if intStringLen < 0 { + return ErrInvalidLengthVersion + } + postIndex := iNdEx + intStringLen + if postIndex < 0 { + return ErrInvalidLengthVersion + } + if postIndex > l { + return io.ErrUnexpectedEOF + } + m.Abci = string(dAtA[iNdEx:postIndex]) + iNdEx = postIndex + case 3: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field P2P", wireType) + } + m.P2P = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowVersion + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.P2P |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + case 4: + if wireType != 0 { + return fmt.Errorf("proto: wrong wireType = %d for field Block", wireType) + } + m.Block = 0 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return ErrIntOverflowVersion + } + if iNdEx >= l { + return io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + m.Block |= uint64(b&0x7F) << shift + if b < 0x80 { + break + } + } + default: + iNdEx = preIndex + skippy, err := skipVersion(dAtA[iNdEx:]) + if err != nil { + return err + } + if (skippy < 0) || (iNdEx+skippy) < 0 { + return ErrInvalidLengthVersion + } + if (iNdEx + skippy) > l { + return io.ErrUnexpectedEOF + } + iNdEx += skippy + } + } + + if iNdEx > l { + return io.ErrUnexpectedEOF + } + return nil +} +func skipVersion(dAtA []byte) (n int, err error) { + l := len(dAtA) + iNdEx := 0 + depth := 0 + for iNdEx < l { + var wire uint64 + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowVersion + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + wire |= (uint64(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + wireType := int(wire & 0x7) + switch wireType { + case 0: + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowVersion + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + iNdEx++ + if dAtA[iNdEx-1] < 0x80 { + break + } + } + case 1: + iNdEx += 8 + case 2: + var length int + for shift := uint(0); ; shift += 7 { + if shift >= 64 { + return 0, ErrIntOverflowVersion + } + if iNdEx >= l { + return 0, io.ErrUnexpectedEOF + } + b := dAtA[iNdEx] + iNdEx++ + length |= (int(b) & 0x7F) << shift + if b < 0x80 { + break + } + } + if length < 0 { + return 0, ErrInvalidLengthVersion + } + iNdEx += length + case 3: + depth++ + case 4: + if depth == 0 { + return 0, ErrUnexpectedEndOfGroupVersion + } + depth-- + case 5: + iNdEx += 4 + default: + return 0, fmt.Errorf("proto: illegal wireType %d", wireType) + } + if iNdEx < 0 { + return 0, ErrInvalidLengthVersion + } + if depth == 0 { + return iNdEx, nil + } + } + return 0, io.ErrUnexpectedEOF +} + +var ( + ErrInvalidLengthVersion = fmt.Errorf("proto: negative length found during unmarshaling") + ErrIntOverflowVersion = fmt.Errorf("proto: integer overflow") + ErrUnexpectedEndOfGroupVersion = fmt.Errorf("proto: unexpected end of group") +) diff --git a/api/cometbft/services/version/v1/version_service.pb.go b/api/cometbft/services/version/v1/version_service.pb.go new file mode 100644 index 00000000000..81e06c1dc9c --- /dev/null +++ b/api/cometbft/services/version/v1/version_service.pb.go @@ -0,0 +1,130 @@ +// Code generated by protoc-gen-gogo. DO NOT EDIT. +// source: cometbft/services/version/v1/version_service.proto + +package v1 + +import ( + context "context" + fmt "fmt" + grpc1 "github.com/cosmos/gogoproto/grpc" + proto "github.com/cosmos/gogoproto/proto" + grpc "google.golang.org/grpc" + codes "google.golang.org/grpc/codes" + status "google.golang.org/grpc/status" + math "math" +) + +// Reference imports to suppress errors if they are not otherwise used. +var _ = proto.Marshal +var _ = fmt.Errorf +var _ = math.Inf + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the proto package it is being compiled against. +// A compilation error at this line likely means your copy of the +// proto package needs to be updated. +const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package + +func init() { + proto.RegisterFile("cometbft/services/version/v1/version_service.proto", fileDescriptor_054267f78f0fa7a9) +} + +var fileDescriptor_054267f78f0fa7a9 = []byte{ + // 183 bytes of a gzipped FileDescriptorProto + 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x32, 0x4a, 0xce, 0xcf, 0x4d, + 0x2d, 0x49, 0x4a, 0x2b, 0xd1, 0x2f, 0x4e, 0x2d, 0x2a, 0xcb, 0x4c, 0x4e, 0x2d, 0xd6, 0x2f, 0x4b, + 0x2d, 0x2a, 0xce, 0xcc, 0xcf, 0xd3, 0x2f, 0x33, 0x84, 0x31, 0xe3, 0xa1, 0x72, 0x7a, 0x05, 0x45, + 0xf9, 0x25, 0xf9, 0x42, 0x32, 0x30, 0x3d, 0x7a, 0x30, 0x3d, 0x7a, 0x50, 0x85, 0x7a, 0x65, 0x86, + 0x52, 0x5a, 0xc4, 0x98, 0x08, 0x31, 0xc9, 0xa8, 0x91, 0x91, 0x8b, 0x2f, 0x0c, 0x22, 0x12, 0x0c, + 0x51, 0x2c, 0x94, 0xcf, 0xc5, 0xe5, 0x9e, 0x5a, 0x02, 0x15, 0x14, 0xd2, 0xd7, 0xc3, 0x67, 0x97, + 0x1e, 0x42, 0x65, 0x50, 0x6a, 0x61, 0x69, 0x6a, 0x71, 0x89, 0x94, 0x01, 0xf1, 0x1a, 0x8a, 0x0b, + 0xf2, 0xf3, 0x8a, 0x53, 0x9d, 0x22, 0x4f, 0x3c, 0x92, 0x63, 0xbc, 0xf0, 0x48, 0x8e, 0xf1, 0xc1, + 0x23, 0x39, 0xc6, 0x09, 0x8f, 0xe5, 0x18, 0x2e, 0x3c, 0x96, 0x63, 0xb8, 0xf1, 0x58, 0x8e, 0x21, + 0xca, 0x3e, 0x3d, 0xb3, 0x24, 0xa3, 0x34, 0x09, 0x64, 0xa2, 0x3e, 0xdc, 0x53, 0x70, 0x06, 0xd8, + 0x07, 0xfa, 0xf8, 0x3c, 0x9b, 0xc4, 0x06, 0x56, 0x63, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0x8e, + 0xfa, 0x65, 0x9f, 0x65, 0x01, 0x00, 0x00, +} + +// Reference imports to suppress errors if they are not otherwise used. +var _ context.Context +var _ grpc.ClientConn + +// This is a compile-time assertion to ensure that this generated file +// is compatible with the grpc package it is being compiled against. +const _ = grpc.SupportPackageIsVersion4 + +// VersionServiceClient is the client API for VersionService service. +// +// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream. +type VersionServiceClient interface { + // GetVersion retrieves version information about the node and the protocols + // it implements. + GetVersion(ctx context.Context, in *GetVersionRequest, opts ...grpc.CallOption) (*GetVersionResponse, error) +} + +type versionServiceClient struct { + cc grpc1.ClientConn +} + +func NewVersionServiceClient(cc grpc1.ClientConn) VersionServiceClient { + return &versionServiceClient{cc} +} + +func (c *versionServiceClient) GetVersion(ctx context.Context, in *GetVersionRequest, opts ...grpc.CallOption) (*GetVersionResponse, error) { + out := new(GetVersionResponse) + err := c.cc.Invoke(ctx, "/cometbft.services.version.v1.VersionService/GetVersion", in, out, opts...) + if err != nil { + return nil, err + } + return out, nil +} + +// VersionServiceServer is the server API for VersionService service. +type VersionServiceServer interface { + // GetVersion retrieves version information about the node and the protocols + // it implements. + GetVersion(context.Context, *GetVersionRequest) (*GetVersionResponse, error) +} + +// UnimplementedVersionServiceServer can be embedded to have forward compatible implementations. +type UnimplementedVersionServiceServer struct { +} + +func (*UnimplementedVersionServiceServer) GetVersion(ctx context.Context, req *GetVersionRequest) (*GetVersionResponse, error) { + return nil, status.Errorf(codes.Unimplemented, "method GetVersion not implemented") +} + +func RegisterVersionServiceServer(s grpc1.Server, srv VersionServiceServer) { + s.RegisterService(&_VersionService_serviceDesc, srv) +} + +func _VersionService_GetVersion_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { + in := new(GetVersionRequest) + if err := dec(in); err != nil { + return nil, err + } + if interceptor == nil { + return srv.(VersionServiceServer).GetVersion(ctx, in) + } + info := &grpc.UnaryServerInfo{ + Server: srv, + FullMethod: "/cometbft.services.version.v1.VersionService/GetVersion", + } + handler := func(ctx context.Context, req interface{}) (interface{}, error) { + return srv.(VersionServiceServer).GetVersion(ctx, req.(*GetVersionRequest)) + } + return interceptor(ctx, in, info, handler) +} + +var _VersionService_serviceDesc = grpc.ServiceDesc{ + ServiceName: "cometbft.services.version.v1.VersionService", + HandlerType: (*VersionServiceServer)(nil), + Methods: []grpc.MethodDesc{ + { + MethodName: "GetVersion", + Handler: _VersionService_GetVersion_Handler, + }, + }, + Streams: []grpc.StreamDesc{}, + Metadata: "cometbft/services/version/v1/version_service.proto", +} diff --git a/consensus/mempool_test.go b/consensus/mempool_test.go index ea7286e0b7b..fdf2376a446 100644 --- a/consensus/mempool_test.go +++ b/consensus/mempool_test.go @@ -110,8 +110,9 @@ func TestMempoolProgressInHigherRound(t *testing.T) { func deliverTxsRange(t *testing.T, cs *State, start, end int) { // Deliver some txs. for i := start; i < end; i++ { - _, err := assertMempool(cs.txNotifier).CheckTx(kvstore.NewTx(fmt.Sprintf("%d", i), "true")) + reqRes, err := assertMempool(cs.txNotifier).CheckTx(kvstore.NewTx(fmt.Sprintf("%d", i), "true")) require.NoError(t, err) + require.False(t, reqRes.Response.GetCheckTx().IsErr()) } } diff --git a/consensus/msgs.go b/consensus/msgs.go index 11ee400313e..dbad58801b1 100644 --- a/consensus/msgs.go +++ b/consensus/msgs.go @@ -15,12 +15,13 @@ import ( "github.com/cometbft/cometbft/types" ) +// TODO: This needs to be removed, but WALToProto depends on this. // Takes a consensus message type and returns the proto defined consensus message, // wrapped in the discriminating Message container. func MsgToWrappedProto(msg Message) (cmtcons.Message, error) { pb := cmtcons.Message{} if msg == nil { - return nil, ErrNilMessage + return pb, ErrNilMessage } switch msg := msg.(type) { @@ -61,7 +62,7 @@ func MsgToWrappedProto(msg Message) (cmtcons.Message, error) { case *BlockPartMessage: parts, err := msg.Part.ToProto() if err != nil { - return nil, cmterrors.ErrMsgToProto{MessageName: "Part", Err: err} + return pb, cmterrors.ErrMsgToProto{MessageName: "Part", Err: err} } pb.Sum = &cmtcons.Message_BlockPart{BlockPart: &cmtcons.BlockPart{ Height: msg.Height, @@ -84,11 +85,11 @@ func MsgToWrappedProto(msg Message) (cmtcons.Message, error) { }} case *HasProposalBlockPartMessage: - pb = &cmtcons.HasProposalBlockPart{ + pb.Sum = &cmtcons.Message_HasProposalBlockPart{HasProposalBlockPart: &cmtcons.HasProposalBlockPart{ Height: msg.Height, Round: msg.Round, Index: msg.Index, - } + }} case *VoteSetMaj23Message: bi := msg.BlockID.ToProto() @@ -117,7 +118,7 @@ func MsgToWrappedProto(msg Message) (cmtcons.Message, error) { pb.Sum = &cmtcons.Message_VoteSetBits{VoteSetBits: vsb} default: - return nil, ErrConsensusMessageNotRecognized{msg} + return pb, ErrConsensusMessageNotRecognized{msg} } return pb, nil diff --git a/consensus/state_test.go b/consensus/state_test.go index 44c58e47634..4a360175815 100644 --- a/consensus/state_test.go +++ b/consensus/state_test.go @@ -739,7 +739,7 @@ func TestStateLockPOLUpdateLock(t *testing.T) { validatePrevote(t, cs1, round, vss[0], nil) // Add prevotes from the remainder of the validators for the new locked block. - signAddVotes(cs1, cmtproto.PrevoteType, propBlockR1Hash, propBlockR1Parts.Header(), false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, propBlockR1Hash, propBlockR1Parts.Header(), false, vs2, vs3, vs4) // Check that we lock on a new block. ensureLock(lockCh, height, round) @@ -790,7 +790,7 @@ func TestStateLockPOLRelock(t *testing.T) { ensurePrevote(voteCh, height, round) - signAddVotes(cs1, cmtproto.PrevoteType, theBlockHash, theBlockParts.Header(), false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, theBlockHash, theBlockParts.Header(), false, vs2, vs3, vs4) // check that the validator generates a Lock event. ensureLock(lockCh, height, round) @@ -799,7 +799,7 @@ func TestStateLockPOLRelock(t *testing.T) { validatePrecommit(t, cs1, round, round, vss[0], theBlockHash, theBlockHash) // add precommits from the rest of the validators. - signAddVotes(cs1, cmtproto.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) + signAddVotes(cs1, types.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) // timeout to new round. ensureNewTimeout(timeoutWaitCh, height, round, cs1.config.Precommit(round).Nanoseconds()) @@ -883,7 +883,7 @@ func TestStateLockPrevoteNilWhenLockedAndMissProposal(t *testing.T) { ensurePrevote(voteCh, height, round) - signAddVotes(cs1, cmtproto.PrevoteType, theBlockHash, theBlockParts.Header(), false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, theBlockHash, theBlockParts.Header(), false, vs2, vs3, vs4) // check that the validator generates a Lock event. ensureLock(lockCh, height, round) @@ -893,7 +893,7 @@ func TestStateLockPrevoteNilWhenLockedAndMissProposal(t *testing.T) { validatePrecommit(t, cs1, round, round, vss[0], theBlockHash, theBlockHash) // add precommits from the rest of the validators. - signAddVotes(cs1, cmtproto.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) + signAddVotes(cs1, types.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) // timeout to new round. ensureNewTimeout(timeoutWaitCh, height, round, cs1.config.Precommit(round).Nanoseconds()) @@ -917,7 +917,7 @@ func TestStateLockPrevoteNilWhenLockedAndMissProposal(t *testing.T) { validatePrevote(t, cs1, round, vss[0], nil) // Add prevotes from the remainder of the validators nil. - signAddVotes(cs1, cmtproto.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) ensurePrecommit(voteCh, height, round) // We should now be locked on the same block but with an updated locked round. validatePrecommit(t, cs1, round, 0, vss[0], nil, theBlockHash) @@ -968,7 +968,7 @@ func TestStateLockPrevoteNilWhenLockedAndDifferentProposal(t *testing.T) { ensurePrevote(voteCh, height, round) - signAddVotes(cs1, cmtproto.PrevoteType, theBlockHash, theBlockParts.Header(), false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, theBlockHash, theBlockParts.Header(), false, vs2, vs3, vs4) // check that the validator generates a Lock event. ensureLock(lockCh, height, round) @@ -978,7 +978,7 @@ func TestStateLockPrevoteNilWhenLockedAndDifferentProposal(t *testing.T) { validatePrecommit(t, cs1, round, round, vss[0], theBlockHash, theBlockHash) // add precommits from the rest of the validators. - signAddVotes(cs1, cmtproto.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) + signAddVotes(cs1, types.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) // timeout to new round. ensureNewTimeout(timeoutWaitCh, height, round, cs1.config.Precommit(round).Nanoseconds()) @@ -1014,7 +1014,7 @@ func TestStateLockPrevoteNilWhenLockedAndDifferentProposal(t *testing.T) { validatePrevote(t, cs1, round, vss[0], nil) // Add prevotes from the remainder of the validators for nil. - signAddVotes(cs1, cmtproto.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) // We should now be locked on the same block but prevote nil. ensurePrecommit(voteCh, height, round) @@ -1127,7 +1127,7 @@ func TestStateLockPOLDoesNotUnlock(t *testing.T) { // verify that we haven't update our locked block since the first round validatePrecommit(t, cs1, round, 0, vss[0], nil, theBlockHash) - signAddVotes(cs1, cmtproto.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) + signAddVotes(cs1, types.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) ensureNewTimeout(timeoutWaitCh, height, round, cs1.config.Precommit(round).Nanoseconds()) /* Round 2: @@ -1155,7 +1155,7 @@ func TestStateLockPOLDoesNotUnlock(t *testing.T) { ensurePrevote(voteCh, height, round) validatePrevote(t, cs1, round, vss[0], nil) - signAddVotes(cs1, cmtproto.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) ensurePrecommit(voteCh, height, round) @@ -1362,13 +1362,13 @@ func TestStateLockDoesNotLockOnOldProposal(t *testing.T) { ensurePrevote(voteCh, height, round) - signAddVotes(cs1, cmtproto.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) // The proposed block should not have been locked. ensurePrecommit(voteCh, height, round) validatePrecommit(t, cs1, round, -1, vss[0], nil, nil) - signAddVotes(cs1, cmtproto.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) + signAddVotes(cs1, types.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) incrementRound(vs2, vs3, vs4) @@ -1659,7 +1659,7 @@ func TestStatePrevotePOLFromPreviousRound(t *testing.T) { ensurePrevote(voteCh, height, round) - signAddVotes(cs1, cmtproto.PrevoteType, theBlockHash, theBlockParts, false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, theBlockHash, theBlockParts, false, vs2, vs3, vs4) // check that the validator generates a Lock event. ensureLock(lockCh, height, round) @@ -1669,7 +1669,7 @@ func TestStatePrevotePOLFromPreviousRound(t *testing.T) { validatePrecommit(t, cs1, round, round, vss[0], theBlockHash, theBlockHash) // add precommits from the rest of the validators. - signAddVotes(cs1, cmtproto.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) + signAddVotes(cs1, types.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) // timeout to new round. ensureNewTimeout(timeoutWaitCh, height, round, cs1.config.Precommit(round).Nanoseconds()) @@ -1699,12 +1699,12 @@ func TestStatePrevotePOLFromPreviousRound(t *testing.T) { ensureNewRound(newRoundCh, height, round) - signAddVotes(cs1, cmtproto.PrevoteType, propBlockR1Hash, propBlockR1Parts.Header(), false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, propBlockR1Hash, propBlockR1Parts.Header(), false, vs2, vs3, vs4) ensurePrevote(voteCh, height, round) validatePrevote(t, cs1, round, vss[0], nil) - signAddVotes(cs1, cmtproto.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) + signAddVotes(cs1, types.PrecommitType, nil, types.PartSetHeader{}, true, vs2, vs3, vs4) ensurePrecommit(voteCh, height, round) @@ -1748,7 +1748,7 @@ func TestStatePrevotePOLFromPreviousRound(t *testing.T) { ensurePrevote(voteCh, height, round) validatePrevote(t, cs1, round, vss[0], propBlockR1Hash) - signAddVotes(cs1, cmtproto.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) + signAddVotes(cs1, types.PrevoteType, nil, types.PartSetHeader{}, false, vs2, vs3, vs4) // cs1 did not receive a POL within this round, so it should remain locked // on the block from round 0. diff --git a/mempool/clist_mempool.go b/mempool/clist_mempool.go index bbb6398ff28..3ad75bafa22 100644 --- a/mempool/clist_mempool.go +++ b/mempool/clist_mempool.go @@ -4,6 +4,7 @@ import ( "bytes" "context" "errors" + "fmt" "sync" "sync/atomic" @@ -283,7 +284,10 @@ func (mem *CListMempool) CheckTx(tx types.Tx) (*abcicli.ReqRes, error) { return nil, ErrTxInCache } - reqRes, err := mem.proxyAppConn.CheckTxAsync(context.TODO(), &abci.RequestCheckTx{Tx: tx}) + reqRes, err := mem.proxyAppConn.CheckTxAsync(context.TODO(), &abci.RequestCheckTx{ + Tx: tx, + Type: abci.CHECK_TX_TYPE_CHECK, + }) if err != nil { mem.logger.Error("RequestCheckTx", "err", err) return nil, err @@ -296,20 +300,24 @@ func (mem *CListMempool) CheckTx(tx types.Tx) (*abcicli.ReqRes, error) { func (mem *CListMempool) globalCb(req *abci.Request, res *abci.Response) { switch res.Value.(type) { case *abci.Response_CheckTx: - switch req.GetCheckTx().GetType() { - case abci.CheckTxType_New: + checkType := req.GetCheckTx().GetType() + switch checkType { + case abci.CHECK_TX_TYPE_CHECK: if mem.recheckCursor != nil { // this should never happen panic("recheck cursor is not nil before resCbFirstTime") } mem.resCbFirstTime(req.GetCheckTx().Tx, res) - case abci.CheckTxType_Recheck: + case abci.CHECK_TX_TYPE_RECHECK: if mem.recheckCursor == nil { return } mem.metrics.RecheckTimes.Add(1) mem.resCbRecheck(req, res) + + default: + panic(fmt.Sprintf("unexpected value %d of RequestCheckTx.type", checkType)) } // update metrics diff --git a/mempool/clist_mempool_test.go b/mempool/clist_mempool_test.go index 6d84045a315..3c0bd6c0b05 100644 --- a/mempool/clist_mempool_test.go +++ b/mempool/clist_mempool_test.go @@ -273,7 +273,7 @@ func TestMempoolUpdateDoesNotPanicWhenApplicationMissedTx(t *testing.T) { // Add 4 transactions to the mempool by calling the mempool's `CheckTx` on each of them. txs := []types.Tx{[]byte{0x01}, []byte{0x02}, []byte{0x03}, []byte{0x04}} for _, tx := range txs { - reqRes := abciclient.NewReqRes(abci.ToRequestCheckTx(&abci.RequestCheckTx{Tx: tx})) + reqRes := abciclient.NewReqRes(abci.ToRequestCheckTx(&abci.RequestCheckTx{Tx: tx, Type: abci.CHECK_TX_TYPE_CHECK})) reqRes.Response = abci.ToResponseCheckTx(&abci.ResponseCheckTx{Code: abci.CodeTypeOK}) mockClient.On("CheckTxAsync", mock.Anything, mock.Anything).Return(reqRes, nil) @@ -296,10 +296,10 @@ func TestMempoolUpdateDoesNotPanicWhenApplicationMissedTx(t *testing.T) { // Previous versions of this code panicked when the ABCI application missed // a recheck-tx request. resp := &abci.ResponseCheckTx{Code: abci.CodeTypeOK} - req := &abci.RequestCheckTx{Tx: txs[1]} + req := &abci.RequestCheckTx{Tx: txs[1], Type: abci.CHECK_TX_TYPE_CHECK} callback(abci.ToRequestCheckTx(req), abci.ToResponseCheckTx(resp)) - req = &abci.RequestCheckTx{Tx: txs[3]} + req = &abci.RequestCheckTx{Tx: txs[3], Type: abci.CHECK_TX_TYPE_CHECK} callback(abci.ToRequestCheckTx(req), abci.ToResponseCheckTx(resp)) mockClient.AssertExpectations(t) } diff --git a/mempool/mocks/mempool.go b/mempool/mocks/mempool.go index 3a01f10b910..2c8eef295a4 100644 --- a/mempool/mocks/mempool.go +++ b/mempool/mocks/mempool.go @@ -4,13 +4,13 @@ package mocks import ( abcicli "github.com/cometbft/cometbft/abci/client" - abcitypes "github.com/cometbft/cometbft/abci/types" - mempool "github.com/cometbft/cometbft/mempool" mock "github.com/stretchr/testify/mock" types "github.com/cometbft/cometbft/types" + + v3 "github.com/cometbft/cometbft/api/cometbft/abci/v3" ) // Mempool is an autogenerated mock type for the Mempool type @@ -174,11 +174,11 @@ func (_m *Mempool) Unlock() { } // Update provides a mock function with given fields: blockHeight, blockTxs, deliverTxResponses, newPreFn, newPostFn -func (_m *Mempool) Update(blockHeight int64, blockTxs types.Txs, deliverTxResponses []*abcitypes.ExecTxResult, newPreFn mempool.PreCheckFunc, newPostFn mempool.PostCheckFunc) error { +func (_m *Mempool) Update(blockHeight int64, blockTxs types.Txs, deliverTxResponses []*v3.ExecTxResult, newPreFn mempool.PreCheckFunc, newPostFn mempool.PostCheckFunc) error { ret := _m.Called(blockHeight, blockTxs, deliverTxResponses, newPreFn, newPostFn) var r0 error - if rf, ok := ret.Get(0).(func(int64, types.Txs, []*abcitypes.ExecTxResult, mempool.PreCheckFunc, mempool.PostCheckFunc) error); ok { + if rf, ok := ret.Get(0).(func(int64, types.Txs, []*v3.ExecTxResult, mempool.PreCheckFunc, mempool.PostCheckFunc) error); ok { r0 = rf(blockHeight, blockTxs, deliverTxResponses, newPreFn, newPostFn) } else { r0 = ret.Error(0) diff --git a/proto/cometbft/abci/v3/types.proto b/proto/cometbft/abci/v3/types.proto index 06b9026816e..56f49bc114c 100644 --- a/proto/cometbft/abci/v3/types.proto +++ b/proto/cometbft/abci/v3/types.proto @@ -101,10 +101,18 @@ message RequestProcessProposal { // Extends a vote with application-injected data message RequestExtendVote { - // the hash of the block that this vote may be referring to + // the hash of the block that this vote may be referring to bytes hash = 1; // the height of the extended vote int64 height = 2; + // info of the block that this vote may be referring to + google.protobuf.Timestamp time = 3 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; + repeated bytes txs = 4; + CommitInfo proposed_last_commit = 5 [(gogoproto.nullable) = false]; + repeated v2.Misbehavior misbehavior = 6 [(gogoproto.nullable) = false]; + bytes next_validators_hash = 7; + // address of the public key of the original proposer of the block. + bytes proposer_address = 8; } // Verify the vote extension @@ -207,7 +215,7 @@ message ResponseFinalizeBlock { repeated v2.Event events = 1 [(gogoproto.nullable) = false, (gogoproto.jsontag) = "events,omitempty"]; // the result of executing each transaction including the events - // the particular transction emitted. This should match the order + // the particular transaction emitted. This should match the order // of the transactions delivered in the block itself repeated ExecTxResult tx_results = 2; // a list of updates to the validator set. These will reflect the validator set at current height + 2. diff --git a/proto/cometbft/abci/v4/types.proto b/proto/cometbft/abci/v4/types.proto index d58da7afc59..f75088312ae 100644 --- a/proto/cometbft/abci/v4/types.proto +++ b/proto/cometbft/abci/v4/types.proto @@ -23,7 +23,7 @@ service ABCI { rpc ApplySnapshotChunk(v1.RequestApplySnapshotChunk) returns (ResponseApplySnapshotChunk); rpc PrepareProposal(RequestPrepareProposal) returns (v2.ResponsePrepareProposal); rpc ProcessProposal(RequestProcessProposal) returns (ResponseProcessProposal); - rpc ExtendVote(v3.RequestExtendVote) returns (v3.ResponseExtendVote); + rpc ExtendVote(RequestExtendVote) returns (v3.ResponseExtendVote); rpc VerifyVoteExtension(v3.RequestVerifyVoteExtension) returns (ResponseVerifyVoteExtension); rpc FinalizeBlock(RequestFinalizeBlock) returns (v3.ResponseFinalizeBlock); } @@ -46,7 +46,7 @@ message Request { v1.RequestApplySnapshotChunk apply_snapshot_chunk = 15; RequestPrepareProposal prepare_proposal = 16; RequestProcessProposal process_proposal = 17; - v3.RequestExtendVote extend_vote = 18; + RequestExtendVote extend_vote = 18; v3.RequestVerifyVoteExtension verify_vote_extension = 19; RequestFinalizeBlock finalize_block = 20; } @@ -106,6 +106,22 @@ message RequestProcessProposal { bytes proposer_address = 8; } +// Extends a vote with application-injected data +message RequestExtendVote { + // the hash of the block that this vote may be referring to + bytes hash = 1; + // the height of the extended vote + int64 height = 2; + // info of the block that this vote may be referring to + google.protobuf.Timestamp time = 3 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; + repeated bytes txs = 4; + v3.CommitInfo proposed_last_commit = 5 [(gogoproto.nullable) = false]; + repeated Misbehavior misbehavior = 6 [(gogoproto.nullable) = false]; + bytes next_validators_hash = 7; + // address of the public key of the original proposer of the block. + bytes proposer_address = 8; +} + message RequestFinalizeBlock { repeated bytes txs = 1; v3.CommitInfo decided_last_commit = 2 [(gogoproto.nullable) = false]; diff --git a/proto/cometbft/consensus/v2/types.proto b/proto/cometbft/consensus/v2/types.proto index 6e2522d8f16..05b4f16ac86 100644 --- a/proto/cometbft/consensus/v2/types.proto +++ b/proto/cometbft/consensus/v2/types.proto @@ -12,6 +12,13 @@ message Vote { cometbft.types.v3.Vote vote = 1; } +// HasProposalBlockPart is sent to indicate that a particular proposal block part has been received. +message HasProposalBlockPart { + int64 height = 1; + int32 round = 2; + int32 index = 3; +} + message Message { oneof sum { v1.NewRoundStep new_round_step = 1; @@ -23,5 +30,6 @@ message Message { v1.HasVote has_vote = 7; v1.VoteSetMaj23 vote_set_maj23 = 8; v1.VoteSetBits vote_set_bits = 9; + HasProposalBlockPart has_proposal_block_part = 10; } } diff --git a/proto/cometbft/services/block/v1/block.proto b/proto/cometbft/services/block/v1/block.proto new file mode 100644 index 00000000000..ae4e24de3b7 --- /dev/null +++ b/proto/cometbft/services/block/v1/block.proto @@ -0,0 +1,34 @@ +syntax = "proto3"; +package cometbft.services.block.v1; + +import "cometbft/types/v1/types.proto"; +import "cometbft/types/v3/block.proto"; + +option go_package = "github.com/cometbft/cometbft/proto/cometbft/services/block/v1"; + +message GetByHeightRequest { + // The height of the block requested. If set to 0, the latest height will be returned. + int64 height = 1; +} + +message GetByHeightResponse { + cometbft.types.v1.BlockID block_id = 1; + cometbft.types.v3.Block block = 2; +} + +message GetLatestRequest {} + +message GetLatestResponse { + cometbft.types.v1.BlockID block_id = 1; + cometbft.types.v3.Block block = 2; +} + +// GetLatestHeightRequest - empty message since no parameter is required +message GetLatestHeightRequest {} + +// GetLatestHeightResponse provides the height of the latest committed block. +message GetLatestHeightResponse { + // The height of the latest committed block. Will be 0 if no data has been + // committed yet. + int64 height = 1; +} diff --git a/proto/cometbft/services/block/v1/block_service.proto b/proto/cometbft/services/block/v1/block_service.proto new file mode 100644 index 00000000000..d2aa68b6fa0 --- /dev/null +++ b/proto/cometbft/services/block/v1/block_service.proto @@ -0,0 +1,21 @@ +syntax = "proto3"; +package cometbft.services.block.v1; + +option go_package = "github.com/cometbft/cometbft/proto/cometbft/services/block/v1"; + +import "cometbft/services/block/v1/block.proto"; + +// BlockService provides information about blocks +service BlockService { + // GetBlock retrieves the block information at a particular height. + rpc GetByHeight(GetByHeightRequest) returns (GetByHeightResponse); + + // GetLatest retrieves the latest block. + rpc GetLatest(GetLatestRequest) returns (GetLatestResponse); + + // GetLatestHeight returns a stream of the latest block heights committed by + // the network. This is a long-lived stream that is only terminated by the + // server if an error occurs. The caller is expected to handle such + // disconnections and automatically reconnect. + rpc GetLatestHeight(GetLatestHeightRequest) returns (stream GetLatestHeightResponse); +} diff --git a/proto/cometbft/services/block_results/v1/block_results.proto b/proto/cometbft/services/block_results/v1/block_results.proto new file mode 100644 index 00000000000..ce0a6e18be2 --- /dev/null +++ b/proto/cometbft/services/block_results/v1/block_results.proto @@ -0,0 +1,25 @@ +syntax = "proto3"; +package cometbft.services.block_results.v1; + +import "cometbft/abci/v1/types.proto"; +import "cometbft/abci/v2/types.proto"; +import "cometbft/abci/v3/types.proto"; +import "cometbft/types/v3/params.proto"; + +option go_package = "github.com/cometbft/cometbft/proto/cometbft/services/block_results/v1"; + +message GetBlockResultsRequest { + int64 height = 1; +} + +message GetLatestBlockResultsRequest { +} + +message GetBlockResultsResponse { + int64 height = 1; + repeated cometbft.abci.v3.ExecTxResult txs_results = 2; + repeated cometbft.abci.v2.Event finalize_block_events = 3; + repeated cometbft.abci.v1.ValidatorUpdate validator_updates = 4; + cometbft.types.v3.ConsensusParams consensus_param_updates = 5; + bytes app_hash = 6; +} diff --git a/proto/cometbft/services/block_results/v1/block_results_service.proto b/proto/cometbft/services/block_results/v1/block_results_service.proto new file mode 100644 index 00000000000..6d1601455f3 --- /dev/null +++ b/proto/cometbft/services/block_results/v1/block_results_service.proto @@ -0,0 +1,17 @@ +syntax = "proto3"; +package cometbft.services.block_results.v1; + +option go_package = "github.com/cometbft/cometbft/proto/cometbft/services/block_results/v1"; + +import "cometbft/services/block_results/v1/block_results.proto"; + +/* + BlockResultService provides the block results of a given or latestheight. + */ +service BlockResultsService { + // GetBlockResults returns the BlockResults of the requested height. + rpc GetBlockResults(GetBlockResultsRequest) returns (GetBlockResultsResponse); + + // GetLatestBlockResults returns the BlockResults of the latest committed height. + rpc GetLatestBlockResults(GetLatestBlockResultsRequest) returns (GetBlockResultsResponse); +} diff --git a/proto/cometbft/services/pruning/v1/pruning.proto b/proto/cometbft/services/pruning/v1/pruning.proto new file mode 100644 index 00000000000..47889a7ad5c --- /dev/null +++ b/proto/cometbft/services/pruning/v1/pruning.proto @@ -0,0 +1,58 @@ +syntax = "proto3"; + +package cometbft.services.pruning.v1; + +message SetBlockRetainHeightRequest { + uint64 height = 1; +} + +message SetBlockRetainHeightResponse {} + +message GetBlockRetainHeightRequest {} + +message GetBlockRetainHeightResponse { + // The retain height set by the application. + uint64 app_retain_height = 1; + + // The retain height set via the pruning service (e.g. by the data + // companion) specifically for blocks. + uint64 pruning_service_retain_height = 2; +} + +message SetBlockResultsRetainHeightRequest { + uint64 height = 1; +} + +message SetBlockResultsRetainHeightResponse {} + +message GetBlockResultsRetainHeightRequest {} + +message GetBlockResultsRetainHeightResponse { + // The retain height set by the pruning service (e.g. by the data + // companion) specifically for block results. + uint64 pruning_service_retain_height = 1; +} + +message SetTxIndexerRetainHeightRequest { + uint64 height = 1; +} + +message SetTxIndexerRetainHeightResponse {} + +message GetTxIndexerRetainHeightRequest {} + +message GetTxIndexerRetainHeightResponse { + uint64 height = 1; +} + +message SetBlockIndexerRetainHeightRequest { + uint64 height = 1; +} + +message SetBlockIndexerRetainHeightResponse {} + +message GetBlockIndexerRetainHeightRequest {} + +message GetBlockIndexerRetainHeightResponse { + uint64 height = 1; +} diff --git a/proto/cometbft/services/pruning/v1/service.proto b/proto/cometbft/services/pruning/v1/service.proto new file mode 100644 index 00000000000..3b18180fd43 --- /dev/null +++ b/proto/cometbft/services/pruning/v1/service.proto @@ -0,0 +1,48 @@ +syntax = "proto3"; + +package cometbft.services.pruning.v1; + +import "cometbft/services/pruning/v1/pruning.proto"; + +// PruningService provides privileged access to specialized pruning +// functionality on the CometBFT node to help control node storage. +service PruningService { + // SetBlockRetainHeightRequest indicates to the node that it can safely + // prune all block data up to the specified retain height. + // + // The lower of this retain height and that set by the application in its + // Commit response will be used by the node to determine which heights' data + // can be pruned. + rpc SetBlockRetainHeight(SetBlockRetainHeightRequest) returns (SetBlockRetainHeightResponse); + + // GetBlockRetainHeight returns information about the retain height + // parameters used by the node to influence block retention/pruning. + rpc GetBlockRetainHeight(GetBlockRetainHeightRequest) returns (GetBlockRetainHeightResponse); + + // SetBlockResultsRetainHeightRequest indicates to the node that it can + // safely prune all block results data up to the specified height. + // + // The node will always store the block results for the latest height to + // help facilitate crash recovery. + rpc SetBlockResultsRetainHeight(SetBlockResultsRetainHeightRequest) returns (SetBlockResultsRetainHeightResponse); + + // GetBlockResultsRetainHeight returns information about the retain height + // parameters used by the node to influence block results retention/pruning. + rpc GetBlockResultsRetainHeight(GetBlockResultsRetainHeightRequest) returns (GetBlockResultsRetainHeightResponse); + + // SetTxIndexerRetainHeightRequest indicates to the node that it can safely + // prune all tx indices up to the specified retain height. + rpc SetTxIndexerRetainHeight(SetTxIndexerRetainHeightRequest) returns (SetTxIndexerRetainHeightResponse); + + // GetTxIndexerRetainHeight returns information about the retain height + // parameters used by the node to influence TxIndexer pruning + rpc GetTxIndexerRetainHeight(GetTxIndexerRetainHeightRequest) returns (GetTxIndexerRetainHeightResponse); + + // SetBlockIndexerRetainHeightRequest indicates to the node that it can safely + // prune all block indices up to the specified retain height. + rpc SetBlockIndexerRetainHeight(SetBlockIndexerRetainHeightRequest) returns (SetBlockIndexerRetainHeightResponse); + + // GetBlockIndexerRetainHeight returns information about the retain height + // parameters used by the node to influence BlockIndexer pruning + rpc GetBlockIndexerRetainHeight(GetBlockIndexerRetainHeightRequest) returns (GetBlockIndexerRetainHeightResponse); +} diff --git a/proto/cometbft/services/version/v1/version.proto b/proto/cometbft/services/version/v1/version.proto new file mode 100644 index 00000000000..515c6fbf7b0 --- /dev/null +++ b/proto/cometbft/services/version/v1/version.proto @@ -0,0 +1,13 @@ +syntax = "proto3"; +package cometbft.services.version.v1; + +option go_package = "github.com/cometbft/cometbft/proto/cometbft/services/version/v1"; + +message GetVersionRequest {} + +message GetVersionResponse { + string node = 1; // The semantic version of the node software. + string abci = 2; // The version of ABCI used by the node. + uint64 p2p = 3; // The version of the P2P protocol. + uint64 block = 4; // The version of the block protocol. +} diff --git a/proto/cometbft/services/version/v1/version_service.proto b/proto/cometbft/services/version/v1/version_service.proto new file mode 100644 index 00000000000..af1800a7df0 --- /dev/null +++ b/proto/cometbft/services/version/v1/version_service.proto @@ -0,0 +1,19 @@ +syntax = "proto3"; +package cometbft.services.version.v1; + +option go_package = "github.com/cometbft/cometbft/proto/cometbft/services/version/v1"; + +import "cometbft/services/version/v1/version.proto"; + +// VersionService simply provides version information about the node and the +// protocols it uses. +// +// The intention with this service is to offer a stable interface through which +// clients can access version information. This means that the version of the +// service should be kept stable at v1, with GetVersionResponse evolving only +// in non-breaking ways. +service VersionService { + // GetVersion retrieves version information about the node and the protocols + // it implements. + rpc GetVersion(GetVersionRequest) returns (GetVersionResponse); +} diff --git a/proxy/app_conn_test.go b/proxy/app_conn_test.go index cbe73d11b7c..3b103ff1f0b 100644 --- a/proxy/app_conn_test.go +++ b/proxy/app_conn_test.go @@ -44,7 +44,10 @@ func TestEcho(t *testing.T) { t.Log("Connected") for i := 0; i < 1000; i++ { - _, err = proxy.CheckTx(context.Background(), &abci.RequestCheckTx{Tx: []byte(fmt.Sprintf("echo-%v", i))}) + _, err = proxy.CheckTx(context.Background(), &abci.RequestCheckTx{ + Tx: []byte(fmt.Sprintf("echo-%v", i)), + Type: abci.CHECK_TX_TYPE_CHECK, + }) if err != nil { t.Fatal(err) } @@ -86,7 +89,10 @@ func BenchmarkEcho(b *testing.B) { b.StartTimer() // Start benchmarking tests for i := 0; i < b.N; i++ { - _, err = proxy.CheckTx(context.Background(), &abci.RequestCheckTx{Tx: []byte("hello")}) + _, err = proxy.CheckTx(context.Background(), &abci.RequestCheckTx{ + Tx: []byte("hello"), + Type: abci.CHECK_TX_TYPE_CHECK, + }) if err != nil { b.Error(err) } diff --git a/proxy/mocks/app_conn_consensus.go b/proxy/mocks/app_conn_consensus.go index 3ae1625e025..216c55679fc 100644 --- a/proxy/mocks/app_conn_consensus.go +++ b/proxy/mocks/app_conn_consensus.go @@ -7,7 +7,11 @@ import ( mock "github.com/stretchr/testify/mock" - types "github.com/cometbft/cometbft/abci/types" + v2 "github.com/cometbft/cometbft/api/cometbft/abci/v2" + + v3 "github.com/cometbft/cometbft/api/cometbft/abci/v3" + + v4 "github.com/cometbft/cometbft/api/cometbft/abci/v4" ) // AppConnConsensus is an autogenerated mock type for the AppConnConsensus type @@ -16,19 +20,19 @@ type AppConnConsensus struct { } // Commit provides a mock function with given fields: _a0 -func (_m *AppConnConsensus) Commit(_a0 context.Context) (*types.ResponseCommit, error) { +func (_m *AppConnConsensus) Commit(_a0 context.Context) (*v3.ResponseCommit, error) { ret := _m.Called(_a0) - var r0 *types.ResponseCommit + var r0 *v3.ResponseCommit var r1 error - if rf, ok := ret.Get(0).(func(context.Context) (*types.ResponseCommit, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context) (*v3.ResponseCommit, error)); ok { return rf(_a0) } - if rf, ok := ret.Get(0).(func(context.Context) *types.ResponseCommit); ok { + if rf, ok := ret.Get(0).(func(context.Context) *v3.ResponseCommit); ok { r0 = rf(_a0) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseCommit) + r0 = ret.Get(0).(*v3.ResponseCommit) } } @@ -56,23 +60,23 @@ func (_m *AppConnConsensus) Error() error { } // ExtendVote provides a mock function with given fields: _a0, _a1 -func (_m *AppConnConsensus) ExtendVote(_a0 context.Context, _a1 *types.RequestExtendVote) (*types.ResponseExtendVote, error) { +func (_m *AppConnConsensus) ExtendVote(_a0 context.Context, _a1 *v4.RequestExtendVote) (*v3.ResponseExtendVote, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseExtendVote + var r0 *v3.ResponseExtendVote var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestExtendVote) (*types.ResponseExtendVote, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestExtendVote) (*v3.ResponseExtendVote, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestExtendVote) *types.ResponseExtendVote); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestExtendVote) *v3.ResponseExtendVote); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseExtendVote) + r0 = ret.Get(0).(*v3.ResponseExtendVote) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestExtendVote) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestExtendVote) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -82,23 +86,23 @@ func (_m *AppConnConsensus) ExtendVote(_a0 context.Context, _a1 *types.RequestEx } // FinalizeBlock provides a mock function with given fields: _a0, _a1 -func (_m *AppConnConsensus) FinalizeBlock(_a0 context.Context, _a1 *types.RequestFinalizeBlock) (*types.ResponseFinalizeBlock, error) { +func (_m *AppConnConsensus) FinalizeBlock(_a0 context.Context, _a1 *v4.RequestFinalizeBlock) (*v3.ResponseFinalizeBlock, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseFinalizeBlock + var r0 *v3.ResponseFinalizeBlock var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestFinalizeBlock) (*types.ResponseFinalizeBlock, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestFinalizeBlock) (*v3.ResponseFinalizeBlock, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestFinalizeBlock) *types.ResponseFinalizeBlock); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestFinalizeBlock) *v3.ResponseFinalizeBlock); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseFinalizeBlock) + r0 = ret.Get(0).(*v3.ResponseFinalizeBlock) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestFinalizeBlock) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestFinalizeBlock) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -108,23 +112,23 @@ func (_m *AppConnConsensus) FinalizeBlock(_a0 context.Context, _a1 *types.Reques } // InitChain provides a mock function with given fields: _a0, _a1 -func (_m *AppConnConsensus) InitChain(_a0 context.Context, _a1 *types.RequestInitChain) (*types.ResponseInitChain, error) { +func (_m *AppConnConsensus) InitChain(_a0 context.Context, _a1 *v3.RequestInitChain) (*v3.ResponseInitChain, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseInitChain + var r0 *v3.ResponseInitChain var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInitChain) (*types.ResponseInitChain, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestInitChain) (*v3.ResponseInitChain, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInitChain) *types.ResponseInitChain); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestInitChain) *v3.ResponseInitChain); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseInitChain) + r0 = ret.Get(0).(*v3.ResponseInitChain) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestInitChain) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v3.RequestInitChain) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -134,23 +138,23 @@ func (_m *AppConnConsensus) InitChain(_a0 context.Context, _a1 *types.RequestIni } // PrepareProposal provides a mock function with given fields: _a0, _a1 -func (_m *AppConnConsensus) PrepareProposal(_a0 context.Context, _a1 *types.RequestPrepareProposal) (*types.ResponsePrepareProposal, error) { +func (_m *AppConnConsensus) PrepareProposal(_a0 context.Context, _a1 *v4.RequestPrepareProposal) (*v2.ResponsePrepareProposal, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponsePrepareProposal + var r0 *v2.ResponsePrepareProposal var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestPrepareProposal) (*types.ResponsePrepareProposal, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestPrepareProposal) (*v2.ResponsePrepareProposal, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestPrepareProposal) *types.ResponsePrepareProposal); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestPrepareProposal) *v2.ResponsePrepareProposal); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponsePrepareProposal) + r0 = ret.Get(0).(*v2.ResponsePrepareProposal) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestPrepareProposal) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestPrepareProposal) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -160,23 +164,23 @@ func (_m *AppConnConsensus) PrepareProposal(_a0 context.Context, _a1 *types.Requ } // ProcessProposal provides a mock function with given fields: _a0, _a1 -func (_m *AppConnConsensus) ProcessProposal(_a0 context.Context, _a1 *types.RequestProcessProposal) (*types.ResponseProcessProposal, error) { +func (_m *AppConnConsensus) ProcessProposal(_a0 context.Context, _a1 *v4.RequestProcessProposal) (*v4.ResponseProcessProposal, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseProcessProposal + var r0 *v4.ResponseProcessProposal var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestProcessProposal) (*types.ResponseProcessProposal, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestProcessProposal) (*v4.ResponseProcessProposal, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestProcessProposal) *types.ResponseProcessProposal); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestProcessProposal) *v4.ResponseProcessProposal); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseProcessProposal) + r0 = ret.Get(0).(*v4.ResponseProcessProposal) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestProcessProposal) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestProcessProposal) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -186,23 +190,23 @@ func (_m *AppConnConsensus) ProcessProposal(_a0 context.Context, _a1 *types.Requ } // VerifyVoteExtension provides a mock function with given fields: _a0, _a1 -func (_m *AppConnConsensus) VerifyVoteExtension(_a0 context.Context, _a1 *types.RequestVerifyVoteExtension) (*types.ResponseVerifyVoteExtension, error) { +func (_m *AppConnConsensus) VerifyVoteExtension(_a0 context.Context, _a1 *v3.RequestVerifyVoteExtension) (*v4.ResponseVerifyVoteExtension, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseVerifyVoteExtension + var r0 *v4.ResponseVerifyVoteExtension var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestVerifyVoteExtension) (*types.ResponseVerifyVoteExtension, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestVerifyVoteExtension) (*v4.ResponseVerifyVoteExtension, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestVerifyVoteExtension) *types.ResponseVerifyVoteExtension); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v3.RequestVerifyVoteExtension) *v4.ResponseVerifyVoteExtension); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseVerifyVoteExtension) + r0 = ret.Get(0).(*v4.ResponseVerifyVoteExtension) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestVerifyVoteExtension) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v3.RequestVerifyVoteExtension) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) diff --git a/proxy/mocks/app_conn_mempool.go b/proxy/mocks/app_conn_mempool.go index 92f1e40be4e..31d3d995965 100644 --- a/proxy/mocks/app_conn_mempool.go +++ b/proxy/mocks/app_conn_mempool.go @@ -9,7 +9,9 @@ import ( mock "github.com/stretchr/testify/mock" - types "github.com/cometbft/cometbft/abci/types" + v3 "github.com/cometbft/cometbft/api/cometbft/abci/v3" + + v4 "github.com/cometbft/cometbft/api/cometbft/abci/v4" ) // AppConnMempool is an autogenerated mock type for the AppConnMempool type @@ -18,23 +20,23 @@ type AppConnMempool struct { } // CheckTx provides a mock function with given fields: _a0, _a1 -func (_m *AppConnMempool) CheckTx(_a0 context.Context, _a1 *types.RequestCheckTx) (*types.ResponseCheckTx, error) { +func (_m *AppConnMempool) CheckTx(_a0 context.Context, _a1 *v4.RequestCheckTx) (*v3.ResponseCheckTx, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseCheckTx + var r0 *v3.ResponseCheckTx var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) (*types.ResponseCheckTx, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) (*v3.ResponseCheckTx, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) *types.ResponseCheckTx); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) *v3.ResponseCheckTx); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseCheckTx) + r0 = ret.Get(0).(*v3.ResponseCheckTx) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestCheckTx) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestCheckTx) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -44,15 +46,15 @@ func (_m *AppConnMempool) CheckTx(_a0 context.Context, _a1 *types.RequestCheckTx } // CheckTxAsync provides a mock function with given fields: _a0, _a1 -func (_m *AppConnMempool) CheckTxAsync(_a0 context.Context, _a1 *types.RequestCheckTx) (*abcicli.ReqRes, error) { +func (_m *AppConnMempool) CheckTxAsync(_a0 context.Context, _a1 *v4.RequestCheckTx) (*abcicli.ReqRes, error) { ret := _m.Called(_a0, _a1) var r0 *abcicli.ReqRes var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) (*abcicli.ReqRes, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) (*abcicli.ReqRes, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestCheckTx) *abcicli.ReqRes); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v4.RequestCheckTx) *abcicli.ReqRes); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { @@ -60,7 +62,7 @@ func (_m *AppConnMempool) CheckTxAsync(_a0 context.Context, _a1 *types.RequestCh } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestCheckTx) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v4.RequestCheckTx) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) diff --git a/proxy/mocks/app_conn_query.go b/proxy/mocks/app_conn_query.go index 4abe27e7172..10c8730cbd7 100644 --- a/proxy/mocks/app_conn_query.go +++ b/proxy/mocks/app_conn_query.go @@ -7,7 +7,9 @@ import ( mock "github.com/stretchr/testify/mock" - types "github.com/cometbft/cometbft/abci/types" + v1 "github.com/cometbft/cometbft/api/cometbft/abci/v1" + + v2 "github.com/cometbft/cometbft/api/cometbft/abci/v2" ) // AppConnQuery is an autogenerated mock type for the AppConnQuery type @@ -16,19 +18,19 @@ type AppConnQuery struct { } // Echo provides a mock function with given fields: _a0, _a1 -func (_m *AppConnQuery) Echo(_a0 context.Context, _a1 string) (*types.ResponseEcho, error) { +func (_m *AppConnQuery) Echo(_a0 context.Context, _a1 string) (*v1.ResponseEcho, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseEcho + var r0 *v1.ResponseEcho var r1 error - if rf, ok := ret.Get(0).(func(context.Context, string) (*types.ResponseEcho, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, string) (*v1.ResponseEcho, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, string) *types.ResponseEcho); ok { + if rf, ok := ret.Get(0).(func(context.Context, string) *v1.ResponseEcho); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseEcho) + r0 = ret.Get(0).(*v1.ResponseEcho) } } @@ -56,23 +58,23 @@ func (_m *AppConnQuery) Error() error { } // Info provides a mock function with given fields: _a0, _a1 -func (_m *AppConnQuery) Info(_a0 context.Context, _a1 *types.RequestInfo) (*types.ResponseInfo, error) { +func (_m *AppConnQuery) Info(_a0 context.Context, _a1 *v2.RequestInfo) (*v1.ResponseInfo, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseInfo + var r0 *v1.ResponseInfo var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInfo) (*types.ResponseInfo, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v2.RequestInfo) (*v1.ResponseInfo, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestInfo) *types.ResponseInfo); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v2.RequestInfo) *v1.ResponseInfo); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseInfo) + r0 = ret.Get(0).(*v1.ResponseInfo) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestInfo) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v2.RequestInfo) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -82,23 +84,23 @@ func (_m *AppConnQuery) Info(_a0 context.Context, _a1 *types.RequestInfo) (*type } // Query provides a mock function with given fields: _a0, _a1 -func (_m *AppConnQuery) Query(_a0 context.Context, _a1 *types.RequestQuery) (*types.ResponseQuery, error) { +func (_m *AppConnQuery) Query(_a0 context.Context, _a1 *v1.RequestQuery) (*v1.ResponseQuery, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseQuery + var r0 *v1.ResponseQuery var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestQuery) (*types.ResponseQuery, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestQuery) (*v1.ResponseQuery, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestQuery) *types.ResponseQuery); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestQuery) *v1.ResponseQuery); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseQuery) + r0 = ret.Get(0).(*v1.ResponseQuery) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestQuery) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestQuery) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) diff --git a/proxy/mocks/app_conn_snapshot.go b/proxy/mocks/app_conn_snapshot.go index ab4450cfd82..4bcf5eeb0e3 100644 --- a/proxy/mocks/app_conn_snapshot.go +++ b/proxy/mocks/app_conn_snapshot.go @@ -7,7 +7,9 @@ import ( mock "github.com/stretchr/testify/mock" - types "github.com/cometbft/cometbft/abci/types" + v1 "github.com/cometbft/cometbft/api/cometbft/abci/v1" + + v4 "github.com/cometbft/cometbft/api/cometbft/abci/v4" ) // AppConnSnapshot is an autogenerated mock type for the AppConnSnapshot type @@ -16,23 +18,23 @@ type AppConnSnapshot struct { } // ApplySnapshotChunk provides a mock function with given fields: _a0, _a1 -func (_m *AppConnSnapshot) ApplySnapshotChunk(_a0 context.Context, _a1 *types.RequestApplySnapshotChunk) (*types.ResponseApplySnapshotChunk, error) { +func (_m *AppConnSnapshot) ApplySnapshotChunk(_a0 context.Context, _a1 *v1.RequestApplySnapshotChunk) (*v4.ResponseApplySnapshotChunk, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseApplySnapshotChunk + var r0 *v4.ResponseApplySnapshotChunk var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestApplySnapshotChunk) (*types.ResponseApplySnapshotChunk, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestApplySnapshotChunk) (*v4.ResponseApplySnapshotChunk, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestApplySnapshotChunk) *types.ResponseApplySnapshotChunk); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestApplySnapshotChunk) *v4.ResponseApplySnapshotChunk); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseApplySnapshotChunk) + r0 = ret.Get(0).(*v4.ResponseApplySnapshotChunk) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestApplySnapshotChunk) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestApplySnapshotChunk) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -56,23 +58,23 @@ func (_m *AppConnSnapshot) Error() error { } // ListSnapshots provides a mock function with given fields: _a0, _a1 -func (_m *AppConnSnapshot) ListSnapshots(_a0 context.Context, _a1 *types.RequestListSnapshots) (*types.ResponseListSnapshots, error) { +func (_m *AppConnSnapshot) ListSnapshots(_a0 context.Context, _a1 *v1.RequestListSnapshots) (*v1.ResponseListSnapshots, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseListSnapshots + var r0 *v1.ResponseListSnapshots var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestListSnapshots) (*types.ResponseListSnapshots, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestListSnapshots) (*v1.ResponseListSnapshots, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestListSnapshots) *types.ResponseListSnapshots); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestListSnapshots) *v1.ResponseListSnapshots); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseListSnapshots) + r0 = ret.Get(0).(*v1.ResponseListSnapshots) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestListSnapshots) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestListSnapshots) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -82,23 +84,23 @@ func (_m *AppConnSnapshot) ListSnapshots(_a0 context.Context, _a1 *types.Request } // LoadSnapshotChunk provides a mock function with given fields: _a0, _a1 -func (_m *AppConnSnapshot) LoadSnapshotChunk(_a0 context.Context, _a1 *types.RequestLoadSnapshotChunk) (*types.ResponseLoadSnapshotChunk, error) { +func (_m *AppConnSnapshot) LoadSnapshotChunk(_a0 context.Context, _a1 *v1.RequestLoadSnapshotChunk) (*v1.ResponseLoadSnapshotChunk, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseLoadSnapshotChunk + var r0 *v1.ResponseLoadSnapshotChunk var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestLoadSnapshotChunk) (*types.ResponseLoadSnapshotChunk, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestLoadSnapshotChunk) (*v1.ResponseLoadSnapshotChunk, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestLoadSnapshotChunk) *types.ResponseLoadSnapshotChunk); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestLoadSnapshotChunk) *v1.ResponseLoadSnapshotChunk); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseLoadSnapshotChunk) + r0 = ret.Get(0).(*v1.ResponseLoadSnapshotChunk) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestLoadSnapshotChunk) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestLoadSnapshotChunk) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) @@ -108,23 +110,23 @@ func (_m *AppConnSnapshot) LoadSnapshotChunk(_a0 context.Context, _a1 *types.Req } // OfferSnapshot provides a mock function with given fields: _a0, _a1 -func (_m *AppConnSnapshot) OfferSnapshot(_a0 context.Context, _a1 *types.RequestOfferSnapshot) (*types.ResponseOfferSnapshot, error) { +func (_m *AppConnSnapshot) OfferSnapshot(_a0 context.Context, _a1 *v1.RequestOfferSnapshot) (*v4.ResponseOfferSnapshot, error) { ret := _m.Called(_a0, _a1) - var r0 *types.ResponseOfferSnapshot + var r0 *v4.ResponseOfferSnapshot var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestOfferSnapshot) (*types.ResponseOfferSnapshot, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestOfferSnapshot) (*v4.ResponseOfferSnapshot, error)); ok { return rf(_a0, _a1) } - if rf, ok := ret.Get(0).(func(context.Context, *types.RequestOfferSnapshot) *types.ResponseOfferSnapshot); ok { + if rf, ok := ret.Get(0).(func(context.Context, *v1.RequestOfferSnapshot) *v4.ResponseOfferSnapshot); ok { r0 = rf(_a0, _a1) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.ResponseOfferSnapshot) + r0 = ret.Get(0).(*v4.ResponseOfferSnapshot) } } - if rf, ok := ret.Get(1).(func(context.Context, *types.RequestOfferSnapshot) error); ok { + if rf, ok := ret.Get(1).(func(context.Context, *v1.RequestOfferSnapshot) error); ok { r1 = rf(_a0, _a1) } else { r1 = ret.Error(1) diff --git a/rpc/core/mempool.go b/rpc/core/mempool.go index ea91520bc23..4f7b1dac1af 100644 --- a/rpc/core/mempool.go +++ b/rpc/core/mempool.go @@ -173,7 +173,7 @@ func (env *Environment) NumUnconfirmedTxs(*rpctypes.Context) (*ctypes.ResultUnco // be added to the mempool either. // More: https://docs.cometbft.com/main/rpc/#/Tx/check_tx func (env *Environment) CheckTx(_ *rpctypes.Context, tx types.Tx) (*ctypes.ResultCheckTx, error) { - res, err := env.ProxyAppMempool.CheckTx(context.TODO(), &abci.RequestCheckTx{Tx: tx}) + res, err := env.ProxyAppMempool.CheckTx(context.TODO(), &abci.RequestCheckTx{Tx: tx, Type: abci.CHECK_TX_TYPE_CHECK}) if err != nil { return nil, err } diff --git a/rpc/grpc/client/block_results_service.go b/rpc/grpc/client/block_results_service.go index be2eb23e0a8..a7348a09353 100644 --- a/rpc/grpc/client/block_results_service.go +++ b/rpc/grpc/client/block_results_service.go @@ -5,11 +5,11 @@ import ( "fmt" abci "github.com/cometbft/cometbft/abci/types" - cmtproto "github.com/cometbft/cometbft/proto/tendermint/types" + cmtproto "github.com/cometbft/cometbft/api/cometbft/types/v3" "github.com/cosmos/gogoproto/grpc" - brs "github.com/cometbft/cometbft/proto/tendermint/services/block_results/v1" + brs "github.com/cometbft/cometbft/api/cometbft/services/block_results/v1" ) type BlockResults struct { diff --git a/rpc/grpc/client/block_service.go b/rpc/grpc/client/block_service.go index 271c1cbac6d..1190e272a7a 100644 --- a/rpc/grpc/client/block_service.go +++ b/rpc/grpc/client/block_service.go @@ -4,8 +4,9 @@ import ( "context" "fmt" - blocksvc "github.com/cometbft/cometbft/proto/tendermint/services/block/v1" - cmtproto "github.com/cometbft/cometbft/proto/tendermint/types" + blocksvc "github.com/cometbft/cometbft/api/cometbft/services/block/v1" + cmtproto1 "github.com/cometbft/cometbft/api/cometbft/types/v1" + cmtproto3 "github.com/cometbft/cometbft/api/cometbft/types/v3" "github.com/cometbft/cometbft/types" "github.com/cosmos/gogoproto/grpc" ) @@ -16,7 +17,7 @@ type Block struct { Block *types.Block `json:"block"` } -func blockFromProto(pblockID *cmtproto.BlockID, pblock *cmtproto.Block) (*Block, error) { +func blockFromProto(pblockID *cmtproto1.BlockID, pblock *cmtproto3.Block) (*Block, error) { blockID, err := types.BlockIDFromProto(pblockID) if err != nil { return nil, err diff --git a/rpc/grpc/client/privileged/pruning_service.go b/rpc/grpc/client/privileged/pruning_service.go index e63c97f45da..dfdc933f91d 100644 --- a/rpc/grpc/client/privileged/pruning_service.go +++ b/rpc/grpc/client/privileged/pruning_service.go @@ -5,7 +5,7 @@ import ( "github.com/cosmos/gogoproto/grpc" - v1 "github.com/cometbft/cometbft/proto/tendermint/services/pruning/v1" + v1 "github.com/cometbft/cometbft/api/cometbft/services/pruning/v1" ) // RetainHeights provides information on which block height limits have been diff --git a/rpc/grpc/client/version_service.go b/rpc/grpc/client/version_service.go index c11fd109b36..380eb3d8b3a 100644 --- a/rpc/grpc/client/version_service.go +++ b/rpc/grpc/client/version_service.go @@ -5,7 +5,7 @@ import ( "github.com/cosmos/gogoproto/grpc" - v1 "github.com/cometbft/cometbft/proto/tendermint/services/version/v1" + v1 "github.com/cometbft/cometbft/api/cometbft/services/version/v1" ) // Version provides version information about a particular CometBFT node. diff --git a/rpc/grpc/server/privileged/privileged.go b/rpc/grpc/server/privileged/privileged.go index 0a3d2d54c98..846ba603dd3 100644 --- a/rpc/grpc/server/privileged/privileged.go +++ b/rpc/grpc/server/privileged/privileged.go @@ -6,8 +6,8 @@ import ( "google.golang.org/grpc" + pbpruningsvc "github.com/cometbft/cometbft/api/cometbft/services/pruning/v1" "github.com/cometbft/cometbft/libs/log" - pbpruningsvc "github.com/cometbft/cometbft/proto/tendermint/services/pruning/v1" "github.com/cometbft/cometbft/rpc/grpc/server/services/pruningservice" sm "github.com/cometbft/cometbft/state" ) diff --git a/rpc/grpc/server/server.go b/rpc/grpc/server/server.go index 217e37d480b..4a81529524a 100644 --- a/rpc/grpc/server/server.go +++ b/rpc/grpc/server/server.go @@ -8,14 +8,14 @@ import ( sm "github.com/cometbft/cometbft/state" "github.com/cometbft/cometbft/store" - brs "github.com/cometbft/cometbft/proto/tendermint/services/block_results/v1" + brs "github.com/cometbft/cometbft/api/cometbft/services/block_results/v1" "github.com/cometbft/cometbft/rpc/grpc/server/services/blockresultservice" "google.golang.org/grpc" + pbblocksvc "github.com/cometbft/cometbft/api/cometbft/services/block/v1" + pbversionsvc "github.com/cometbft/cometbft/api/cometbft/services/version/v1" "github.com/cometbft/cometbft/libs/log" - pbblocksvc "github.com/cometbft/cometbft/proto/tendermint/services/block/v1" - pbversionsvc "github.com/cometbft/cometbft/proto/tendermint/services/version/v1" "github.com/cometbft/cometbft/rpc/grpc/server/services/blockservice" "github.com/cometbft/cometbft/rpc/grpc/server/services/versionservice" "github.com/cometbft/cometbft/types" diff --git a/rpc/grpc/server/services/blockresultservice/service.go b/rpc/grpc/server/services/blockresultservice/service.go index ab67b061d71..e9e1a6edce8 100644 --- a/rpc/grpc/server/services/blockresultservice/service.go +++ b/rpc/grpc/server/services/blockresultservice/service.go @@ -10,7 +10,7 @@ import ( sm "github.com/cometbft/cometbft/state" "github.com/cometbft/cometbft/store" - brs "github.com/cometbft/cometbft/proto/tendermint/services/block_results/v1" + brs "github.com/cometbft/cometbft/api/cometbft/services/block_results/v1" ) type blockResultsService struct { diff --git a/rpc/grpc/server/services/blockservice/service.go b/rpc/grpc/server/services/blockservice/service.go index cbf66f57658..a7c41d3b125 100644 --- a/rpc/grpc/server/services/blockservice/service.go +++ b/rpc/grpc/server/services/blockservice/service.go @@ -4,11 +4,12 @@ import ( context "context" "fmt" + blocksvc "github.com/cometbft/cometbft/api/cometbft/services/block/v1" + ptypes1 "github.com/cometbft/cometbft/api/cometbft/types/v1" + ptypes3 "github.com/cometbft/cometbft/api/cometbft/types/v3" "github.com/cometbft/cometbft/internal/rpctrace" "github.com/cometbft/cometbft/libs/log" cmtpubsub "github.com/cometbft/cometbft/libs/pubsub" - blocksvc "github.com/cometbft/cometbft/proto/tendermint/services/block/v1" - ptypes "github.com/cometbft/cometbft/proto/tendermint/types" "github.com/cometbft/cometbft/store" "github.com/cometbft/cometbft/types" "google.golang.org/grpc/codes" @@ -68,7 +69,7 @@ func (s *blockServiceServer) GetLatest(context.Context, *blocksvc.GetLatestReque }, nil } -func (s *blockServiceServer) getBlock(height int64, logger log.Logger) (*ptypes.BlockID, *ptypes.Block, error) { +func (s *blockServiceServer) getBlock(height int64, logger log.Logger) (*ptypes1.BlockID, *ptypes3.Block, error) { traceID, err := rpctrace.New() if err != nil { logger.Error("Error generating RPC trace ID", "err", err) diff --git a/rpc/grpc/server/services/pruningservice/service.go b/rpc/grpc/server/services/pruningservice/service.go index 06daf3d7728..d47c92c9805 100644 --- a/rpc/grpc/server/services/pruningservice/service.go +++ b/rpc/grpc/server/services/pruningservice/service.go @@ -8,9 +8,9 @@ import ( "google.golang.org/grpc/codes" "google.golang.org/grpc/status" + v1 "github.com/cometbft/cometbft/api/cometbft/services/pruning/v1" "github.com/cometbft/cometbft/internal/rpctrace" "github.com/cometbft/cometbft/libs/log" - v1 "github.com/cometbft/cometbft/proto/tendermint/services/pruning/v1" sm "github.com/cometbft/cometbft/state" ) diff --git a/rpc/grpc/server/services/versionservice/service.go b/rpc/grpc/server/services/versionservice/service.go index 028d2711fcb..18b7c6b2f98 100644 --- a/rpc/grpc/server/services/versionservice/service.go +++ b/rpc/grpc/server/services/versionservice/service.go @@ -3,7 +3,7 @@ package versionservice import ( context "context" - v1 "github.com/cometbft/cometbft/proto/tendermint/services/version/v1" + v1 "github.com/cometbft/cometbft/api/cometbft/services/version/v1" "github.com/cometbft/cometbft/version" ) diff --git a/state/mocks/store.go b/state/mocks/store.go index 7d94c70a72f..8c5f6eb617f 100644 --- a/state/mocks/store.go +++ b/state/mocks/store.go @@ -3,12 +3,12 @@ package mocks import ( - abcitypes "github.com/cometbft/cometbft/abci/types" - mock "github.com/stretchr/testify/mock" - state "github.com/cometbft/cometbft/state" + mock "github.com/stretchr/testify/mock" types "github.com/cometbft/cometbft/types" + + v3 "github.com/cometbft/cometbft/api/cometbft/abci/v3" ) // Store is an autogenerated mock type for the Store type @@ -189,19 +189,19 @@ func (_m *Store) LoadConsensusParams(height int64) (types.ConsensusParams, error } // LoadFinalizeBlockResponse provides a mock function with given fields: height -func (_m *Store) LoadFinalizeBlockResponse(height int64) (*abcitypes.ResponseFinalizeBlock, error) { +func (_m *Store) LoadFinalizeBlockResponse(height int64) (*v3.ResponseFinalizeBlock, error) { ret := _m.Called(height) - var r0 *abcitypes.ResponseFinalizeBlock + var r0 *v3.ResponseFinalizeBlock var r1 error - if rf, ok := ret.Get(0).(func(int64) (*abcitypes.ResponseFinalizeBlock, error)); ok { + if rf, ok := ret.Get(0).(func(int64) (*v3.ResponseFinalizeBlock, error)); ok { return rf(height) } - if rf, ok := ret.Get(0).(func(int64) *abcitypes.ResponseFinalizeBlock); ok { + if rf, ok := ret.Get(0).(func(int64) *v3.ResponseFinalizeBlock); ok { r0 = rf(height) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*abcitypes.ResponseFinalizeBlock) + r0 = ret.Get(0).(*v3.ResponseFinalizeBlock) } } @@ -263,19 +263,19 @@ func (_m *Store) LoadFromDBOrGenesisFile(_a0 string) (state.State, error) { } // LoadLastFinalizeBlockResponse provides a mock function with given fields: height -func (_m *Store) LoadLastFinalizeBlockResponse(height int64) (*abcitypes.ResponseFinalizeBlock, error) { +func (_m *Store) LoadLastFinalizeBlockResponse(height int64) (*v3.ResponseFinalizeBlock, error) { ret := _m.Called(height) - var r0 *abcitypes.ResponseFinalizeBlock + var r0 *v3.ResponseFinalizeBlock var r1 error - if rf, ok := ret.Get(0).(func(int64) (*abcitypes.ResponseFinalizeBlock, error)); ok { + if rf, ok := ret.Get(0).(func(int64) (*v3.ResponseFinalizeBlock, error)); ok { return rf(height) } - if rf, ok := ret.Get(0).(func(int64) *abcitypes.ResponseFinalizeBlock); ok { + if rf, ok := ret.Get(0).(func(int64) *v3.ResponseFinalizeBlock); ok { r0 = rf(height) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*abcitypes.ResponseFinalizeBlock) + r0 = ret.Get(0).(*v3.ResponseFinalizeBlock) } } @@ -416,11 +416,11 @@ func (_m *Store) SaveCompanionBlockRetainHeight(height int64) error { } // SaveFinalizeBlockResponse provides a mock function with given fields: height, res -func (_m *Store) SaveFinalizeBlockResponse(height int64, res *abcitypes.ResponseFinalizeBlock) error { +func (_m *Store) SaveFinalizeBlockResponse(height int64, res *v3.ResponseFinalizeBlock) error { ret := _m.Called(height, res) var r0 error - if rf, ok := ret.Get(0).(func(int64, *abcitypes.ResponseFinalizeBlock) error); ok { + if rf, ok := ret.Get(0).(func(int64, *v3.ResponseFinalizeBlock) error); ok { r0 = rf(height, res) } else { r0 = ret.Error(0) diff --git a/state/txindex/mocks/tx_indexer.go b/state/txindex/mocks/tx_indexer.go index 5ba235e59aa..7e2a92a9664 100644 --- a/state/txindex/mocks/tx_indexer.go +++ b/state/txindex/mocks/tx_indexer.go @@ -12,7 +12,7 @@ import ( txindex "github.com/cometbft/cometbft/state/txindex" - types "github.com/cometbft/cometbft/abci/types" + v3 "github.com/cometbft/cometbft/api/cometbft/abci/v3" ) // TxIndexer is an autogenerated mock type for the TxIndexer type @@ -35,19 +35,19 @@ func (_m *TxIndexer) AddBatch(b *txindex.Batch) error { } // Get provides a mock function with given fields: hash -func (_m *TxIndexer) Get(hash []byte) (*types.TxResult, error) { +func (_m *TxIndexer) Get(hash []byte) (*v3.TxResult, error) { ret := _m.Called(hash) - var r0 *types.TxResult + var r0 *v3.TxResult var r1 error - if rf, ok := ret.Get(0).(func([]byte) (*types.TxResult, error)); ok { + if rf, ok := ret.Get(0).(func([]byte) (*v3.TxResult, error)); ok { return rf(hash) } - if rf, ok := ret.Get(0).(func([]byte) *types.TxResult); ok { + if rf, ok := ret.Get(0).(func([]byte) *v3.TxResult); ok { r0 = rf(hash) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).(*types.TxResult) + r0 = ret.Get(0).(*v3.TxResult) } } @@ -85,11 +85,11 @@ func (_m *TxIndexer) GetRetainHeight() (int64, error) { } // Index provides a mock function with given fields: result -func (_m *TxIndexer) Index(result *types.TxResult) error { +func (_m *TxIndexer) Index(result *v3.TxResult) error { ret := _m.Called(result) var r0 error - if rf, ok := ret.Get(0).(func(*types.TxResult) error); ok { + if rf, ok := ret.Get(0).(func(*v3.TxResult) error); ok { r0 = rf(result) } else { r0 = ret.Error(0) @@ -130,19 +130,19 @@ func (_m *TxIndexer) Prune(retainHeight int64) (int64, int64, error) { } // Search provides a mock function with given fields: ctx, q -func (_m *TxIndexer) Search(ctx context.Context, q *query.Query) ([]*types.TxResult, error) { +func (_m *TxIndexer) Search(ctx context.Context, q *query.Query) ([]*v3.TxResult, error) { ret := _m.Called(ctx, q) - var r0 []*types.TxResult + var r0 []*v3.TxResult var r1 error - if rf, ok := ret.Get(0).(func(context.Context, *query.Query) ([]*types.TxResult, error)); ok { + if rf, ok := ret.Get(0).(func(context.Context, *query.Query) ([]*v3.TxResult, error)); ok { return rf(ctx, q) } - if rf, ok := ret.Get(0).(func(context.Context, *query.Query) []*types.TxResult); ok { + if rf, ok := ret.Get(0).(func(context.Context, *query.Query) []*v3.TxResult); ok { r0 = rf(ctx, q) } else { if ret.Get(0) != nil { - r0 = ret.Get(0).([]*types.TxResult) + r0 = ret.Get(0).([]*v3.TxResult) } }