You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

14560 lines
346 KiB

7 years ago
7 years ago
7 years ago
7 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
7 years ago
7 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
7 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
8 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
add support for block pruning via ABCI Commit response (#4588) * Added BlockStore.DeleteBlock() * Added initial block pruner prototype * wip * Added BlockStore.PruneBlocks() * Added consensus setting for block pruning * Added BlockStore base * Error on replay if base does not have blocks * Handle missing blocks when sending VoteSetMaj23Message * Error message tweak * Properly update blockstore state * Error message fix again * blockchain: ignore peer missing blocks * Added FIXME * Added test for block replay with truncated history * Handle peer base in blockchain reactor * Improved replay error handling * Added tests for Store.PruneBlocks() * Fix non-RPC handling of truncated block history * Panic on missing block meta in needProofBlock() * Updated changelog * Handle truncated block history in RPC layer * Added info about earliest block in /status RPC * Reorder height and base in blockchain reactor messages * Updated changelog * Fix tests * Appease linter * Minor review fixes * Non-empty BlockStores should always have base > 0 * Update code to assume base > 0 invariant * Added blockstore tests for pruning to 0 * Make sure we don't prune below the current base * Added BlockStore.Size() * config: added retain_blocks recommendations * Update v1 blockchain reactor to handle blockstore base * Added state database pruning * Propagate errors on missing validator sets * Comment tweaks * Improved error message Co-Authored-By: Anton Kaliaev <anton.kalyaev@gmail.com> * use ABCI field ResponseCommit.retain_height instead of retain-blocks config option * remove State.RetainHeight, return value instead * fix minor issues * rename pruneHeights() to pruneBlocks() * noop to fix GitHub borkage Co-authored-by: Anton Kaliaev <anton.kalyaev@gmail.com>
5 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
abci: Refactor tagging events using list of lists (#3643) ## PR This PR introduces a fundamental breaking change to the structure of ABCI response and tx tags and the way they're processed. Namely, the SDK can support more complex and aggregated events for distribution and slashing. In addition, block responses can include duplicate keys in events. Implement new Event type. An event has a type and a list of KV pairs (ie. list-of-lists). Typical events may look like: "rewards": [{"amount": "5000uatom", "validator": "...", "recipient": "..."}] "sender": [{"address": "...", "balance": "100uatom"}] The events are indexed by {even.type}.{even.attribute[i].key}/.... In this case a client would subscribe or query for rewards.recipient='...' ABCI response types and related types now include Events []Event instead of Tags []cmn.KVPair. PubSub logic now publishes/matches against map[string][]string instead of map[string]string to support duplicate keys in response events (from #1385). A match is successful if the value is found in the slice of strings. closes: #1859 closes: #2905 ## Commits: * Implement Event ABCI type and updates responses to use events * Update messages_test.go * Update kvstore.go * Update event_bus.go * Update subscription.go * Update pubsub.go * Update kvstore.go * Update query logic to handle slice of strings in events * Update Empty#Matches and unit tests * Update pubsub logic * Update EventBus#Publish * Update kv tx indexer * Update godocs * Update ResultEvent to use slice of strings; update RPC * Update more tests * Update abci.md * Check for key in validateAndStringifyEvents * Fix KV indexer to skip empty keys * Fix linting errors * Update CHANGELOG_PENDING.md * Update docs/spec/abci/abci.md Co-Authored-By: Federico Kunze <31522760+fedekunze@users.noreply.github.com> * Update abci/types/types.proto Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update docs/spec/abci/abci.md Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update libs/pubsub/query/query.go Co-Authored-By: Ethan Buchman <ethan@coinculture.info> * Update match function to match if ANY value matches * Implement TestSubscribeDuplicateKeys * Update TestMatches to include multi-key test cases * Update events.go * Update Query interface godoc * Update match godoc * Add godoc for matchValue * DRY-up tx indexing * Return error from PublishWithEvents in EventBus#Publish * Update PublishEventNewBlockHeader to return an error * Fix build * Update events doc in ABCI * Update ABCI events godoc * Implement TestEventBusPublishEventTxDuplicateKeys * Update TestSubscribeDuplicateKeys to be table-driven * Remove mod file * Remove markdown from events godoc * Implement TestTxSearchDeprecatedIndexing test
6 years ago
  1. // Code generated by protoc-gen-gogo. DO NOT EDIT.
  2. // source: tendermint/abci/types.proto
  3. package types
  4. import (
  5. context "context"
  6. fmt "fmt"
  7. _ "github.com/gogo/protobuf/gogoproto"
  8. proto "github.com/gogo/protobuf/proto"
  9. _ "github.com/gogo/protobuf/types"
  10. github_com_gogo_protobuf_types "github.com/gogo/protobuf/types"
  11. crypto "github.com/tendermint/tendermint/proto/tendermint/crypto"
  12. types1 "github.com/tendermint/tendermint/proto/tendermint/types"
  13. grpc "google.golang.org/grpc"
  14. codes "google.golang.org/grpc/codes"
  15. status "google.golang.org/grpc/status"
  16. io "io"
  17. math "math"
  18. math_bits "math/bits"
  19. time "time"
  20. )
  21. // Reference imports to suppress errors if they are not otherwise used.
  22. var _ = proto.Marshal
  23. var _ = fmt.Errorf
  24. var _ = math.Inf
  25. var _ = time.Kitchen
  26. // This is a compile-time assertion to ensure that this generated file
  27. // is compatible with the proto package it is being compiled against.
  28. // A compilation error at this line likely means your copy of the
  29. // proto package needs to be updated.
  30. const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package
  31. type CheckTxType int32
  32. const (
  33. CheckTxType_New CheckTxType = 0
  34. CheckTxType_Recheck CheckTxType = 1
  35. )
  36. var CheckTxType_name = map[int32]string{
  37. 0: "NEW",
  38. 1: "RECHECK",
  39. }
  40. var CheckTxType_value = map[string]int32{
  41. "NEW": 0,
  42. "RECHECK": 1,
  43. }
  44. func (x CheckTxType) String() string {
  45. return proto.EnumName(CheckTxType_name, int32(x))
  46. }
  47. func (CheckTxType) EnumDescriptor() ([]byte, []int) {
  48. return fileDescriptor_252557cfdd89a31a, []int{0}
  49. }
  50. type EvidenceType int32
  51. const (
  52. EvidenceType_UNKNOWN EvidenceType = 0
  53. EvidenceType_DUPLICATE_VOTE EvidenceType = 1
  54. EvidenceType_LIGHT_CLIENT_ATTACK EvidenceType = 2
  55. )
  56. var EvidenceType_name = map[int32]string{
  57. 0: "UNKNOWN",
  58. 1: "DUPLICATE_VOTE",
  59. 2: "LIGHT_CLIENT_ATTACK",
  60. }
  61. var EvidenceType_value = map[string]int32{
  62. "UNKNOWN": 0,
  63. "DUPLICATE_VOTE": 1,
  64. "LIGHT_CLIENT_ATTACK": 2,
  65. }
  66. func (x EvidenceType) String() string {
  67. return proto.EnumName(EvidenceType_name, int32(x))
  68. }
  69. func (EvidenceType) EnumDescriptor() ([]byte, []int) {
  70. return fileDescriptor_252557cfdd89a31a, []int{1}
  71. }
  72. type ResponseOfferSnapshot_Result int32
  73. const (
  74. ResponseOfferSnapshot_UNKNOWN ResponseOfferSnapshot_Result = 0
  75. ResponseOfferSnapshot_ACCEPT ResponseOfferSnapshot_Result = 1
  76. ResponseOfferSnapshot_ABORT ResponseOfferSnapshot_Result = 2
  77. ResponseOfferSnapshot_REJECT ResponseOfferSnapshot_Result = 3
  78. ResponseOfferSnapshot_REJECT_FORMAT ResponseOfferSnapshot_Result = 4
  79. ResponseOfferSnapshot_REJECT_SENDER ResponseOfferSnapshot_Result = 5
  80. )
  81. var ResponseOfferSnapshot_Result_name = map[int32]string{
  82. 0: "UNKNOWN",
  83. 1: "ACCEPT",
  84. 2: "ABORT",
  85. 3: "REJECT",
  86. 4: "REJECT_FORMAT",
  87. 5: "REJECT_SENDER",
  88. }
  89. var ResponseOfferSnapshot_Result_value = map[string]int32{
  90. "UNKNOWN": 0,
  91. "ACCEPT": 1,
  92. "ABORT": 2,
  93. "REJECT": 3,
  94. "REJECT_FORMAT": 4,
  95. "REJECT_SENDER": 5,
  96. }
  97. func (x ResponseOfferSnapshot_Result) String() string {
  98. return proto.EnumName(ResponseOfferSnapshot_Result_name, int32(x))
  99. }
  100. func (ResponseOfferSnapshot_Result) EnumDescriptor() ([]byte, []int) {
  101. return fileDescriptor_252557cfdd89a31a, []int{30, 0}
  102. }
  103. type ResponseApplySnapshotChunk_Result int32
  104. const (
  105. ResponseApplySnapshotChunk_UNKNOWN ResponseApplySnapshotChunk_Result = 0
  106. ResponseApplySnapshotChunk_ACCEPT ResponseApplySnapshotChunk_Result = 1
  107. ResponseApplySnapshotChunk_ABORT ResponseApplySnapshotChunk_Result = 2
  108. ResponseApplySnapshotChunk_RETRY ResponseApplySnapshotChunk_Result = 3
  109. ResponseApplySnapshotChunk_RETRY_SNAPSHOT ResponseApplySnapshotChunk_Result = 4
  110. ResponseApplySnapshotChunk_REJECT_SNAPSHOT ResponseApplySnapshotChunk_Result = 5
  111. )
  112. var ResponseApplySnapshotChunk_Result_name = map[int32]string{
  113. 0: "UNKNOWN",
  114. 1: "ACCEPT",
  115. 2: "ABORT",
  116. 3: "RETRY",
  117. 4: "RETRY_SNAPSHOT",
  118. 5: "REJECT_SNAPSHOT",
  119. }
  120. var ResponseApplySnapshotChunk_Result_value = map[string]int32{
  121. "UNKNOWN": 0,
  122. "ACCEPT": 1,
  123. "ABORT": 2,
  124. "RETRY": 3,
  125. "RETRY_SNAPSHOT": 4,
  126. "REJECT_SNAPSHOT": 5,
  127. }
  128. func (x ResponseApplySnapshotChunk_Result) String() string {
  129. return proto.EnumName(ResponseApplySnapshotChunk_Result_name, int32(x))
  130. }
  131. func (ResponseApplySnapshotChunk_Result) EnumDescriptor() ([]byte, []int) {
  132. return fileDescriptor_252557cfdd89a31a, []int{32, 0}
  133. }
  134. type Request struct {
  135. // Types that are valid to be assigned to Value:
  136. // *Request_Echo
  137. // *Request_Flush
  138. // *Request_Info
  139. // *Request_SetOption
  140. // *Request_InitChain
  141. // *Request_Query
  142. // *Request_BeginBlock
  143. // *Request_CheckTx
  144. // *Request_DeliverTx
  145. // *Request_EndBlock
  146. // *Request_Commit
  147. // *Request_ListSnapshots
  148. // *Request_OfferSnapshot
  149. // *Request_LoadSnapshotChunk
  150. // *Request_ApplySnapshotChunk
  151. Value isRequest_Value `protobuf_oneof:"value"`
  152. }
  153. func (m *Request) Reset() { *m = Request{} }
  154. func (m *Request) String() string { return proto.CompactTextString(m) }
  155. func (*Request) ProtoMessage() {}
  156. func (*Request) Descriptor() ([]byte, []int) {
  157. return fileDescriptor_252557cfdd89a31a, []int{0}
  158. }
  159. func (m *Request) XXX_Unmarshal(b []byte) error {
  160. return m.Unmarshal(b)
  161. }
  162. func (m *Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  163. if deterministic {
  164. return xxx_messageInfo_Request.Marshal(b, m, deterministic)
  165. } else {
  166. b = b[:cap(b)]
  167. n, err := m.MarshalToSizedBuffer(b)
  168. if err != nil {
  169. return nil, err
  170. }
  171. return b[:n], nil
  172. }
  173. }
  174. func (m *Request) XXX_Merge(src proto.Message) {
  175. xxx_messageInfo_Request.Merge(m, src)
  176. }
  177. func (m *Request) XXX_Size() int {
  178. return m.Size()
  179. }
  180. func (m *Request) XXX_DiscardUnknown() {
  181. xxx_messageInfo_Request.DiscardUnknown(m)
  182. }
  183. var xxx_messageInfo_Request proto.InternalMessageInfo
  184. type isRequest_Value interface {
  185. isRequest_Value()
  186. MarshalTo([]byte) (int, error)
  187. Size() int
  188. }
  189. type Request_Echo struct {
  190. Echo *RequestEcho `protobuf:"bytes,1,opt,name=echo,proto3,oneof" json:"echo,omitempty"`
  191. }
  192. type Request_Flush struct {
  193. Flush *RequestFlush `protobuf:"bytes,2,opt,name=flush,proto3,oneof" json:"flush,omitempty"`
  194. }
  195. type Request_Info struct {
  196. Info *RequestInfo `protobuf:"bytes,3,opt,name=info,proto3,oneof" json:"info,omitempty"`
  197. }
  198. type Request_SetOption struct {
  199. SetOption *RequestSetOption `protobuf:"bytes,4,opt,name=set_option,json=setOption,proto3,oneof" json:"set_option,omitempty"`
  200. }
  201. type Request_InitChain struct {
  202. InitChain *RequestInitChain `protobuf:"bytes,5,opt,name=init_chain,json=initChain,proto3,oneof" json:"init_chain,omitempty"`
  203. }
  204. type Request_Query struct {
  205. Query *RequestQuery `protobuf:"bytes,6,opt,name=query,proto3,oneof" json:"query,omitempty"`
  206. }
  207. type Request_BeginBlock struct {
  208. BeginBlock *RequestBeginBlock `protobuf:"bytes,7,opt,name=begin_block,json=beginBlock,proto3,oneof" json:"begin_block,omitempty"`
  209. }
  210. type Request_CheckTx struct {
  211. CheckTx *RequestCheckTx `protobuf:"bytes,8,opt,name=check_tx,json=checkTx,proto3,oneof" json:"check_tx,omitempty"`
  212. }
  213. type Request_DeliverTx struct {
  214. DeliverTx *RequestDeliverTx `protobuf:"bytes,9,opt,name=deliver_tx,json=deliverTx,proto3,oneof" json:"deliver_tx,omitempty"`
  215. }
  216. type Request_EndBlock struct {
  217. EndBlock *RequestEndBlock `protobuf:"bytes,10,opt,name=end_block,json=endBlock,proto3,oneof" json:"end_block,omitempty"`
  218. }
  219. type Request_Commit struct {
  220. Commit *RequestCommit `protobuf:"bytes,11,opt,name=commit,proto3,oneof" json:"commit,omitempty"`
  221. }
  222. type Request_ListSnapshots struct {
  223. ListSnapshots *RequestListSnapshots `protobuf:"bytes,12,opt,name=list_snapshots,json=listSnapshots,proto3,oneof" json:"list_snapshots,omitempty"`
  224. }
  225. type Request_OfferSnapshot struct {
  226. OfferSnapshot *RequestOfferSnapshot `protobuf:"bytes,13,opt,name=offer_snapshot,json=offerSnapshot,proto3,oneof" json:"offer_snapshot,omitempty"`
  227. }
  228. type Request_LoadSnapshotChunk struct {
  229. LoadSnapshotChunk *RequestLoadSnapshotChunk `protobuf:"bytes,14,opt,name=load_snapshot_chunk,json=loadSnapshotChunk,proto3,oneof" json:"load_snapshot_chunk,omitempty"`
  230. }
  231. type Request_ApplySnapshotChunk struct {
  232. ApplySnapshotChunk *RequestApplySnapshotChunk `protobuf:"bytes,15,opt,name=apply_snapshot_chunk,json=applySnapshotChunk,proto3,oneof" json:"apply_snapshot_chunk,omitempty"`
  233. }
  234. func (*Request_Echo) isRequest_Value() {}
  235. func (*Request_Flush) isRequest_Value() {}
  236. func (*Request_Info) isRequest_Value() {}
  237. func (*Request_SetOption) isRequest_Value() {}
  238. func (*Request_InitChain) isRequest_Value() {}
  239. func (*Request_Query) isRequest_Value() {}
  240. func (*Request_BeginBlock) isRequest_Value() {}
  241. func (*Request_CheckTx) isRequest_Value() {}
  242. func (*Request_DeliverTx) isRequest_Value() {}
  243. func (*Request_EndBlock) isRequest_Value() {}
  244. func (*Request_Commit) isRequest_Value() {}
  245. func (*Request_ListSnapshots) isRequest_Value() {}
  246. func (*Request_OfferSnapshot) isRequest_Value() {}
  247. func (*Request_LoadSnapshotChunk) isRequest_Value() {}
  248. func (*Request_ApplySnapshotChunk) isRequest_Value() {}
  249. func (m *Request) GetValue() isRequest_Value {
  250. if m != nil {
  251. return m.Value
  252. }
  253. return nil
  254. }
  255. func (m *Request) GetEcho() *RequestEcho {
  256. if x, ok := m.GetValue().(*Request_Echo); ok {
  257. return x.Echo
  258. }
  259. return nil
  260. }
  261. func (m *Request) GetFlush() *RequestFlush {
  262. if x, ok := m.GetValue().(*Request_Flush); ok {
  263. return x.Flush
  264. }
  265. return nil
  266. }
  267. func (m *Request) GetInfo() *RequestInfo {
  268. if x, ok := m.GetValue().(*Request_Info); ok {
  269. return x.Info
  270. }
  271. return nil
  272. }
  273. func (m *Request) GetSetOption() *RequestSetOption {
  274. if x, ok := m.GetValue().(*Request_SetOption); ok {
  275. return x.SetOption
  276. }
  277. return nil
  278. }
  279. func (m *Request) GetInitChain() *RequestInitChain {
  280. if x, ok := m.GetValue().(*Request_InitChain); ok {
  281. return x.InitChain
  282. }
  283. return nil
  284. }
  285. func (m *Request) GetQuery() *RequestQuery {
  286. if x, ok := m.GetValue().(*Request_Query); ok {
  287. return x.Query
  288. }
  289. return nil
  290. }
  291. func (m *Request) GetBeginBlock() *RequestBeginBlock {
  292. if x, ok := m.GetValue().(*Request_BeginBlock); ok {
  293. return x.BeginBlock
  294. }
  295. return nil
  296. }
  297. func (m *Request) GetCheckTx() *RequestCheckTx {
  298. if x, ok := m.GetValue().(*Request_CheckTx); ok {
  299. return x.CheckTx
  300. }
  301. return nil
  302. }
  303. func (m *Request) GetDeliverTx() *RequestDeliverTx {
  304. if x, ok := m.GetValue().(*Request_DeliverTx); ok {
  305. return x.DeliverTx
  306. }
  307. return nil
  308. }
  309. func (m *Request) GetEndBlock() *RequestEndBlock {
  310. if x, ok := m.GetValue().(*Request_EndBlock); ok {
  311. return x.EndBlock
  312. }
  313. return nil
  314. }
  315. func (m *Request) GetCommit() *RequestCommit {
  316. if x, ok := m.GetValue().(*Request_Commit); ok {
  317. return x.Commit
  318. }
  319. return nil
  320. }
  321. func (m *Request) GetListSnapshots() *RequestListSnapshots {
  322. if x, ok := m.GetValue().(*Request_ListSnapshots); ok {
  323. return x.ListSnapshots
  324. }
  325. return nil
  326. }
  327. func (m *Request) GetOfferSnapshot() *RequestOfferSnapshot {
  328. if x, ok := m.GetValue().(*Request_OfferSnapshot); ok {
  329. return x.OfferSnapshot
  330. }
  331. return nil
  332. }
  333. func (m *Request) GetLoadSnapshotChunk() *RequestLoadSnapshotChunk {
  334. if x, ok := m.GetValue().(*Request_LoadSnapshotChunk); ok {
  335. return x.LoadSnapshotChunk
  336. }
  337. return nil
  338. }
  339. func (m *Request) GetApplySnapshotChunk() *RequestApplySnapshotChunk {
  340. if x, ok := m.GetValue().(*Request_ApplySnapshotChunk); ok {
  341. return x.ApplySnapshotChunk
  342. }
  343. return nil
  344. }
  345. // XXX_OneofWrappers is for the internal use of the proto package.
  346. func (*Request) XXX_OneofWrappers() []interface{} {
  347. return []interface{}{
  348. (*Request_Echo)(nil),
  349. (*Request_Flush)(nil),
  350. (*Request_Info)(nil),
  351. (*Request_SetOption)(nil),
  352. (*Request_InitChain)(nil),
  353. (*Request_Query)(nil),
  354. (*Request_BeginBlock)(nil),
  355. (*Request_CheckTx)(nil),
  356. (*Request_DeliverTx)(nil),
  357. (*Request_EndBlock)(nil),
  358. (*Request_Commit)(nil),
  359. (*Request_ListSnapshots)(nil),
  360. (*Request_OfferSnapshot)(nil),
  361. (*Request_LoadSnapshotChunk)(nil),
  362. (*Request_ApplySnapshotChunk)(nil),
  363. }
  364. }
  365. type RequestEcho struct {
  366. Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
  367. }
  368. func (m *RequestEcho) Reset() { *m = RequestEcho{} }
  369. func (m *RequestEcho) String() string { return proto.CompactTextString(m) }
  370. func (*RequestEcho) ProtoMessage() {}
  371. func (*RequestEcho) Descriptor() ([]byte, []int) {
  372. return fileDescriptor_252557cfdd89a31a, []int{1}
  373. }
  374. func (m *RequestEcho) XXX_Unmarshal(b []byte) error {
  375. return m.Unmarshal(b)
  376. }
  377. func (m *RequestEcho) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  378. if deterministic {
  379. return xxx_messageInfo_RequestEcho.Marshal(b, m, deterministic)
  380. } else {
  381. b = b[:cap(b)]
  382. n, err := m.MarshalToSizedBuffer(b)
  383. if err != nil {
  384. return nil, err
  385. }
  386. return b[:n], nil
  387. }
  388. }
  389. func (m *RequestEcho) XXX_Merge(src proto.Message) {
  390. xxx_messageInfo_RequestEcho.Merge(m, src)
  391. }
  392. func (m *RequestEcho) XXX_Size() int {
  393. return m.Size()
  394. }
  395. func (m *RequestEcho) XXX_DiscardUnknown() {
  396. xxx_messageInfo_RequestEcho.DiscardUnknown(m)
  397. }
  398. var xxx_messageInfo_RequestEcho proto.InternalMessageInfo
  399. func (m *RequestEcho) GetMessage() string {
  400. if m != nil {
  401. return m.Message
  402. }
  403. return ""
  404. }
  405. type RequestFlush struct {
  406. }
  407. func (m *RequestFlush) Reset() { *m = RequestFlush{} }
  408. func (m *RequestFlush) String() string { return proto.CompactTextString(m) }
  409. func (*RequestFlush) ProtoMessage() {}
  410. func (*RequestFlush) Descriptor() ([]byte, []int) {
  411. return fileDescriptor_252557cfdd89a31a, []int{2}
  412. }
  413. func (m *RequestFlush) XXX_Unmarshal(b []byte) error {
  414. return m.Unmarshal(b)
  415. }
  416. func (m *RequestFlush) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  417. if deterministic {
  418. return xxx_messageInfo_RequestFlush.Marshal(b, m, deterministic)
  419. } else {
  420. b = b[:cap(b)]
  421. n, err := m.MarshalToSizedBuffer(b)
  422. if err != nil {
  423. return nil, err
  424. }
  425. return b[:n], nil
  426. }
  427. }
  428. func (m *RequestFlush) XXX_Merge(src proto.Message) {
  429. xxx_messageInfo_RequestFlush.Merge(m, src)
  430. }
  431. func (m *RequestFlush) XXX_Size() int {
  432. return m.Size()
  433. }
  434. func (m *RequestFlush) XXX_DiscardUnknown() {
  435. xxx_messageInfo_RequestFlush.DiscardUnknown(m)
  436. }
  437. var xxx_messageInfo_RequestFlush proto.InternalMessageInfo
  438. type RequestInfo struct {
  439. Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"`
  440. BlockVersion uint64 `protobuf:"varint,2,opt,name=block_version,json=blockVersion,proto3" json:"block_version,omitempty"`
  441. P2PVersion uint64 `protobuf:"varint,3,opt,name=p2p_version,json=p2pVersion,proto3" json:"p2p_version,omitempty"`
  442. }
  443. func (m *RequestInfo) Reset() { *m = RequestInfo{} }
  444. func (m *RequestInfo) String() string { return proto.CompactTextString(m) }
  445. func (*RequestInfo) ProtoMessage() {}
  446. func (*RequestInfo) Descriptor() ([]byte, []int) {
  447. return fileDescriptor_252557cfdd89a31a, []int{3}
  448. }
  449. func (m *RequestInfo) XXX_Unmarshal(b []byte) error {
  450. return m.Unmarshal(b)
  451. }
  452. func (m *RequestInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  453. if deterministic {
  454. return xxx_messageInfo_RequestInfo.Marshal(b, m, deterministic)
  455. } else {
  456. b = b[:cap(b)]
  457. n, err := m.MarshalToSizedBuffer(b)
  458. if err != nil {
  459. return nil, err
  460. }
  461. return b[:n], nil
  462. }
  463. }
  464. func (m *RequestInfo) XXX_Merge(src proto.Message) {
  465. xxx_messageInfo_RequestInfo.Merge(m, src)
  466. }
  467. func (m *RequestInfo) XXX_Size() int {
  468. return m.Size()
  469. }
  470. func (m *RequestInfo) XXX_DiscardUnknown() {
  471. xxx_messageInfo_RequestInfo.DiscardUnknown(m)
  472. }
  473. var xxx_messageInfo_RequestInfo proto.InternalMessageInfo
  474. func (m *RequestInfo) GetVersion() string {
  475. if m != nil {
  476. return m.Version
  477. }
  478. return ""
  479. }
  480. func (m *RequestInfo) GetBlockVersion() uint64 {
  481. if m != nil {
  482. return m.BlockVersion
  483. }
  484. return 0
  485. }
  486. func (m *RequestInfo) GetP2PVersion() uint64 {
  487. if m != nil {
  488. return m.P2PVersion
  489. }
  490. return 0
  491. }
  492. // nondeterministic
  493. type RequestSetOption struct {
  494. Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
  495. Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
  496. }
  497. func (m *RequestSetOption) Reset() { *m = RequestSetOption{} }
  498. func (m *RequestSetOption) String() string { return proto.CompactTextString(m) }
  499. func (*RequestSetOption) ProtoMessage() {}
  500. func (*RequestSetOption) Descriptor() ([]byte, []int) {
  501. return fileDescriptor_252557cfdd89a31a, []int{4}
  502. }
  503. func (m *RequestSetOption) XXX_Unmarshal(b []byte) error {
  504. return m.Unmarshal(b)
  505. }
  506. func (m *RequestSetOption) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  507. if deterministic {
  508. return xxx_messageInfo_RequestSetOption.Marshal(b, m, deterministic)
  509. } else {
  510. b = b[:cap(b)]
  511. n, err := m.MarshalToSizedBuffer(b)
  512. if err != nil {
  513. return nil, err
  514. }
  515. return b[:n], nil
  516. }
  517. }
  518. func (m *RequestSetOption) XXX_Merge(src proto.Message) {
  519. xxx_messageInfo_RequestSetOption.Merge(m, src)
  520. }
  521. func (m *RequestSetOption) XXX_Size() int {
  522. return m.Size()
  523. }
  524. func (m *RequestSetOption) XXX_DiscardUnknown() {
  525. xxx_messageInfo_RequestSetOption.DiscardUnknown(m)
  526. }
  527. var xxx_messageInfo_RequestSetOption proto.InternalMessageInfo
  528. func (m *RequestSetOption) GetKey() string {
  529. if m != nil {
  530. return m.Key
  531. }
  532. return ""
  533. }
  534. func (m *RequestSetOption) GetValue() string {
  535. if m != nil {
  536. return m.Value
  537. }
  538. return ""
  539. }
  540. type RequestInitChain struct {
  541. Time time.Time `protobuf:"bytes,1,opt,name=time,proto3,stdtime" json:"time"`
  542. ChainId string `protobuf:"bytes,2,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"`
  543. ConsensusParams *ConsensusParams `protobuf:"bytes,3,opt,name=consensus_params,json=consensusParams,proto3" json:"consensus_params,omitempty"`
  544. Validators []ValidatorUpdate `protobuf:"bytes,4,rep,name=validators,proto3" json:"validators"`
  545. AppStateBytes []byte `protobuf:"bytes,5,opt,name=app_state_bytes,json=appStateBytes,proto3" json:"app_state_bytes,omitempty"`
  546. InitialHeight int64 `protobuf:"varint,6,opt,name=initial_height,json=initialHeight,proto3" json:"initial_height,omitempty"`
  547. }
  548. func (m *RequestInitChain) Reset() { *m = RequestInitChain{} }
  549. func (m *RequestInitChain) String() string { return proto.CompactTextString(m) }
  550. func (*RequestInitChain) ProtoMessage() {}
  551. func (*RequestInitChain) Descriptor() ([]byte, []int) {
  552. return fileDescriptor_252557cfdd89a31a, []int{5}
  553. }
  554. func (m *RequestInitChain) XXX_Unmarshal(b []byte) error {
  555. return m.Unmarshal(b)
  556. }
  557. func (m *RequestInitChain) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  558. if deterministic {
  559. return xxx_messageInfo_RequestInitChain.Marshal(b, m, deterministic)
  560. } else {
  561. b = b[:cap(b)]
  562. n, err := m.MarshalToSizedBuffer(b)
  563. if err != nil {
  564. return nil, err
  565. }
  566. return b[:n], nil
  567. }
  568. }
  569. func (m *RequestInitChain) XXX_Merge(src proto.Message) {
  570. xxx_messageInfo_RequestInitChain.Merge(m, src)
  571. }
  572. func (m *RequestInitChain) XXX_Size() int {
  573. return m.Size()
  574. }
  575. func (m *RequestInitChain) XXX_DiscardUnknown() {
  576. xxx_messageInfo_RequestInitChain.DiscardUnknown(m)
  577. }
  578. var xxx_messageInfo_RequestInitChain proto.InternalMessageInfo
  579. func (m *RequestInitChain) GetTime() time.Time {
  580. if m != nil {
  581. return m.Time
  582. }
  583. return time.Time{}
  584. }
  585. func (m *RequestInitChain) GetChainId() string {
  586. if m != nil {
  587. return m.ChainId
  588. }
  589. return ""
  590. }
  591. func (m *RequestInitChain) GetConsensusParams() *ConsensusParams {
  592. if m != nil {
  593. return m.ConsensusParams
  594. }
  595. return nil
  596. }
  597. func (m *RequestInitChain) GetValidators() []ValidatorUpdate {
  598. if m != nil {
  599. return m.Validators
  600. }
  601. return nil
  602. }
  603. func (m *RequestInitChain) GetAppStateBytes() []byte {
  604. if m != nil {
  605. return m.AppStateBytes
  606. }
  607. return nil
  608. }
  609. func (m *RequestInitChain) GetInitialHeight() int64 {
  610. if m != nil {
  611. return m.InitialHeight
  612. }
  613. return 0
  614. }
  615. type RequestQuery struct {
  616. Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
  617. Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"`
  618. Height int64 `protobuf:"varint,3,opt,name=height,proto3" json:"height,omitempty"`
  619. Prove bool `protobuf:"varint,4,opt,name=prove,proto3" json:"prove,omitempty"`
  620. }
  621. func (m *RequestQuery) Reset() { *m = RequestQuery{} }
  622. func (m *RequestQuery) String() string { return proto.CompactTextString(m) }
  623. func (*RequestQuery) ProtoMessage() {}
  624. func (*RequestQuery) Descriptor() ([]byte, []int) {
  625. return fileDescriptor_252557cfdd89a31a, []int{6}
  626. }
  627. func (m *RequestQuery) XXX_Unmarshal(b []byte) error {
  628. return m.Unmarshal(b)
  629. }
  630. func (m *RequestQuery) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  631. if deterministic {
  632. return xxx_messageInfo_RequestQuery.Marshal(b, m, deterministic)
  633. } else {
  634. b = b[:cap(b)]
  635. n, err := m.MarshalToSizedBuffer(b)
  636. if err != nil {
  637. return nil, err
  638. }
  639. return b[:n], nil
  640. }
  641. }
  642. func (m *RequestQuery) XXX_Merge(src proto.Message) {
  643. xxx_messageInfo_RequestQuery.Merge(m, src)
  644. }
  645. func (m *RequestQuery) XXX_Size() int {
  646. return m.Size()
  647. }
  648. func (m *RequestQuery) XXX_DiscardUnknown() {
  649. xxx_messageInfo_RequestQuery.DiscardUnknown(m)
  650. }
  651. var xxx_messageInfo_RequestQuery proto.InternalMessageInfo
  652. func (m *RequestQuery) GetData() []byte {
  653. if m != nil {
  654. return m.Data
  655. }
  656. return nil
  657. }
  658. func (m *RequestQuery) GetPath() string {
  659. if m != nil {
  660. return m.Path
  661. }
  662. return ""
  663. }
  664. func (m *RequestQuery) GetHeight() int64 {
  665. if m != nil {
  666. return m.Height
  667. }
  668. return 0
  669. }
  670. func (m *RequestQuery) GetProve() bool {
  671. if m != nil {
  672. return m.Prove
  673. }
  674. return false
  675. }
  676. type RequestBeginBlock struct {
  677. Hash []byte `protobuf:"bytes,1,opt,name=hash,proto3" json:"hash,omitempty"`
  678. Header types1.Header `protobuf:"bytes,2,opt,name=header,proto3" json:"header"`
  679. LastCommitInfo LastCommitInfo `protobuf:"bytes,3,opt,name=last_commit_info,json=lastCommitInfo,proto3" json:"last_commit_info"`
  680. ByzantineValidators []Evidence `protobuf:"bytes,4,rep,name=byzantine_validators,json=byzantineValidators,proto3" json:"byzantine_validators"`
  681. }
  682. func (m *RequestBeginBlock) Reset() { *m = RequestBeginBlock{} }
  683. func (m *RequestBeginBlock) String() string { return proto.CompactTextString(m) }
  684. func (*RequestBeginBlock) ProtoMessage() {}
  685. func (*RequestBeginBlock) Descriptor() ([]byte, []int) {
  686. return fileDescriptor_252557cfdd89a31a, []int{7}
  687. }
  688. func (m *RequestBeginBlock) XXX_Unmarshal(b []byte) error {
  689. return m.Unmarshal(b)
  690. }
  691. func (m *RequestBeginBlock) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  692. if deterministic {
  693. return xxx_messageInfo_RequestBeginBlock.Marshal(b, m, deterministic)
  694. } else {
  695. b = b[:cap(b)]
  696. n, err := m.MarshalToSizedBuffer(b)
  697. if err != nil {
  698. return nil, err
  699. }
  700. return b[:n], nil
  701. }
  702. }
  703. func (m *RequestBeginBlock) XXX_Merge(src proto.Message) {
  704. xxx_messageInfo_RequestBeginBlock.Merge(m, src)
  705. }
  706. func (m *RequestBeginBlock) XXX_Size() int {
  707. return m.Size()
  708. }
  709. func (m *RequestBeginBlock) XXX_DiscardUnknown() {
  710. xxx_messageInfo_RequestBeginBlock.DiscardUnknown(m)
  711. }
  712. var xxx_messageInfo_RequestBeginBlock proto.InternalMessageInfo
  713. func (m *RequestBeginBlock) GetHash() []byte {
  714. if m != nil {
  715. return m.Hash
  716. }
  717. return nil
  718. }
  719. func (m *RequestBeginBlock) GetHeader() types1.Header {
  720. if m != nil {
  721. return m.Header
  722. }
  723. return types1.Header{}
  724. }
  725. func (m *RequestBeginBlock) GetLastCommitInfo() LastCommitInfo {
  726. if m != nil {
  727. return m.LastCommitInfo
  728. }
  729. return LastCommitInfo{}
  730. }
  731. func (m *RequestBeginBlock) GetByzantineValidators() []Evidence {
  732. if m != nil {
  733. return m.ByzantineValidators
  734. }
  735. return nil
  736. }
  737. type RequestCheckTx struct {
  738. Tx []byte `protobuf:"bytes,1,opt,name=tx,proto3" json:"tx,omitempty"`
  739. Type CheckTxType `protobuf:"varint,2,opt,name=type,proto3,enum=tendermint.abci.CheckTxType" json:"type,omitempty"`
  740. }
  741. func (m *RequestCheckTx) Reset() { *m = RequestCheckTx{} }
  742. func (m *RequestCheckTx) String() string { return proto.CompactTextString(m) }
  743. func (*RequestCheckTx) ProtoMessage() {}
  744. func (*RequestCheckTx) Descriptor() ([]byte, []int) {
  745. return fileDescriptor_252557cfdd89a31a, []int{8}
  746. }
  747. func (m *RequestCheckTx) XXX_Unmarshal(b []byte) error {
  748. return m.Unmarshal(b)
  749. }
  750. func (m *RequestCheckTx) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  751. if deterministic {
  752. return xxx_messageInfo_RequestCheckTx.Marshal(b, m, deterministic)
  753. } else {
  754. b = b[:cap(b)]
  755. n, err := m.MarshalToSizedBuffer(b)
  756. if err != nil {
  757. return nil, err
  758. }
  759. return b[:n], nil
  760. }
  761. }
  762. func (m *RequestCheckTx) XXX_Merge(src proto.Message) {
  763. xxx_messageInfo_RequestCheckTx.Merge(m, src)
  764. }
  765. func (m *RequestCheckTx) XXX_Size() int {
  766. return m.Size()
  767. }
  768. func (m *RequestCheckTx) XXX_DiscardUnknown() {
  769. xxx_messageInfo_RequestCheckTx.DiscardUnknown(m)
  770. }
  771. var xxx_messageInfo_RequestCheckTx proto.InternalMessageInfo
  772. func (m *RequestCheckTx) GetTx() []byte {
  773. if m != nil {
  774. return m.Tx
  775. }
  776. return nil
  777. }
  778. func (m *RequestCheckTx) GetType() CheckTxType {
  779. if m != nil {
  780. return m.Type
  781. }
  782. return CheckTxType_New
  783. }
  784. type RequestDeliverTx struct {
  785. Tx []byte `protobuf:"bytes,1,opt,name=tx,proto3" json:"tx,omitempty"`
  786. }
  787. func (m *RequestDeliverTx) Reset() { *m = RequestDeliverTx{} }
  788. func (m *RequestDeliverTx) String() string { return proto.CompactTextString(m) }
  789. func (*RequestDeliverTx) ProtoMessage() {}
  790. func (*RequestDeliverTx) Descriptor() ([]byte, []int) {
  791. return fileDescriptor_252557cfdd89a31a, []int{9}
  792. }
  793. func (m *RequestDeliverTx) XXX_Unmarshal(b []byte) error {
  794. return m.Unmarshal(b)
  795. }
  796. func (m *RequestDeliverTx) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  797. if deterministic {
  798. return xxx_messageInfo_RequestDeliverTx.Marshal(b, m, deterministic)
  799. } else {
  800. b = b[:cap(b)]
  801. n, err := m.MarshalToSizedBuffer(b)
  802. if err != nil {
  803. return nil, err
  804. }
  805. return b[:n], nil
  806. }
  807. }
  808. func (m *RequestDeliverTx) XXX_Merge(src proto.Message) {
  809. xxx_messageInfo_RequestDeliverTx.Merge(m, src)
  810. }
  811. func (m *RequestDeliverTx) XXX_Size() int {
  812. return m.Size()
  813. }
  814. func (m *RequestDeliverTx) XXX_DiscardUnknown() {
  815. xxx_messageInfo_RequestDeliverTx.DiscardUnknown(m)
  816. }
  817. var xxx_messageInfo_RequestDeliverTx proto.InternalMessageInfo
  818. func (m *RequestDeliverTx) GetTx() []byte {
  819. if m != nil {
  820. return m.Tx
  821. }
  822. return nil
  823. }
  824. type RequestEndBlock struct {
  825. Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"`
  826. }
  827. func (m *RequestEndBlock) Reset() { *m = RequestEndBlock{} }
  828. func (m *RequestEndBlock) String() string { return proto.CompactTextString(m) }
  829. func (*RequestEndBlock) ProtoMessage() {}
  830. func (*RequestEndBlock) Descriptor() ([]byte, []int) {
  831. return fileDescriptor_252557cfdd89a31a, []int{10}
  832. }
  833. func (m *RequestEndBlock) XXX_Unmarshal(b []byte) error {
  834. return m.Unmarshal(b)
  835. }
  836. func (m *RequestEndBlock) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  837. if deterministic {
  838. return xxx_messageInfo_RequestEndBlock.Marshal(b, m, deterministic)
  839. } else {
  840. b = b[:cap(b)]
  841. n, err := m.MarshalToSizedBuffer(b)
  842. if err != nil {
  843. return nil, err
  844. }
  845. return b[:n], nil
  846. }
  847. }
  848. func (m *RequestEndBlock) XXX_Merge(src proto.Message) {
  849. xxx_messageInfo_RequestEndBlock.Merge(m, src)
  850. }
  851. func (m *RequestEndBlock) XXX_Size() int {
  852. return m.Size()
  853. }
  854. func (m *RequestEndBlock) XXX_DiscardUnknown() {
  855. xxx_messageInfo_RequestEndBlock.DiscardUnknown(m)
  856. }
  857. var xxx_messageInfo_RequestEndBlock proto.InternalMessageInfo
  858. func (m *RequestEndBlock) GetHeight() int64 {
  859. if m != nil {
  860. return m.Height
  861. }
  862. return 0
  863. }
  864. type RequestCommit struct {
  865. }
  866. func (m *RequestCommit) Reset() { *m = RequestCommit{} }
  867. func (m *RequestCommit) String() string { return proto.CompactTextString(m) }
  868. func (*RequestCommit) ProtoMessage() {}
  869. func (*RequestCommit) Descriptor() ([]byte, []int) {
  870. return fileDescriptor_252557cfdd89a31a, []int{11}
  871. }
  872. func (m *RequestCommit) XXX_Unmarshal(b []byte) error {
  873. return m.Unmarshal(b)
  874. }
  875. func (m *RequestCommit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  876. if deterministic {
  877. return xxx_messageInfo_RequestCommit.Marshal(b, m, deterministic)
  878. } else {
  879. b = b[:cap(b)]
  880. n, err := m.MarshalToSizedBuffer(b)
  881. if err != nil {
  882. return nil, err
  883. }
  884. return b[:n], nil
  885. }
  886. }
  887. func (m *RequestCommit) XXX_Merge(src proto.Message) {
  888. xxx_messageInfo_RequestCommit.Merge(m, src)
  889. }
  890. func (m *RequestCommit) XXX_Size() int {
  891. return m.Size()
  892. }
  893. func (m *RequestCommit) XXX_DiscardUnknown() {
  894. xxx_messageInfo_RequestCommit.DiscardUnknown(m)
  895. }
  896. var xxx_messageInfo_RequestCommit proto.InternalMessageInfo
  897. // lists available snapshots
  898. type RequestListSnapshots struct {
  899. }
  900. func (m *RequestListSnapshots) Reset() { *m = RequestListSnapshots{} }
  901. func (m *RequestListSnapshots) String() string { return proto.CompactTextString(m) }
  902. func (*RequestListSnapshots) ProtoMessage() {}
  903. func (*RequestListSnapshots) Descriptor() ([]byte, []int) {
  904. return fileDescriptor_252557cfdd89a31a, []int{12}
  905. }
  906. func (m *RequestListSnapshots) XXX_Unmarshal(b []byte) error {
  907. return m.Unmarshal(b)
  908. }
  909. func (m *RequestListSnapshots) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  910. if deterministic {
  911. return xxx_messageInfo_RequestListSnapshots.Marshal(b, m, deterministic)
  912. } else {
  913. b = b[:cap(b)]
  914. n, err := m.MarshalToSizedBuffer(b)
  915. if err != nil {
  916. return nil, err
  917. }
  918. return b[:n], nil
  919. }
  920. }
  921. func (m *RequestListSnapshots) XXX_Merge(src proto.Message) {
  922. xxx_messageInfo_RequestListSnapshots.Merge(m, src)
  923. }
  924. func (m *RequestListSnapshots) XXX_Size() int {
  925. return m.Size()
  926. }
  927. func (m *RequestListSnapshots) XXX_DiscardUnknown() {
  928. xxx_messageInfo_RequestListSnapshots.DiscardUnknown(m)
  929. }
  930. var xxx_messageInfo_RequestListSnapshots proto.InternalMessageInfo
  931. // offers a snapshot to the application
  932. type RequestOfferSnapshot struct {
  933. Snapshot *Snapshot `protobuf:"bytes,1,opt,name=snapshot,proto3" json:"snapshot,omitempty"`
  934. AppHash []byte `protobuf:"bytes,2,opt,name=app_hash,json=appHash,proto3" json:"app_hash,omitempty"`
  935. }
  936. func (m *RequestOfferSnapshot) Reset() { *m = RequestOfferSnapshot{} }
  937. func (m *RequestOfferSnapshot) String() string { return proto.CompactTextString(m) }
  938. func (*RequestOfferSnapshot) ProtoMessage() {}
  939. func (*RequestOfferSnapshot) Descriptor() ([]byte, []int) {
  940. return fileDescriptor_252557cfdd89a31a, []int{13}
  941. }
  942. func (m *RequestOfferSnapshot) XXX_Unmarshal(b []byte) error {
  943. return m.Unmarshal(b)
  944. }
  945. func (m *RequestOfferSnapshot) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  946. if deterministic {
  947. return xxx_messageInfo_RequestOfferSnapshot.Marshal(b, m, deterministic)
  948. } else {
  949. b = b[:cap(b)]
  950. n, err := m.MarshalToSizedBuffer(b)
  951. if err != nil {
  952. return nil, err
  953. }
  954. return b[:n], nil
  955. }
  956. }
  957. func (m *RequestOfferSnapshot) XXX_Merge(src proto.Message) {
  958. xxx_messageInfo_RequestOfferSnapshot.Merge(m, src)
  959. }
  960. func (m *RequestOfferSnapshot) XXX_Size() int {
  961. return m.Size()
  962. }
  963. func (m *RequestOfferSnapshot) XXX_DiscardUnknown() {
  964. xxx_messageInfo_RequestOfferSnapshot.DiscardUnknown(m)
  965. }
  966. var xxx_messageInfo_RequestOfferSnapshot proto.InternalMessageInfo
  967. func (m *RequestOfferSnapshot) GetSnapshot() *Snapshot {
  968. if m != nil {
  969. return m.Snapshot
  970. }
  971. return nil
  972. }
  973. func (m *RequestOfferSnapshot) GetAppHash() []byte {
  974. if m != nil {
  975. return m.AppHash
  976. }
  977. return nil
  978. }
  979. // loads a snapshot chunk
  980. type RequestLoadSnapshotChunk struct {
  981. Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"`
  982. Format uint32 `protobuf:"varint,2,opt,name=format,proto3" json:"format,omitempty"`
  983. Chunk uint32 `protobuf:"varint,3,opt,name=chunk,proto3" json:"chunk,omitempty"`
  984. }
  985. func (m *RequestLoadSnapshotChunk) Reset() { *m = RequestLoadSnapshotChunk{} }
  986. func (m *RequestLoadSnapshotChunk) String() string { return proto.CompactTextString(m) }
  987. func (*RequestLoadSnapshotChunk) ProtoMessage() {}
  988. func (*RequestLoadSnapshotChunk) Descriptor() ([]byte, []int) {
  989. return fileDescriptor_252557cfdd89a31a, []int{14}
  990. }
  991. func (m *RequestLoadSnapshotChunk) XXX_Unmarshal(b []byte) error {
  992. return m.Unmarshal(b)
  993. }
  994. func (m *RequestLoadSnapshotChunk) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  995. if deterministic {
  996. return xxx_messageInfo_RequestLoadSnapshotChunk.Marshal(b, m, deterministic)
  997. } else {
  998. b = b[:cap(b)]
  999. n, err := m.MarshalToSizedBuffer(b)
  1000. if err != nil {
  1001. return nil, err
  1002. }
  1003. return b[:n], nil
  1004. }
  1005. }
  1006. func (m *RequestLoadSnapshotChunk) XXX_Merge(src proto.Message) {
  1007. xxx_messageInfo_RequestLoadSnapshotChunk.Merge(m, src)
  1008. }
  1009. func (m *RequestLoadSnapshotChunk) XXX_Size() int {
  1010. return m.Size()
  1011. }
  1012. func (m *RequestLoadSnapshotChunk) XXX_DiscardUnknown() {
  1013. xxx_messageInfo_RequestLoadSnapshotChunk.DiscardUnknown(m)
  1014. }
  1015. var xxx_messageInfo_RequestLoadSnapshotChunk proto.InternalMessageInfo
  1016. func (m *RequestLoadSnapshotChunk) GetHeight() uint64 {
  1017. if m != nil {
  1018. return m.Height
  1019. }
  1020. return 0
  1021. }
  1022. func (m *RequestLoadSnapshotChunk) GetFormat() uint32 {
  1023. if m != nil {
  1024. return m.Format
  1025. }
  1026. return 0
  1027. }
  1028. func (m *RequestLoadSnapshotChunk) GetChunk() uint32 {
  1029. if m != nil {
  1030. return m.Chunk
  1031. }
  1032. return 0
  1033. }
  1034. // Applies a snapshot chunk
  1035. type RequestApplySnapshotChunk struct {
  1036. Index uint32 `protobuf:"varint,1,opt,name=index,proto3" json:"index,omitempty"`
  1037. Chunk []byte `protobuf:"bytes,2,opt,name=chunk,proto3" json:"chunk,omitempty"`
  1038. Sender string `protobuf:"bytes,3,opt,name=sender,proto3" json:"sender,omitempty"`
  1039. }
  1040. func (m *RequestApplySnapshotChunk) Reset() { *m = RequestApplySnapshotChunk{} }
  1041. func (m *RequestApplySnapshotChunk) String() string { return proto.CompactTextString(m) }
  1042. func (*RequestApplySnapshotChunk) ProtoMessage() {}
  1043. func (*RequestApplySnapshotChunk) Descriptor() ([]byte, []int) {
  1044. return fileDescriptor_252557cfdd89a31a, []int{15}
  1045. }
  1046. func (m *RequestApplySnapshotChunk) XXX_Unmarshal(b []byte) error {
  1047. return m.Unmarshal(b)
  1048. }
  1049. func (m *RequestApplySnapshotChunk) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1050. if deterministic {
  1051. return xxx_messageInfo_RequestApplySnapshotChunk.Marshal(b, m, deterministic)
  1052. } else {
  1053. b = b[:cap(b)]
  1054. n, err := m.MarshalToSizedBuffer(b)
  1055. if err != nil {
  1056. return nil, err
  1057. }
  1058. return b[:n], nil
  1059. }
  1060. }
  1061. func (m *RequestApplySnapshotChunk) XXX_Merge(src proto.Message) {
  1062. xxx_messageInfo_RequestApplySnapshotChunk.Merge(m, src)
  1063. }
  1064. func (m *RequestApplySnapshotChunk) XXX_Size() int {
  1065. return m.Size()
  1066. }
  1067. func (m *RequestApplySnapshotChunk) XXX_DiscardUnknown() {
  1068. xxx_messageInfo_RequestApplySnapshotChunk.DiscardUnknown(m)
  1069. }
  1070. var xxx_messageInfo_RequestApplySnapshotChunk proto.InternalMessageInfo
  1071. func (m *RequestApplySnapshotChunk) GetIndex() uint32 {
  1072. if m != nil {
  1073. return m.Index
  1074. }
  1075. return 0
  1076. }
  1077. func (m *RequestApplySnapshotChunk) GetChunk() []byte {
  1078. if m != nil {
  1079. return m.Chunk
  1080. }
  1081. return nil
  1082. }
  1083. func (m *RequestApplySnapshotChunk) GetSender() string {
  1084. if m != nil {
  1085. return m.Sender
  1086. }
  1087. return ""
  1088. }
  1089. type Response struct {
  1090. // Types that are valid to be assigned to Value:
  1091. // *Response_Exception
  1092. // *Response_Echo
  1093. // *Response_Flush
  1094. // *Response_Info
  1095. // *Response_SetOption
  1096. // *Response_InitChain
  1097. // *Response_Query
  1098. // *Response_BeginBlock
  1099. // *Response_CheckTx
  1100. // *Response_DeliverTx
  1101. // *Response_EndBlock
  1102. // *Response_Commit
  1103. // *Response_ListSnapshots
  1104. // *Response_OfferSnapshot
  1105. // *Response_LoadSnapshotChunk
  1106. // *Response_ApplySnapshotChunk
  1107. Value isResponse_Value `protobuf_oneof:"value"`
  1108. }
  1109. func (m *Response) Reset() { *m = Response{} }
  1110. func (m *Response) String() string { return proto.CompactTextString(m) }
  1111. func (*Response) ProtoMessage() {}
  1112. func (*Response) Descriptor() ([]byte, []int) {
  1113. return fileDescriptor_252557cfdd89a31a, []int{16}
  1114. }
  1115. func (m *Response) XXX_Unmarshal(b []byte) error {
  1116. return m.Unmarshal(b)
  1117. }
  1118. func (m *Response) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1119. if deterministic {
  1120. return xxx_messageInfo_Response.Marshal(b, m, deterministic)
  1121. } else {
  1122. b = b[:cap(b)]
  1123. n, err := m.MarshalToSizedBuffer(b)
  1124. if err != nil {
  1125. return nil, err
  1126. }
  1127. return b[:n], nil
  1128. }
  1129. }
  1130. func (m *Response) XXX_Merge(src proto.Message) {
  1131. xxx_messageInfo_Response.Merge(m, src)
  1132. }
  1133. func (m *Response) XXX_Size() int {
  1134. return m.Size()
  1135. }
  1136. func (m *Response) XXX_DiscardUnknown() {
  1137. xxx_messageInfo_Response.DiscardUnknown(m)
  1138. }
  1139. var xxx_messageInfo_Response proto.InternalMessageInfo
  1140. type isResponse_Value interface {
  1141. isResponse_Value()
  1142. MarshalTo([]byte) (int, error)
  1143. Size() int
  1144. }
  1145. type Response_Exception struct {
  1146. Exception *ResponseException `protobuf:"bytes,1,opt,name=exception,proto3,oneof" json:"exception,omitempty"`
  1147. }
  1148. type Response_Echo struct {
  1149. Echo *ResponseEcho `protobuf:"bytes,2,opt,name=echo,proto3,oneof" json:"echo,omitempty"`
  1150. }
  1151. type Response_Flush struct {
  1152. Flush *ResponseFlush `protobuf:"bytes,3,opt,name=flush,proto3,oneof" json:"flush,omitempty"`
  1153. }
  1154. type Response_Info struct {
  1155. Info *ResponseInfo `protobuf:"bytes,4,opt,name=info,proto3,oneof" json:"info,omitempty"`
  1156. }
  1157. type Response_SetOption struct {
  1158. SetOption *ResponseSetOption `protobuf:"bytes,5,opt,name=set_option,json=setOption,proto3,oneof" json:"set_option,omitempty"`
  1159. }
  1160. type Response_InitChain struct {
  1161. InitChain *ResponseInitChain `protobuf:"bytes,6,opt,name=init_chain,json=initChain,proto3,oneof" json:"init_chain,omitempty"`
  1162. }
  1163. type Response_Query struct {
  1164. Query *ResponseQuery `protobuf:"bytes,7,opt,name=query,proto3,oneof" json:"query,omitempty"`
  1165. }
  1166. type Response_BeginBlock struct {
  1167. BeginBlock *ResponseBeginBlock `protobuf:"bytes,8,opt,name=begin_block,json=beginBlock,proto3,oneof" json:"begin_block,omitempty"`
  1168. }
  1169. type Response_CheckTx struct {
  1170. CheckTx *ResponseCheckTx `protobuf:"bytes,9,opt,name=check_tx,json=checkTx,proto3,oneof" json:"check_tx,omitempty"`
  1171. }
  1172. type Response_DeliverTx struct {
  1173. DeliverTx *ResponseDeliverTx `protobuf:"bytes,10,opt,name=deliver_tx,json=deliverTx,proto3,oneof" json:"deliver_tx,omitempty"`
  1174. }
  1175. type Response_EndBlock struct {
  1176. EndBlock *ResponseEndBlock `protobuf:"bytes,11,opt,name=end_block,json=endBlock,proto3,oneof" json:"end_block,omitempty"`
  1177. }
  1178. type Response_Commit struct {
  1179. Commit *ResponseCommit `protobuf:"bytes,12,opt,name=commit,proto3,oneof" json:"commit,omitempty"`
  1180. }
  1181. type Response_ListSnapshots struct {
  1182. ListSnapshots *ResponseListSnapshots `protobuf:"bytes,13,opt,name=list_snapshots,json=listSnapshots,proto3,oneof" json:"list_snapshots,omitempty"`
  1183. }
  1184. type Response_OfferSnapshot struct {
  1185. OfferSnapshot *ResponseOfferSnapshot `protobuf:"bytes,14,opt,name=offer_snapshot,json=offerSnapshot,proto3,oneof" json:"offer_snapshot,omitempty"`
  1186. }
  1187. type Response_LoadSnapshotChunk struct {
  1188. LoadSnapshotChunk *ResponseLoadSnapshotChunk `protobuf:"bytes,15,opt,name=load_snapshot_chunk,json=loadSnapshotChunk,proto3,oneof" json:"load_snapshot_chunk,omitempty"`
  1189. }
  1190. type Response_ApplySnapshotChunk struct {
  1191. ApplySnapshotChunk *ResponseApplySnapshotChunk `protobuf:"bytes,16,opt,name=apply_snapshot_chunk,json=applySnapshotChunk,proto3,oneof" json:"apply_snapshot_chunk,omitempty"`
  1192. }
  1193. func (*Response_Exception) isResponse_Value() {}
  1194. func (*Response_Echo) isResponse_Value() {}
  1195. func (*Response_Flush) isResponse_Value() {}
  1196. func (*Response_Info) isResponse_Value() {}
  1197. func (*Response_SetOption) isResponse_Value() {}
  1198. func (*Response_InitChain) isResponse_Value() {}
  1199. func (*Response_Query) isResponse_Value() {}
  1200. func (*Response_BeginBlock) isResponse_Value() {}
  1201. func (*Response_CheckTx) isResponse_Value() {}
  1202. func (*Response_DeliverTx) isResponse_Value() {}
  1203. func (*Response_EndBlock) isResponse_Value() {}
  1204. func (*Response_Commit) isResponse_Value() {}
  1205. func (*Response_ListSnapshots) isResponse_Value() {}
  1206. func (*Response_OfferSnapshot) isResponse_Value() {}
  1207. func (*Response_LoadSnapshotChunk) isResponse_Value() {}
  1208. func (*Response_ApplySnapshotChunk) isResponse_Value() {}
  1209. func (m *Response) GetValue() isResponse_Value {
  1210. if m != nil {
  1211. return m.Value
  1212. }
  1213. return nil
  1214. }
  1215. func (m *Response) GetException() *ResponseException {
  1216. if x, ok := m.GetValue().(*Response_Exception); ok {
  1217. return x.Exception
  1218. }
  1219. return nil
  1220. }
  1221. func (m *Response) GetEcho() *ResponseEcho {
  1222. if x, ok := m.GetValue().(*Response_Echo); ok {
  1223. return x.Echo
  1224. }
  1225. return nil
  1226. }
  1227. func (m *Response) GetFlush() *ResponseFlush {
  1228. if x, ok := m.GetValue().(*Response_Flush); ok {
  1229. return x.Flush
  1230. }
  1231. return nil
  1232. }
  1233. func (m *Response) GetInfo() *ResponseInfo {
  1234. if x, ok := m.GetValue().(*Response_Info); ok {
  1235. return x.Info
  1236. }
  1237. return nil
  1238. }
  1239. func (m *Response) GetSetOption() *ResponseSetOption {
  1240. if x, ok := m.GetValue().(*Response_SetOption); ok {
  1241. return x.SetOption
  1242. }
  1243. return nil
  1244. }
  1245. func (m *Response) GetInitChain() *ResponseInitChain {
  1246. if x, ok := m.GetValue().(*Response_InitChain); ok {
  1247. return x.InitChain
  1248. }
  1249. return nil
  1250. }
  1251. func (m *Response) GetQuery() *ResponseQuery {
  1252. if x, ok := m.GetValue().(*Response_Query); ok {
  1253. return x.Query
  1254. }
  1255. return nil
  1256. }
  1257. func (m *Response) GetBeginBlock() *ResponseBeginBlock {
  1258. if x, ok := m.GetValue().(*Response_BeginBlock); ok {
  1259. return x.BeginBlock
  1260. }
  1261. return nil
  1262. }
  1263. func (m *Response) GetCheckTx() *ResponseCheckTx {
  1264. if x, ok := m.GetValue().(*Response_CheckTx); ok {
  1265. return x.CheckTx
  1266. }
  1267. return nil
  1268. }
  1269. func (m *Response) GetDeliverTx() *ResponseDeliverTx {
  1270. if x, ok := m.GetValue().(*Response_DeliverTx); ok {
  1271. return x.DeliverTx
  1272. }
  1273. return nil
  1274. }
  1275. func (m *Response) GetEndBlock() *ResponseEndBlock {
  1276. if x, ok := m.GetValue().(*Response_EndBlock); ok {
  1277. return x.EndBlock
  1278. }
  1279. return nil
  1280. }
  1281. func (m *Response) GetCommit() *ResponseCommit {
  1282. if x, ok := m.GetValue().(*Response_Commit); ok {
  1283. return x.Commit
  1284. }
  1285. return nil
  1286. }
  1287. func (m *Response) GetListSnapshots() *ResponseListSnapshots {
  1288. if x, ok := m.GetValue().(*Response_ListSnapshots); ok {
  1289. return x.ListSnapshots
  1290. }
  1291. return nil
  1292. }
  1293. func (m *Response) GetOfferSnapshot() *ResponseOfferSnapshot {
  1294. if x, ok := m.GetValue().(*Response_OfferSnapshot); ok {
  1295. return x.OfferSnapshot
  1296. }
  1297. return nil
  1298. }
  1299. func (m *Response) GetLoadSnapshotChunk() *ResponseLoadSnapshotChunk {
  1300. if x, ok := m.GetValue().(*Response_LoadSnapshotChunk); ok {
  1301. return x.LoadSnapshotChunk
  1302. }
  1303. return nil
  1304. }
  1305. func (m *Response) GetApplySnapshotChunk() *ResponseApplySnapshotChunk {
  1306. if x, ok := m.GetValue().(*Response_ApplySnapshotChunk); ok {
  1307. return x.ApplySnapshotChunk
  1308. }
  1309. return nil
  1310. }
  1311. // XXX_OneofWrappers is for the internal use of the proto package.
  1312. func (*Response) XXX_OneofWrappers() []interface{} {
  1313. return []interface{}{
  1314. (*Response_Exception)(nil),
  1315. (*Response_Echo)(nil),
  1316. (*Response_Flush)(nil),
  1317. (*Response_Info)(nil),
  1318. (*Response_SetOption)(nil),
  1319. (*Response_InitChain)(nil),
  1320. (*Response_Query)(nil),
  1321. (*Response_BeginBlock)(nil),
  1322. (*Response_CheckTx)(nil),
  1323. (*Response_DeliverTx)(nil),
  1324. (*Response_EndBlock)(nil),
  1325. (*Response_Commit)(nil),
  1326. (*Response_ListSnapshots)(nil),
  1327. (*Response_OfferSnapshot)(nil),
  1328. (*Response_LoadSnapshotChunk)(nil),
  1329. (*Response_ApplySnapshotChunk)(nil),
  1330. }
  1331. }
  1332. // nondeterministic
  1333. type ResponseException struct {
  1334. Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
  1335. }
  1336. func (m *ResponseException) Reset() { *m = ResponseException{} }
  1337. func (m *ResponseException) String() string { return proto.CompactTextString(m) }
  1338. func (*ResponseException) ProtoMessage() {}
  1339. func (*ResponseException) Descriptor() ([]byte, []int) {
  1340. return fileDescriptor_252557cfdd89a31a, []int{17}
  1341. }
  1342. func (m *ResponseException) XXX_Unmarshal(b []byte) error {
  1343. return m.Unmarshal(b)
  1344. }
  1345. func (m *ResponseException) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1346. if deterministic {
  1347. return xxx_messageInfo_ResponseException.Marshal(b, m, deterministic)
  1348. } else {
  1349. b = b[:cap(b)]
  1350. n, err := m.MarshalToSizedBuffer(b)
  1351. if err != nil {
  1352. return nil, err
  1353. }
  1354. return b[:n], nil
  1355. }
  1356. }
  1357. func (m *ResponseException) XXX_Merge(src proto.Message) {
  1358. xxx_messageInfo_ResponseException.Merge(m, src)
  1359. }
  1360. func (m *ResponseException) XXX_Size() int {
  1361. return m.Size()
  1362. }
  1363. func (m *ResponseException) XXX_DiscardUnknown() {
  1364. xxx_messageInfo_ResponseException.DiscardUnknown(m)
  1365. }
  1366. var xxx_messageInfo_ResponseException proto.InternalMessageInfo
  1367. func (m *ResponseException) GetError() string {
  1368. if m != nil {
  1369. return m.Error
  1370. }
  1371. return ""
  1372. }
  1373. type ResponseEcho struct {
  1374. Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
  1375. }
  1376. func (m *ResponseEcho) Reset() { *m = ResponseEcho{} }
  1377. func (m *ResponseEcho) String() string { return proto.CompactTextString(m) }
  1378. func (*ResponseEcho) ProtoMessage() {}
  1379. func (*ResponseEcho) Descriptor() ([]byte, []int) {
  1380. return fileDescriptor_252557cfdd89a31a, []int{18}
  1381. }
  1382. func (m *ResponseEcho) XXX_Unmarshal(b []byte) error {
  1383. return m.Unmarshal(b)
  1384. }
  1385. func (m *ResponseEcho) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1386. if deterministic {
  1387. return xxx_messageInfo_ResponseEcho.Marshal(b, m, deterministic)
  1388. } else {
  1389. b = b[:cap(b)]
  1390. n, err := m.MarshalToSizedBuffer(b)
  1391. if err != nil {
  1392. return nil, err
  1393. }
  1394. return b[:n], nil
  1395. }
  1396. }
  1397. func (m *ResponseEcho) XXX_Merge(src proto.Message) {
  1398. xxx_messageInfo_ResponseEcho.Merge(m, src)
  1399. }
  1400. func (m *ResponseEcho) XXX_Size() int {
  1401. return m.Size()
  1402. }
  1403. func (m *ResponseEcho) XXX_DiscardUnknown() {
  1404. xxx_messageInfo_ResponseEcho.DiscardUnknown(m)
  1405. }
  1406. var xxx_messageInfo_ResponseEcho proto.InternalMessageInfo
  1407. func (m *ResponseEcho) GetMessage() string {
  1408. if m != nil {
  1409. return m.Message
  1410. }
  1411. return ""
  1412. }
  1413. type ResponseFlush struct {
  1414. }
  1415. func (m *ResponseFlush) Reset() { *m = ResponseFlush{} }
  1416. func (m *ResponseFlush) String() string { return proto.CompactTextString(m) }
  1417. func (*ResponseFlush) ProtoMessage() {}
  1418. func (*ResponseFlush) Descriptor() ([]byte, []int) {
  1419. return fileDescriptor_252557cfdd89a31a, []int{19}
  1420. }
  1421. func (m *ResponseFlush) XXX_Unmarshal(b []byte) error {
  1422. return m.Unmarshal(b)
  1423. }
  1424. func (m *ResponseFlush) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1425. if deterministic {
  1426. return xxx_messageInfo_ResponseFlush.Marshal(b, m, deterministic)
  1427. } else {
  1428. b = b[:cap(b)]
  1429. n, err := m.MarshalToSizedBuffer(b)
  1430. if err != nil {
  1431. return nil, err
  1432. }
  1433. return b[:n], nil
  1434. }
  1435. }
  1436. func (m *ResponseFlush) XXX_Merge(src proto.Message) {
  1437. xxx_messageInfo_ResponseFlush.Merge(m, src)
  1438. }
  1439. func (m *ResponseFlush) XXX_Size() int {
  1440. return m.Size()
  1441. }
  1442. func (m *ResponseFlush) XXX_DiscardUnknown() {
  1443. xxx_messageInfo_ResponseFlush.DiscardUnknown(m)
  1444. }
  1445. var xxx_messageInfo_ResponseFlush proto.InternalMessageInfo
  1446. type ResponseInfo struct {
  1447. Data string `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
  1448. Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
  1449. AppVersion uint64 `protobuf:"varint,3,opt,name=app_version,json=appVersion,proto3" json:"app_version,omitempty"`
  1450. LastBlockHeight int64 `protobuf:"varint,4,opt,name=last_block_height,json=lastBlockHeight,proto3" json:"last_block_height,omitempty"`
  1451. LastBlockAppHash []byte `protobuf:"bytes,5,opt,name=last_block_app_hash,json=lastBlockAppHash,proto3" json:"last_block_app_hash,omitempty"`
  1452. }
  1453. func (m *ResponseInfo) Reset() { *m = ResponseInfo{} }
  1454. func (m *ResponseInfo) String() string { return proto.CompactTextString(m) }
  1455. func (*ResponseInfo) ProtoMessage() {}
  1456. func (*ResponseInfo) Descriptor() ([]byte, []int) {
  1457. return fileDescriptor_252557cfdd89a31a, []int{20}
  1458. }
  1459. func (m *ResponseInfo) XXX_Unmarshal(b []byte) error {
  1460. return m.Unmarshal(b)
  1461. }
  1462. func (m *ResponseInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1463. if deterministic {
  1464. return xxx_messageInfo_ResponseInfo.Marshal(b, m, deterministic)
  1465. } else {
  1466. b = b[:cap(b)]
  1467. n, err := m.MarshalToSizedBuffer(b)
  1468. if err != nil {
  1469. return nil, err
  1470. }
  1471. return b[:n], nil
  1472. }
  1473. }
  1474. func (m *ResponseInfo) XXX_Merge(src proto.Message) {
  1475. xxx_messageInfo_ResponseInfo.Merge(m, src)
  1476. }
  1477. func (m *ResponseInfo) XXX_Size() int {
  1478. return m.Size()
  1479. }
  1480. func (m *ResponseInfo) XXX_DiscardUnknown() {
  1481. xxx_messageInfo_ResponseInfo.DiscardUnknown(m)
  1482. }
  1483. var xxx_messageInfo_ResponseInfo proto.InternalMessageInfo
  1484. func (m *ResponseInfo) GetData() string {
  1485. if m != nil {
  1486. return m.Data
  1487. }
  1488. return ""
  1489. }
  1490. func (m *ResponseInfo) GetVersion() string {
  1491. if m != nil {
  1492. return m.Version
  1493. }
  1494. return ""
  1495. }
  1496. func (m *ResponseInfo) GetAppVersion() uint64 {
  1497. if m != nil {
  1498. return m.AppVersion
  1499. }
  1500. return 0
  1501. }
  1502. func (m *ResponseInfo) GetLastBlockHeight() int64 {
  1503. if m != nil {
  1504. return m.LastBlockHeight
  1505. }
  1506. return 0
  1507. }
  1508. func (m *ResponseInfo) GetLastBlockAppHash() []byte {
  1509. if m != nil {
  1510. return m.LastBlockAppHash
  1511. }
  1512. return nil
  1513. }
  1514. // nondeterministic
  1515. type ResponseSetOption struct {
  1516. Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
  1517. // bytes data = 2;
  1518. Log string `protobuf:"bytes,3,opt,name=log,proto3" json:"log,omitempty"`
  1519. Info string `protobuf:"bytes,4,opt,name=info,proto3" json:"info,omitempty"`
  1520. }
  1521. func (m *ResponseSetOption) Reset() { *m = ResponseSetOption{} }
  1522. func (m *ResponseSetOption) String() string { return proto.CompactTextString(m) }
  1523. func (*ResponseSetOption) ProtoMessage() {}
  1524. func (*ResponseSetOption) Descriptor() ([]byte, []int) {
  1525. return fileDescriptor_252557cfdd89a31a, []int{21}
  1526. }
  1527. func (m *ResponseSetOption) XXX_Unmarshal(b []byte) error {
  1528. return m.Unmarshal(b)
  1529. }
  1530. func (m *ResponseSetOption) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1531. if deterministic {
  1532. return xxx_messageInfo_ResponseSetOption.Marshal(b, m, deterministic)
  1533. } else {
  1534. b = b[:cap(b)]
  1535. n, err := m.MarshalToSizedBuffer(b)
  1536. if err != nil {
  1537. return nil, err
  1538. }
  1539. return b[:n], nil
  1540. }
  1541. }
  1542. func (m *ResponseSetOption) XXX_Merge(src proto.Message) {
  1543. xxx_messageInfo_ResponseSetOption.Merge(m, src)
  1544. }
  1545. func (m *ResponseSetOption) XXX_Size() int {
  1546. return m.Size()
  1547. }
  1548. func (m *ResponseSetOption) XXX_DiscardUnknown() {
  1549. xxx_messageInfo_ResponseSetOption.DiscardUnknown(m)
  1550. }
  1551. var xxx_messageInfo_ResponseSetOption proto.InternalMessageInfo
  1552. func (m *ResponseSetOption) GetCode() uint32 {
  1553. if m != nil {
  1554. return m.Code
  1555. }
  1556. return 0
  1557. }
  1558. func (m *ResponseSetOption) GetLog() string {
  1559. if m != nil {
  1560. return m.Log
  1561. }
  1562. return ""
  1563. }
  1564. func (m *ResponseSetOption) GetInfo() string {
  1565. if m != nil {
  1566. return m.Info
  1567. }
  1568. return ""
  1569. }
  1570. type ResponseInitChain struct {
  1571. ConsensusParams *ConsensusParams `protobuf:"bytes,1,opt,name=consensus_params,json=consensusParams,proto3" json:"consensus_params,omitempty"`
  1572. Validators []ValidatorUpdate `protobuf:"bytes,2,rep,name=validators,proto3" json:"validators"`
  1573. AppHash []byte `protobuf:"bytes,3,opt,name=app_hash,json=appHash,proto3" json:"app_hash,omitempty"`
  1574. }
  1575. func (m *ResponseInitChain) Reset() { *m = ResponseInitChain{} }
  1576. func (m *ResponseInitChain) String() string { return proto.CompactTextString(m) }
  1577. func (*ResponseInitChain) ProtoMessage() {}
  1578. func (*ResponseInitChain) Descriptor() ([]byte, []int) {
  1579. return fileDescriptor_252557cfdd89a31a, []int{22}
  1580. }
  1581. func (m *ResponseInitChain) XXX_Unmarshal(b []byte) error {
  1582. return m.Unmarshal(b)
  1583. }
  1584. func (m *ResponseInitChain) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1585. if deterministic {
  1586. return xxx_messageInfo_ResponseInitChain.Marshal(b, m, deterministic)
  1587. } else {
  1588. b = b[:cap(b)]
  1589. n, err := m.MarshalToSizedBuffer(b)
  1590. if err != nil {
  1591. return nil, err
  1592. }
  1593. return b[:n], nil
  1594. }
  1595. }
  1596. func (m *ResponseInitChain) XXX_Merge(src proto.Message) {
  1597. xxx_messageInfo_ResponseInitChain.Merge(m, src)
  1598. }
  1599. func (m *ResponseInitChain) XXX_Size() int {
  1600. return m.Size()
  1601. }
  1602. func (m *ResponseInitChain) XXX_DiscardUnknown() {
  1603. xxx_messageInfo_ResponseInitChain.DiscardUnknown(m)
  1604. }
  1605. var xxx_messageInfo_ResponseInitChain proto.InternalMessageInfo
  1606. func (m *ResponseInitChain) GetConsensusParams() *ConsensusParams {
  1607. if m != nil {
  1608. return m.ConsensusParams
  1609. }
  1610. return nil
  1611. }
  1612. func (m *ResponseInitChain) GetValidators() []ValidatorUpdate {
  1613. if m != nil {
  1614. return m.Validators
  1615. }
  1616. return nil
  1617. }
  1618. func (m *ResponseInitChain) GetAppHash() []byte {
  1619. if m != nil {
  1620. return m.AppHash
  1621. }
  1622. return nil
  1623. }
  1624. type ResponseQuery struct {
  1625. Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
  1626. // bytes data = 2; // use "value" instead.
  1627. Log string `protobuf:"bytes,3,opt,name=log,proto3" json:"log,omitempty"`
  1628. Info string `protobuf:"bytes,4,opt,name=info,proto3" json:"info,omitempty"`
  1629. Index int64 `protobuf:"varint,5,opt,name=index,proto3" json:"index,omitempty"`
  1630. Key []byte `protobuf:"bytes,6,opt,name=key,proto3" json:"key,omitempty"`
  1631. Value []byte `protobuf:"bytes,7,opt,name=value,proto3" json:"value,omitempty"`
  1632. ProofOps *crypto.ProofOps `protobuf:"bytes,8,opt,name=proof_ops,json=proofOps,proto3" json:"proof_ops,omitempty"`
  1633. Height int64 `protobuf:"varint,9,opt,name=height,proto3" json:"height,omitempty"`
  1634. Codespace string `protobuf:"bytes,10,opt,name=codespace,proto3" json:"codespace,omitempty"`
  1635. }
  1636. func (m *ResponseQuery) Reset() { *m = ResponseQuery{} }
  1637. func (m *ResponseQuery) String() string { return proto.CompactTextString(m) }
  1638. func (*ResponseQuery) ProtoMessage() {}
  1639. func (*ResponseQuery) Descriptor() ([]byte, []int) {
  1640. return fileDescriptor_252557cfdd89a31a, []int{23}
  1641. }
  1642. func (m *ResponseQuery) XXX_Unmarshal(b []byte) error {
  1643. return m.Unmarshal(b)
  1644. }
  1645. func (m *ResponseQuery) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1646. if deterministic {
  1647. return xxx_messageInfo_ResponseQuery.Marshal(b, m, deterministic)
  1648. } else {
  1649. b = b[:cap(b)]
  1650. n, err := m.MarshalToSizedBuffer(b)
  1651. if err != nil {
  1652. return nil, err
  1653. }
  1654. return b[:n], nil
  1655. }
  1656. }
  1657. func (m *ResponseQuery) XXX_Merge(src proto.Message) {
  1658. xxx_messageInfo_ResponseQuery.Merge(m, src)
  1659. }
  1660. func (m *ResponseQuery) XXX_Size() int {
  1661. return m.Size()
  1662. }
  1663. func (m *ResponseQuery) XXX_DiscardUnknown() {
  1664. xxx_messageInfo_ResponseQuery.DiscardUnknown(m)
  1665. }
  1666. var xxx_messageInfo_ResponseQuery proto.InternalMessageInfo
  1667. func (m *ResponseQuery) GetCode() uint32 {
  1668. if m != nil {
  1669. return m.Code
  1670. }
  1671. return 0
  1672. }
  1673. func (m *ResponseQuery) GetLog() string {
  1674. if m != nil {
  1675. return m.Log
  1676. }
  1677. return ""
  1678. }
  1679. func (m *ResponseQuery) GetInfo() string {
  1680. if m != nil {
  1681. return m.Info
  1682. }
  1683. return ""
  1684. }
  1685. func (m *ResponseQuery) GetIndex() int64 {
  1686. if m != nil {
  1687. return m.Index
  1688. }
  1689. return 0
  1690. }
  1691. func (m *ResponseQuery) GetKey() []byte {
  1692. if m != nil {
  1693. return m.Key
  1694. }
  1695. return nil
  1696. }
  1697. func (m *ResponseQuery) GetValue() []byte {
  1698. if m != nil {
  1699. return m.Value
  1700. }
  1701. return nil
  1702. }
  1703. func (m *ResponseQuery) GetProofOps() *crypto.ProofOps {
  1704. if m != nil {
  1705. return m.ProofOps
  1706. }
  1707. return nil
  1708. }
  1709. func (m *ResponseQuery) GetHeight() int64 {
  1710. if m != nil {
  1711. return m.Height
  1712. }
  1713. return 0
  1714. }
  1715. func (m *ResponseQuery) GetCodespace() string {
  1716. if m != nil {
  1717. return m.Codespace
  1718. }
  1719. return ""
  1720. }
  1721. type ResponseBeginBlock struct {
  1722. Events []Event `protobuf:"bytes,1,rep,name=events,proto3" json:"events,omitempty"`
  1723. }
  1724. func (m *ResponseBeginBlock) Reset() { *m = ResponseBeginBlock{} }
  1725. func (m *ResponseBeginBlock) String() string { return proto.CompactTextString(m) }
  1726. func (*ResponseBeginBlock) ProtoMessage() {}
  1727. func (*ResponseBeginBlock) Descriptor() ([]byte, []int) {
  1728. return fileDescriptor_252557cfdd89a31a, []int{24}
  1729. }
  1730. func (m *ResponseBeginBlock) XXX_Unmarshal(b []byte) error {
  1731. return m.Unmarshal(b)
  1732. }
  1733. func (m *ResponseBeginBlock) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1734. if deterministic {
  1735. return xxx_messageInfo_ResponseBeginBlock.Marshal(b, m, deterministic)
  1736. } else {
  1737. b = b[:cap(b)]
  1738. n, err := m.MarshalToSizedBuffer(b)
  1739. if err != nil {
  1740. return nil, err
  1741. }
  1742. return b[:n], nil
  1743. }
  1744. }
  1745. func (m *ResponseBeginBlock) XXX_Merge(src proto.Message) {
  1746. xxx_messageInfo_ResponseBeginBlock.Merge(m, src)
  1747. }
  1748. func (m *ResponseBeginBlock) XXX_Size() int {
  1749. return m.Size()
  1750. }
  1751. func (m *ResponseBeginBlock) XXX_DiscardUnknown() {
  1752. xxx_messageInfo_ResponseBeginBlock.DiscardUnknown(m)
  1753. }
  1754. var xxx_messageInfo_ResponseBeginBlock proto.InternalMessageInfo
  1755. func (m *ResponseBeginBlock) GetEvents() []Event {
  1756. if m != nil {
  1757. return m.Events
  1758. }
  1759. return nil
  1760. }
  1761. type ResponseCheckTx struct {
  1762. Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
  1763. Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
  1764. Log string `protobuf:"bytes,3,opt,name=log,proto3" json:"log,omitempty"`
  1765. Info string `protobuf:"bytes,4,opt,name=info,proto3" json:"info,omitempty"`
  1766. GasWanted int64 `protobuf:"varint,5,opt,name=gas_wanted,proto3" json:"gas_wanted,omitempty"`
  1767. GasUsed int64 `protobuf:"varint,6,opt,name=gas_used,proto3" json:"gas_used,omitempty"`
  1768. Events []Event `protobuf:"bytes,7,rep,name=events,proto3" json:"events,omitempty"`
  1769. Codespace string `protobuf:"bytes,8,opt,name=codespace,proto3" json:"codespace,omitempty"`
  1770. }
  1771. func (m *ResponseCheckTx) Reset() { *m = ResponseCheckTx{} }
  1772. func (m *ResponseCheckTx) String() string { return proto.CompactTextString(m) }
  1773. func (*ResponseCheckTx) ProtoMessage() {}
  1774. func (*ResponseCheckTx) Descriptor() ([]byte, []int) {
  1775. return fileDescriptor_252557cfdd89a31a, []int{25}
  1776. }
  1777. func (m *ResponseCheckTx) XXX_Unmarshal(b []byte) error {
  1778. return m.Unmarshal(b)
  1779. }
  1780. func (m *ResponseCheckTx) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1781. if deterministic {
  1782. return xxx_messageInfo_ResponseCheckTx.Marshal(b, m, deterministic)
  1783. } else {
  1784. b = b[:cap(b)]
  1785. n, err := m.MarshalToSizedBuffer(b)
  1786. if err != nil {
  1787. return nil, err
  1788. }
  1789. return b[:n], nil
  1790. }
  1791. }
  1792. func (m *ResponseCheckTx) XXX_Merge(src proto.Message) {
  1793. xxx_messageInfo_ResponseCheckTx.Merge(m, src)
  1794. }
  1795. func (m *ResponseCheckTx) XXX_Size() int {
  1796. return m.Size()
  1797. }
  1798. func (m *ResponseCheckTx) XXX_DiscardUnknown() {
  1799. xxx_messageInfo_ResponseCheckTx.DiscardUnknown(m)
  1800. }
  1801. var xxx_messageInfo_ResponseCheckTx proto.InternalMessageInfo
  1802. func (m *ResponseCheckTx) GetCode() uint32 {
  1803. if m != nil {
  1804. return m.Code
  1805. }
  1806. return 0
  1807. }
  1808. func (m *ResponseCheckTx) GetData() []byte {
  1809. if m != nil {
  1810. return m.Data
  1811. }
  1812. return nil
  1813. }
  1814. func (m *ResponseCheckTx) GetLog() string {
  1815. if m != nil {
  1816. return m.Log
  1817. }
  1818. return ""
  1819. }
  1820. func (m *ResponseCheckTx) GetInfo() string {
  1821. if m != nil {
  1822. return m.Info
  1823. }
  1824. return ""
  1825. }
  1826. func (m *ResponseCheckTx) GetGasWanted() int64 {
  1827. if m != nil {
  1828. return m.GasWanted
  1829. }
  1830. return 0
  1831. }
  1832. func (m *ResponseCheckTx) GetGasUsed() int64 {
  1833. if m != nil {
  1834. return m.GasUsed
  1835. }
  1836. return 0
  1837. }
  1838. func (m *ResponseCheckTx) GetEvents() []Event {
  1839. if m != nil {
  1840. return m.Events
  1841. }
  1842. return nil
  1843. }
  1844. func (m *ResponseCheckTx) GetCodespace() string {
  1845. if m != nil {
  1846. return m.Codespace
  1847. }
  1848. return ""
  1849. }
  1850. type ResponseDeliverTx struct {
  1851. Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
  1852. Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
  1853. Log string `protobuf:"bytes,3,opt,name=log,proto3" json:"log,omitempty"`
  1854. Info string `protobuf:"bytes,4,opt,name=info,proto3" json:"info,omitempty"`
  1855. GasWanted int64 `protobuf:"varint,5,opt,name=gas_wanted,proto3" json:"gas_wanted,omitempty"`
  1856. GasUsed int64 `protobuf:"varint,6,opt,name=gas_used,proto3" json:"gas_used,omitempty"`
  1857. Events []Event `protobuf:"bytes,7,rep,name=events,proto3" json:"events,omitempty"`
  1858. Codespace string `protobuf:"bytes,8,opt,name=codespace,proto3" json:"codespace,omitempty"`
  1859. }
  1860. func (m *ResponseDeliverTx) Reset() { *m = ResponseDeliverTx{} }
  1861. func (m *ResponseDeliverTx) String() string { return proto.CompactTextString(m) }
  1862. func (*ResponseDeliverTx) ProtoMessage() {}
  1863. func (*ResponseDeliverTx) Descriptor() ([]byte, []int) {
  1864. return fileDescriptor_252557cfdd89a31a, []int{26}
  1865. }
  1866. func (m *ResponseDeliverTx) XXX_Unmarshal(b []byte) error {
  1867. return m.Unmarshal(b)
  1868. }
  1869. func (m *ResponseDeliverTx) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1870. if deterministic {
  1871. return xxx_messageInfo_ResponseDeliverTx.Marshal(b, m, deterministic)
  1872. } else {
  1873. b = b[:cap(b)]
  1874. n, err := m.MarshalToSizedBuffer(b)
  1875. if err != nil {
  1876. return nil, err
  1877. }
  1878. return b[:n], nil
  1879. }
  1880. }
  1881. func (m *ResponseDeliverTx) XXX_Merge(src proto.Message) {
  1882. xxx_messageInfo_ResponseDeliverTx.Merge(m, src)
  1883. }
  1884. func (m *ResponseDeliverTx) XXX_Size() int {
  1885. return m.Size()
  1886. }
  1887. func (m *ResponseDeliverTx) XXX_DiscardUnknown() {
  1888. xxx_messageInfo_ResponseDeliverTx.DiscardUnknown(m)
  1889. }
  1890. var xxx_messageInfo_ResponseDeliverTx proto.InternalMessageInfo
  1891. func (m *ResponseDeliverTx) GetCode() uint32 {
  1892. if m != nil {
  1893. return m.Code
  1894. }
  1895. return 0
  1896. }
  1897. func (m *ResponseDeliverTx) GetData() []byte {
  1898. if m != nil {
  1899. return m.Data
  1900. }
  1901. return nil
  1902. }
  1903. func (m *ResponseDeliverTx) GetLog() string {
  1904. if m != nil {
  1905. return m.Log
  1906. }
  1907. return ""
  1908. }
  1909. func (m *ResponseDeliverTx) GetInfo() string {
  1910. if m != nil {
  1911. return m.Info
  1912. }
  1913. return ""
  1914. }
  1915. func (m *ResponseDeliverTx) GetGasWanted() int64 {
  1916. if m != nil {
  1917. return m.GasWanted
  1918. }
  1919. return 0
  1920. }
  1921. func (m *ResponseDeliverTx) GetGasUsed() int64 {
  1922. if m != nil {
  1923. return m.GasUsed
  1924. }
  1925. return 0
  1926. }
  1927. func (m *ResponseDeliverTx) GetEvents() []Event {
  1928. if m != nil {
  1929. return m.Events
  1930. }
  1931. return nil
  1932. }
  1933. func (m *ResponseDeliverTx) GetCodespace() string {
  1934. if m != nil {
  1935. return m.Codespace
  1936. }
  1937. return ""
  1938. }
  1939. type ResponseEndBlock struct {
  1940. ValidatorUpdates []ValidatorUpdate `protobuf:"bytes,1,rep,name=validator_updates,json=validatorUpdates,proto3" json:"validator_updates"`
  1941. ConsensusParamUpdates *ConsensusParams `protobuf:"bytes,2,opt,name=consensus_param_updates,json=consensusParamUpdates,proto3" json:"consensus_param_updates,omitempty"`
  1942. Events []Event `protobuf:"bytes,3,rep,name=events,proto3" json:"events,omitempty"`
  1943. }
  1944. func (m *ResponseEndBlock) Reset() { *m = ResponseEndBlock{} }
  1945. func (m *ResponseEndBlock) String() string { return proto.CompactTextString(m) }
  1946. func (*ResponseEndBlock) ProtoMessage() {}
  1947. func (*ResponseEndBlock) Descriptor() ([]byte, []int) {
  1948. return fileDescriptor_252557cfdd89a31a, []int{27}
  1949. }
  1950. func (m *ResponseEndBlock) XXX_Unmarshal(b []byte) error {
  1951. return m.Unmarshal(b)
  1952. }
  1953. func (m *ResponseEndBlock) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  1954. if deterministic {
  1955. return xxx_messageInfo_ResponseEndBlock.Marshal(b, m, deterministic)
  1956. } else {
  1957. b = b[:cap(b)]
  1958. n, err := m.MarshalToSizedBuffer(b)
  1959. if err != nil {
  1960. return nil, err
  1961. }
  1962. return b[:n], nil
  1963. }
  1964. }
  1965. func (m *ResponseEndBlock) XXX_Merge(src proto.Message) {
  1966. xxx_messageInfo_ResponseEndBlock.Merge(m, src)
  1967. }
  1968. func (m *ResponseEndBlock) XXX_Size() int {
  1969. return m.Size()
  1970. }
  1971. func (m *ResponseEndBlock) XXX_DiscardUnknown() {
  1972. xxx_messageInfo_ResponseEndBlock.DiscardUnknown(m)
  1973. }
  1974. var xxx_messageInfo_ResponseEndBlock proto.InternalMessageInfo
  1975. func (m *ResponseEndBlock) GetValidatorUpdates() []ValidatorUpdate {
  1976. if m != nil {
  1977. return m.ValidatorUpdates
  1978. }
  1979. return nil
  1980. }
  1981. func (m *ResponseEndBlock) GetConsensusParamUpdates() *ConsensusParams {
  1982. if m != nil {
  1983. return m.ConsensusParamUpdates
  1984. }
  1985. return nil
  1986. }
  1987. func (m *ResponseEndBlock) GetEvents() []Event {
  1988. if m != nil {
  1989. return m.Events
  1990. }
  1991. return nil
  1992. }
  1993. type ResponseCommit struct {
  1994. // reserve 1
  1995. Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
  1996. RetainHeight int64 `protobuf:"varint,3,opt,name=retain_height,json=retainHeight,proto3" json:"retain_height,omitempty"`
  1997. }
  1998. func (m *ResponseCommit) Reset() { *m = ResponseCommit{} }
  1999. func (m *ResponseCommit) String() string { return proto.CompactTextString(m) }
  2000. func (*ResponseCommit) ProtoMessage() {}
  2001. func (*ResponseCommit) Descriptor() ([]byte, []int) {
  2002. return fileDescriptor_252557cfdd89a31a, []int{28}
  2003. }
  2004. func (m *ResponseCommit) XXX_Unmarshal(b []byte) error {
  2005. return m.Unmarshal(b)
  2006. }
  2007. func (m *ResponseCommit) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2008. if deterministic {
  2009. return xxx_messageInfo_ResponseCommit.Marshal(b, m, deterministic)
  2010. } else {
  2011. b = b[:cap(b)]
  2012. n, err := m.MarshalToSizedBuffer(b)
  2013. if err != nil {
  2014. return nil, err
  2015. }
  2016. return b[:n], nil
  2017. }
  2018. }
  2019. func (m *ResponseCommit) XXX_Merge(src proto.Message) {
  2020. xxx_messageInfo_ResponseCommit.Merge(m, src)
  2021. }
  2022. func (m *ResponseCommit) XXX_Size() int {
  2023. return m.Size()
  2024. }
  2025. func (m *ResponseCommit) XXX_DiscardUnknown() {
  2026. xxx_messageInfo_ResponseCommit.DiscardUnknown(m)
  2027. }
  2028. var xxx_messageInfo_ResponseCommit proto.InternalMessageInfo
  2029. func (m *ResponseCommit) GetData() []byte {
  2030. if m != nil {
  2031. return m.Data
  2032. }
  2033. return nil
  2034. }
  2035. func (m *ResponseCommit) GetRetainHeight() int64 {
  2036. if m != nil {
  2037. return m.RetainHeight
  2038. }
  2039. return 0
  2040. }
  2041. type ResponseListSnapshots struct {
  2042. Snapshots []*Snapshot `protobuf:"bytes,1,rep,name=snapshots,proto3" json:"snapshots,omitempty"`
  2043. }
  2044. func (m *ResponseListSnapshots) Reset() { *m = ResponseListSnapshots{} }
  2045. func (m *ResponseListSnapshots) String() string { return proto.CompactTextString(m) }
  2046. func (*ResponseListSnapshots) ProtoMessage() {}
  2047. func (*ResponseListSnapshots) Descriptor() ([]byte, []int) {
  2048. return fileDescriptor_252557cfdd89a31a, []int{29}
  2049. }
  2050. func (m *ResponseListSnapshots) XXX_Unmarshal(b []byte) error {
  2051. return m.Unmarshal(b)
  2052. }
  2053. func (m *ResponseListSnapshots) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2054. if deterministic {
  2055. return xxx_messageInfo_ResponseListSnapshots.Marshal(b, m, deterministic)
  2056. } else {
  2057. b = b[:cap(b)]
  2058. n, err := m.MarshalToSizedBuffer(b)
  2059. if err != nil {
  2060. return nil, err
  2061. }
  2062. return b[:n], nil
  2063. }
  2064. }
  2065. func (m *ResponseListSnapshots) XXX_Merge(src proto.Message) {
  2066. xxx_messageInfo_ResponseListSnapshots.Merge(m, src)
  2067. }
  2068. func (m *ResponseListSnapshots) XXX_Size() int {
  2069. return m.Size()
  2070. }
  2071. func (m *ResponseListSnapshots) XXX_DiscardUnknown() {
  2072. xxx_messageInfo_ResponseListSnapshots.DiscardUnknown(m)
  2073. }
  2074. var xxx_messageInfo_ResponseListSnapshots proto.InternalMessageInfo
  2075. func (m *ResponseListSnapshots) GetSnapshots() []*Snapshot {
  2076. if m != nil {
  2077. return m.Snapshots
  2078. }
  2079. return nil
  2080. }
  2081. type ResponseOfferSnapshot struct {
  2082. Result ResponseOfferSnapshot_Result `protobuf:"varint,1,opt,name=result,proto3,enum=tendermint.abci.ResponseOfferSnapshot_Result" json:"result,omitempty"`
  2083. }
  2084. func (m *ResponseOfferSnapshot) Reset() { *m = ResponseOfferSnapshot{} }
  2085. func (m *ResponseOfferSnapshot) String() string { return proto.CompactTextString(m) }
  2086. func (*ResponseOfferSnapshot) ProtoMessage() {}
  2087. func (*ResponseOfferSnapshot) Descriptor() ([]byte, []int) {
  2088. return fileDescriptor_252557cfdd89a31a, []int{30}
  2089. }
  2090. func (m *ResponseOfferSnapshot) XXX_Unmarshal(b []byte) error {
  2091. return m.Unmarshal(b)
  2092. }
  2093. func (m *ResponseOfferSnapshot) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2094. if deterministic {
  2095. return xxx_messageInfo_ResponseOfferSnapshot.Marshal(b, m, deterministic)
  2096. } else {
  2097. b = b[:cap(b)]
  2098. n, err := m.MarshalToSizedBuffer(b)
  2099. if err != nil {
  2100. return nil, err
  2101. }
  2102. return b[:n], nil
  2103. }
  2104. }
  2105. func (m *ResponseOfferSnapshot) XXX_Merge(src proto.Message) {
  2106. xxx_messageInfo_ResponseOfferSnapshot.Merge(m, src)
  2107. }
  2108. func (m *ResponseOfferSnapshot) XXX_Size() int {
  2109. return m.Size()
  2110. }
  2111. func (m *ResponseOfferSnapshot) XXX_DiscardUnknown() {
  2112. xxx_messageInfo_ResponseOfferSnapshot.DiscardUnknown(m)
  2113. }
  2114. var xxx_messageInfo_ResponseOfferSnapshot proto.InternalMessageInfo
  2115. func (m *ResponseOfferSnapshot) GetResult() ResponseOfferSnapshot_Result {
  2116. if m != nil {
  2117. return m.Result
  2118. }
  2119. return ResponseOfferSnapshot_UNKNOWN
  2120. }
  2121. type ResponseLoadSnapshotChunk struct {
  2122. Chunk []byte `protobuf:"bytes,1,opt,name=chunk,proto3" json:"chunk,omitempty"`
  2123. }
  2124. func (m *ResponseLoadSnapshotChunk) Reset() { *m = ResponseLoadSnapshotChunk{} }
  2125. func (m *ResponseLoadSnapshotChunk) String() string { return proto.CompactTextString(m) }
  2126. func (*ResponseLoadSnapshotChunk) ProtoMessage() {}
  2127. func (*ResponseLoadSnapshotChunk) Descriptor() ([]byte, []int) {
  2128. return fileDescriptor_252557cfdd89a31a, []int{31}
  2129. }
  2130. func (m *ResponseLoadSnapshotChunk) XXX_Unmarshal(b []byte) error {
  2131. return m.Unmarshal(b)
  2132. }
  2133. func (m *ResponseLoadSnapshotChunk) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2134. if deterministic {
  2135. return xxx_messageInfo_ResponseLoadSnapshotChunk.Marshal(b, m, deterministic)
  2136. } else {
  2137. b = b[:cap(b)]
  2138. n, err := m.MarshalToSizedBuffer(b)
  2139. if err != nil {
  2140. return nil, err
  2141. }
  2142. return b[:n], nil
  2143. }
  2144. }
  2145. func (m *ResponseLoadSnapshotChunk) XXX_Merge(src proto.Message) {
  2146. xxx_messageInfo_ResponseLoadSnapshotChunk.Merge(m, src)
  2147. }
  2148. func (m *ResponseLoadSnapshotChunk) XXX_Size() int {
  2149. return m.Size()
  2150. }
  2151. func (m *ResponseLoadSnapshotChunk) XXX_DiscardUnknown() {
  2152. xxx_messageInfo_ResponseLoadSnapshotChunk.DiscardUnknown(m)
  2153. }
  2154. var xxx_messageInfo_ResponseLoadSnapshotChunk proto.InternalMessageInfo
  2155. func (m *ResponseLoadSnapshotChunk) GetChunk() []byte {
  2156. if m != nil {
  2157. return m.Chunk
  2158. }
  2159. return nil
  2160. }
  2161. type ResponseApplySnapshotChunk struct {
  2162. Result ResponseApplySnapshotChunk_Result `protobuf:"varint,1,opt,name=result,proto3,enum=tendermint.abci.ResponseApplySnapshotChunk_Result" json:"result,omitempty"`
  2163. RefetchChunks []uint32 `protobuf:"varint,2,rep,packed,name=refetch_chunks,json=refetchChunks,proto3" json:"refetch_chunks,omitempty"`
  2164. RejectSenders []string `protobuf:"bytes,3,rep,name=reject_senders,json=rejectSenders,proto3" json:"reject_senders,omitempty"`
  2165. }
  2166. func (m *ResponseApplySnapshotChunk) Reset() { *m = ResponseApplySnapshotChunk{} }
  2167. func (m *ResponseApplySnapshotChunk) String() string { return proto.CompactTextString(m) }
  2168. func (*ResponseApplySnapshotChunk) ProtoMessage() {}
  2169. func (*ResponseApplySnapshotChunk) Descriptor() ([]byte, []int) {
  2170. return fileDescriptor_252557cfdd89a31a, []int{32}
  2171. }
  2172. func (m *ResponseApplySnapshotChunk) XXX_Unmarshal(b []byte) error {
  2173. return m.Unmarshal(b)
  2174. }
  2175. func (m *ResponseApplySnapshotChunk) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2176. if deterministic {
  2177. return xxx_messageInfo_ResponseApplySnapshotChunk.Marshal(b, m, deterministic)
  2178. } else {
  2179. b = b[:cap(b)]
  2180. n, err := m.MarshalToSizedBuffer(b)
  2181. if err != nil {
  2182. return nil, err
  2183. }
  2184. return b[:n], nil
  2185. }
  2186. }
  2187. func (m *ResponseApplySnapshotChunk) XXX_Merge(src proto.Message) {
  2188. xxx_messageInfo_ResponseApplySnapshotChunk.Merge(m, src)
  2189. }
  2190. func (m *ResponseApplySnapshotChunk) XXX_Size() int {
  2191. return m.Size()
  2192. }
  2193. func (m *ResponseApplySnapshotChunk) XXX_DiscardUnknown() {
  2194. xxx_messageInfo_ResponseApplySnapshotChunk.DiscardUnknown(m)
  2195. }
  2196. var xxx_messageInfo_ResponseApplySnapshotChunk proto.InternalMessageInfo
  2197. func (m *ResponseApplySnapshotChunk) GetResult() ResponseApplySnapshotChunk_Result {
  2198. if m != nil {
  2199. return m.Result
  2200. }
  2201. return ResponseApplySnapshotChunk_UNKNOWN
  2202. }
  2203. func (m *ResponseApplySnapshotChunk) GetRefetchChunks() []uint32 {
  2204. if m != nil {
  2205. return m.RefetchChunks
  2206. }
  2207. return nil
  2208. }
  2209. func (m *ResponseApplySnapshotChunk) GetRejectSenders() []string {
  2210. if m != nil {
  2211. return m.RejectSenders
  2212. }
  2213. return nil
  2214. }
  2215. // ConsensusParams contains all consensus-relevant parameters
  2216. // that can be adjusted by the abci app
  2217. type ConsensusParams struct {
  2218. Block *BlockParams `protobuf:"bytes,1,opt,name=block,proto3" json:"block,omitempty"`
  2219. Evidence *types1.EvidenceParams `protobuf:"bytes,2,opt,name=evidence,proto3" json:"evidence,omitempty"`
  2220. Validator *types1.ValidatorParams `protobuf:"bytes,3,opt,name=validator,proto3" json:"validator,omitempty"`
  2221. Version *types1.VersionParams `protobuf:"bytes,4,opt,name=version,proto3" json:"version,omitempty"`
  2222. }
  2223. func (m *ConsensusParams) Reset() { *m = ConsensusParams{} }
  2224. func (m *ConsensusParams) String() string { return proto.CompactTextString(m) }
  2225. func (*ConsensusParams) ProtoMessage() {}
  2226. func (*ConsensusParams) Descriptor() ([]byte, []int) {
  2227. return fileDescriptor_252557cfdd89a31a, []int{33}
  2228. }
  2229. func (m *ConsensusParams) XXX_Unmarshal(b []byte) error {
  2230. return m.Unmarshal(b)
  2231. }
  2232. func (m *ConsensusParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2233. if deterministic {
  2234. return xxx_messageInfo_ConsensusParams.Marshal(b, m, deterministic)
  2235. } else {
  2236. b = b[:cap(b)]
  2237. n, err := m.MarshalToSizedBuffer(b)
  2238. if err != nil {
  2239. return nil, err
  2240. }
  2241. return b[:n], nil
  2242. }
  2243. }
  2244. func (m *ConsensusParams) XXX_Merge(src proto.Message) {
  2245. xxx_messageInfo_ConsensusParams.Merge(m, src)
  2246. }
  2247. func (m *ConsensusParams) XXX_Size() int {
  2248. return m.Size()
  2249. }
  2250. func (m *ConsensusParams) XXX_DiscardUnknown() {
  2251. xxx_messageInfo_ConsensusParams.DiscardUnknown(m)
  2252. }
  2253. var xxx_messageInfo_ConsensusParams proto.InternalMessageInfo
  2254. func (m *ConsensusParams) GetBlock() *BlockParams {
  2255. if m != nil {
  2256. return m.Block
  2257. }
  2258. return nil
  2259. }
  2260. func (m *ConsensusParams) GetEvidence() *types1.EvidenceParams {
  2261. if m != nil {
  2262. return m.Evidence
  2263. }
  2264. return nil
  2265. }
  2266. func (m *ConsensusParams) GetValidator() *types1.ValidatorParams {
  2267. if m != nil {
  2268. return m.Validator
  2269. }
  2270. return nil
  2271. }
  2272. func (m *ConsensusParams) GetVersion() *types1.VersionParams {
  2273. if m != nil {
  2274. return m.Version
  2275. }
  2276. return nil
  2277. }
  2278. // BlockParams contains limits on the block size.
  2279. type BlockParams struct {
  2280. // Note: must be greater than 0
  2281. MaxBytes int64 `protobuf:"varint,1,opt,name=max_bytes,json=maxBytes,proto3" json:"max_bytes,omitempty"`
  2282. // Note: must be greater or equal to -1
  2283. MaxGas int64 `protobuf:"varint,2,opt,name=max_gas,json=maxGas,proto3" json:"max_gas,omitempty"`
  2284. }
  2285. func (m *BlockParams) Reset() { *m = BlockParams{} }
  2286. func (m *BlockParams) String() string { return proto.CompactTextString(m) }
  2287. func (*BlockParams) ProtoMessage() {}
  2288. func (*BlockParams) Descriptor() ([]byte, []int) {
  2289. return fileDescriptor_252557cfdd89a31a, []int{34}
  2290. }
  2291. func (m *BlockParams) XXX_Unmarshal(b []byte) error {
  2292. return m.Unmarshal(b)
  2293. }
  2294. func (m *BlockParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2295. if deterministic {
  2296. return xxx_messageInfo_BlockParams.Marshal(b, m, deterministic)
  2297. } else {
  2298. b = b[:cap(b)]
  2299. n, err := m.MarshalToSizedBuffer(b)
  2300. if err != nil {
  2301. return nil, err
  2302. }
  2303. return b[:n], nil
  2304. }
  2305. }
  2306. func (m *BlockParams) XXX_Merge(src proto.Message) {
  2307. xxx_messageInfo_BlockParams.Merge(m, src)
  2308. }
  2309. func (m *BlockParams) XXX_Size() int {
  2310. return m.Size()
  2311. }
  2312. func (m *BlockParams) XXX_DiscardUnknown() {
  2313. xxx_messageInfo_BlockParams.DiscardUnknown(m)
  2314. }
  2315. var xxx_messageInfo_BlockParams proto.InternalMessageInfo
  2316. func (m *BlockParams) GetMaxBytes() int64 {
  2317. if m != nil {
  2318. return m.MaxBytes
  2319. }
  2320. return 0
  2321. }
  2322. func (m *BlockParams) GetMaxGas() int64 {
  2323. if m != nil {
  2324. return m.MaxGas
  2325. }
  2326. return 0
  2327. }
  2328. type LastCommitInfo struct {
  2329. Round int32 `protobuf:"varint,1,opt,name=round,proto3" json:"round,omitempty"`
  2330. Votes []VoteInfo `protobuf:"bytes,2,rep,name=votes,proto3" json:"votes"`
  2331. }
  2332. func (m *LastCommitInfo) Reset() { *m = LastCommitInfo{} }
  2333. func (m *LastCommitInfo) String() string { return proto.CompactTextString(m) }
  2334. func (*LastCommitInfo) ProtoMessage() {}
  2335. func (*LastCommitInfo) Descriptor() ([]byte, []int) {
  2336. return fileDescriptor_252557cfdd89a31a, []int{35}
  2337. }
  2338. func (m *LastCommitInfo) XXX_Unmarshal(b []byte) error {
  2339. return m.Unmarshal(b)
  2340. }
  2341. func (m *LastCommitInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2342. if deterministic {
  2343. return xxx_messageInfo_LastCommitInfo.Marshal(b, m, deterministic)
  2344. } else {
  2345. b = b[:cap(b)]
  2346. n, err := m.MarshalToSizedBuffer(b)
  2347. if err != nil {
  2348. return nil, err
  2349. }
  2350. return b[:n], nil
  2351. }
  2352. }
  2353. func (m *LastCommitInfo) XXX_Merge(src proto.Message) {
  2354. xxx_messageInfo_LastCommitInfo.Merge(m, src)
  2355. }
  2356. func (m *LastCommitInfo) XXX_Size() int {
  2357. return m.Size()
  2358. }
  2359. func (m *LastCommitInfo) XXX_DiscardUnknown() {
  2360. xxx_messageInfo_LastCommitInfo.DiscardUnknown(m)
  2361. }
  2362. var xxx_messageInfo_LastCommitInfo proto.InternalMessageInfo
  2363. func (m *LastCommitInfo) GetRound() int32 {
  2364. if m != nil {
  2365. return m.Round
  2366. }
  2367. return 0
  2368. }
  2369. func (m *LastCommitInfo) GetVotes() []VoteInfo {
  2370. if m != nil {
  2371. return m.Votes
  2372. }
  2373. return nil
  2374. }
  2375. // Event allows application developers to attach additional information to
  2376. // ResponseBeginBlock, ResponseEndBlock, ResponseCheckTx and ResponseDeliverTx.
  2377. // Later, transactions may be queried using these events.
  2378. type Event struct {
  2379. Type string `protobuf:"bytes,1,opt,name=type,proto3" json:"type,omitempty"`
  2380. Attributes []EventAttribute `protobuf:"bytes,2,rep,name=attributes,proto3" json:"attributes,omitempty"`
  2381. }
  2382. func (m *Event) Reset() { *m = Event{} }
  2383. func (m *Event) String() string { return proto.CompactTextString(m) }
  2384. func (*Event) ProtoMessage() {}
  2385. func (*Event) Descriptor() ([]byte, []int) {
  2386. return fileDescriptor_252557cfdd89a31a, []int{36}
  2387. }
  2388. func (m *Event) XXX_Unmarshal(b []byte) error {
  2389. return m.Unmarshal(b)
  2390. }
  2391. func (m *Event) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2392. if deterministic {
  2393. return xxx_messageInfo_Event.Marshal(b, m, deterministic)
  2394. } else {
  2395. b = b[:cap(b)]
  2396. n, err := m.MarshalToSizedBuffer(b)
  2397. if err != nil {
  2398. return nil, err
  2399. }
  2400. return b[:n], nil
  2401. }
  2402. }
  2403. func (m *Event) XXX_Merge(src proto.Message) {
  2404. xxx_messageInfo_Event.Merge(m, src)
  2405. }
  2406. func (m *Event) XXX_Size() int {
  2407. return m.Size()
  2408. }
  2409. func (m *Event) XXX_DiscardUnknown() {
  2410. xxx_messageInfo_Event.DiscardUnknown(m)
  2411. }
  2412. var xxx_messageInfo_Event proto.InternalMessageInfo
  2413. func (m *Event) GetType() string {
  2414. if m != nil {
  2415. return m.Type
  2416. }
  2417. return ""
  2418. }
  2419. func (m *Event) GetAttributes() []EventAttribute {
  2420. if m != nil {
  2421. return m.Attributes
  2422. }
  2423. return nil
  2424. }
  2425. // EventAttribute is a single key-value pair, associated with an event.
  2426. type EventAttribute struct {
  2427. Key []byte `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
  2428. Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
  2429. Index bool `protobuf:"varint,3,opt,name=index,proto3" json:"index,omitempty"`
  2430. }
  2431. func (m *EventAttribute) Reset() { *m = EventAttribute{} }
  2432. func (m *EventAttribute) String() string { return proto.CompactTextString(m) }
  2433. func (*EventAttribute) ProtoMessage() {}
  2434. func (*EventAttribute) Descriptor() ([]byte, []int) {
  2435. return fileDescriptor_252557cfdd89a31a, []int{37}
  2436. }
  2437. func (m *EventAttribute) XXX_Unmarshal(b []byte) error {
  2438. return m.Unmarshal(b)
  2439. }
  2440. func (m *EventAttribute) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2441. if deterministic {
  2442. return xxx_messageInfo_EventAttribute.Marshal(b, m, deterministic)
  2443. } else {
  2444. b = b[:cap(b)]
  2445. n, err := m.MarshalToSizedBuffer(b)
  2446. if err != nil {
  2447. return nil, err
  2448. }
  2449. return b[:n], nil
  2450. }
  2451. }
  2452. func (m *EventAttribute) XXX_Merge(src proto.Message) {
  2453. xxx_messageInfo_EventAttribute.Merge(m, src)
  2454. }
  2455. func (m *EventAttribute) XXX_Size() int {
  2456. return m.Size()
  2457. }
  2458. func (m *EventAttribute) XXX_DiscardUnknown() {
  2459. xxx_messageInfo_EventAttribute.DiscardUnknown(m)
  2460. }
  2461. var xxx_messageInfo_EventAttribute proto.InternalMessageInfo
  2462. func (m *EventAttribute) GetKey() []byte {
  2463. if m != nil {
  2464. return m.Key
  2465. }
  2466. return nil
  2467. }
  2468. func (m *EventAttribute) GetValue() []byte {
  2469. if m != nil {
  2470. return m.Value
  2471. }
  2472. return nil
  2473. }
  2474. func (m *EventAttribute) GetIndex() bool {
  2475. if m != nil {
  2476. return m.Index
  2477. }
  2478. return false
  2479. }
  2480. // TxResult contains results of executing the transaction.
  2481. //
  2482. // One usage is indexing transaction results.
  2483. type TxResult struct {
  2484. Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"`
  2485. Index uint32 `protobuf:"varint,2,opt,name=index,proto3" json:"index,omitempty"`
  2486. Tx []byte `protobuf:"bytes,3,opt,name=tx,proto3" json:"tx,omitempty"`
  2487. Result ResponseDeliverTx `protobuf:"bytes,4,opt,name=result,proto3" json:"result"`
  2488. }
  2489. func (m *TxResult) Reset() { *m = TxResult{} }
  2490. func (m *TxResult) String() string { return proto.CompactTextString(m) }
  2491. func (*TxResult) ProtoMessage() {}
  2492. func (*TxResult) Descriptor() ([]byte, []int) {
  2493. return fileDescriptor_252557cfdd89a31a, []int{38}
  2494. }
  2495. func (m *TxResult) XXX_Unmarshal(b []byte) error {
  2496. return m.Unmarshal(b)
  2497. }
  2498. func (m *TxResult) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2499. if deterministic {
  2500. return xxx_messageInfo_TxResult.Marshal(b, m, deterministic)
  2501. } else {
  2502. b = b[:cap(b)]
  2503. n, err := m.MarshalToSizedBuffer(b)
  2504. if err != nil {
  2505. return nil, err
  2506. }
  2507. return b[:n], nil
  2508. }
  2509. }
  2510. func (m *TxResult) XXX_Merge(src proto.Message) {
  2511. xxx_messageInfo_TxResult.Merge(m, src)
  2512. }
  2513. func (m *TxResult) XXX_Size() int {
  2514. return m.Size()
  2515. }
  2516. func (m *TxResult) XXX_DiscardUnknown() {
  2517. xxx_messageInfo_TxResult.DiscardUnknown(m)
  2518. }
  2519. var xxx_messageInfo_TxResult proto.InternalMessageInfo
  2520. func (m *TxResult) GetHeight() int64 {
  2521. if m != nil {
  2522. return m.Height
  2523. }
  2524. return 0
  2525. }
  2526. func (m *TxResult) GetIndex() uint32 {
  2527. if m != nil {
  2528. return m.Index
  2529. }
  2530. return 0
  2531. }
  2532. func (m *TxResult) GetTx() []byte {
  2533. if m != nil {
  2534. return m.Tx
  2535. }
  2536. return nil
  2537. }
  2538. func (m *TxResult) GetResult() ResponseDeliverTx {
  2539. if m != nil {
  2540. return m.Result
  2541. }
  2542. return ResponseDeliverTx{}
  2543. }
  2544. // Validator
  2545. type Validator struct {
  2546. Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
  2547. // PubKey pub_key = 2 [(gogoproto.nullable)=false];
  2548. Power int64 `protobuf:"varint,3,opt,name=power,proto3" json:"power,omitempty"`
  2549. }
  2550. func (m *Validator) Reset() { *m = Validator{} }
  2551. func (m *Validator) String() string { return proto.CompactTextString(m) }
  2552. func (*Validator) ProtoMessage() {}
  2553. func (*Validator) Descriptor() ([]byte, []int) {
  2554. return fileDescriptor_252557cfdd89a31a, []int{39}
  2555. }
  2556. func (m *Validator) XXX_Unmarshal(b []byte) error {
  2557. return m.Unmarshal(b)
  2558. }
  2559. func (m *Validator) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2560. if deterministic {
  2561. return xxx_messageInfo_Validator.Marshal(b, m, deterministic)
  2562. } else {
  2563. b = b[:cap(b)]
  2564. n, err := m.MarshalToSizedBuffer(b)
  2565. if err != nil {
  2566. return nil, err
  2567. }
  2568. return b[:n], nil
  2569. }
  2570. }
  2571. func (m *Validator) XXX_Merge(src proto.Message) {
  2572. xxx_messageInfo_Validator.Merge(m, src)
  2573. }
  2574. func (m *Validator) XXX_Size() int {
  2575. return m.Size()
  2576. }
  2577. func (m *Validator) XXX_DiscardUnknown() {
  2578. xxx_messageInfo_Validator.DiscardUnknown(m)
  2579. }
  2580. var xxx_messageInfo_Validator proto.InternalMessageInfo
  2581. func (m *Validator) GetAddress() []byte {
  2582. if m != nil {
  2583. return m.Address
  2584. }
  2585. return nil
  2586. }
  2587. func (m *Validator) GetPower() int64 {
  2588. if m != nil {
  2589. return m.Power
  2590. }
  2591. return 0
  2592. }
  2593. // ValidatorUpdate
  2594. type ValidatorUpdate struct {
  2595. PubKey crypto.PublicKey `protobuf:"bytes,1,opt,name=pub_key,json=pubKey,proto3" json:"pub_key"`
  2596. Power int64 `protobuf:"varint,2,opt,name=power,proto3" json:"power,omitempty"`
  2597. }
  2598. func (m *ValidatorUpdate) Reset() { *m = ValidatorUpdate{} }
  2599. func (m *ValidatorUpdate) String() string { return proto.CompactTextString(m) }
  2600. func (*ValidatorUpdate) ProtoMessage() {}
  2601. func (*ValidatorUpdate) Descriptor() ([]byte, []int) {
  2602. return fileDescriptor_252557cfdd89a31a, []int{40}
  2603. }
  2604. func (m *ValidatorUpdate) XXX_Unmarshal(b []byte) error {
  2605. return m.Unmarshal(b)
  2606. }
  2607. func (m *ValidatorUpdate) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2608. if deterministic {
  2609. return xxx_messageInfo_ValidatorUpdate.Marshal(b, m, deterministic)
  2610. } else {
  2611. b = b[:cap(b)]
  2612. n, err := m.MarshalToSizedBuffer(b)
  2613. if err != nil {
  2614. return nil, err
  2615. }
  2616. return b[:n], nil
  2617. }
  2618. }
  2619. func (m *ValidatorUpdate) XXX_Merge(src proto.Message) {
  2620. xxx_messageInfo_ValidatorUpdate.Merge(m, src)
  2621. }
  2622. func (m *ValidatorUpdate) XXX_Size() int {
  2623. return m.Size()
  2624. }
  2625. func (m *ValidatorUpdate) XXX_DiscardUnknown() {
  2626. xxx_messageInfo_ValidatorUpdate.DiscardUnknown(m)
  2627. }
  2628. var xxx_messageInfo_ValidatorUpdate proto.InternalMessageInfo
  2629. func (m *ValidatorUpdate) GetPubKey() crypto.PublicKey {
  2630. if m != nil {
  2631. return m.PubKey
  2632. }
  2633. return crypto.PublicKey{}
  2634. }
  2635. func (m *ValidatorUpdate) GetPower() int64 {
  2636. if m != nil {
  2637. return m.Power
  2638. }
  2639. return 0
  2640. }
  2641. // VoteInfo
  2642. type VoteInfo struct {
  2643. Validator Validator `protobuf:"bytes,1,opt,name=validator,proto3" json:"validator"`
  2644. SignedLastBlock bool `protobuf:"varint,2,opt,name=signed_last_block,json=signedLastBlock,proto3" json:"signed_last_block,omitempty"`
  2645. }
  2646. func (m *VoteInfo) Reset() { *m = VoteInfo{} }
  2647. func (m *VoteInfo) String() string { return proto.CompactTextString(m) }
  2648. func (*VoteInfo) ProtoMessage() {}
  2649. func (*VoteInfo) Descriptor() ([]byte, []int) {
  2650. return fileDescriptor_252557cfdd89a31a, []int{41}
  2651. }
  2652. func (m *VoteInfo) XXX_Unmarshal(b []byte) error {
  2653. return m.Unmarshal(b)
  2654. }
  2655. func (m *VoteInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2656. if deterministic {
  2657. return xxx_messageInfo_VoteInfo.Marshal(b, m, deterministic)
  2658. } else {
  2659. b = b[:cap(b)]
  2660. n, err := m.MarshalToSizedBuffer(b)
  2661. if err != nil {
  2662. return nil, err
  2663. }
  2664. return b[:n], nil
  2665. }
  2666. }
  2667. func (m *VoteInfo) XXX_Merge(src proto.Message) {
  2668. xxx_messageInfo_VoteInfo.Merge(m, src)
  2669. }
  2670. func (m *VoteInfo) XXX_Size() int {
  2671. return m.Size()
  2672. }
  2673. func (m *VoteInfo) XXX_DiscardUnknown() {
  2674. xxx_messageInfo_VoteInfo.DiscardUnknown(m)
  2675. }
  2676. var xxx_messageInfo_VoteInfo proto.InternalMessageInfo
  2677. func (m *VoteInfo) GetValidator() Validator {
  2678. if m != nil {
  2679. return m.Validator
  2680. }
  2681. return Validator{}
  2682. }
  2683. func (m *VoteInfo) GetSignedLastBlock() bool {
  2684. if m != nil {
  2685. return m.SignedLastBlock
  2686. }
  2687. return false
  2688. }
  2689. type Evidence struct {
  2690. Type EvidenceType `protobuf:"varint,1,opt,name=type,proto3,enum=tendermint.abci.EvidenceType" json:"type,omitempty"`
  2691. // The offending validator
  2692. Validator Validator `protobuf:"bytes,2,opt,name=validator,proto3" json:"validator"`
  2693. // The height when the offense occurred
  2694. Height int64 `protobuf:"varint,3,opt,name=height,proto3" json:"height,omitempty"`
  2695. // The corresponding time where the offense occurred
  2696. Time time.Time `protobuf:"bytes,4,opt,name=time,proto3,stdtime" json:"time"`
  2697. // Total voting power of the validator set in case the ABCI application does
  2698. // not store historical validators.
  2699. // https://github.com/tendermint/tendermint/issues/4581
  2700. TotalVotingPower int64 `protobuf:"varint,5,opt,name=total_voting_power,json=totalVotingPower,proto3" json:"total_voting_power,omitempty"`
  2701. }
  2702. func (m *Evidence) Reset() { *m = Evidence{} }
  2703. func (m *Evidence) String() string { return proto.CompactTextString(m) }
  2704. func (*Evidence) ProtoMessage() {}
  2705. func (*Evidence) Descriptor() ([]byte, []int) {
  2706. return fileDescriptor_252557cfdd89a31a, []int{42}
  2707. }
  2708. func (m *Evidence) XXX_Unmarshal(b []byte) error {
  2709. return m.Unmarshal(b)
  2710. }
  2711. func (m *Evidence) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2712. if deterministic {
  2713. return xxx_messageInfo_Evidence.Marshal(b, m, deterministic)
  2714. } else {
  2715. b = b[:cap(b)]
  2716. n, err := m.MarshalToSizedBuffer(b)
  2717. if err != nil {
  2718. return nil, err
  2719. }
  2720. return b[:n], nil
  2721. }
  2722. }
  2723. func (m *Evidence) XXX_Merge(src proto.Message) {
  2724. xxx_messageInfo_Evidence.Merge(m, src)
  2725. }
  2726. func (m *Evidence) XXX_Size() int {
  2727. return m.Size()
  2728. }
  2729. func (m *Evidence) XXX_DiscardUnknown() {
  2730. xxx_messageInfo_Evidence.DiscardUnknown(m)
  2731. }
  2732. var xxx_messageInfo_Evidence proto.InternalMessageInfo
  2733. func (m *Evidence) GetType() EvidenceType {
  2734. if m != nil {
  2735. return m.Type
  2736. }
  2737. return EvidenceType_UNKNOWN
  2738. }
  2739. func (m *Evidence) GetValidator() Validator {
  2740. if m != nil {
  2741. return m.Validator
  2742. }
  2743. return Validator{}
  2744. }
  2745. func (m *Evidence) GetHeight() int64 {
  2746. if m != nil {
  2747. return m.Height
  2748. }
  2749. return 0
  2750. }
  2751. func (m *Evidence) GetTime() time.Time {
  2752. if m != nil {
  2753. return m.Time
  2754. }
  2755. return time.Time{}
  2756. }
  2757. func (m *Evidence) GetTotalVotingPower() int64 {
  2758. if m != nil {
  2759. return m.TotalVotingPower
  2760. }
  2761. return 0
  2762. }
  2763. type Snapshot struct {
  2764. Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"`
  2765. Format uint32 `protobuf:"varint,2,opt,name=format,proto3" json:"format,omitempty"`
  2766. Chunks uint32 `protobuf:"varint,3,opt,name=chunks,proto3" json:"chunks,omitempty"`
  2767. Hash []byte `protobuf:"bytes,4,opt,name=hash,proto3" json:"hash,omitempty"`
  2768. Metadata []byte `protobuf:"bytes,5,opt,name=metadata,proto3" json:"metadata,omitempty"`
  2769. }
  2770. func (m *Snapshot) Reset() { *m = Snapshot{} }
  2771. func (m *Snapshot) String() string { return proto.CompactTextString(m) }
  2772. func (*Snapshot) ProtoMessage() {}
  2773. func (*Snapshot) Descriptor() ([]byte, []int) {
  2774. return fileDescriptor_252557cfdd89a31a, []int{43}
  2775. }
  2776. func (m *Snapshot) XXX_Unmarshal(b []byte) error {
  2777. return m.Unmarshal(b)
  2778. }
  2779. func (m *Snapshot) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
  2780. if deterministic {
  2781. return xxx_messageInfo_Snapshot.Marshal(b, m, deterministic)
  2782. } else {
  2783. b = b[:cap(b)]
  2784. n, err := m.MarshalToSizedBuffer(b)
  2785. if err != nil {
  2786. return nil, err
  2787. }
  2788. return b[:n], nil
  2789. }
  2790. }
  2791. func (m *Snapshot) XXX_Merge(src proto.Message) {
  2792. xxx_messageInfo_Snapshot.Merge(m, src)
  2793. }
  2794. func (m *Snapshot) XXX_Size() int {
  2795. return m.Size()
  2796. }
  2797. func (m *Snapshot) XXX_DiscardUnknown() {
  2798. xxx_messageInfo_Snapshot.DiscardUnknown(m)
  2799. }
  2800. var xxx_messageInfo_Snapshot proto.InternalMessageInfo
  2801. func (m *Snapshot) GetHeight() uint64 {
  2802. if m != nil {
  2803. return m.Height
  2804. }
  2805. return 0
  2806. }
  2807. func (m *Snapshot) GetFormat() uint32 {
  2808. if m != nil {
  2809. return m.Format
  2810. }
  2811. return 0
  2812. }
  2813. func (m *Snapshot) GetChunks() uint32 {
  2814. if m != nil {
  2815. return m.Chunks
  2816. }
  2817. return 0
  2818. }
  2819. func (m *Snapshot) GetHash() []byte {
  2820. if m != nil {
  2821. return m.Hash
  2822. }
  2823. return nil
  2824. }
  2825. func (m *Snapshot) GetMetadata() []byte {
  2826. if m != nil {
  2827. return m.Metadata
  2828. }
  2829. return nil
  2830. }
  2831. func init() {
  2832. proto.RegisterEnum("tendermint.abci.CheckTxType", CheckTxType_name, CheckTxType_value)
  2833. proto.RegisterEnum("tendermint.abci.EvidenceType", EvidenceType_name, EvidenceType_value)
  2834. proto.RegisterEnum("tendermint.abci.ResponseOfferSnapshot_Result", ResponseOfferSnapshot_Result_name, ResponseOfferSnapshot_Result_value)
  2835. proto.RegisterEnum("tendermint.abci.ResponseApplySnapshotChunk_Result", ResponseApplySnapshotChunk_Result_name, ResponseApplySnapshotChunk_Result_value)
  2836. proto.RegisterType((*Request)(nil), "tendermint.abci.Request")
  2837. proto.RegisterType((*RequestEcho)(nil), "tendermint.abci.RequestEcho")
  2838. proto.RegisterType((*RequestFlush)(nil), "tendermint.abci.RequestFlush")
  2839. proto.RegisterType((*RequestInfo)(nil), "tendermint.abci.RequestInfo")
  2840. proto.RegisterType((*RequestSetOption)(nil), "tendermint.abci.RequestSetOption")
  2841. proto.RegisterType((*RequestInitChain)(nil), "tendermint.abci.RequestInitChain")
  2842. proto.RegisterType((*RequestQuery)(nil), "tendermint.abci.RequestQuery")
  2843. proto.RegisterType((*RequestBeginBlock)(nil), "tendermint.abci.RequestBeginBlock")
  2844. proto.RegisterType((*RequestCheckTx)(nil), "tendermint.abci.RequestCheckTx")
  2845. proto.RegisterType((*RequestDeliverTx)(nil), "tendermint.abci.RequestDeliverTx")
  2846. proto.RegisterType((*RequestEndBlock)(nil), "tendermint.abci.RequestEndBlock")
  2847. proto.RegisterType((*RequestCommit)(nil), "tendermint.abci.RequestCommit")
  2848. proto.RegisterType((*RequestListSnapshots)(nil), "tendermint.abci.RequestListSnapshots")
  2849. proto.RegisterType((*RequestOfferSnapshot)(nil), "tendermint.abci.RequestOfferSnapshot")
  2850. proto.RegisterType((*RequestLoadSnapshotChunk)(nil), "tendermint.abci.RequestLoadSnapshotChunk")
  2851. proto.RegisterType((*RequestApplySnapshotChunk)(nil), "tendermint.abci.RequestApplySnapshotChunk")
  2852. proto.RegisterType((*Response)(nil), "tendermint.abci.Response")
  2853. proto.RegisterType((*ResponseException)(nil), "tendermint.abci.ResponseException")
  2854. proto.RegisterType((*ResponseEcho)(nil), "tendermint.abci.ResponseEcho")
  2855. proto.RegisterType((*ResponseFlush)(nil), "tendermint.abci.ResponseFlush")
  2856. proto.RegisterType((*ResponseInfo)(nil), "tendermint.abci.ResponseInfo")
  2857. proto.RegisterType((*ResponseSetOption)(nil), "tendermint.abci.ResponseSetOption")
  2858. proto.RegisterType((*ResponseInitChain)(nil), "tendermint.abci.ResponseInitChain")
  2859. proto.RegisterType((*ResponseQuery)(nil), "tendermint.abci.ResponseQuery")
  2860. proto.RegisterType((*ResponseBeginBlock)(nil), "tendermint.abci.ResponseBeginBlock")
  2861. proto.RegisterType((*ResponseCheckTx)(nil), "tendermint.abci.ResponseCheckTx")
  2862. proto.RegisterType((*ResponseDeliverTx)(nil), "tendermint.abci.ResponseDeliverTx")
  2863. proto.RegisterType((*ResponseEndBlock)(nil), "tendermint.abci.ResponseEndBlock")
  2864. proto.RegisterType((*ResponseCommit)(nil), "tendermint.abci.ResponseCommit")
  2865. proto.RegisterType((*ResponseListSnapshots)(nil), "tendermint.abci.ResponseListSnapshots")
  2866. proto.RegisterType((*ResponseOfferSnapshot)(nil), "tendermint.abci.ResponseOfferSnapshot")
  2867. proto.RegisterType((*ResponseLoadSnapshotChunk)(nil), "tendermint.abci.ResponseLoadSnapshotChunk")
  2868. proto.RegisterType((*ResponseApplySnapshotChunk)(nil), "tendermint.abci.ResponseApplySnapshotChunk")
  2869. proto.RegisterType((*ConsensusParams)(nil), "tendermint.abci.ConsensusParams")
  2870. proto.RegisterType((*BlockParams)(nil), "tendermint.abci.BlockParams")
  2871. proto.RegisterType((*LastCommitInfo)(nil), "tendermint.abci.LastCommitInfo")
  2872. proto.RegisterType((*Event)(nil), "tendermint.abci.Event")
  2873. proto.RegisterType((*EventAttribute)(nil), "tendermint.abci.EventAttribute")
  2874. proto.RegisterType((*TxResult)(nil), "tendermint.abci.TxResult")
  2875. proto.RegisterType((*Validator)(nil), "tendermint.abci.Validator")
  2876. proto.RegisterType((*ValidatorUpdate)(nil), "tendermint.abci.ValidatorUpdate")
  2877. proto.RegisterType((*VoteInfo)(nil), "tendermint.abci.VoteInfo")
  2878. proto.RegisterType((*Evidence)(nil), "tendermint.abci.Evidence")
  2879. proto.RegisterType((*Snapshot)(nil), "tendermint.abci.Snapshot")
  2880. }
  2881. func init() { proto.RegisterFile("tendermint/abci/types.proto", fileDescriptor_252557cfdd89a31a) }
  2882. var fileDescriptor_252557cfdd89a31a = []byte{
  2883. // 2741 bytes of a gzipped FileDescriptorProto
  2884. 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe4, 0x5a, 0x4b, 0x73, 0x1b, 0xc7,
  2885. 0x11, 0xc6, 0xfb, 0xd1, 0x24, 0x1e, 0x1c, 0xd1, 0x12, 0xb4, 0x92, 0x48, 0x79, 0x55, 0x72, 0x2c,
  2886. 0xd9, 0x26, 0x63, 0xaa, 0xa4, 0x48, 0xb1, 0x13, 0x9b, 0x80, 0x20, 0x83, 0x26, 0x4d, 0x30, 0x4b,
  2887. 0x48, 0xce, 0xcb, 0x5a, 0x2f, 0xb0, 0x43, 0x60, 0x2d, 0x60, 0x77, 0x8d, 0x1d, 0x50, 0xa4, 0x8f,
  2888. 0x71, 0x72, 0x51, 0x2e, 0xce, 0x2d, 0x17, 0xff, 0x8f, 0x9c, 0x72, 0xc9, 0xc5, 0x55, 0xb9, 0xf8,
  2889. 0x98, 0x93, 0x93, 0x92, 0x2a, 0x97, 0xfc, 0x81, 0x9c, 0x52, 0x49, 0xcd, 0x63, 0x5f, 0x00, 0x16,
  2890. 0x00, 0xed, 0xdc, 0x7c, 0x9b, 0x99, 0xed, 0xee, 0xc5, 0xf4, 0x4e, 0x7f, 0xfd, 0x75, 0x0f, 0xe0,
  2891. 0x12, 0xc1, 0xa6, 0x8e, 0x87, 0x03, 0xc3, 0x24, 0x9b, 0x5a, 0xbb, 0x63, 0x6c, 0x92, 0x53, 0x1b,
  2892. 0x3b, 0x1b, 0xf6, 0xd0, 0x22, 0x16, 0x2a, 0xf9, 0x0f, 0x37, 0xe8, 0x43, 0xe9, 0x4a, 0x40, 0xba,
  2893. 0x33, 0x3c, 0xb5, 0x89, 0xb5, 0x69, 0x0f, 0x2d, 0xeb, 0x88, 0xcb, 0x4b, 0x97, 0x03, 0x8f, 0x99,
  2894. 0x9d, 0xa0, 0xb5, 0xd0, 0x53, 0xa1, 0xfc, 0x04, 0x9f, 0xba, 0x4f, 0xaf, 0x4c, 0xe8, 0xda, 0xda,
  2895. 0x50, 0x1b, 0xb8, 0x8f, 0xd7, 0xbb, 0x96, 0xd5, 0xed, 0xe3, 0x4d, 0x36, 0x6b, 0x8f, 0x8e, 0x36,
  2896. 0x89, 0x31, 0xc0, 0x0e, 0xd1, 0x06, 0xb6, 0x10, 0x58, 0xed, 0x5a, 0x5d, 0x8b, 0x0d, 0x37, 0xe9,
  2897. 0x88, 0xaf, 0xca, 0x7f, 0xc8, 0x41, 0x56, 0xc1, 0x9f, 0x8e, 0xb0, 0x43, 0xd0, 0x16, 0xa4, 0x70,
  2898. 0xa7, 0x67, 0x55, 0xe2, 0x57, 0xe3, 0xaf, 0x2e, 0x6d, 0x5d, 0xde, 0x18, 0xdb, 0xdc, 0x86, 0x90,
  2899. 0xab, 0x77, 0x7a, 0x56, 0x23, 0xa6, 0x30, 0x59, 0x74, 0x1b, 0xd2, 0x47, 0xfd, 0x91, 0xd3, 0xab,
  2900. 0x24, 0x98, 0xd2, 0x95, 0x28, 0xa5, 0x07, 0x54, 0xa8, 0x11, 0x53, 0xb8, 0x34, 0x7d, 0x95, 0x61,
  2901. 0x1e, 0x59, 0x95, 0xe4, 0xec, 0x57, 0xed, 0x98, 0x47, 0xec, 0x55, 0x54, 0x16, 0x55, 0x01, 0x1c,
  2902. 0x4c, 0x54, 0xcb, 0x26, 0x86, 0x65, 0x56, 0x52, 0x4c, 0xf3, 0xe5, 0x28, 0xcd, 0x43, 0x4c, 0x9a,
  2903. 0x4c, 0xb0, 0x11, 0x53, 0xf2, 0x8e, 0x3b, 0xa1, 0x36, 0x0c, 0xd3, 0x20, 0x6a, 0xa7, 0xa7, 0x19,
  2904. 0x66, 0x25, 0x3d, 0xdb, 0xc6, 0x8e, 0x69, 0x90, 0x1a, 0x15, 0xa4, 0x36, 0x0c, 0x77, 0x42, 0xb7,
  2905. 0xfc, 0xe9, 0x08, 0x0f, 0x4f, 0x2b, 0x99, 0xd9, 0x5b, 0xfe, 0x19, 0x15, 0xa2, 0x5b, 0x66, 0xd2,
  2906. 0xa8, 0x0e, 0x4b, 0x6d, 0xdc, 0x35, 0x4c, 0xb5, 0xdd, 0xb7, 0x3a, 0x4f, 0x2a, 0x59, 0xa6, 0x2c,
  2907. 0x47, 0x29, 0x57, 0xa9, 0x68, 0x95, 0x4a, 0x36, 0x62, 0x0a, 0xb4, 0xbd, 0x19, 0x7a, 0x1b, 0x72,
  2908. 0x9d, 0x1e, 0xee, 0x3c, 0x51, 0xc9, 0x49, 0x25, 0xc7, 0x6c, 0xac, 0x47, 0xd9, 0xa8, 0x51, 0xb9,
  2909. 0xd6, 0x49, 0x23, 0xa6, 0x64, 0x3b, 0x7c, 0x48, 0xf7, 0xaf, 0xe3, 0xbe, 0x71, 0x8c, 0x87, 0x54,
  2910. 0x3f, 0x3f, 0x7b, 0xff, 0xf7, 0xb9, 0x24, 0xb3, 0x90, 0xd7, 0xdd, 0x09, 0x7a, 0x07, 0xf2, 0xd8,
  2911. 0xd4, 0xc5, 0x36, 0x80, 0x99, 0xb8, 0x1a, 0x79, 0x56, 0x4c, 0xdd, 0xdd, 0x44, 0x0e, 0x8b, 0x31,
  2912. 0xba, 0x0b, 0x99, 0x8e, 0x35, 0x18, 0x18, 0xa4, 0xb2, 0xc4, 0xb4, 0xd7, 0x22, 0x37, 0xc0, 0xa4,
  2913. 0x1a, 0x31, 0x45, 0xc8, 0xa3, 0x7d, 0x28, 0xf6, 0x0d, 0x87, 0xa8, 0x8e, 0xa9, 0xd9, 0x4e, 0xcf,
  2914. 0x22, 0x4e, 0x65, 0x99, 0x59, 0xb8, 0x1e, 0x65, 0x61, 0xcf, 0x70, 0xc8, 0xa1, 0x2b, 0xdc, 0x88,
  2915. 0x29, 0x85, 0x7e, 0x70, 0x81, 0xda, 0xb3, 0x8e, 0x8e, 0xf0, 0xd0, 0x33, 0x58, 0x29, 0xcc, 0xb6,
  2916. 0xd7, 0xa4, 0xd2, 0xae, 0x3e, 0xb5, 0x67, 0x05, 0x17, 0xd0, 0xaf, 0xe0, 0x5c, 0xdf, 0xd2, 0x74,
  2917. 0xcf, 0x9c, 0xda, 0xe9, 0x8d, 0xcc, 0x27, 0x95, 0x22, 0x33, 0x7a, 0x23, 0xf2, 0x47, 0x5a, 0x9a,
  2918. 0xee, 0x9a, 0xa8, 0x51, 0x85, 0x46, 0x4c, 0x59, 0xe9, 0x8f, 0x2f, 0xa2, 0xc7, 0xb0, 0xaa, 0xd9,
  2919. 0x76, 0xff, 0x74, 0xdc, 0x7a, 0x89, 0x59, 0xbf, 0x19, 0x65, 0x7d, 0x9b, 0xea, 0x8c, 0x9b, 0x47,
  2920. 0xda, 0xc4, 0x6a, 0x35, 0x0b, 0xe9, 0x63, 0xad, 0x3f, 0xc2, 0xf2, 0x0f, 0x60, 0x29, 0x10, 0xea,
  2921. 0xa8, 0x02, 0xd9, 0x01, 0x76, 0x1c, 0xad, 0x8b, 0x19, 0x32, 0xe4, 0x15, 0x77, 0x2a, 0x17, 0x61,
  2922. 0x39, 0x18, 0xde, 0xf2, 0xc0, 0x53, 0xa4, 0x81, 0x4b, 0x15, 0x8f, 0xf1, 0xd0, 0xa1, 0xd1, 0x2a,
  2923. 0x14, 0xc5, 0x14, 0x5d, 0x83, 0x02, 0x3b, 0x3e, 0xaa, 0xfb, 0x9c, 0xa2, 0x47, 0x4a, 0x59, 0x66,
  2924. 0x8b, 0x8f, 0x84, 0xd0, 0x3a, 0x2c, 0xd9, 0x5b, 0xb6, 0x27, 0x92, 0x64, 0x22, 0x60, 0x6f, 0xd9,
  2925. 0x42, 0x40, 0xfe, 0x31, 0x94, 0xc7, 0xa3, 0x1d, 0x95, 0x21, 0xf9, 0x04, 0x9f, 0x8a, 0xf7, 0xd1,
  2926. 0x21, 0x5a, 0x15, 0xdb, 0x62, 0xef, 0xc8, 0x2b, 0x62, 0x8f, 0x7f, 0x4d, 0x78, 0xca, 0x5e, 0x98,
  2927. 0xa3, 0xbb, 0x90, 0xa2, 0xa8, 0x29, 0x00, 0x50, 0xda, 0xe0, 0x90, 0xba, 0xe1, 0x42, 0xea, 0x46,
  2928. 0xcb, 0x85, 0xd4, 0x6a, 0xee, 0xab, 0x6f, 0xd6, 0x63, 0x5f, 0xfc, 0x7d, 0x3d, 0xae, 0x30, 0x0d,
  2929. 0x74, 0x91, 0x46, 0xa5, 0x66, 0x98, 0xaa, 0xa1, 0x8b, 0xf7, 0x64, 0xd9, 0x7c, 0x47, 0x47, 0xbb,
  2930. 0x50, 0xee, 0x58, 0xa6, 0x83, 0x4d, 0x67, 0xe4, 0xa8, 0x1c, 0xb2, 0x05, 0xec, 0x4d, 0x46, 0x4d,
  2931. 0xcd, 0x15, 0x3c, 0x60, 0x72, 0x4a, 0xa9, 0x13, 0x5e, 0x40, 0x0f, 0x00, 0x8e, 0xb5, 0xbe, 0xa1,
  2932. 0x6b, 0xc4, 0x1a, 0x3a, 0x95, 0xd4, 0xd5, 0xe4, 0x54, 0x33, 0x8f, 0x5c, 0x91, 0x87, 0xb6, 0xae,
  2933. 0x11, 0x5c, 0x4d, 0xd1, 0x5f, 0xab, 0x04, 0x34, 0xd1, 0x2b, 0x50, 0xd2, 0x6c, 0x5b, 0x75, 0x88,
  2934. 0x46, 0xb0, 0xda, 0x3e, 0x25, 0xd8, 0x61, 0x60, 0xb8, 0xac, 0x14, 0x34, 0xdb, 0x3e, 0xa4, 0xab,
  2935. 0x55, 0xba, 0x88, 0xae, 0x43, 0x91, 0x02, 0x9f, 0xa1, 0xf5, 0xd5, 0x1e, 0x36, 0xba, 0x3d, 0xc2,
  2936. 0x40, 0x2f, 0xa9, 0x14, 0xc4, 0x6a, 0x83, 0x2d, 0xca, 0xba, 0x77, 0x10, 0x18, 0xe8, 0x21, 0x04,
  2937. 0x29, 0x5d, 0x23, 0x1a, 0x73, 0xe4, 0xb2, 0xc2, 0xc6, 0x74, 0xcd, 0xd6, 0x48, 0x4f, 0xb8, 0x87,
  2938. 0x8d, 0xd1, 0x79, 0xc8, 0x08, 0xb3, 0x49, 0x66, 0x56, 0xcc, 0xe8, 0x37, 0xb3, 0x87, 0xd6, 0x31,
  2939. 0x66, 0x28, 0x9f, 0x53, 0xf8, 0x44, 0xfe, 0x6d, 0x02, 0x56, 0x26, 0xe0, 0x91, 0xda, 0xed, 0x69,
  2940. 0x4e, 0xcf, 0x7d, 0x17, 0x1d, 0xa3, 0x3b, 0xd4, 0xae, 0xa6, 0xe3, 0xa1, 0x48, 0x4b, 0x95, 0xa0,
  2941. 0x8b, 0x78, 0xca, 0x6d, 0xb0, 0xe7, 0xc2, 0x35, 0x42, 0x1a, 0x35, 0xa1, 0xdc, 0xd7, 0x1c, 0xa2,
  2942. 0x72, 0xb8, 0x51, 0x03, 0x29, 0x6a, 0x12, 0x64, 0xf7, 0x34, 0x17, 0xa0, 0xe8, 0x61, 0x17, 0x86,
  2943. 0x8a, 0xfd, 0xd0, 0x2a, 0x52, 0x60, 0xb5, 0x7d, 0xfa, 0x99, 0x66, 0x12, 0xc3, 0xc4, 0xea, 0xc4,
  2944. 0x97, 0xbb, 0x38, 0x61, 0xb4, 0x7e, 0x6c, 0xe8, 0xd8, 0xec, 0xb8, 0x9f, 0xec, 0x9c, 0xa7, 0xec,
  2945. 0x7d, 0x52, 0x47, 0x56, 0xa0, 0x18, 0x06, 0x78, 0x54, 0x84, 0x04, 0x39, 0x11, 0x0e, 0x48, 0x90,
  2946. 0x13, 0xf4, 0x43, 0x48, 0xd1, 0x4d, 0xb2, 0xcd, 0x17, 0xa7, 0x64, 0x57, 0xa1, 0xd7, 0x3a, 0xb5,
  2947. 0xb1, 0xc2, 0x24, 0x65, 0xd9, 0x8b, 0x06, 0x0f, 0xf4, 0xc7, 0xad, 0xca, 0x37, 0xa0, 0x34, 0x86,
  2948. 0xea, 0x81, 0xef, 0x17, 0x0f, 0x7e, 0x3f, 0xb9, 0x04, 0x85, 0x10, 0x84, 0xcb, 0xe7, 0x61, 0x75,
  2949. 0x1a, 0x22, 0xcb, 0x3d, 0x6f, 0x3d, 0x84, 0xac, 0xe8, 0x36, 0xe4, 0x3c, 0x48, 0xe6, 0xd1, 0x38,
  2950. 0xe9, 0x2b, 0x57, 0x58, 0xf1, 0x44, 0x69, 0x18, 0xd2, 0x63, 0xcd, 0xce, 0x43, 0x82, 0xfd, 0xf0,
  2951. 0xac, 0x66, 0xdb, 0x0d, 0xcd, 0xe9, 0xc9, 0x1f, 0x43, 0x25, 0x0a, 0x6e, 0xc7, 0xb6, 0x91, 0xf2,
  2952. 0x8e, 0xe1, 0x79, 0xc8, 0x1c, 0x59, 0xc3, 0x81, 0x46, 0x98, 0xb1, 0x82, 0x22, 0x66, 0xf4, 0x78,
  2953. 0x72, 0xe8, 0x4d, 0xb2, 0x65, 0x3e, 0x91, 0x55, 0xb8, 0x18, 0x09, 0xb9, 0x54, 0xc5, 0x30, 0x75,
  2954. 0xcc, 0xfd, 0x59, 0x50, 0xf8, 0xc4, 0x37, 0xc4, 0x7f, 0x2c, 0x9f, 0xd0, 0xd7, 0x3a, 0x6c, 0xaf,
  2955. 0xcc, 0x7e, 0x5e, 0x11, 0x33, 0xf9, 0x9f, 0x39, 0xc8, 0x29, 0xd8, 0xb1, 0x29, 0x26, 0xa0, 0x2a,
  2956. 0xe4, 0xf1, 0x49, 0x07, 0x73, 0x32, 0x14, 0x8f, 0x24, 0x13, 0x5c, 0xba, 0xee, 0x4a, 0xd2, 0x4c,
  2957. 0xee, 0xa9, 0xa1, 0x5b, 0x82, 0xf0, 0x45, 0x73, 0x37, 0xa1, 0x1e, 0x64, 0x7c, 0x77, 0x5c, 0xc6,
  2958. 0x97, 0x8c, 0x4c, 0xde, 0x5c, 0x6b, 0x8c, 0xf2, 0xdd, 0x12, 0x94, 0x2f, 0x35, 0xe7, 0x65, 0x21,
  2959. 0xce, 0x57, 0x0b, 0x71, 0xbe, 0xf4, 0x9c, 0x6d, 0x46, 0x90, 0xbe, 0x5a, 0x88, 0xf4, 0x65, 0xe6,
  2960. 0x18, 0x89, 0x60, 0x7d, 0x77, 0x5c, 0xd6, 0x97, 0x9d, 0xb3, 0xed, 0x31, 0xda, 0xf7, 0x20, 0x4c,
  2961. 0xfb, 0x38, 0x65, 0xbb, 0x16, 0xa9, 0x1d, 0xc9, 0xfb, 0x7e, 0x12, 0xe0, 0x7d, 0xf9, 0x48, 0xd2,
  2962. 0xc5, 0x8d, 0x4c, 0x21, 0x7e, 0xb5, 0x10, 0xf1, 0x83, 0x39, 0x3e, 0x88, 0x60, 0x7e, 0xef, 0x06,
  2963. 0x99, 0xdf, 0x52, 0x24, 0x79, 0x14, 0x87, 0x66, 0x1a, 0xf5, 0xbb, 0xe7, 0x51, 0xbf, 0xe5, 0x48,
  2964. 0xee, 0x2a, 0xf6, 0x30, 0xce, 0xfd, 0x9a, 0x13, 0xdc, 0x8f, 0x73, 0xb5, 0x57, 0x22, 0x4d, 0xcc,
  2965. 0x21, 0x7f, 0xcd, 0x09, 0xf2, 0x57, 0x9c, 0x63, 0x70, 0x0e, 0xfb, 0xfb, 0xf5, 0x74, 0xf6, 0x17,
  2966. 0xcd, 0xcf, 0xc4, 0xcf, 0x5c, 0x8c, 0xfe, 0xa9, 0x11, 0xf4, 0xaf, 0xcc, 0xcc, 0xbf, 0x16, 0x69,
  2967. 0xfe, 0xec, 0xfc, 0xef, 0x06, 0x4d, 0xb3, 0x63, 0xc0, 0x41, 0xa1, 0x0a, 0x0f, 0x87, 0xd6, 0x50,
  2968. 0x50, 0x2b, 0x3e, 0x91, 0x5f, 0xa5, 0x89, 0xdf, 0x07, 0x89, 0x19, 0x5c, 0x91, 0xa5, 0x84, 0x00,
  2969. 0x30, 0xc8, 0x7f, 0x8a, 0xfb, 0xba, 0x2c, 0x57, 0x06, 0x49, 0x43, 0x5e, 0x90, 0x86, 0x00, 0x85,
  2970. 0x4c, 0x84, 0x29, 0xe4, 0x3a, 0x2c, 0x51, 0xa8, 0x1f, 0x63, 0x87, 0x9a, 0xed, 0xb2, 0x43, 0x74,
  2971. 0x13, 0x56, 0x58, 0x2e, 0xe7, 0x44, 0x53, 0xe0, 0x7b, 0x8a, 0xa5, 0xa9, 0x12, 0x7d, 0xc0, 0x0f,
  2972. 0x27, 0x07, 0xfa, 0x37, 0xe0, 0x5c, 0x40, 0xd6, 0x4b, 0x21, 0x9c, 0x12, 0x95, 0x3d, 0xe9, 0x6d,
  2973. 0x91, 0x4b, 0x3e, 0xf0, 0x1d, 0xe4, 0x33, 0x4f, 0x04, 0xa9, 0x8e, 0xa5, 0x63, 0x01, 0xf0, 0x6c,
  2974. 0x4c, 0xd9, 0x68, 0xdf, 0xea, 0x0a, 0x18, 0xa7, 0x43, 0x2a, 0xe5, 0xa1, 0x60, 0x9e, 0x83, 0x9c,
  2975. 0xfc, 0x97, 0xb8, 0x6f, 0xcf, 0x27, 0xa3, 0xd3, 0x78, 0x63, 0xfc, 0xff, 0xc3, 0x1b, 0x13, 0xdf,
  2976. 0x9a, 0x37, 0x06, 0x13, 0x6c, 0x32, 0x9c, 0x60, 0xff, 0x1d, 0xf7, 0xbf, 0xb0, 0xc7, 0x02, 0xbf,
  2977. 0x9d, 0x47, 0xfc, 0x6c, 0x99, 0x66, 0xdf, 0x4b, 0x64, 0x4b, 0xc1, 0xed, 0x33, 0xec, 0xbd, 0x61,
  2978. 0x6e, 0x9f, 0xe5, 0xf9, 0x93, 0x4d, 0xd0, 0x5d, 0xc8, 0xb3, 0xa6, 0x8b, 0x6a, 0xd9, 0x8e, 0x00,
  2979. 0xdc, 0x4b, 0xc1, 0xbd, 0xf2, 0xde, 0xca, 0xc6, 0x01, 0x95, 0x69, 0xda, 0x8e, 0x92, 0xb3, 0xc5,
  2980. 0x28, 0x40, 0x04, 0xf2, 0x21, 0x3e, 0x7a, 0x19, 0xf2, 0xf4, 0xd7, 0x3b, 0xb6, 0xd6, 0xc1, 0x0c,
  2981. 0x3c, 0xf3, 0x8a, 0xbf, 0x20, 0x3f, 0x06, 0x34, 0x09, 0xdf, 0xa8, 0x01, 0x19, 0x7c, 0x8c, 0x4d,
  2982. 0x42, 0xbf, 0x1a, 0x75, 0xf7, 0xf9, 0x29, 0x64, 0x0f, 0x9b, 0xa4, 0x5a, 0xa1, 0x4e, 0xfe, 0xd7,
  2983. 0x37, 0xeb, 0x65, 0x2e, 0xfd, 0xba, 0x35, 0x30, 0x08, 0x1e, 0xd8, 0xe4, 0x54, 0x11, 0xfa, 0xf2,
  2984. 0xe7, 0x09, 0xca, 0xbc, 0x42, 0xd0, 0x3e, 0xd5, 0xb7, 0x6e, 0x00, 0x25, 0x02, 0xac, 0x7b, 0x31,
  2985. 0x7f, 0xaf, 0x01, 0x74, 0x35, 0x47, 0x7d, 0xaa, 0x99, 0x04, 0xeb, 0xc2, 0xe9, 0x81, 0x15, 0x24,
  2986. 0x41, 0x8e, 0xce, 0x46, 0x0e, 0xd6, 0x45, 0x01, 0xe0, 0xcd, 0x03, 0xfb, 0xcc, 0x7e, 0xb7, 0x7d,
  2987. 0x86, 0xbd, 0x9c, 0x1b, 0xf7, 0xf2, 0xef, 0x12, 0x7e, 0x94, 0xf8, 0x24, 0xf5, 0xfb, 0xe7, 0x87,
  2988. 0xdf, 0xb3, 0xca, 0x35, 0x9c, 0x63, 0xd1, 0x21, 0xac, 0x78, 0x51, 0xaa, 0x8e, 0x58, 0xf4, 0xba,
  2989. 0xe7, 0x6e, 0xd1, 0x30, 0x2f, 0x1f, 0x87, 0x97, 0x1d, 0xf4, 0x73, 0xb8, 0x30, 0x86, 0x40, 0x9e,
  2990. 0xe9, 0xc4, 0x82, 0x40, 0xf4, 0x52, 0x18, 0x88, 0x5c, 0xcb, 0xbe, 0xaf, 0x92, 0xdf, 0x31, 0x36,
  2991. 0x76, 0x68, 0x31, 0x14, 0x64, 0x0c, 0x53, 0xbf, 0xfe, 0x35, 0x28, 0x0c, 0x31, 0xa1, 0xf5, 0x79,
  2992. 0xa8, 0xdc, 0x5c, 0xe6, 0x8b, 0xa2, 0x88, 0x3d, 0x80, 0x97, 0xa6, 0x32, 0x07, 0xf4, 0x23, 0xc8,
  2993. 0xfb, 0xa4, 0x23, 0x1e, 0x51, 0xb9, 0x79, 0xd5, 0x88, 0x2f, 0x2b, 0xff, 0x39, 0xee, 0x9b, 0x0c,
  2994. 0xd7, 0x37, 0x75, 0xc8, 0x0c, 0xb1, 0x33, 0xea, 0xf3, 0x8a, 0xa3, 0xb8, 0xf5, 0xc6, 0x62, 0x9c,
  2995. 0x83, 0xae, 0x8e, 0xfa, 0x44, 0x11, 0xca, 0xf2, 0x63, 0xc8, 0xf0, 0x15, 0xb4, 0x04, 0xd9, 0x87,
  2996. 0xfb, 0xbb, 0xfb, 0xcd, 0x0f, 0xf7, 0xcb, 0x31, 0x04, 0x90, 0xd9, 0xae, 0xd5, 0xea, 0x07, 0xad,
  2997. 0x72, 0x1c, 0xe5, 0x21, 0xbd, 0x5d, 0x6d, 0x2a, 0xad, 0x72, 0x82, 0x2e, 0x2b, 0xf5, 0xf7, 0xeb,
  2998. 0xb5, 0x56, 0x39, 0x89, 0x56, 0xa0, 0xc0, 0xc7, 0xea, 0x83, 0xa6, 0xf2, 0xc1, 0x76, 0xab, 0x9c,
  2999. 0x0a, 0x2c, 0x1d, 0xd6, 0xf7, 0xef, 0xd7, 0x95, 0x72, 0x5a, 0x7e, 0x93, 0x96, 0x34, 0x11, 0x2c,
  3000. 0xc5, 0x2f, 0x5e, 0xe2, 0x81, 0xe2, 0x45, 0xfe, 0x63, 0x02, 0xa4, 0x68, 0xea, 0x81, 0xde, 0x1f,
  3001. 0xdb, 0xf8, 0xd6, 0x19, 0x78, 0xcb, 0xd8, 0xee, 0xd1, 0x75, 0x28, 0x0e, 0xf1, 0x11, 0x26, 0x9d,
  3002. 0x1e, 0xa7, 0x42, 0x3c, 0xb1, 0x15, 0x94, 0x82, 0x58, 0x65, 0x4a, 0x0e, 0x17, 0xfb, 0x04, 0x77,
  3003. 0x88, 0xca, 0xeb, 0x28, 0x7e, 0xe8, 0xf2, 0x54, 0x8c, 0xae, 0x1e, 0xf2, 0x45, 0xf9, 0xe3, 0x33,
  3004. 0xf9, 0x32, 0x0f, 0x69, 0xa5, 0xde, 0x52, 0x7e, 0x51, 0x4e, 0x22, 0x04, 0x45, 0x36, 0x54, 0x0f,
  3005. 0xf7, 0xb7, 0x0f, 0x0e, 0x1b, 0x4d, 0xea, 0xcb, 0x73, 0x50, 0x72, 0x7d, 0xe9, 0x2e, 0xa6, 0xe5,
  3006. 0xff, 0xc6, 0xa1, 0x34, 0x16, 0x20, 0x68, 0x0b, 0xd2, 0x9c, 0x4e, 0x47, 0x35, 0xdd, 0x59, 0x7c,
  3007. 0x8b, 0x68, 0xe2, 0xa2, 0xe8, 0x6d, 0xc8, 0x61, 0xd1, 0x27, 0x98, 0x16, 0x88, 0xbc, 0xbf, 0xe1,
  3008. 0x76, 0x12, 0x84, 0xaa, 0xa7, 0x81, 0xde, 0x81, 0xbc, 0x17, 0xe9, 0xa2, 0x86, 0x7b, 0x79, 0x52,
  3009. 0xdd, 0xc3, 0x08, 0xa1, 0xef, 0xeb, 0xa0, 0x7b, 0x3e, 0x27, 0x4b, 0x4d, 0x92, 0x78, 0xa1, 0xce,
  3010. 0x05, 0x84, 0xb2, 0x2b, 0x2f, 0xd7, 0x60, 0x29, 0xb0, 0x1f, 0x74, 0x09, 0xf2, 0x03, 0xed, 0x44,
  3011. 0xf4, 0x9f, 0x78, 0x07, 0x21, 0x37, 0xd0, 0x4e, 0x78, 0xeb, 0xe9, 0x02, 0x64, 0xe9, 0xc3, 0xae,
  3012. 0xc6, 0xd1, 0x26, 0xa9, 0x64, 0x06, 0xda, 0xc9, 0x7b, 0x9a, 0x23, 0x7f, 0x04, 0xc5, 0x70, 0xef,
  3013. 0x85, 0x9e, 0xc4, 0xa1, 0x35, 0x32, 0x75, 0x66, 0x23, 0xad, 0xf0, 0x09, 0xba, 0x0d, 0xe9, 0x63,
  3014. 0x8b, 0x83, 0xd5, 0xf4, 0x90, 0x7d, 0x64, 0x11, 0x1c, 0xe8, 0xdd, 0x70, 0x69, 0xf9, 0x33, 0x48,
  3015. 0x33, 0xf0, 0xa1, 0x40, 0xc2, 0xba, 0x28, 0x82, 0x8f, 0xd2, 0x31, 0xfa, 0x08, 0x40, 0x23, 0x64,
  3016. 0x68, 0xb4, 0x47, 0xbe, 0xe1, 0xf5, 0xe9, 0xe0, 0xb5, 0xed, 0xca, 0x55, 0x2f, 0x0b, 0x14, 0x5b,
  3017. 0xf5, 0x55, 0x03, 0x48, 0x16, 0x30, 0x28, 0xef, 0x43, 0x31, 0xac, 0x1b, 0xec, 0x67, 0x2e, 0x4f,
  3018. 0xe9, 0x67, 0x7a, 0x9c, 0xc7, 0x63, 0x4c, 0x49, 0xde, 0x31, 0x63, 0x13, 0xf9, 0x59, 0x1c, 0x72,
  3019. 0xad, 0x13, 0x71, 0xac, 0x23, 0x9a, 0x35, 0xbe, 0x6a, 0x22, 0xd8, 0x9a, 0xe0, 0xdd, 0x9f, 0xa4,
  3020. 0xd7, 0x53, 0x7a, 0xd7, 0x0b, 0xdc, 0xd4, 0xa2, 0xc5, 0xa3, 0xdb, 0x5c, 0x13, 0x60, 0xf5, 0x16,
  3021. 0xe4, 0xbd, 0x53, 0x45, 0x89, 0xbd, 0xa6, 0xeb, 0x43, 0xec, 0x38, 0x62, 0x6f, 0xee, 0x94, 0xf5,
  3022. 0xfe, 0xac, 0xa7, 0xa2, 0xf9, 0x91, 0x54, 0xf8, 0x44, 0xd6, 0xa1, 0x34, 0x96, 0xb6, 0xd0, 0x5b,
  3023. 0x90, 0xb5, 0x47, 0x6d, 0xd5, 0x75, 0xcf, 0x58, 0xf0, 0xb8, 0x24, 0x6f, 0xd4, 0xee, 0x1b, 0x9d,
  3024. 0x5d, 0x7c, 0xea, 0xfe, 0x18, 0x7b, 0xd4, 0xde, 0xe5, 0x5e, 0xe4, 0x6f, 0x49, 0x04, 0xdf, 0x72,
  3025. 0x0c, 0x39, 0xf7, 0x50, 0xa0, 0x9f, 0x06, 0xe3, 0xc4, 0xed, 0x08, 0x47, 0xa6, 0x52, 0x61, 0x3e,
  3026. 0x10, 0x26, 0x37, 0x61, 0xc5, 0x31, 0xba, 0x26, 0xd6, 0x55, 0xbf, 0xb4, 0x60, 0x6f, 0xcb, 0x29,
  3027. 0x25, 0xfe, 0x60, 0xcf, 0xad, 0x2b, 0xe4, 0xff, 0xc4, 0x21, 0xe7, 0x06, 0x2c, 0x7a, 0x33, 0x70,
  3028. 0xee, 0x8a, 0x53, 0x1a, 0x25, 0xae, 0xa0, 0xdf, 0xbe, 0x0b, 0xff, 0xd6, 0xc4, 0xd9, 0x7f, 0x6b,
  3029. 0x54, 0x1f, 0xd6, 0x6d, 0x88, 0xa7, 0xce, 0xdc, 0x10, 0x7f, 0x1d, 0x10, 0xb1, 0x88, 0xd6, 0x57,
  3030. 0x8f, 0x2d, 0x62, 0x98, 0x5d, 0x95, 0x3b, 0x9b, 0x33, 0xaa, 0x32, 0x7b, 0xf2, 0x88, 0x3d, 0x38,
  3031. 0x60, 0x7e, 0xff, 0x4d, 0x1c, 0x72, 0x5e, 0x6e, 0x3c, 0x6b, 0x37, 0xee, 0x3c, 0x64, 0x04, 0xfc,
  3032. 0xf3, 0x76, 0x9c, 0x98, 0x79, 0x8d, 0xe1, 0x54, 0xa0, 0x31, 0x2c, 0x41, 0x6e, 0x80, 0x89, 0xc6,
  3033. 0x08, 0x02, 0xaf, 0xee, 0xbc, 0xf9, 0xcd, 0x7b, 0xb0, 0x14, 0x68, 0x8c, 0xd2, 0xc8, 0xdb, 0xaf,
  3034. 0x7f, 0x58, 0x8e, 0x49, 0xd9, 0x67, 0x5f, 0x5e, 0x4d, 0xee, 0xe3, 0xa7, 0xf4, 0xcc, 0x2a, 0xf5,
  3035. 0x5a, 0xa3, 0x5e, 0xdb, 0x2d, 0xc7, 0xa5, 0xa5, 0x67, 0x5f, 0x5e, 0xcd, 0x2a, 0x98, 0xf5, 0x57,
  3036. 0x6e, 0x36, 0x60, 0x39, 0xf8, 0x55, 0xc2, 0x19, 0x04, 0x41, 0xf1, 0xfe, 0xc3, 0x83, 0xbd, 0x9d,
  3037. 0xda, 0x76, 0xab, 0xae, 0x3e, 0x6a, 0xb6, 0xea, 0xe5, 0x38, 0xba, 0x00, 0xe7, 0xf6, 0x76, 0xde,
  3038. 0x6b, 0xb4, 0xd4, 0xda, 0xde, 0x4e, 0x7d, 0xbf, 0xa5, 0x6e, 0xb7, 0x5a, 0xdb, 0xb5, 0xdd, 0x72,
  3039. 0x62, 0xeb, 0x73, 0x80, 0xd2, 0x76, 0xb5, 0xb6, 0x43, 0xb3, 0x9f, 0xd1, 0xd1, 0x44, 0xff, 0x2a,
  3040. 0xc5, 0x8a, 0xeb, 0x99, 0x37, 0xb2, 0xd2, 0xec, 0xf6, 0x1d, 0x7a, 0x00, 0x69, 0x56, 0x77, 0xa3,
  3041. 0xd9, 0x57, 0xb4, 0xd2, 0x9c, 0x7e, 0x1e, 0xfd, 0x31, 0x2c, 0x3c, 0x66, 0xde, 0xd9, 0x4a, 0xb3,
  3042. 0xdb, 0x7b, 0x48, 0x81, 0xbc, 0x5f, 0x38, 0xcf, 0xbf, 0xc3, 0x95, 0x16, 0x68, 0xf9, 0x51, 0x9b,
  3043. 0x7e, 0x59, 0x30, 0xff, 0x4e, 0x53, 0x5a, 0x00, 0xc0, 0xd0, 0x1e, 0x64, 0xdd, 0x82, 0x6b, 0xde,
  3044. 0x2d, 0xab, 0x34, 0xb7, 0x1d, 0x47, 0x3f, 0x01, 0x2f, 0x8c, 0x67, 0x5f, 0x19, 0x4b, 0x73, 0x7a,
  3045. 0x8b, 0x68, 0x07, 0x32, 0x82, 0xeb, 0xce, 0xb9, 0x39, 0x95, 0xe6, 0xb5, 0xd7, 0xa8, 0xd3, 0xfc,
  3046. 0x8e, 0xc3, 0xfc, 0x8b, 0x70, 0x69, 0x81, 0xb6, 0x29, 0x7a, 0x08, 0x10, 0x28, 0x83, 0x17, 0xb8,
  3047. 0xe1, 0x96, 0x16, 0x69, 0x87, 0xa2, 0x26, 0xe4, 0xbc, 0x72, 0x67, 0xee, 0x7d, 0xb3, 0x34, 0xbf,
  3048. 0x2f, 0x89, 0x1e, 0x43, 0x21, 0xcc, 0xf3, 0x17, 0xbb, 0x45, 0x96, 0x16, 0x6c, 0x38, 0x52, 0xfb,
  3049. 0x61, 0xd2, 0xbf, 0xd8, 0xad, 0xb2, 0xb4, 0x60, 0xff, 0x11, 0x7d, 0x02, 0x2b, 0x93, 0xa4, 0x7c,
  3050. 0xf1, 0x4b, 0x66, 0xe9, 0x0c, 0x1d, 0x49, 0x34, 0x00, 0x34, 0x85, 0xcc, 0x9f, 0xe1, 0xce, 0x59,
  3051. 0x3a, 0x4b, 0x83, 0xb2, 0x5a, 0xff, 0xea, 0xf9, 0x5a, 0xfc, 0xeb, 0xe7, 0x6b, 0xf1, 0x7f, 0x3c,
  3052. 0x5f, 0x8b, 0x7f, 0xf1, 0x62, 0x2d, 0xf6, 0xf5, 0x8b, 0xb5, 0xd8, 0xdf, 0x5e, 0xac, 0xc5, 0x7e,
  3053. 0xf9, 0x5a, 0xd7, 0x20, 0xbd, 0x51, 0x7b, 0xa3, 0x63, 0x0d, 0x36, 0x83, 0x7f, 0x88, 0x99, 0xf6,
  3054. 0x27, 0x9d, 0x76, 0x86, 0x25, 0xaa, 0x5b, 0xff, 0x0b, 0x00, 0x00, 0xff, 0xff, 0x3b, 0xae, 0x48,
  3055. 0xb4, 0xc4, 0x23, 0x00, 0x00,
  3056. }
  3057. // Reference imports to suppress errors if they are not otherwise used.
  3058. var _ context.Context
  3059. var _ grpc.ClientConn
  3060. // This is a compile-time assertion to ensure that this generated file
  3061. // is compatible with the grpc package it is being compiled against.
  3062. const _ = grpc.SupportPackageIsVersion4
  3063. // ABCIApplicationClient is the client API for ABCIApplication service.
  3064. //
  3065. // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
  3066. type ABCIApplicationClient interface {
  3067. Echo(ctx context.Context, in *RequestEcho, opts ...grpc.CallOption) (*ResponseEcho, error)
  3068. Flush(ctx context.Context, in *RequestFlush, opts ...grpc.CallOption) (*ResponseFlush, error)
  3069. Info(ctx context.Context, in *RequestInfo, opts ...grpc.CallOption) (*ResponseInfo, error)
  3070. SetOption(ctx context.Context, in *RequestSetOption, opts ...grpc.CallOption) (*ResponseSetOption, error)
  3071. DeliverTx(ctx context.Context, in *RequestDeliverTx, opts ...grpc.CallOption) (*ResponseDeliverTx, error)
  3072. CheckTx(ctx context.Context, in *RequestCheckTx, opts ...grpc.CallOption) (*ResponseCheckTx, error)
  3073. Query(ctx context.Context, in *RequestQuery, opts ...grpc.CallOption) (*ResponseQuery, error)
  3074. Commit(ctx context.Context, in *RequestCommit, opts ...grpc.CallOption) (*ResponseCommit, error)
  3075. InitChain(ctx context.Context, in *RequestInitChain, opts ...grpc.CallOption) (*ResponseInitChain, error)
  3076. BeginBlock(ctx context.Context, in *RequestBeginBlock, opts ...grpc.CallOption) (*ResponseBeginBlock, error)
  3077. EndBlock(ctx context.Context, in *RequestEndBlock, opts ...grpc.CallOption) (*ResponseEndBlock, error)
  3078. ListSnapshots(ctx context.Context, in *RequestListSnapshots, opts ...grpc.CallOption) (*ResponseListSnapshots, error)
  3079. OfferSnapshot(ctx context.Context, in *RequestOfferSnapshot, opts ...grpc.CallOption) (*ResponseOfferSnapshot, error)
  3080. LoadSnapshotChunk(ctx context.Context, in *RequestLoadSnapshotChunk, opts ...grpc.CallOption) (*ResponseLoadSnapshotChunk, error)
  3081. ApplySnapshotChunk(ctx context.Context, in *RequestApplySnapshotChunk, opts ...grpc.CallOption) (*ResponseApplySnapshotChunk, error)
  3082. }
  3083. type aBCIApplicationClient struct {
  3084. cc *grpc.ClientConn
  3085. }
  3086. func NewABCIApplicationClient(cc *grpc.ClientConn) ABCIApplicationClient {
  3087. return &aBCIApplicationClient{cc}
  3088. }
  3089. func (c *aBCIApplicationClient) Echo(ctx context.Context, in *RequestEcho, opts ...grpc.CallOption) (*ResponseEcho, error) {
  3090. out := new(ResponseEcho)
  3091. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/Echo", in, out, opts...)
  3092. if err != nil {
  3093. return nil, err
  3094. }
  3095. return out, nil
  3096. }
  3097. func (c *aBCIApplicationClient) Flush(ctx context.Context, in *RequestFlush, opts ...grpc.CallOption) (*ResponseFlush, error) {
  3098. out := new(ResponseFlush)
  3099. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/Flush", in, out, opts...)
  3100. if err != nil {
  3101. return nil, err
  3102. }
  3103. return out, nil
  3104. }
  3105. func (c *aBCIApplicationClient) Info(ctx context.Context, in *RequestInfo, opts ...grpc.CallOption) (*ResponseInfo, error) {
  3106. out := new(ResponseInfo)
  3107. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/Info", in, out, opts...)
  3108. if err != nil {
  3109. return nil, err
  3110. }
  3111. return out, nil
  3112. }
  3113. func (c *aBCIApplicationClient) SetOption(ctx context.Context, in *RequestSetOption, opts ...grpc.CallOption) (*ResponseSetOption, error) {
  3114. out := new(ResponseSetOption)
  3115. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/SetOption", in, out, opts...)
  3116. if err != nil {
  3117. return nil, err
  3118. }
  3119. return out, nil
  3120. }
  3121. func (c *aBCIApplicationClient) DeliverTx(ctx context.Context, in *RequestDeliverTx, opts ...grpc.CallOption) (*ResponseDeliverTx, error) {
  3122. out := new(ResponseDeliverTx)
  3123. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/DeliverTx", in, out, opts...)
  3124. if err != nil {
  3125. return nil, err
  3126. }
  3127. return out, nil
  3128. }
  3129. func (c *aBCIApplicationClient) CheckTx(ctx context.Context, in *RequestCheckTx, opts ...grpc.CallOption) (*ResponseCheckTx, error) {
  3130. out := new(ResponseCheckTx)
  3131. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/CheckTx", in, out, opts...)
  3132. if err != nil {
  3133. return nil, err
  3134. }
  3135. return out, nil
  3136. }
  3137. func (c *aBCIApplicationClient) Query(ctx context.Context, in *RequestQuery, opts ...grpc.CallOption) (*ResponseQuery, error) {
  3138. out := new(ResponseQuery)
  3139. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/Query", in, out, opts...)
  3140. if err != nil {
  3141. return nil, err
  3142. }
  3143. return out, nil
  3144. }
  3145. func (c *aBCIApplicationClient) Commit(ctx context.Context, in *RequestCommit, opts ...grpc.CallOption) (*ResponseCommit, error) {
  3146. out := new(ResponseCommit)
  3147. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/Commit", in, out, opts...)
  3148. if err != nil {
  3149. return nil, err
  3150. }
  3151. return out, nil
  3152. }
  3153. func (c *aBCIApplicationClient) InitChain(ctx context.Context, in *RequestInitChain, opts ...grpc.CallOption) (*ResponseInitChain, error) {
  3154. out := new(ResponseInitChain)
  3155. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/InitChain", in, out, opts...)
  3156. if err != nil {
  3157. return nil, err
  3158. }
  3159. return out, nil
  3160. }
  3161. func (c *aBCIApplicationClient) BeginBlock(ctx context.Context, in *RequestBeginBlock, opts ...grpc.CallOption) (*ResponseBeginBlock, error) {
  3162. out := new(ResponseBeginBlock)
  3163. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/BeginBlock", in, out, opts...)
  3164. if err != nil {
  3165. return nil, err
  3166. }
  3167. return out, nil
  3168. }
  3169. func (c *aBCIApplicationClient) EndBlock(ctx context.Context, in *RequestEndBlock, opts ...grpc.CallOption) (*ResponseEndBlock, error) {
  3170. out := new(ResponseEndBlock)
  3171. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/EndBlock", in, out, opts...)
  3172. if err != nil {
  3173. return nil, err
  3174. }
  3175. return out, nil
  3176. }
  3177. func (c *aBCIApplicationClient) ListSnapshots(ctx context.Context, in *RequestListSnapshots, opts ...grpc.CallOption) (*ResponseListSnapshots, error) {
  3178. out := new(ResponseListSnapshots)
  3179. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/ListSnapshots", in, out, opts...)
  3180. if err != nil {
  3181. return nil, err
  3182. }
  3183. return out, nil
  3184. }
  3185. func (c *aBCIApplicationClient) OfferSnapshot(ctx context.Context, in *RequestOfferSnapshot, opts ...grpc.CallOption) (*ResponseOfferSnapshot, error) {
  3186. out := new(ResponseOfferSnapshot)
  3187. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/OfferSnapshot", in, out, opts...)
  3188. if err != nil {
  3189. return nil, err
  3190. }
  3191. return out, nil
  3192. }
  3193. func (c *aBCIApplicationClient) LoadSnapshotChunk(ctx context.Context, in *RequestLoadSnapshotChunk, opts ...grpc.CallOption) (*ResponseLoadSnapshotChunk, error) {
  3194. out := new(ResponseLoadSnapshotChunk)
  3195. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/LoadSnapshotChunk", in, out, opts...)
  3196. if err != nil {
  3197. return nil, err
  3198. }
  3199. return out, nil
  3200. }
  3201. func (c *aBCIApplicationClient) ApplySnapshotChunk(ctx context.Context, in *RequestApplySnapshotChunk, opts ...grpc.CallOption) (*ResponseApplySnapshotChunk, error) {
  3202. out := new(ResponseApplySnapshotChunk)
  3203. err := c.cc.Invoke(ctx, "/tendermint.abci.ABCIApplication/ApplySnapshotChunk", in, out, opts...)
  3204. if err != nil {
  3205. return nil, err
  3206. }
  3207. return out, nil
  3208. }
  3209. // ABCIApplicationServer is the server API for ABCIApplication service.
  3210. type ABCIApplicationServer interface {
  3211. Echo(context.Context, *RequestEcho) (*ResponseEcho, error)
  3212. Flush(context.Context, *RequestFlush) (*ResponseFlush, error)
  3213. Info(context.Context, *RequestInfo) (*ResponseInfo, error)
  3214. SetOption(context.Context, *RequestSetOption) (*ResponseSetOption, error)
  3215. DeliverTx(context.Context, *RequestDeliverTx) (*ResponseDeliverTx, error)
  3216. CheckTx(context.Context, *RequestCheckTx) (*ResponseCheckTx, error)
  3217. Query(context.Context, *RequestQuery) (*ResponseQuery, error)
  3218. Commit(context.Context, *RequestCommit) (*ResponseCommit, error)
  3219. InitChain(context.Context, *RequestInitChain) (*ResponseInitChain, error)
  3220. BeginBlock(context.Context, *RequestBeginBlock) (*ResponseBeginBlock, error)
  3221. EndBlock(context.Context, *RequestEndBlock) (*ResponseEndBlock, error)
  3222. ListSnapshots(context.Context, *RequestListSnapshots) (*ResponseListSnapshots, error)
  3223. OfferSnapshot(context.Context, *RequestOfferSnapshot) (*ResponseOfferSnapshot, error)
  3224. LoadSnapshotChunk(context.Context, *RequestLoadSnapshotChunk) (*ResponseLoadSnapshotChunk, error)
  3225. ApplySnapshotChunk(context.Context, *RequestApplySnapshotChunk) (*ResponseApplySnapshotChunk, error)
  3226. }
  3227. // UnimplementedABCIApplicationServer can be embedded to have forward compatible implementations.
  3228. type UnimplementedABCIApplicationServer struct {
  3229. }
  3230. func (*UnimplementedABCIApplicationServer) Echo(ctx context.Context, req *RequestEcho) (*ResponseEcho, error) {
  3231. return nil, status.Errorf(codes.Unimplemented, "method Echo not implemented")
  3232. }
  3233. func (*UnimplementedABCIApplicationServer) Flush(ctx context.Context, req *RequestFlush) (*ResponseFlush, error) {
  3234. return nil, status.Errorf(codes.Unimplemented, "method Flush not implemented")
  3235. }
  3236. func (*UnimplementedABCIApplicationServer) Info(ctx context.Context, req *RequestInfo) (*ResponseInfo, error) {
  3237. return nil, status.Errorf(codes.Unimplemented, "method Info not implemented")
  3238. }
  3239. func (*UnimplementedABCIApplicationServer) SetOption(ctx context.Context, req *RequestSetOption) (*ResponseSetOption, error) {
  3240. return nil, status.Errorf(codes.Unimplemented, "method SetOption not implemented")
  3241. }
  3242. func (*UnimplementedABCIApplicationServer) DeliverTx(ctx context.Context, req *RequestDeliverTx) (*ResponseDeliverTx, error) {
  3243. return nil, status.Errorf(codes.Unimplemented, "method DeliverTx not implemented")
  3244. }
  3245. func (*UnimplementedABCIApplicationServer) CheckTx(ctx context.Context, req *RequestCheckTx) (*ResponseCheckTx, error) {
  3246. return nil, status.Errorf(codes.Unimplemented, "method CheckTx not implemented")
  3247. }
  3248. func (*UnimplementedABCIApplicationServer) Query(ctx context.Context, req *RequestQuery) (*ResponseQuery, error) {
  3249. return nil, status.Errorf(codes.Unimplemented, "method Query not implemented")
  3250. }
  3251. func (*UnimplementedABCIApplicationServer) Commit(ctx context.Context, req *RequestCommit) (*ResponseCommit, error) {
  3252. return nil, status.Errorf(codes.Unimplemented, "method Commit not implemented")
  3253. }
  3254. func (*UnimplementedABCIApplicationServer) InitChain(ctx context.Context, req *RequestInitChain) (*ResponseInitChain, error) {
  3255. return nil, status.Errorf(codes.Unimplemented, "method InitChain not implemented")
  3256. }
  3257. func (*UnimplementedABCIApplicationServer) BeginBlock(ctx context.Context, req *RequestBeginBlock) (*ResponseBeginBlock, error) {
  3258. return nil, status.Errorf(codes.Unimplemented, "method BeginBlock not implemented")
  3259. }
  3260. func (*UnimplementedABCIApplicationServer) EndBlock(ctx context.Context, req *RequestEndBlock) (*ResponseEndBlock, error) {
  3261. return nil, status.Errorf(codes.Unimplemented, "method EndBlock not implemented")
  3262. }
  3263. func (*UnimplementedABCIApplicationServer) ListSnapshots(ctx context.Context, req *RequestListSnapshots) (*ResponseListSnapshots, error) {
  3264. return nil, status.Errorf(codes.Unimplemented, "method ListSnapshots not implemented")
  3265. }
  3266. func (*UnimplementedABCIApplicationServer) OfferSnapshot(ctx context.Context, req *RequestOfferSnapshot) (*ResponseOfferSnapshot, error) {
  3267. return nil, status.Errorf(codes.Unimplemented, "method OfferSnapshot not implemented")
  3268. }
  3269. func (*UnimplementedABCIApplicationServer) LoadSnapshotChunk(ctx context.Context, req *RequestLoadSnapshotChunk) (*ResponseLoadSnapshotChunk, error) {
  3270. return nil, status.Errorf(codes.Unimplemented, "method LoadSnapshotChunk not implemented")
  3271. }
  3272. func (*UnimplementedABCIApplicationServer) ApplySnapshotChunk(ctx context.Context, req *RequestApplySnapshotChunk) (*ResponseApplySnapshotChunk, error) {
  3273. return nil, status.Errorf(codes.Unimplemented, "method ApplySnapshotChunk not implemented")
  3274. }
  3275. func RegisterABCIApplicationServer(s *grpc.Server, srv ABCIApplicationServer) {
  3276. s.RegisterService(&_ABCIApplication_serviceDesc, srv)
  3277. }
  3278. func _ABCIApplication_Echo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3279. in := new(RequestEcho)
  3280. if err := dec(in); err != nil {
  3281. return nil, err
  3282. }
  3283. if interceptor == nil {
  3284. return srv.(ABCIApplicationServer).Echo(ctx, in)
  3285. }
  3286. info := &grpc.UnaryServerInfo{
  3287. Server: srv,
  3288. FullMethod: "/tendermint.abci.ABCIApplication/Echo",
  3289. }
  3290. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3291. return srv.(ABCIApplicationServer).Echo(ctx, req.(*RequestEcho))
  3292. }
  3293. return interceptor(ctx, in, info, handler)
  3294. }
  3295. func _ABCIApplication_Flush_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3296. in := new(RequestFlush)
  3297. if err := dec(in); err != nil {
  3298. return nil, err
  3299. }
  3300. if interceptor == nil {
  3301. return srv.(ABCIApplicationServer).Flush(ctx, in)
  3302. }
  3303. info := &grpc.UnaryServerInfo{
  3304. Server: srv,
  3305. FullMethod: "/tendermint.abci.ABCIApplication/Flush",
  3306. }
  3307. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3308. return srv.(ABCIApplicationServer).Flush(ctx, req.(*RequestFlush))
  3309. }
  3310. return interceptor(ctx, in, info, handler)
  3311. }
  3312. func _ABCIApplication_Info_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3313. in := new(RequestInfo)
  3314. if err := dec(in); err != nil {
  3315. return nil, err
  3316. }
  3317. if interceptor == nil {
  3318. return srv.(ABCIApplicationServer).Info(ctx, in)
  3319. }
  3320. info := &grpc.UnaryServerInfo{
  3321. Server: srv,
  3322. FullMethod: "/tendermint.abci.ABCIApplication/Info",
  3323. }
  3324. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3325. return srv.(ABCIApplicationServer).Info(ctx, req.(*RequestInfo))
  3326. }
  3327. return interceptor(ctx, in, info, handler)
  3328. }
  3329. func _ABCIApplication_SetOption_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3330. in := new(RequestSetOption)
  3331. if err := dec(in); err != nil {
  3332. return nil, err
  3333. }
  3334. if interceptor == nil {
  3335. return srv.(ABCIApplicationServer).SetOption(ctx, in)
  3336. }
  3337. info := &grpc.UnaryServerInfo{
  3338. Server: srv,
  3339. FullMethod: "/tendermint.abci.ABCIApplication/SetOption",
  3340. }
  3341. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3342. return srv.(ABCIApplicationServer).SetOption(ctx, req.(*RequestSetOption))
  3343. }
  3344. return interceptor(ctx, in, info, handler)
  3345. }
  3346. func _ABCIApplication_DeliverTx_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3347. in := new(RequestDeliverTx)
  3348. if err := dec(in); err != nil {
  3349. return nil, err
  3350. }
  3351. if interceptor == nil {
  3352. return srv.(ABCIApplicationServer).DeliverTx(ctx, in)
  3353. }
  3354. info := &grpc.UnaryServerInfo{
  3355. Server: srv,
  3356. FullMethod: "/tendermint.abci.ABCIApplication/DeliverTx",
  3357. }
  3358. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3359. return srv.(ABCIApplicationServer).DeliverTx(ctx, req.(*RequestDeliverTx))
  3360. }
  3361. return interceptor(ctx, in, info, handler)
  3362. }
  3363. func _ABCIApplication_CheckTx_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3364. in := new(RequestCheckTx)
  3365. if err := dec(in); err != nil {
  3366. return nil, err
  3367. }
  3368. if interceptor == nil {
  3369. return srv.(ABCIApplicationServer).CheckTx(ctx, in)
  3370. }
  3371. info := &grpc.UnaryServerInfo{
  3372. Server: srv,
  3373. FullMethod: "/tendermint.abci.ABCIApplication/CheckTx",
  3374. }
  3375. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3376. return srv.(ABCIApplicationServer).CheckTx(ctx, req.(*RequestCheckTx))
  3377. }
  3378. return interceptor(ctx, in, info, handler)
  3379. }
  3380. func _ABCIApplication_Query_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3381. in := new(RequestQuery)
  3382. if err := dec(in); err != nil {
  3383. return nil, err
  3384. }
  3385. if interceptor == nil {
  3386. return srv.(ABCIApplicationServer).Query(ctx, in)
  3387. }
  3388. info := &grpc.UnaryServerInfo{
  3389. Server: srv,
  3390. FullMethod: "/tendermint.abci.ABCIApplication/Query",
  3391. }
  3392. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3393. return srv.(ABCIApplicationServer).Query(ctx, req.(*RequestQuery))
  3394. }
  3395. return interceptor(ctx, in, info, handler)
  3396. }
  3397. func _ABCIApplication_Commit_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3398. in := new(RequestCommit)
  3399. if err := dec(in); err != nil {
  3400. return nil, err
  3401. }
  3402. if interceptor == nil {
  3403. return srv.(ABCIApplicationServer).Commit(ctx, in)
  3404. }
  3405. info := &grpc.UnaryServerInfo{
  3406. Server: srv,
  3407. FullMethod: "/tendermint.abci.ABCIApplication/Commit",
  3408. }
  3409. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3410. return srv.(ABCIApplicationServer).Commit(ctx, req.(*RequestCommit))
  3411. }
  3412. return interceptor(ctx, in, info, handler)
  3413. }
  3414. func _ABCIApplication_InitChain_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3415. in := new(RequestInitChain)
  3416. if err := dec(in); err != nil {
  3417. return nil, err
  3418. }
  3419. if interceptor == nil {
  3420. return srv.(ABCIApplicationServer).InitChain(ctx, in)
  3421. }
  3422. info := &grpc.UnaryServerInfo{
  3423. Server: srv,
  3424. FullMethod: "/tendermint.abci.ABCIApplication/InitChain",
  3425. }
  3426. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3427. return srv.(ABCIApplicationServer).InitChain(ctx, req.(*RequestInitChain))
  3428. }
  3429. return interceptor(ctx, in, info, handler)
  3430. }
  3431. func _ABCIApplication_BeginBlock_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3432. in := new(RequestBeginBlock)
  3433. if err := dec(in); err != nil {
  3434. return nil, err
  3435. }
  3436. if interceptor == nil {
  3437. return srv.(ABCIApplicationServer).BeginBlock(ctx, in)
  3438. }
  3439. info := &grpc.UnaryServerInfo{
  3440. Server: srv,
  3441. FullMethod: "/tendermint.abci.ABCIApplication/BeginBlock",
  3442. }
  3443. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3444. return srv.(ABCIApplicationServer).BeginBlock(ctx, req.(*RequestBeginBlock))
  3445. }
  3446. return interceptor(ctx, in, info, handler)
  3447. }
  3448. func _ABCIApplication_EndBlock_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3449. in := new(RequestEndBlock)
  3450. if err := dec(in); err != nil {
  3451. return nil, err
  3452. }
  3453. if interceptor == nil {
  3454. return srv.(ABCIApplicationServer).EndBlock(ctx, in)
  3455. }
  3456. info := &grpc.UnaryServerInfo{
  3457. Server: srv,
  3458. FullMethod: "/tendermint.abci.ABCIApplication/EndBlock",
  3459. }
  3460. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3461. return srv.(ABCIApplicationServer).EndBlock(ctx, req.(*RequestEndBlock))
  3462. }
  3463. return interceptor(ctx, in, info, handler)
  3464. }
  3465. func _ABCIApplication_ListSnapshots_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3466. in := new(RequestListSnapshots)
  3467. if err := dec(in); err != nil {
  3468. return nil, err
  3469. }
  3470. if interceptor == nil {
  3471. return srv.(ABCIApplicationServer).ListSnapshots(ctx, in)
  3472. }
  3473. info := &grpc.UnaryServerInfo{
  3474. Server: srv,
  3475. FullMethod: "/tendermint.abci.ABCIApplication/ListSnapshots",
  3476. }
  3477. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3478. return srv.(ABCIApplicationServer).ListSnapshots(ctx, req.(*RequestListSnapshots))
  3479. }
  3480. return interceptor(ctx, in, info, handler)
  3481. }
  3482. func _ABCIApplication_OfferSnapshot_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3483. in := new(RequestOfferSnapshot)
  3484. if err := dec(in); err != nil {
  3485. return nil, err
  3486. }
  3487. if interceptor == nil {
  3488. return srv.(ABCIApplicationServer).OfferSnapshot(ctx, in)
  3489. }
  3490. info := &grpc.UnaryServerInfo{
  3491. Server: srv,
  3492. FullMethod: "/tendermint.abci.ABCIApplication/OfferSnapshot",
  3493. }
  3494. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3495. return srv.(ABCIApplicationServer).OfferSnapshot(ctx, req.(*RequestOfferSnapshot))
  3496. }
  3497. return interceptor(ctx, in, info, handler)
  3498. }
  3499. func _ABCIApplication_LoadSnapshotChunk_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3500. in := new(RequestLoadSnapshotChunk)
  3501. if err := dec(in); err != nil {
  3502. return nil, err
  3503. }
  3504. if interceptor == nil {
  3505. return srv.(ABCIApplicationServer).LoadSnapshotChunk(ctx, in)
  3506. }
  3507. info := &grpc.UnaryServerInfo{
  3508. Server: srv,
  3509. FullMethod: "/tendermint.abci.ABCIApplication/LoadSnapshotChunk",
  3510. }
  3511. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3512. return srv.(ABCIApplicationServer).LoadSnapshotChunk(ctx, req.(*RequestLoadSnapshotChunk))
  3513. }
  3514. return interceptor(ctx, in, info, handler)
  3515. }
  3516. func _ABCIApplication_ApplySnapshotChunk_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
  3517. in := new(RequestApplySnapshotChunk)
  3518. if err := dec(in); err != nil {
  3519. return nil, err
  3520. }
  3521. if interceptor == nil {
  3522. return srv.(ABCIApplicationServer).ApplySnapshotChunk(ctx, in)
  3523. }
  3524. info := &grpc.UnaryServerInfo{
  3525. Server: srv,
  3526. FullMethod: "/tendermint.abci.ABCIApplication/ApplySnapshotChunk",
  3527. }
  3528. handler := func(ctx context.Context, req interface{}) (interface{}, error) {
  3529. return srv.(ABCIApplicationServer).ApplySnapshotChunk(ctx, req.(*RequestApplySnapshotChunk))
  3530. }
  3531. return interceptor(ctx, in, info, handler)
  3532. }
  3533. var _ABCIApplication_serviceDesc = grpc.ServiceDesc{
  3534. ServiceName: "tendermint.abci.ABCIApplication",
  3535. HandlerType: (*ABCIApplicationServer)(nil),
  3536. Methods: []grpc.MethodDesc{
  3537. {
  3538. MethodName: "Echo",
  3539. Handler: _ABCIApplication_Echo_Handler,
  3540. },
  3541. {
  3542. MethodName: "Flush",
  3543. Handler: _ABCIApplication_Flush_Handler,
  3544. },
  3545. {
  3546. MethodName: "Info",
  3547. Handler: _ABCIApplication_Info_Handler,
  3548. },
  3549. {
  3550. MethodName: "SetOption",
  3551. Handler: _ABCIApplication_SetOption_Handler,
  3552. },
  3553. {
  3554. MethodName: "DeliverTx",
  3555. Handler: _ABCIApplication_DeliverTx_Handler,
  3556. },
  3557. {
  3558. MethodName: "CheckTx",
  3559. Handler: _ABCIApplication_CheckTx_Handler,
  3560. },
  3561. {
  3562. MethodName: "Query",
  3563. Handler: _ABCIApplication_Query_Handler,
  3564. },
  3565. {
  3566. MethodName: "Commit",
  3567. Handler: _ABCIApplication_Commit_Handler,
  3568. },
  3569. {
  3570. MethodName: "InitChain",
  3571. Handler: _ABCIApplication_InitChain_Handler,
  3572. },
  3573. {
  3574. MethodName: "BeginBlock",
  3575. Handler: _ABCIApplication_BeginBlock_Handler,
  3576. },
  3577. {
  3578. MethodName: "EndBlock",
  3579. Handler: _ABCIApplication_EndBlock_Handler,
  3580. },
  3581. {
  3582. MethodName: "ListSnapshots",
  3583. Handler: _ABCIApplication_ListSnapshots_Handler,
  3584. },
  3585. {
  3586. MethodName: "OfferSnapshot",
  3587. Handler: _ABCIApplication_OfferSnapshot_Handler,
  3588. },
  3589. {
  3590. MethodName: "LoadSnapshotChunk",
  3591. Handler: _ABCIApplication_LoadSnapshotChunk_Handler,
  3592. },
  3593. {
  3594. MethodName: "ApplySnapshotChunk",
  3595. Handler: _ABCIApplication_ApplySnapshotChunk_Handler,
  3596. },
  3597. },
  3598. Streams: []grpc.StreamDesc{},
  3599. Metadata: "tendermint/abci/types.proto",
  3600. }
  3601. func (m *Request) Marshal() (dAtA []byte, err error) {
  3602. size := m.Size()
  3603. dAtA = make([]byte, size)
  3604. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  3605. if err != nil {
  3606. return nil, err
  3607. }
  3608. return dAtA[:n], nil
  3609. }
  3610. func (m *Request) MarshalTo(dAtA []byte) (int, error) {
  3611. size := m.Size()
  3612. return m.MarshalToSizedBuffer(dAtA[:size])
  3613. }
  3614. func (m *Request) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3615. i := len(dAtA)
  3616. _ = i
  3617. var l int
  3618. _ = l
  3619. if m.Value != nil {
  3620. {
  3621. size := m.Value.Size()
  3622. i -= size
  3623. if _, err := m.Value.MarshalTo(dAtA[i:]); err != nil {
  3624. return 0, err
  3625. }
  3626. }
  3627. }
  3628. return len(dAtA) - i, nil
  3629. }
  3630. func (m *Request_Echo) MarshalTo(dAtA []byte) (int, error) {
  3631. size := m.Size()
  3632. return m.MarshalToSizedBuffer(dAtA[:size])
  3633. }
  3634. func (m *Request_Echo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3635. i := len(dAtA)
  3636. if m.Echo != nil {
  3637. {
  3638. size, err := m.Echo.MarshalToSizedBuffer(dAtA[:i])
  3639. if err != nil {
  3640. return 0, err
  3641. }
  3642. i -= size
  3643. i = encodeVarintTypes(dAtA, i, uint64(size))
  3644. }
  3645. i--
  3646. dAtA[i] = 0xa
  3647. }
  3648. return len(dAtA) - i, nil
  3649. }
  3650. func (m *Request_Flush) MarshalTo(dAtA []byte) (int, error) {
  3651. size := m.Size()
  3652. return m.MarshalToSizedBuffer(dAtA[:size])
  3653. }
  3654. func (m *Request_Flush) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3655. i := len(dAtA)
  3656. if m.Flush != nil {
  3657. {
  3658. size, err := m.Flush.MarshalToSizedBuffer(dAtA[:i])
  3659. if err != nil {
  3660. return 0, err
  3661. }
  3662. i -= size
  3663. i = encodeVarintTypes(dAtA, i, uint64(size))
  3664. }
  3665. i--
  3666. dAtA[i] = 0x12
  3667. }
  3668. return len(dAtA) - i, nil
  3669. }
  3670. func (m *Request_Info) MarshalTo(dAtA []byte) (int, error) {
  3671. size := m.Size()
  3672. return m.MarshalToSizedBuffer(dAtA[:size])
  3673. }
  3674. func (m *Request_Info) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3675. i := len(dAtA)
  3676. if m.Info != nil {
  3677. {
  3678. size, err := m.Info.MarshalToSizedBuffer(dAtA[:i])
  3679. if err != nil {
  3680. return 0, err
  3681. }
  3682. i -= size
  3683. i = encodeVarintTypes(dAtA, i, uint64(size))
  3684. }
  3685. i--
  3686. dAtA[i] = 0x1a
  3687. }
  3688. return len(dAtA) - i, nil
  3689. }
  3690. func (m *Request_SetOption) MarshalTo(dAtA []byte) (int, error) {
  3691. size := m.Size()
  3692. return m.MarshalToSizedBuffer(dAtA[:size])
  3693. }
  3694. func (m *Request_SetOption) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3695. i := len(dAtA)
  3696. if m.SetOption != nil {
  3697. {
  3698. size, err := m.SetOption.MarshalToSizedBuffer(dAtA[:i])
  3699. if err != nil {
  3700. return 0, err
  3701. }
  3702. i -= size
  3703. i = encodeVarintTypes(dAtA, i, uint64(size))
  3704. }
  3705. i--
  3706. dAtA[i] = 0x22
  3707. }
  3708. return len(dAtA) - i, nil
  3709. }
  3710. func (m *Request_InitChain) MarshalTo(dAtA []byte) (int, error) {
  3711. size := m.Size()
  3712. return m.MarshalToSizedBuffer(dAtA[:size])
  3713. }
  3714. func (m *Request_InitChain) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3715. i := len(dAtA)
  3716. if m.InitChain != nil {
  3717. {
  3718. size, err := m.InitChain.MarshalToSizedBuffer(dAtA[:i])
  3719. if err != nil {
  3720. return 0, err
  3721. }
  3722. i -= size
  3723. i = encodeVarintTypes(dAtA, i, uint64(size))
  3724. }
  3725. i--
  3726. dAtA[i] = 0x2a
  3727. }
  3728. return len(dAtA) - i, nil
  3729. }
  3730. func (m *Request_Query) MarshalTo(dAtA []byte) (int, error) {
  3731. size := m.Size()
  3732. return m.MarshalToSizedBuffer(dAtA[:size])
  3733. }
  3734. func (m *Request_Query) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3735. i := len(dAtA)
  3736. if m.Query != nil {
  3737. {
  3738. size, err := m.Query.MarshalToSizedBuffer(dAtA[:i])
  3739. if err != nil {
  3740. return 0, err
  3741. }
  3742. i -= size
  3743. i = encodeVarintTypes(dAtA, i, uint64(size))
  3744. }
  3745. i--
  3746. dAtA[i] = 0x32
  3747. }
  3748. return len(dAtA) - i, nil
  3749. }
  3750. func (m *Request_BeginBlock) MarshalTo(dAtA []byte) (int, error) {
  3751. size := m.Size()
  3752. return m.MarshalToSizedBuffer(dAtA[:size])
  3753. }
  3754. func (m *Request_BeginBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3755. i := len(dAtA)
  3756. if m.BeginBlock != nil {
  3757. {
  3758. size, err := m.BeginBlock.MarshalToSizedBuffer(dAtA[:i])
  3759. if err != nil {
  3760. return 0, err
  3761. }
  3762. i -= size
  3763. i = encodeVarintTypes(dAtA, i, uint64(size))
  3764. }
  3765. i--
  3766. dAtA[i] = 0x3a
  3767. }
  3768. return len(dAtA) - i, nil
  3769. }
  3770. func (m *Request_CheckTx) MarshalTo(dAtA []byte) (int, error) {
  3771. size := m.Size()
  3772. return m.MarshalToSizedBuffer(dAtA[:size])
  3773. }
  3774. func (m *Request_CheckTx) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3775. i := len(dAtA)
  3776. if m.CheckTx != nil {
  3777. {
  3778. size, err := m.CheckTx.MarshalToSizedBuffer(dAtA[:i])
  3779. if err != nil {
  3780. return 0, err
  3781. }
  3782. i -= size
  3783. i = encodeVarintTypes(dAtA, i, uint64(size))
  3784. }
  3785. i--
  3786. dAtA[i] = 0x42
  3787. }
  3788. return len(dAtA) - i, nil
  3789. }
  3790. func (m *Request_DeliverTx) MarshalTo(dAtA []byte) (int, error) {
  3791. size := m.Size()
  3792. return m.MarshalToSizedBuffer(dAtA[:size])
  3793. }
  3794. func (m *Request_DeliverTx) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3795. i := len(dAtA)
  3796. if m.DeliverTx != nil {
  3797. {
  3798. size, err := m.DeliverTx.MarshalToSizedBuffer(dAtA[:i])
  3799. if err != nil {
  3800. return 0, err
  3801. }
  3802. i -= size
  3803. i = encodeVarintTypes(dAtA, i, uint64(size))
  3804. }
  3805. i--
  3806. dAtA[i] = 0x4a
  3807. }
  3808. return len(dAtA) - i, nil
  3809. }
  3810. func (m *Request_EndBlock) MarshalTo(dAtA []byte) (int, error) {
  3811. size := m.Size()
  3812. return m.MarshalToSizedBuffer(dAtA[:size])
  3813. }
  3814. func (m *Request_EndBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3815. i := len(dAtA)
  3816. if m.EndBlock != nil {
  3817. {
  3818. size, err := m.EndBlock.MarshalToSizedBuffer(dAtA[:i])
  3819. if err != nil {
  3820. return 0, err
  3821. }
  3822. i -= size
  3823. i = encodeVarintTypes(dAtA, i, uint64(size))
  3824. }
  3825. i--
  3826. dAtA[i] = 0x52
  3827. }
  3828. return len(dAtA) - i, nil
  3829. }
  3830. func (m *Request_Commit) MarshalTo(dAtA []byte) (int, error) {
  3831. size := m.Size()
  3832. return m.MarshalToSizedBuffer(dAtA[:size])
  3833. }
  3834. func (m *Request_Commit) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3835. i := len(dAtA)
  3836. if m.Commit != nil {
  3837. {
  3838. size, err := m.Commit.MarshalToSizedBuffer(dAtA[:i])
  3839. if err != nil {
  3840. return 0, err
  3841. }
  3842. i -= size
  3843. i = encodeVarintTypes(dAtA, i, uint64(size))
  3844. }
  3845. i--
  3846. dAtA[i] = 0x5a
  3847. }
  3848. return len(dAtA) - i, nil
  3849. }
  3850. func (m *Request_ListSnapshots) MarshalTo(dAtA []byte) (int, error) {
  3851. size := m.Size()
  3852. return m.MarshalToSizedBuffer(dAtA[:size])
  3853. }
  3854. func (m *Request_ListSnapshots) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3855. i := len(dAtA)
  3856. if m.ListSnapshots != nil {
  3857. {
  3858. size, err := m.ListSnapshots.MarshalToSizedBuffer(dAtA[:i])
  3859. if err != nil {
  3860. return 0, err
  3861. }
  3862. i -= size
  3863. i = encodeVarintTypes(dAtA, i, uint64(size))
  3864. }
  3865. i--
  3866. dAtA[i] = 0x62
  3867. }
  3868. return len(dAtA) - i, nil
  3869. }
  3870. func (m *Request_OfferSnapshot) MarshalTo(dAtA []byte) (int, error) {
  3871. size := m.Size()
  3872. return m.MarshalToSizedBuffer(dAtA[:size])
  3873. }
  3874. func (m *Request_OfferSnapshot) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3875. i := len(dAtA)
  3876. if m.OfferSnapshot != nil {
  3877. {
  3878. size, err := m.OfferSnapshot.MarshalToSizedBuffer(dAtA[:i])
  3879. if err != nil {
  3880. return 0, err
  3881. }
  3882. i -= size
  3883. i = encodeVarintTypes(dAtA, i, uint64(size))
  3884. }
  3885. i--
  3886. dAtA[i] = 0x6a
  3887. }
  3888. return len(dAtA) - i, nil
  3889. }
  3890. func (m *Request_LoadSnapshotChunk) MarshalTo(dAtA []byte) (int, error) {
  3891. size := m.Size()
  3892. return m.MarshalToSizedBuffer(dAtA[:size])
  3893. }
  3894. func (m *Request_LoadSnapshotChunk) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3895. i := len(dAtA)
  3896. if m.LoadSnapshotChunk != nil {
  3897. {
  3898. size, err := m.LoadSnapshotChunk.MarshalToSizedBuffer(dAtA[:i])
  3899. if err != nil {
  3900. return 0, err
  3901. }
  3902. i -= size
  3903. i = encodeVarintTypes(dAtA, i, uint64(size))
  3904. }
  3905. i--
  3906. dAtA[i] = 0x72
  3907. }
  3908. return len(dAtA) - i, nil
  3909. }
  3910. func (m *Request_ApplySnapshotChunk) MarshalTo(dAtA []byte) (int, error) {
  3911. size := m.Size()
  3912. return m.MarshalToSizedBuffer(dAtA[:size])
  3913. }
  3914. func (m *Request_ApplySnapshotChunk) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3915. i := len(dAtA)
  3916. if m.ApplySnapshotChunk != nil {
  3917. {
  3918. size, err := m.ApplySnapshotChunk.MarshalToSizedBuffer(dAtA[:i])
  3919. if err != nil {
  3920. return 0, err
  3921. }
  3922. i -= size
  3923. i = encodeVarintTypes(dAtA, i, uint64(size))
  3924. }
  3925. i--
  3926. dAtA[i] = 0x7a
  3927. }
  3928. return len(dAtA) - i, nil
  3929. }
  3930. func (m *RequestEcho) Marshal() (dAtA []byte, err error) {
  3931. size := m.Size()
  3932. dAtA = make([]byte, size)
  3933. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  3934. if err != nil {
  3935. return nil, err
  3936. }
  3937. return dAtA[:n], nil
  3938. }
  3939. func (m *RequestEcho) MarshalTo(dAtA []byte) (int, error) {
  3940. size := m.Size()
  3941. return m.MarshalToSizedBuffer(dAtA[:size])
  3942. }
  3943. func (m *RequestEcho) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3944. i := len(dAtA)
  3945. _ = i
  3946. var l int
  3947. _ = l
  3948. if len(m.Message) > 0 {
  3949. i -= len(m.Message)
  3950. copy(dAtA[i:], m.Message)
  3951. i = encodeVarintTypes(dAtA, i, uint64(len(m.Message)))
  3952. i--
  3953. dAtA[i] = 0xa
  3954. }
  3955. return len(dAtA) - i, nil
  3956. }
  3957. func (m *RequestFlush) Marshal() (dAtA []byte, err error) {
  3958. size := m.Size()
  3959. dAtA = make([]byte, size)
  3960. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  3961. if err != nil {
  3962. return nil, err
  3963. }
  3964. return dAtA[:n], nil
  3965. }
  3966. func (m *RequestFlush) MarshalTo(dAtA []byte) (int, error) {
  3967. size := m.Size()
  3968. return m.MarshalToSizedBuffer(dAtA[:size])
  3969. }
  3970. func (m *RequestFlush) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3971. i := len(dAtA)
  3972. _ = i
  3973. var l int
  3974. _ = l
  3975. return len(dAtA) - i, nil
  3976. }
  3977. func (m *RequestInfo) Marshal() (dAtA []byte, err error) {
  3978. size := m.Size()
  3979. dAtA = make([]byte, size)
  3980. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  3981. if err != nil {
  3982. return nil, err
  3983. }
  3984. return dAtA[:n], nil
  3985. }
  3986. func (m *RequestInfo) MarshalTo(dAtA []byte) (int, error) {
  3987. size := m.Size()
  3988. return m.MarshalToSizedBuffer(dAtA[:size])
  3989. }
  3990. func (m *RequestInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  3991. i := len(dAtA)
  3992. _ = i
  3993. var l int
  3994. _ = l
  3995. if m.P2PVersion != 0 {
  3996. i = encodeVarintTypes(dAtA, i, uint64(m.P2PVersion))
  3997. i--
  3998. dAtA[i] = 0x18
  3999. }
  4000. if m.BlockVersion != 0 {
  4001. i = encodeVarintTypes(dAtA, i, uint64(m.BlockVersion))
  4002. i--
  4003. dAtA[i] = 0x10
  4004. }
  4005. if len(m.Version) > 0 {
  4006. i -= len(m.Version)
  4007. copy(dAtA[i:], m.Version)
  4008. i = encodeVarintTypes(dAtA, i, uint64(len(m.Version)))
  4009. i--
  4010. dAtA[i] = 0xa
  4011. }
  4012. return len(dAtA) - i, nil
  4013. }
  4014. func (m *RequestSetOption) Marshal() (dAtA []byte, err error) {
  4015. size := m.Size()
  4016. dAtA = make([]byte, size)
  4017. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4018. if err != nil {
  4019. return nil, err
  4020. }
  4021. return dAtA[:n], nil
  4022. }
  4023. func (m *RequestSetOption) MarshalTo(dAtA []byte) (int, error) {
  4024. size := m.Size()
  4025. return m.MarshalToSizedBuffer(dAtA[:size])
  4026. }
  4027. func (m *RequestSetOption) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4028. i := len(dAtA)
  4029. _ = i
  4030. var l int
  4031. _ = l
  4032. if len(m.Value) > 0 {
  4033. i -= len(m.Value)
  4034. copy(dAtA[i:], m.Value)
  4035. i = encodeVarintTypes(dAtA, i, uint64(len(m.Value)))
  4036. i--
  4037. dAtA[i] = 0x12
  4038. }
  4039. if len(m.Key) > 0 {
  4040. i -= len(m.Key)
  4041. copy(dAtA[i:], m.Key)
  4042. i = encodeVarintTypes(dAtA, i, uint64(len(m.Key)))
  4043. i--
  4044. dAtA[i] = 0xa
  4045. }
  4046. return len(dAtA) - i, nil
  4047. }
  4048. func (m *RequestInitChain) Marshal() (dAtA []byte, err error) {
  4049. size := m.Size()
  4050. dAtA = make([]byte, size)
  4051. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4052. if err != nil {
  4053. return nil, err
  4054. }
  4055. return dAtA[:n], nil
  4056. }
  4057. func (m *RequestInitChain) MarshalTo(dAtA []byte) (int, error) {
  4058. size := m.Size()
  4059. return m.MarshalToSizedBuffer(dAtA[:size])
  4060. }
  4061. func (m *RequestInitChain) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4062. i := len(dAtA)
  4063. _ = i
  4064. var l int
  4065. _ = l
  4066. if m.InitialHeight != 0 {
  4067. i = encodeVarintTypes(dAtA, i, uint64(m.InitialHeight))
  4068. i--
  4069. dAtA[i] = 0x30
  4070. }
  4071. if len(m.AppStateBytes) > 0 {
  4072. i -= len(m.AppStateBytes)
  4073. copy(dAtA[i:], m.AppStateBytes)
  4074. i = encodeVarintTypes(dAtA, i, uint64(len(m.AppStateBytes)))
  4075. i--
  4076. dAtA[i] = 0x2a
  4077. }
  4078. if len(m.Validators) > 0 {
  4079. for iNdEx := len(m.Validators) - 1; iNdEx >= 0; iNdEx-- {
  4080. {
  4081. size, err := m.Validators[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  4082. if err != nil {
  4083. return 0, err
  4084. }
  4085. i -= size
  4086. i = encodeVarintTypes(dAtA, i, uint64(size))
  4087. }
  4088. i--
  4089. dAtA[i] = 0x22
  4090. }
  4091. }
  4092. if m.ConsensusParams != nil {
  4093. {
  4094. size, err := m.ConsensusParams.MarshalToSizedBuffer(dAtA[:i])
  4095. if err != nil {
  4096. return 0, err
  4097. }
  4098. i -= size
  4099. i = encodeVarintTypes(dAtA, i, uint64(size))
  4100. }
  4101. i--
  4102. dAtA[i] = 0x1a
  4103. }
  4104. if len(m.ChainId) > 0 {
  4105. i -= len(m.ChainId)
  4106. copy(dAtA[i:], m.ChainId)
  4107. i = encodeVarintTypes(dAtA, i, uint64(len(m.ChainId)))
  4108. i--
  4109. dAtA[i] = 0x12
  4110. }
  4111. n17, err17 := github_com_gogo_protobuf_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(m.Time):])
  4112. if err17 != nil {
  4113. return 0, err17
  4114. }
  4115. i -= n17
  4116. i = encodeVarintTypes(dAtA, i, uint64(n17))
  4117. i--
  4118. dAtA[i] = 0xa
  4119. return len(dAtA) - i, nil
  4120. }
  4121. func (m *RequestQuery) Marshal() (dAtA []byte, err error) {
  4122. size := m.Size()
  4123. dAtA = make([]byte, size)
  4124. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4125. if err != nil {
  4126. return nil, err
  4127. }
  4128. return dAtA[:n], nil
  4129. }
  4130. func (m *RequestQuery) MarshalTo(dAtA []byte) (int, error) {
  4131. size := m.Size()
  4132. return m.MarshalToSizedBuffer(dAtA[:size])
  4133. }
  4134. func (m *RequestQuery) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4135. i := len(dAtA)
  4136. _ = i
  4137. var l int
  4138. _ = l
  4139. if m.Prove {
  4140. i--
  4141. if m.Prove {
  4142. dAtA[i] = 1
  4143. } else {
  4144. dAtA[i] = 0
  4145. }
  4146. i--
  4147. dAtA[i] = 0x20
  4148. }
  4149. if m.Height != 0 {
  4150. i = encodeVarintTypes(dAtA, i, uint64(m.Height))
  4151. i--
  4152. dAtA[i] = 0x18
  4153. }
  4154. if len(m.Path) > 0 {
  4155. i -= len(m.Path)
  4156. copy(dAtA[i:], m.Path)
  4157. i = encodeVarintTypes(dAtA, i, uint64(len(m.Path)))
  4158. i--
  4159. dAtA[i] = 0x12
  4160. }
  4161. if len(m.Data) > 0 {
  4162. i -= len(m.Data)
  4163. copy(dAtA[i:], m.Data)
  4164. i = encodeVarintTypes(dAtA, i, uint64(len(m.Data)))
  4165. i--
  4166. dAtA[i] = 0xa
  4167. }
  4168. return len(dAtA) - i, nil
  4169. }
  4170. func (m *RequestBeginBlock) Marshal() (dAtA []byte, err error) {
  4171. size := m.Size()
  4172. dAtA = make([]byte, size)
  4173. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4174. if err != nil {
  4175. return nil, err
  4176. }
  4177. return dAtA[:n], nil
  4178. }
  4179. func (m *RequestBeginBlock) MarshalTo(dAtA []byte) (int, error) {
  4180. size := m.Size()
  4181. return m.MarshalToSizedBuffer(dAtA[:size])
  4182. }
  4183. func (m *RequestBeginBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4184. i := len(dAtA)
  4185. _ = i
  4186. var l int
  4187. _ = l
  4188. if len(m.ByzantineValidators) > 0 {
  4189. for iNdEx := len(m.ByzantineValidators) - 1; iNdEx >= 0; iNdEx-- {
  4190. {
  4191. size, err := m.ByzantineValidators[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  4192. if err != nil {
  4193. return 0, err
  4194. }
  4195. i -= size
  4196. i = encodeVarintTypes(dAtA, i, uint64(size))
  4197. }
  4198. i--
  4199. dAtA[i] = 0x22
  4200. }
  4201. }
  4202. {
  4203. size, err := m.LastCommitInfo.MarshalToSizedBuffer(dAtA[:i])
  4204. if err != nil {
  4205. return 0, err
  4206. }
  4207. i -= size
  4208. i = encodeVarintTypes(dAtA, i, uint64(size))
  4209. }
  4210. i--
  4211. dAtA[i] = 0x1a
  4212. {
  4213. size, err := m.Header.MarshalToSizedBuffer(dAtA[:i])
  4214. if err != nil {
  4215. return 0, err
  4216. }
  4217. i -= size
  4218. i = encodeVarintTypes(dAtA, i, uint64(size))
  4219. }
  4220. i--
  4221. dAtA[i] = 0x12
  4222. if len(m.Hash) > 0 {
  4223. i -= len(m.Hash)
  4224. copy(dAtA[i:], m.Hash)
  4225. i = encodeVarintTypes(dAtA, i, uint64(len(m.Hash)))
  4226. i--
  4227. dAtA[i] = 0xa
  4228. }
  4229. return len(dAtA) - i, nil
  4230. }
  4231. func (m *RequestCheckTx) Marshal() (dAtA []byte, err error) {
  4232. size := m.Size()
  4233. dAtA = make([]byte, size)
  4234. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4235. if err != nil {
  4236. return nil, err
  4237. }
  4238. return dAtA[:n], nil
  4239. }
  4240. func (m *RequestCheckTx) MarshalTo(dAtA []byte) (int, error) {
  4241. size := m.Size()
  4242. return m.MarshalToSizedBuffer(dAtA[:size])
  4243. }
  4244. func (m *RequestCheckTx) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4245. i := len(dAtA)
  4246. _ = i
  4247. var l int
  4248. _ = l
  4249. if m.Type != 0 {
  4250. i = encodeVarintTypes(dAtA, i, uint64(m.Type))
  4251. i--
  4252. dAtA[i] = 0x10
  4253. }
  4254. if len(m.Tx) > 0 {
  4255. i -= len(m.Tx)
  4256. copy(dAtA[i:], m.Tx)
  4257. i = encodeVarintTypes(dAtA, i, uint64(len(m.Tx)))
  4258. i--
  4259. dAtA[i] = 0xa
  4260. }
  4261. return len(dAtA) - i, nil
  4262. }
  4263. func (m *RequestDeliverTx) Marshal() (dAtA []byte, err error) {
  4264. size := m.Size()
  4265. dAtA = make([]byte, size)
  4266. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4267. if err != nil {
  4268. return nil, err
  4269. }
  4270. return dAtA[:n], nil
  4271. }
  4272. func (m *RequestDeliverTx) MarshalTo(dAtA []byte) (int, error) {
  4273. size := m.Size()
  4274. return m.MarshalToSizedBuffer(dAtA[:size])
  4275. }
  4276. func (m *RequestDeliverTx) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4277. i := len(dAtA)
  4278. _ = i
  4279. var l int
  4280. _ = l
  4281. if len(m.Tx) > 0 {
  4282. i -= len(m.Tx)
  4283. copy(dAtA[i:], m.Tx)
  4284. i = encodeVarintTypes(dAtA, i, uint64(len(m.Tx)))
  4285. i--
  4286. dAtA[i] = 0xa
  4287. }
  4288. return len(dAtA) - i, nil
  4289. }
  4290. func (m *RequestEndBlock) Marshal() (dAtA []byte, err error) {
  4291. size := m.Size()
  4292. dAtA = make([]byte, size)
  4293. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4294. if err != nil {
  4295. return nil, err
  4296. }
  4297. return dAtA[:n], nil
  4298. }
  4299. func (m *RequestEndBlock) MarshalTo(dAtA []byte) (int, error) {
  4300. size := m.Size()
  4301. return m.MarshalToSizedBuffer(dAtA[:size])
  4302. }
  4303. func (m *RequestEndBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4304. i := len(dAtA)
  4305. _ = i
  4306. var l int
  4307. _ = l
  4308. if m.Height != 0 {
  4309. i = encodeVarintTypes(dAtA, i, uint64(m.Height))
  4310. i--
  4311. dAtA[i] = 0x8
  4312. }
  4313. return len(dAtA) - i, nil
  4314. }
  4315. func (m *RequestCommit) Marshal() (dAtA []byte, err error) {
  4316. size := m.Size()
  4317. dAtA = make([]byte, size)
  4318. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4319. if err != nil {
  4320. return nil, err
  4321. }
  4322. return dAtA[:n], nil
  4323. }
  4324. func (m *RequestCommit) MarshalTo(dAtA []byte) (int, error) {
  4325. size := m.Size()
  4326. return m.MarshalToSizedBuffer(dAtA[:size])
  4327. }
  4328. func (m *RequestCommit) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4329. i := len(dAtA)
  4330. _ = i
  4331. var l int
  4332. _ = l
  4333. return len(dAtA) - i, nil
  4334. }
  4335. func (m *RequestListSnapshots) Marshal() (dAtA []byte, err error) {
  4336. size := m.Size()
  4337. dAtA = make([]byte, size)
  4338. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4339. if err != nil {
  4340. return nil, err
  4341. }
  4342. return dAtA[:n], nil
  4343. }
  4344. func (m *RequestListSnapshots) MarshalTo(dAtA []byte) (int, error) {
  4345. size := m.Size()
  4346. return m.MarshalToSizedBuffer(dAtA[:size])
  4347. }
  4348. func (m *RequestListSnapshots) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4349. i := len(dAtA)
  4350. _ = i
  4351. var l int
  4352. _ = l
  4353. return len(dAtA) - i, nil
  4354. }
  4355. func (m *RequestOfferSnapshot) Marshal() (dAtA []byte, err error) {
  4356. size := m.Size()
  4357. dAtA = make([]byte, size)
  4358. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4359. if err != nil {
  4360. return nil, err
  4361. }
  4362. return dAtA[:n], nil
  4363. }
  4364. func (m *RequestOfferSnapshot) MarshalTo(dAtA []byte) (int, error) {
  4365. size := m.Size()
  4366. return m.MarshalToSizedBuffer(dAtA[:size])
  4367. }
  4368. func (m *RequestOfferSnapshot) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4369. i := len(dAtA)
  4370. _ = i
  4371. var l int
  4372. _ = l
  4373. if len(m.AppHash) > 0 {
  4374. i -= len(m.AppHash)
  4375. copy(dAtA[i:], m.AppHash)
  4376. i = encodeVarintTypes(dAtA, i, uint64(len(m.AppHash)))
  4377. i--
  4378. dAtA[i] = 0x12
  4379. }
  4380. if m.Snapshot != nil {
  4381. {
  4382. size, err := m.Snapshot.MarshalToSizedBuffer(dAtA[:i])
  4383. if err != nil {
  4384. return 0, err
  4385. }
  4386. i -= size
  4387. i = encodeVarintTypes(dAtA, i, uint64(size))
  4388. }
  4389. i--
  4390. dAtA[i] = 0xa
  4391. }
  4392. return len(dAtA) - i, nil
  4393. }
  4394. func (m *RequestLoadSnapshotChunk) Marshal() (dAtA []byte, err error) {
  4395. size := m.Size()
  4396. dAtA = make([]byte, size)
  4397. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4398. if err != nil {
  4399. return nil, err
  4400. }
  4401. return dAtA[:n], nil
  4402. }
  4403. func (m *RequestLoadSnapshotChunk) MarshalTo(dAtA []byte) (int, error) {
  4404. size := m.Size()
  4405. return m.MarshalToSizedBuffer(dAtA[:size])
  4406. }
  4407. func (m *RequestLoadSnapshotChunk) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4408. i := len(dAtA)
  4409. _ = i
  4410. var l int
  4411. _ = l
  4412. if m.Chunk != 0 {
  4413. i = encodeVarintTypes(dAtA, i, uint64(m.Chunk))
  4414. i--
  4415. dAtA[i] = 0x18
  4416. }
  4417. if m.Format != 0 {
  4418. i = encodeVarintTypes(dAtA, i, uint64(m.Format))
  4419. i--
  4420. dAtA[i] = 0x10
  4421. }
  4422. if m.Height != 0 {
  4423. i = encodeVarintTypes(dAtA, i, uint64(m.Height))
  4424. i--
  4425. dAtA[i] = 0x8
  4426. }
  4427. return len(dAtA) - i, nil
  4428. }
  4429. func (m *RequestApplySnapshotChunk) Marshal() (dAtA []byte, err error) {
  4430. size := m.Size()
  4431. dAtA = make([]byte, size)
  4432. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4433. if err != nil {
  4434. return nil, err
  4435. }
  4436. return dAtA[:n], nil
  4437. }
  4438. func (m *RequestApplySnapshotChunk) MarshalTo(dAtA []byte) (int, error) {
  4439. size := m.Size()
  4440. return m.MarshalToSizedBuffer(dAtA[:size])
  4441. }
  4442. func (m *RequestApplySnapshotChunk) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4443. i := len(dAtA)
  4444. _ = i
  4445. var l int
  4446. _ = l
  4447. if len(m.Sender) > 0 {
  4448. i -= len(m.Sender)
  4449. copy(dAtA[i:], m.Sender)
  4450. i = encodeVarintTypes(dAtA, i, uint64(len(m.Sender)))
  4451. i--
  4452. dAtA[i] = 0x1a
  4453. }
  4454. if len(m.Chunk) > 0 {
  4455. i -= len(m.Chunk)
  4456. copy(dAtA[i:], m.Chunk)
  4457. i = encodeVarintTypes(dAtA, i, uint64(len(m.Chunk)))
  4458. i--
  4459. dAtA[i] = 0x12
  4460. }
  4461. if m.Index != 0 {
  4462. i = encodeVarintTypes(dAtA, i, uint64(m.Index))
  4463. i--
  4464. dAtA[i] = 0x8
  4465. }
  4466. return len(dAtA) - i, nil
  4467. }
  4468. func (m *Response) Marshal() (dAtA []byte, err error) {
  4469. size := m.Size()
  4470. dAtA = make([]byte, size)
  4471. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4472. if err != nil {
  4473. return nil, err
  4474. }
  4475. return dAtA[:n], nil
  4476. }
  4477. func (m *Response) MarshalTo(dAtA []byte) (int, error) {
  4478. size := m.Size()
  4479. return m.MarshalToSizedBuffer(dAtA[:size])
  4480. }
  4481. func (m *Response) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4482. i := len(dAtA)
  4483. _ = i
  4484. var l int
  4485. _ = l
  4486. if m.Value != nil {
  4487. {
  4488. size := m.Value.Size()
  4489. i -= size
  4490. if _, err := m.Value.MarshalTo(dAtA[i:]); err != nil {
  4491. return 0, err
  4492. }
  4493. }
  4494. }
  4495. return len(dAtA) - i, nil
  4496. }
  4497. func (m *Response_Exception) MarshalTo(dAtA []byte) (int, error) {
  4498. size := m.Size()
  4499. return m.MarshalToSizedBuffer(dAtA[:size])
  4500. }
  4501. func (m *Response_Exception) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4502. i := len(dAtA)
  4503. if m.Exception != nil {
  4504. {
  4505. size, err := m.Exception.MarshalToSizedBuffer(dAtA[:i])
  4506. if err != nil {
  4507. return 0, err
  4508. }
  4509. i -= size
  4510. i = encodeVarintTypes(dAtA, i, uint64(size))
  4511. }
  4512. i--
  4513. dAtA[i] = 0xa
  4514. }
  4515. return len(dAtA) - i, nil
  4516. }
  4517. func (m *Response_Echo) MarshalTo(dAtA []byte) (int, error) {
  4518. size := m.Size()
  4519. return m.MarshalToSizedBuffer(dAtA[:size])
  4520. }
  4521. func (m *Response_Echo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4522. i := len(dAtA)
  4523. if m.Echo != nil {
  4524. {
  4525. size, err := m.Echo.MarshalToSizedBuffer(dAtA[:i])
  4526. if err != nil {
  4527. return 0, err
  4528. }
  4529. i -= size
  4530. i = encodeVarintTypes(dAtA, i, uint64(size))
  4531. }
  4532. i--
  4533. dAtA[i] = 0x12
  4534. }
  4535. return len(dAtA) - i, nil
  4536. }
  4537. func (m *Response_Flush) MarshalTo(dAtA []byte) (int, error) {
  4538. size := m.Size()
  4539. return m.MarshalToSizedBuffer(dAtA[:size])
  4540. }
  4541. func (m *Response_Flush) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4542. i := len(dAtA)
  4543. if m.Flush != nil {
  4544. {
  4545. size, err := m.Flush.MarshalToSizedBuffer(dAtA[:i])
  4546. if err != nil {
  4547. return 0, err
  4548. }
  4549. i -= size
  4550. i = encodeVarintTypes(dAtA, i, uint64(size))
  4551. }
  4552. i--
  4553. dAtA[i] = 0x1a
  4554. }
  4555. return len(dAtA) - i, nil
  4556. }
  4557. func (m *Response_Info) MarshalTo(dAtA []byte) (int, error) {
  4558. size := m.Size()
  4559. return m.MarshalToSizedBuffer(dAtA[:size])
  4560. }
  4561. func (m *Response_Info) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4562. i := len(dAtA)
  4563. if m.Info != nil {
  4564. {
  4565. size, err := m.Info.MarshalToSizedBuffer(dAtA[:i])
  4566. if err != nil {
  4567. return 0, err
  4568. }
  4569. i -= size
  4570. i = encodeVarintTypes(dAtA, i, uint64(size))
  4571. }
  4572. i--
  4573. dAtA[i] = 0x22
  4574. }
  4575. return len(dAtA) - i, nil
  4576. }
  4577. func (m *Response_SetOption) MarshalTo(dAtA []byte) (int, error) {
  4578. size := m.Size()
  4579. return m.MarshalToSizedBuffer(dAtA[:size])
  4580. }
  4581. func (m *Response_SetOption) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4582. i := len(dAtA)
  4583. if m.SetOption != nil {
  4584. {
  4585. size, err := m.SetOption.MarshalToSizedBuffer(dAtA[:i])
  4586. if err != nil {
  4587. return 0, err
  4588. }
  4589. i -= size
  4590. i = encodeVarintTypes(dAtA, i, uint64(size))
  4591. }
  4592. i--
  4593. dAtA[i] = 0x2a
  4594. }
  4595. return len(dAtA) - i, nil
  4596. }
  4597. func (m *Response_InitChain) MarshalTo(dAtA []byte) (int, error) {
  4598. size := m.Size()
  4599. return m.MarshalToSizedBuffer(dAtA[:size])
  4600. }
  4601. func (m *Response_InitChain) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4602. i := len(dAtA)
  4603. if m.InitChain != nil {
  4604. {
  4605. size, err := m.InitChain.MarshalToSizedBuffer(dAtA[:i])
  4606. if err != nil {
  4607. return 0, err
  4608. }
  4609. i -= size
  4610. i = encodeVarintTypes(dAtA, i, uint64(size))
  4611. }
  4612. i--
  4613. dAtA[i] = 0x32
  4614. }
  4615. return len(dAtA) - i, nil
  4616. }
  4617. func (m *Response_Query) MarshalTo(dAtA []byte) (int, error) {
  4618. size := m.Size()
  4619. return m.MarshalToSizedBuffer(dAtA[:size])
  4620. }
  4621. func (m *Response_Query) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4622. i := len(dAtA)
  4623. if m.Query != nil {
  4624. {
  4625. size, err := m.Query.MarshalToSizedBuffer(dAtA[:i])
  4626. if err != nil {
  4627. return 0, err
  4628. }
  4629. i -= size
  4630. i = encodeVarintTypes(dAtA, i, uint64(size))
  4631. }
  4632. i--
  4633. dAtA[i] = 0x3a
  4634. }
  4635. return len(dAtA) - i, nil
  4636. }
  4637. func (m *Response_BeginBlock) MarshalTo(dAtA []byte) (int, error) {
  4638. size := m.Size()
  4639. return m.MarshalToSizedBuffer(dAtA[:size])
  4640. }
  4641. func (m *Response_BeginBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4642. i := len(dAtA)
  4643. if m.BeginBlock != nil {
  4644. {
  4645. size, err := m.BeginBlock.MarshalToSizedBuffer(dAtA[:i])
  4646. if err != nil {
  4647. return 0, err
  4648. }
  4649. i -= size
  4650. i = encodeVarintTypes(dAtA, i, uint64(size))
  4651. }
  4652. i--
  4653. dAtA[i] = 0x42
  4654. }
  4655. return len(dAtA) - i, nil
  4656. }
  4657. func (m *Response_CheckTx) MarshalTo(dAtA []byte) (int, error) {
  4658. size := m.Size()
  4659. return m.MarshalToSizedBuffer(dAtA[:size])
  4660. }
  4661. func (m *Response_CheckTx) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4662. i := len(dAtA)
  4663. if m.CheckTx != nil {
  4664. {
  4665. size, err := m.CheckTx.MarshalToSizedBuffer(dAtA[:i])
  4666. if err != nil {
  4667. return 0, err
  4668. }
  4669. i -= size
  4670. i = encodeVarintTypes(dAtA, i, uint64(size))
  4671. }
  4672. i--
  4673. dAtA[i] = 0x4a
  4674. }
  4675. return len(dAtA) - i, nil
  4676. }
  4677. func (m *Response_DeliverTx) MarshalTo(dAtA []byte) (int, error) {
  4678. size := m.Size()
  4679. return m.MarshalToSizedBuffer(dAtA[:size])
  4680. }
  4681. func (m *Response_DeliverTx) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4682. i := len(dAtA)
  4683. if m.DeliverTx != nil {
  4684. {
  4685. size, err := m.DeliverTx.MarshalToSizedBuffer(dAtA[:i])
  4686. if err != nil {
  4687. return 0, err
  4688. }
  4689. i -= size
  4690. i = encodeVarintTypes(dAtA, i, uint64(size))
  4691. }
  4692. i--
  4693. dAtA[i] = 0x52
  4694. }
  4695. return len(dAtA) - i, nil
  4696. }
  4697. func (m *Response_EndBlock) MarshalTo(dAtA []byte) (int, error) {
  4698. size := m.Size()
  4699. return m.MarshalToSizedBuffer(dAtA[:size])
  4700. }
  4701. func (m *Response_EndBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4702. i := len(dAtA)
  4703. if m.EndBlock != nil {
  4704. {
  4705. size, err := m.EndBlock.MarshalToSizedBuffer(dAtA[:i])
  4706. if err != nil {
  4707. return 0, err
  4708. }
  4709. i -= size
  4710. i = encodeVarintTypes(dAtA, i, uint64(size))
  4711. }
  4712. i--
  4713. dAtA[i] = 0x5a
  4714. }
  4715. return len(dAtA) - i, nil
  4716. }
  4717. func (m *Response_Commit) MarshalTo(dAtA []byte) (int, error) {
  4718. size := m.Size()
  4719. return m.MarshalToSizedBuffer(dAtA[:size])
  4720. }
  4721. func (m *Response_Commit) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4722. i := len(dAtA)
  4723. if m.Commit != nil {
  4724. {
  4725. size, err := m.Commit.MarshalToSizedBuffer(dAtA[:i])
  4726. if err != nil {
  4727. return 0, err
  4728. }
  4729. i -= size
  4730. i = encodeVarintTypes(dAtA, i, uint64(size))
  4731. }
  4732. i--
  4733. dAtA[i] = 0x62
  4734. }
  4735. return len(dAtA) - i, nil
  4736. }
  4737. func (m *Response_ListSnapshots) MarshalTo(dAtA []byte) (int, error) {
  4738. size := m.Size()
  4739. return m.MarshalToSizedBuffer(dAtA[:size])
  4740. }
  4741. func (m *Response_ListSnapshots) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4742. i := len(dAtA)
  4743. if m.ListSnapshots != nil {
  4744. {
  4745. size, err := m.ListSnapshots.MarshalToSizedBuffer(dAtA[:i])
  4746. if err != nil {
  4747. return 0, err
  4748. }
  4749. i -= size
  4750. i = encodeVarintTypes(dAtA, i, uint64(size))
  4751. }
  4752. i--
  4753. dAtA[i] = 0x6a
  4754. }
  4755. return len(dAtA) - i, nil
  4756. }
  4757. func (m *Response_OfferSnapshot) MarshalTo(dAtA []byte) (int, error) {
  4758. size := m.Size()
  4759. return m.MarshalToSizedBuffer(dAtA[:size])
  4760. }
  4761. func (m *Response_OfferSnapshot) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4762. i := len(dAtA)
  4763. if m.OfferSnapshot != nil {
  4764. {
  4765. size, err := m.OfferSnapshot.MarshalToSizedBuffer(dAtA[:i])
  4766. if err != nil {
  4767. return 0, err
  4768. }
  4769. i -= size
  4770. i = encodeVarintTypes(dAtA, i, uint64(size))
  4771. }
  4772. i--
  4773. dAtA[i] = 0x72
  4774. }
  4775. return len(dAtA) - i, nil
  4776. }
  4777. func (m *Response_LoadSnapshotChunk) MarshalTo(dAtA []byte) (int, error) {
  4778. size := m.Size()
  4779. return m.MarshalToSizedBuffer(dAtA[:size])
  4780. }
  4781. func (m *Response_LoadSnapshotChunk) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4782. i := len(dAtA)
  4783. if m.LoadSnapshotChunk != nil {
  4784. {
  4785. size, err := m.LoadSnapshotChunk.MarshalToSizedBuffer(dAtA[:i])
  4786. if err != nil {
  4787. return 0, err
  4788. }
  4789. i -= size
  4790. i = encodeVarintTypes(dAtA, i, uint64(size))
  4791. }
  4792. i--
  4793. dAtA[i] = 0x7a
  4794. }
  4795. return len(dAtA) - i, nil
  4796. }
  4797. func (m *Response_ApplySnapshotChunk) MarshalTo(dAtA []byte) (int, error) {
  4798. size := m.Size()
  4799. return m.MarshalToSizedBuffer(dAtA[:size])
  4800. }
  4801. func (m *Response_ApplySnapshotChunk) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4802. i := len(dAtA)
  4803. if m.ApplySnapshotChunk != nil {
  4804. {
  4805. size, err := m.ApplySnapshotChunk.MarshalToSizedBuffer(dAtA[:i])
  4806. if err != nil {
  4807. return 0, err
  4808. }
  4809. i -= size
  4810. i = encodeVarintTypes(dAtA, i, uint64(size))
  4811. }
  4812. i--
  4813. dAtA[i] = 0x1
  4814. i--
  4815. dAtA[i] = 0x82
  4816. }
  4817. return len(dAtA) - i, nil
  4818. }
  4819. func (m *ResponseException) Marshal() (dAtA []byte, err error) {
  4820. size := m.Size()
  4821. dAtA = make([]byte, size)
  4822. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4823. if err != nil {
  4824. return nil, err
  4825. }
  4826. return dAtA[:n], nil
  4827. }
  4828. func (m *ResponseException) MarshalTo(dAtA []byte) (int, error) {
  4829. size := m.Size()
  4830. return m.MarshalToSizedBuffer(dAtA[:size])
  4831. }
  4832. func (m *ResponseException) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4833. i := len(dAtA)
  4834. _ = i
  4835. var l int
  4836. _ = l
  4837. if len(m.Error) > 0 {
  4838. i -= len(m.Error)
  4839. copy(dAtA[i:], m.Error)
  4840. i = encodeVarintTypes(dAtA, i, uint64(len(m.Error)))
  4841. i--
  4842. dAtA[i] = 0xa
  4843. }
  4844. return len(dAtA) - i, nil
  4845. }
  4846. func (m *ResponseEcho) Marshal() (dAtA []byte, err error) {
  4847. size := m.Size()
  4848. dAtA = make([]byte, size)
  4849. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4850. if err != nil {
  4851. return nil, err
  4852. }
  4853. return dAtA[:n], nil
  4854. }
  4855. func (m *ResponseEcho) MarshalTo(dAtA []byte) (int, error) {
  4856. size := m.Size()
  4857. return m.MarshalToSizedBuffer(dAtA[:size])
  4858. }
  4859. func (m *ResponseEcho) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4860. i := len(dAtA)
  4861. _ = i
  4862. var l int
  4863. _ = l
  4864. if len(m.Message) > 0 {
  4865. i -= len(m.Message)
  4866. copy(dAtA[i:], m.Message)
  4867. i = encodeVarintTypes(dAtA, i, uint64(len(m.Message)))
  4868. i--
  4869. dAtA[i] = 0xa
  4870. }
  4871. return len(dAtA) - i, nil
  4872. }
  4873. func (m *ResponseFlush) Marshal() (dAtA []byte, err error) {
  4874. size := m.Size()
  4875. dAtA = make([]byte, size)
  4876. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4877. if err != nil {
  4878. return nil, err
  4879. }
  4880. return dAtA[:n], nil
  4881. }
  4882. func (m *ResponseFlush) MarshalTo(dAtA []byte) (int, error) {
  4883. size := m.Size()
  4884. return m.MarshalToSizedBuffer(dAtA[:size])
  4885. }
  4886. func (m *ResponseFlush) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4887. i := len(dAtA)
  4888. _ = i
  4889. var l int
  4890. _ = l
  4891. return len(dAtA) - i, nil
  4892. }
  4893. func (m *ResponseInfo) Marshal() (dAtA []byte, err error) {
  4894. size := m.Size()
  4895. dAtA = make([]byte, size)
  4896. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4897. if err != nil {
  4898. return nil, err
  4899. }
  4900. return dAtA[:n], nil
  4901. }
  4902. func (m *ResponseInfo) MarshalTo(dAtA []byte) (int, error) {
  4903. size := m.Size()
  4904. return m.MarshalToSizedBuffer(dAtA[:size])
  4905. }
  4906. func (m *ResponseInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4907. i := len(dAtA)
  4908. _ = i
  4909. var l int
  4910. _ = l
  4911. if len(m.LastBlockAppHash) > 0 {
  4912. i -= len(m.LastBlockAppHash)
  4913. copy(dAtA[i:], m.LastBlockAppHash)
  4914. i = encodeVarintTypes(dAtA, i, uint64(len(m.LastBlockAppHash)))
  4915. i--
  4916. dAtA[i] = 0x2a
  4917. }
  4918. if m.LastBlockHeight != 0 {
  4919. i = encodeVarintTypes(dAtA, i, uint64(m.LastBlockHeight))
  4920. i--
  4921. dAtA[i] = 0x20
  4922. }
  4923. if m.AppVersion != 0 {
  4924. i = encodeVarintTypes(dAtA, i, uint64(m.AppVersion))
  4925. i--
  4926. dAtA[i] = 0x18
  4927. }
  4928. if len(m.Version) > 0 {
  4929. i -= len(m.Version)
  4930. copy(dAtA[i:], m.Version)
  4931. i = encodeVarintTypes(dAtA, i, uint64(len(m.Version)))
  4932. i--
  4933. dAtA[i] = 0x12
  4934. }
  4935. if len(m.Data) > 0 {
  4936. i -= len(m.Data)
  4937. copy(dAtA[i:], m.Data)
  4938. i = encodeVarintTypes(dAtA, i, uint64(len(m.Data)))
  4939. i--
  4940. dAtA[i] = 0xa
  4941. }
  4942. return len(dAtA) - i, nil
  4943. }
  4944. func (m *ResponseSetOption) Marshal() (dAtA []byte, err error) {
  4945. size := m.Size()
  4946. dAtA = make([]byte, size)
  4947. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4948. if err != nil {
  4949. return nil, err
  4950. }
  4951. return dAtA[:n], nil
  4952. }
  4953. func (m *ResponseSetOption) MarshalTo(dAtA []byte) (int, error) {
  4954. size := m.Size()
  4955. return m.MarshalToSizedBuffer(dAtA[:size])
  4956. }
  4957. func (m *ResponseSetOption) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4958. i := len(dAtA)
  4959. _ = i
  4960. var l int
  4961. _ = l
  4962. if len(m.Info) > 0 {
  4963. i -= len(m.Info)
  4964. copy(dAtA[i:], m.Info)
  4965. i = encodeVarintTypes(dAtA, i, uint64(len(m.Info)))
  4966. i--
  4967. dAtA[i] = 0x22
  4968. }
  4969. if len(m.Log) > 0 {
  4970. i -= len(m.Log)
  4971. copy(dAtA[i:], m.Log)
  4972. i = encodeVarintTypes(dAtA, i, uint64(len(m.Log)))
  4973. i--
  4974. dAtA[i] = 0x1a
  4975. }
  4976. if m.Code != 0 {
  4977. i = encodeVarintTypes(dAtA, i, uint64(m.Code))
  4978. i--
  4979. dAtA[i] = 0x8
  4980. }
  4981. return len(dAtA) - i, nil
  4982. }
  4983. func (m *ResponseInitChain) Marshal() (dAtA []byte, err error) {
  4984. size := m.Size()
  4985. dAtA = make([]byte, size)
  4986. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  4987. if err != nil {
  4988. return nil, err
  4989. }
  4990. return dAtA[:n], nil
  4991. }
  4992. func (m *ResponseInitChain) MarshalTo(dAtA []byte) (int, error) {
  4993. size := m.Size()
  4994. return m.MarshalToSizedBuffer(dAtA[:size])
  4995. }
  4996. func (m *ResponseInitChain) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  4997. i := len(dAtA)
  4998. _ = i
  4999. var l int
  5000. _ = l
  5001. if len(m.AppHash) > 0 {
  5002. i -= len(m.AppHash)
  5003. copy(dAtA[i:], m.AppHash)
  5004. i = encodeVarintTypes(dAtA, i, uint64(len(m.AppHash)))
  5005. i--
  5006. dAtA[i] = 0x1a
  5007. }
  5008. if len(m.Validators) > 0 {
  5009. for iNdEx := len(m.Validators) - 1; iNdEx >= 0; iNdEx-- {
  5010. {
  5011. size, err := m.Validators[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  5012. if err != nil {
  5013. return 0, err
  5014. }
  5015. i -= size
  5016. i = encodeVarintTypes(dAtA, i, uint64(size))
  5017. }
  5018. i--
  5019. dAtA[i] = 0x12
  5020. }
  5021. }
  5022. if m.ConsensusParams != nil {
  5023. {
  5024. size, err := m.ConsensusParams.MarshalToSizedBuffer(dAtA[:i])
  5025. if err != nil {
  5026. return 0, err
  5027. }
  5028. i -= size
  5029. i = encodeVarintTypes(dAtA, i, uint64(size))
  5030. }
  5031. i--
  5032. dAtA[i] = 0xa
  5033. }
  5034. return len(dAtA) - i, nil
  5035. }
  5036. func (m *ResponseQuery) Marshal() (dAtA []byte, err error) {
  5037. size := m.Size()
  5038. dAtA = make([]byte, size)
  5039. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5040. if err != nil {
  5041. return nil, err
  5042. }
  5043. return dAtA[:n], nil
  5044. }
  5045. func (m *ResponseQuery) MarshalTo(dAtA []byte) (int, error) {
  5046. size := m.Size()
  5047. return m.MarshalToSizedBuffer(dAtA[:size])
  5048. }
  5049. func (m *ResponseQuery) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5050. i := len(dAtA)
  5051. _ = i
  5052. var l int
  5053. _ = l
  5054. if len(m.Codespace) > 0 {
  5055. i -= len(m.Codespace)
  5056. copy(dAtA[i:], m.Codespace)
  5057. i = encodeVarintTypes(dAtA, i, uint64(len(m.Codespace)))
  5058. i--
  5059. dAtA[i] = 0x52
  5060. }
  5061. if m.Height != 0 {
  5062. i = encodeVarintTypes(dAtA, i, uint64(m.Height))
  5063. i--
  5064. dAtA[i] = 0x48
  5065. }
  5066. if m.ProofOps != nil {
  5067. {
  5068. size, err := m.ProofOps.MarshalToSizedBuffer(dAtA[:i])
  5069. if err != nil {
  5070. return 0, err
  5071. }
  5072. i -= size
  5073. i = encodeVarintTypes(dAtA, i, uint64(size))
  5074. }
  5075. i--
  5076. dAtA[i] = 0x42
  5077. }
  5078. if len(m.Value) > 0 {
  5079. i -= len(m.Value)
  5080. copy(dAtA[i:], m.Value)
  5081. i = encodeVarintTypes(dAtA, i, uint64(len(m.Value)))
  5082. i--
  5083. dAtA[i] = 0x3a
  5084. }
  5085. if len(m.Key) > 0 {
  5086. i -= len(m.Key)
  5087. copy(dAtA[i:], m.Key)
  5088. i = encodeVarintTypes(dAtA, i, uint64(len(m.Key)))
  5089. i--
  5090. dAtA[i] = 0x32
  5091. }
  5092. if m.Index != 0 {
  5093. i = encodeVarintTypes(dAtA, i, uint64(m.Index))
  5094. i--
  5095. dAtA[i] = 0x28
  5096. }
  5097. if len(m.Info) > 0 {
  5098. i -= len(m.Info)
  5099. copy(dAtA[i:], m.Info)
  5100. i = encodeVarintTypes(dAtA, i, uint64(len(m.Info)))
  5101. i--
  5102. dAtA[i] = 0x22
  5103. }
  5104. if len(m.Log) > 0 {
  5105. i -= len(m.Log)
  5106. copy(dAtA[i:], m.Log)
  5107. i = encodeVarintTypes(dAtA, i, uint64(len(m.Log)))
  5108. i--
  5109. dAtA[i] = 0x1a
  5110. }
  5111. if m.Code != 0 {
  5112. i = encodeVarintTypes(dAtA, i, uint64(m.Code))
  5113. i--
  5114. dAtA[i] = 0x8
  5115. }
  5116. return len(dAtA) - i, nil
  5117. }
  5118. func (m *ResponseBeginBlock) Marshal() (dAtA []byte, err error) {
  5119. size := m.Size()
  5120. dAtA = make([]byte, size)
  5121. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5122. if err != nil {
  5123. return nil, err
  5124. }
  5125. return dAtA[:n], nil
  5126. }
  5127. func (m *ResponseBeginBlock) MarshalTo(dAtA []byte) (int, error) {
  5128. size := m.Size()
  5129. return m.MarshalToSizedBuffer(dAtA[:size])
  5130. }
  5131. func (m *ResponseBeginBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5132. i := len(dAtA)
  5133. _ = i
  5134. var l int
  5135. _ = l
  5136. if len(m.Events) > 0 {
  5137. for iNdEx := len(m.Events) - 1; iNdEx >= 0; iNdEx-- {
  5138. {
  5139. size, err := m.Events[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  5140. if err != nil {
  5141. return 0, err
  5142. }
  5143. i -= size
  5144. i = encodeVarintTypes(dAtA, i, uint64(size))
  5145. }
  5146. i--
  5147. dAtA[i] = 0xa
  5148. }
  5149. }
  5150. return len(dAtA) - i, nil
  5151. }
  5152. func (m *ResponseCheckTx) Marshal() (dAtA []byte, err error) {
  5153. size := m.Size()
  5154. dAtA = make([]byte, size)
  5155. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5156. if err != nil {
  5157. return nil, err
  5158. }
  5159. return dAtA[:n], nil
  5160. }
  5161. func (m *ResponseCheckTx) MarshalTo(dAtA []byte) (int, error) {
  5162. size := m.Size()
  5163. return m.MarshalToSizedBuffer(dAtA[:size])
  5164. }
  5165. func (m *ResponseCheckTx) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5166. i := len(dAtA)
  5167. _ = i
  5168. var l int
  5169. _ = l
  5170. if len(m.Codespace) > 0 {
  5171. i -= len(m.Codespace)
  5172. copy(dAtA[i:], m.Codespace)
  5173. i = encodeVarintTypes(dAtA, i, uint64(len(m.Codespace)))
  5174. i--
  5175. dAtA[i] = 0x42
  5176. }
  5177. if len(m.Events) > 0 {
  5178. for iNdEx := len(m.Events) - 1; iNdEx >= 0; iNdEx-- {
  5179. {
  5180. size, err := m.Events[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  5181. if err != nil {
  5182. return 0, err
  5183. }
  5184. i -= size
  5185. i = encodeVarintTypes(dAtA, i, uint64(size))
  5186. }
  5187. i--
  5188. dAtA[i] = 0x3a
  5189. }
  5190. }
  5191. if m.GasUsed != 0 {
  5192. i = encodeVarintTypes(dAtA, i, uint64(m.GasUsed))
  5193. i--
  5194. dAtA[i] = 0x30
  5195. }
  5196. if m.GasWanted != 0 {
  5197. i = encodeVarintTypes(dAtA, i, uint64(m.GasWanted))
  5198. i--
  5199. dAtA[i] = 0x28
  5200. }
  5201. if len(m.Info) > 0 {
  5202. i -= len(m.Info)
  5203. copy(dAtA[i:], m.Info)
  5204. i = encodeVarintTypes(dAtA, i, uint64(len(m.Info)))
  5205. i--
  5206. dAtA[i] = 0x22
  5207. }
  5208. if len(m.Log) > 0 {
  5209. i -= len(m.Log)
  5210. copy(dAtA[i:], m.Log)
  5211. i = encodeVarintTypes(dAtA, i, uint64(len(m.Log)))
  5212. i--
  5213. dAtA[i] = 0x1a
  5214. }
  5215. if len(m.Data) > 0 {
  5216. i -= len(m.Data)
  5217. copy(dAtA[i:], m.Data)
  5218. i = encodeVarintTypes(dAtA, i, uint64(len(m.Data)))
  5219. i--
  5220. dAtA[i] = 0x12
  5221. }
  5222. if m.Code != 0 {
  5223. i = encodeVarintTypes(dAtA, i, uint64(m.Code))
  5224. i--
  5225. dAtA[i] = 0x8
  5226. }
  5227. return len(dAtA) - i, nil
  5228. }
  5229. func (m *ResponseDeliverTx) Marshal() (dAtA []byte, err error) {
  5230. size := m.Size()
  5231. dAtA = make([]byte, size)
  5232. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5233. if err != nil {
  5234. return nil, err
  5235. }
  5236. return dAtA[:n], nil
  5237. }
  5238. func (m *ResponseDeliverTx) MarshalTo(dAtA []byte) (int, error) {
  5239. size := m.Size()
  5240. return m.MarshalToSizedBuffer(dAtA[:size])
  5241. }
  5242. func (m *ResponseDeliverTx) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5243. i := len(dAtA)
  5244. _ = i
  5245. var l int
  5246. _ = l
  5247. if len(m.Codespace) > 0 {
  5248. i -= len(m.Codespace)
  5249. copy(dAtA[i:], m.Codespace)
  5250. i = encodeVarintTypes(dAtA, i, uint64(len(m.Codespace)))
  5251. i--
  5252. dAtA[i] = 0x42
  5253. }
  5254. if len(m.Events) > 0 {
  5255. for iNdEx := len(m.Events) - 1; iNdEx >= 0; iNdEx-- {
  5256. {
  5257. size, err := m.Events[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  5258. if err != nil {
  5259. return 0, err
  5260. }
  5261. i -= size
  5262. i = encodeVarintTypes(dAtA, i, uint64(size))
  5263. }
  5264. i--
  5265. dAtA[i] = 0x3a
  5266. }
  5267. }
  5268. if m.GasUsed != 0 {
  5269. i = encodeVarintTypes(dAtA, i, uint64(m.GasUsed))
  5270. i--
  5271. dAtA[i] = 0x30
  5272. }
  5273. if m.GasWanted != 0 {
  5274. i = encodeVarintTypes(dAtA, i, uint64(m.GasWanted))
  5275. i--
  5276. dAtA[i] = 0x28
  5277. }
  5278. if len(m.Info) > 0 {
  5279. i -= len(m.Info)
  5280. copy(dAtA[i:], m.Info)
  5281. i = encodeVarintTypes(dAtA, i, uint64(len(m.Info)))
  5282. i--
  5283. dAtA[i] = 0x22
  5284. }
  5285. if len(m.Log) > 0 {
  5286. i -= len(m.Log)
  5287. copy(dAtA[i:], m.Log)
  5288. i = encodeVarintTypes(dAtA, i, uint64(len(m.Log)))
  5289. i--
  5290. dAtA[i] = 0x1a
  5291. }
  5292. if len(m.Data) > 0 {
  5293. i -= len(m.Data)
  5294. copy(dAtA[i:], m.Data)
  5295. i = encodeVarintTypes(dAtA, i, uint64(len(m.Data)))
  5296. i--
  5297. dAtA[i] = 0x12
  5298. }
  5299. if m.Code != 0 {
  5300. i = encodeVarintTypes(dAtA, i, uint64(m.Code))
  5301. i--
  5302. dAtA[i] = 0x8
  5303. }
  5304. return len(dAtA) - i, nil
  5305. }
  5306. func (m *ResponseEndBlock) Marshal() (dAtA []byte, err error) {
  5307. size := m.Size()
  5308. dAtA = make([]byte, size)
  5309. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5310. if err != nil {
  5311. return nil, err
  5312. }
  5313. return dAtA[:n], nil
  5314. }
  5315. func (m *ResponseEndBlock) MarshalTo(dAtA []byte) (int, error) {
  5316. size := m.Size()
  5317. return m.MarshalToSizedBuffer(dAtA[:size])
  5318. }
  5319. func (m *ResponseEndBlock) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5320. i := len(dAtA)
  5321. _ = i
  5322. var l int
  5323. _ = l
  5324. if len(m.Events) > 0 {
  5325. for iNdEx := len(m.Events) - 1; iNdEx >= 0; iNdEx-- {
  5326. {
  5327. size, err := m.Events[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  5328. if err != nil {
  5329. return 0, err
  5330. }
  5331. i -= size
  5332. i = encodeVarintTypes(dAtA, i, uint64(size))
  5333. }
  5334. i--
  5335. dAtA[i] = 0x1a
  5336. }
  5337. }
  5338. if m.ConsensusParamUpdates != nil {
  5339. {
  5340. size, err := m.ConsensusParamUpdates.MarshalToSizedBuffer(dAtA[:i])
  5341. if err != nil {
  5342. return 0, err
  5343. }
  5344. i -= size
  5345. i = encodeVarintTypes(dAtA, i, uint64(size))
  5346. }
  5347. i--
  5348. dAtA[i] = 0x12
  5349. }
  5350. if len(m.ValidatorUpdates) > 0 {
  5351. for iNdEx := len(m.ValidatorUpdates) - 1; iNdEx >= 0; iNdEx-- {
  5352. {
  5353. size, err := m.ValidatorUpdates[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  5354. if err != nil {
  5355. return 0, err
  5356. }
  5357. i -= size
  5358. i = encodeVarintTypes(dAtA, i, uint64(size))
  5359. }
  5360. i--
  5361. dAtA[i] = 0xa
  5362. }
  5363. }
  5364. return len(dAtA) - i, nil
  5365. }
  5366. func (m *ResponseCommit) Marshal() (dAtA []byte, err error) {
  5367. size := m.Size()
  5368. dAtA = make([]byte, size)
  5369. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5370. if err != nil {
  5371. return nil, err
  5372. }
  5373. return dAtA[:n], nil
  5374. }
  5375. func (m *ResponseCommit) MarshalTo(dAtA []byte) (int, error) {
  5376. size := m.Size()
  5377. return m.MarshalToSizedBuffer(dAtA[:size])
  5378. }
  5379. func (m *ResponseCommit) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5380. i := len(dAtA)
  5381. _ = i
  5382. var l int
  5383. _ = l
  5384. if m.RetainHeight != 0 {
  5385. i = encodeVarintTypes(dAtA, i, uint64(m.RetainHeight))
  5386. i--
  5387. dAtA[i] = 0x18
  5388. }
  5389. if len(m.Data) > 0 {
  5390. i -= len(m.Data)
  5391. copy(dAtA[i:], m.Data)
  5392. i = encodeVarintTypes(dAtA, i, uint64(len(m.Data)))
  5393. i--
  5394. dAtA[i] = 0x12
  5395. }
  5396. return len(dAtA) - i, nil
  5397. }
  5398. func (m *ResponseListSnapshots) Marshal() (dAtA []byte, err error) {
  5399. size := m.Size()
  5400. dAtA = make([]byte, size)
  5401. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5402. if err != nil {
  5403. return nil, err
  5404. }
  5405. return dAtA[:n], nil
  5406. }
  5407. func (m *ResponseListSnapshots) MarshalTo(dAtA []byte) (int, error) {
  5408. size := m.Size()
  5409. return m.MarshalToSizedBuffer(dAtA[:size])
  5410. }
  5411. func (m *ResponseListSnapshots) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5412. i := len(dAtA)
  5413. _ = i
  5414. var l int
  5415. _ = l
  5416. if len(m.Snapshots) > 0 {
  5417. for iNdEx := len(m.Snapshots) - 1; iNdEx >= 0; iNdEx-- {
  5418. {
  5419. size, err := m.Snapshots[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  5420. if err != nil {
  5421. return 0, err
  5422. }
  5423. i -= size
  5424. i = encodeVarintTypes(dAtA, i, uint64(size))
  5425. }
  5426. i--
  5427. dAtA[i] = 0xa
  5428. }
  5429. }
  5430. return len(dAtA) - i, nil
  5431. }
  5432. func (m *ResponseOfferSnapshot) Marshal() (dAtA []byte, err error) {
  5433. size := m.Size()
  5434. dAtA = make([]byte, size)
  5435. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5436. if err != nil {
  5437. return nil, err
  5438. }
  5439. return dAtA[:n], nil
  5440. }
  5441. func (m *ResponseOfferSnapshot) MarshalTo(dAtA []byte) (int, error) {
  5442. size := m.Size()
  5443. return m.MarshalToSizedBuffer(dAtA[:size])
  5444. }
  5445. func (m *ResponseOfferSnapshot) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5446. i := len(dAtA)
  5447. _ = i
  5448. var l int
  5449. _ = l
  5450. if m.Result != 0 {
  5451. i = encodeVarintTypes(dAtA, i, uint64(m.Result))
  5452. i--
  5453. dAtA[i] = 0x8
  5454. }
  5455. return len(dAtA) - i, nil
  5456. }
  5457. func (m *ResponseLoadSnapshotChunk) Marshal() (dAtA []byte, err error) {
  5458. size := m.Size()
  5459. dAtA = make([]byte, size)
  5460. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5461. if err != nil {
  5462. return nil, err
  5463. }
  5464. return dAtA[:n], nil
  5465. }
  5466. func (m *ResponseLoadSnapshotChunk) MarshalTo(dAtA []byte) (int, error) {
  5467. size := m.Size()
  5468. return m.MarshalToSizedBuffer(dAtA[:size])
  5469. }
  5470. func (m *ResponseLoadSnapshotChunk) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5471. i := len(dAtA)
  5472. _ = i
  5473. var l int
  5474. _ = l
  5475. if len(m.Chunk) > 0 {
  5476. i -= len(m.Chunk)
  5477. copy(dAtA[i:], m.Chunk)
  5478. i = encodeVarintTypes(dAtA, i, uint64(len(m.Chunk)))
  5479. i--
  5480. dAtA[i] = 0xa
  5481. }
  5482. return len(dAtA) - i, nil
  5483. }
  5484. func (m *ResponseApplySnapshotChunk) Marshal() (dAtA []byte, err error) {
  5485. size := m.Size()
  5486. dAtA = make([]byte, size)
  5487. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5488. if err != nil {
  5489. return nil, err
  5490. }
  5491. return dAtA[:n], nil
  5492. }
  5493. func (m *ResponseApplySnapshotChunk) MarshalTo(dAtA []byte) (int, error) {
  5494. size := m.Size()
  5495. return m.MarshalToSizedBuffer(dAtA[:size])
  5496. }
  5497. func (m *ResponseApplySnapshotChunk) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5498. i := len(dAtA)
  5499. _ = i
  5500. var l int
  5501. _ = l
  5502. if len(m.RejectSenders) > 0 {
  5503. for iNdEx := len(m.RejectSenders) - 1; iNdEx >= 0; iNdEx-- {
  5504. i -= len(m.RejectSenders[iNdEx])
  5505. copy(dAtA[i:], m.RejectSenders[iNdEx])
  5506. i = encodeVarintTypes(dAtA, i, uint64(len(m.RejectSenders[iNdEx])))
  5507. i--
  5508. dAtA[i] = 0x1a
  5509. }
  5510. }
  5511. if len(m.RefetchChunks) > 0 {
  5512. dAtA41 := make([]byte, len(m.RefetchChunks)*10)
  5513. var j40 int
  5514. for _, num := range m.RefetchChunks {
  5515. for num >= 1<<7 {
  5516. dAtA41[j40] = uint8(uint64(num)&0x7f | 0x80)
  5517. num >>= 7
  5518. j40++
  5519. }
  5520. dAtA41[j40] = uint8(num)
  5521. j40++
  5522. }
  5523. i -= j40
  5524. copy(dAtA[i:], dAtA41[:j40])
  5525. i = encodeVarintTypes(dAtA, i, uint64(j40))
  5526. i--
  5527. dAtA[i] = 0x12
  5528. }
  5529. if m.Result != 0 {
  5530. i = encodeVarintTypes(dAtA, i, uint64(m.Result))
  5531. i--
  5532. dAtA[i] = 0x8
  5533. }
  5534. return len(dAtA) - i, nil
  5535. }
  5536. func (m *ConsensusParams) Marshal() (dAtA []byte, err error) {
  5537. size := m.Size()
  5538. dAtA = make([]byte, size)
  5539. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5540. if err != nil {
  5541. return nil, err
  5542. }
  5543. return dAtA[:n], nil
  5544. }
  5545. func (m *ConsensusParams) MarshalTo(dAtA []byte) (int, error) {
  5546. size := m.Size()
  5547. return m.MarshalToSizedBuffer(dAtA[:size])
  5548. }
  5549. func (m *ConsensusParams) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5550. i := len(dAtA)
  5551. _ = i
  5552. var l int
  5553. _ = l
  5554. if m.Version != nil {
  5555. {
  5556. size, err := m.Version.MarshalToSizedBuffer(dAtA[:i])
  5557. if err != nil {
  5558. return 0, err
  5559. }
  5560. i -= size
  5561. i = encodeVarintTypes(dAtA, i, uint64(size))
  5562. }
  5563. i--
  5564. dAtA[i] = 0x22
  5565. }
  5566. if m.Validator != nil {
  5567. {
  5568. size, err := m.Validator.MarshalToSizedBuffer(dAtA[:i])
  5569. if err != nil {
  5570. return 0, err
  5571. }
  5572. i -= size
  5573. i = encodeVarintTypes(dAtA, i, uint64(size))
  5574. }
  5575. i--
  5576. dAtA[i] = 0x1a
  5577. }
  5578. if m.Evidence != nil {
  5579. {
  5580. size, err := m.Evidence.MarshalToSizedBuffer(dAtA[:i])
  5581. if err != nil {
  5582. return 0, err
  5583. }
  5584. i -= size
  5585. i = encodeVarintTypes(dAtA, i, uint64(size))
  5586. }
  5587. i--
  5588. dAtA[i] = 0x12
  5589. }
  5590. if m.Block != nil {
  5591. {
  5592. size, err := m.Block.MarshalToSizedBuffer(dAtA[:i])
  5593. if err != nil {
  5594. return 0, err
  5595. }
  5596. i -= size
  5597. i = encodeVarintTypes(dAtA, i, uint64(size))
  5598. }
  5599. i--
  5600. dAtA[i] = 0xa
  5601. }
  5602. return len(dAtA) - i, nil
  5603. }
  5604. func (m *BlockParams) Marshal() (dAtA []byte, err error) {
  5605. size := m.Size()
  5606. dAtA = make([]byte, size)
  5607. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5608. if err != nil {
  5609. return nil, err
  5610. }
  5611. return dAtA[:n], nil
  5612. }
  5613. func (m *BlockParams) MarshalTo(dAtA []byte) (int, error) {
  5614. size := m.Size()
  5615. return m.MarshalToSizedBuffer(dAtA[:size])
  5616. }
  5617. func (m *BlockParams) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5618. i := len(dAtA)
  5619. _ = i
  5620. var l int
  5621. _ = l
  5622. if m.MaxGas != 0 {
  5623. i = encodeVarintTypes(dAtA, i, uint64(m.MaxGas))
  5624. i--
  5625. dAtA[i] = 0x10
  5626. }
  5627. if m.MaxBytes != 0 {
  5628. i = encodeVarintTypes(dAtA, i, uint64(m.MaxBytes))
  5629. i--
  5630. dAtA[i] = 0x8
  5631. }
  5632. return len(dAtA) - i, nil
  5633. }
  5634. func (m *LastCommitInfo) Marshal() (dAtA []byte, err error) {
  5635. size := m.Size()
  5636. dAtA = make([]byte, size)
  5637. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5638. if err != nil {
  5639. return nil, err
  5640. }
  5641. return dAtA[:n], nil
  5642. }
  5643. func (m *LastCommitInfo) MarshalTo(dAtA []byte) (int, error) {
  5644. size := m.Size()
  5645. return m.MarshalToSizedBuffer(dAtA[:size])
  5646. }
  5647. func (m *LastCommitInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5648. i := len(dAtA)
  5649. _ = i
  5650. var l int
  5651. _ = l
  5652. if len(m.Votes) > 0 {
  5653. for iNdEx := len(m.Votes) - 1; iNdEx >= 0; iNdEx-- {
  5654. {
  5655. size, err := m.Votes[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  5656. if err != nil {
  5657. return 0, err
  5658. }
  5659. i -= size
  5660. i = encodeVarintTypes(dAtA, i, uint64(size))
  5661. }
  5662. i--
  5663. dAtA[i] = 0x12
  5664. }
  5665. }
  5666. if m.Round != 0 {
  5667. i = encodeVarintTypes(dAtA, i, uint64(m.Round))
  5668. i--
  5669. dAtA[i] = 0x8
  5670. }
  5671. return len(dAtA) - i, nil
  5672. }
  5673. func (m *Event) Marshal() (dAtA []byte, err error) {
  5674. size := m.Size()
  5675. dAtA = make([]byte, size)
  5676. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5677. if err != nil {
  5678. return nil, err
  5679. }
  5680. return dAtA[:n], nil
  5681. }
  5682. func (m *Event) MarshalTo(dAtA []byte) (int, error) {
  5683. size := m.Size()
  5684. return m.MarshalToSizedBuffer(dAtA[:size])
  5685. }
  5686. func (m *Event) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5687. i := len(dAtA)
  5688. _ = i
  5689. var l int
  5690. _ = l
  5691. if len(m.Attributes) > 0 {
  5692. for iNdEx := len(m.Attributes) - 1; iNdEx >= 0; iNdEx-- {
  5693. {
  5694. size, err := m.Attributes[iNdEx].MarshalToSizedBuffer(dAtA[:i])
  5695. if err != nil {
  5696. return 0, err
  5697. }
  5698. i -= size
  5699. i = encodeVarintTypes(dAtA, i, uint64(size))
  5700. }
  5701. i--
  5702. dAtA[i] = 0x12
  5703. }
  5704. }
  5705. if len(m.Type) > 0 {
  5706. i -= len(m.Type)
  5707. copy(dAtA[i:], m.Type)
  5708. i = encodeVarintTypes(dAtA, i, uint64(len(m.Type)))
  5709. i--
  5710. dAtA[i] = 0xa
  5711. }
  5712. return len(dAtA) - i, nil
  5713. }
  5714. func (m *EventAttribute) Marshal() (dAtA []byte, err error) {
  5715. size := m.Size()
  5716. dAtA = make([]byte, size)
  5717. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5718. if err != nil {
  5719. return nil, err
  5720. }
  5721. return dAtA[:n], nil
  5722. }
  5723. func (m *EventAttribute) MarshalTo(dAtA []byte) (int, error) {
  5724. size := m.Size()
  5725. return m.MarshalToSizedBuffer(dAtA[:size])
  5726. }
  5727. func (m *EventAttribute) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5728. i := len(dAtA)
  5729. _ = i
  5730. var l int
  5731. _ = l
  5732. if m.Index {
  5733. i--
  5734. if m.Index {
  5735. dAtA[i] = 1
  5736. } else {
  5737. dAtA[i] = 0
  5738. }
  5739. i--
  5740. dAtA[i] = 0x18
  5741. }
  5742. if len(m.Value) > 0 {
  5743. i -= len(m.Value)
  5744. copy(dAtA[i:], m.Value)
  5745. i = encodeVarintTypes(dAtA, i, uint64(len(m.Value)))
  5746. i--
  5747. dAtA[i] = 0x12
  5748. }
  5749. if len(m.Key) > 0 {
  5750. i -= len(m.Key)
  5751. copy(dAtA[i:], m.Key)
  5752. i = encodeVarintTypes(dAtA, i, uint64(len(m.Key)))
  5753. i--
  5754. dAtA[i] = 0xa
  5755. }
  5756. return len(dAtA) - i, nil
  5757. }
  5758. func (m *TxResult) Marshal() (dAtA []byte, err error) {
  5759. size := m.Size()
  5760. dAtA = make([]byte, size)
  5761. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5762. if err != nil {
  5763. return nil, err
  5764. }
  5765. return dAtA[:n], nil
  5766. }
  5767. func (m *TxResult) MarshalTo(dAtA []byte) (int, error) {
  5768. size := m.Size()
  5769. return m.MarshalToSizedBuffer(dAtA[:size])
  5770. }
  5771. func (m *TxResult) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5772. i := len(dAtA)
  5773. _ = i
  5774. var l int
  5775. _ = l
  5776. {
  5777. size, err := m.Result.MarshalToSizedBuffer(dAtA[:i])
  5778. if err != nil {
  5779. return 0, err
  5780. }
  5781. i -= size
  5782. i = encodeVarintTypes(dAtA, i, uint64(size))
  5783. }
  5784. i--
  5785. dAtA[i] = 0x22
  5786. if len(m.Tx) > 0 {
  5787. i -= len(m.Tx)
  5788. copy(dAtA[i:], m.Tx)
  5789. i = encodeVarintTypes(dAtA, i, uint64(len(m.Tx)))
  5790. i--
  5791. dAtA[i] = 0x1a
  5792. }
  5793. if m.Index != 0 {
  5794. i = encodeVarintTypes(dAtA, i, uint64(m.Index))
  5795. i--
  5796. dAtA[i] = 0x10
  5797. }
  5798. if m.Height != 0 {
  5799. i = encodeVarintTypes(dAtA, i, uint64(m.Height))
  5800. i--
  5801. dAtA[i] = 0x8
  5802. }
  5803. return len(dAtA) - i, nil
  5804. }
  5805. func (m *Validator) Marshal() (dAtA []byte, err error) {
  5806. size := m.Size()
  5807. dAtA = make([]byte, size)
  5808. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5809. if err != nil {
  5810. return nil, err
  5811. }
  5812. return dAtA[:n], nil
  5813. }
  5814. func (m *Validator) MarshalTo(dAtA []byte) (int, error) {
  5815. size := m.Size()
  5816. return m.MarshalToSizedBuffer(dAtA[:size])
  5817. }
  5818. func (m *Validator) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5819. i := len(dAtA)
  5820. _ = i
  5821. var l int
  5822. _ = l
  5823. if m.Power != 0 {
  5824. i = encodeVarintTypes(dAtA, i, uint64(m.Power))
  5825. i--
  5826. dAtA[i] = 0x18
  5827. }
  5828. if len(m.Address) > 0 {
  5829. i -= len(m.Address)
  5830. copy(dAtA[i:], m.Address)
  5831. i = encodeVarintTypes(dAtA, i, uint64(len(m.Address)))
  5832. i--
  5833. dAtA[i] = 0xa
  5834. }
  5835. return len(dAtA) - i, nil
  5836. }
  5837. func (m *ValidatorUpdate) Marshal() (dAtA []byte, err error) {
  5838. size := m.Size()
  5839. dAtA = make([]byte, size)
  5840. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5841. if err != nil {
  5842. return nil, err
  5843. }
  5844. return dAtA[:n], nil
  5845. }
  5846. func (m *ValidatorUpdate) MarshalTo(dAtA []byte) (int, error) {
  5847. size := m.Size()
  5848. return m.MarshalToSizedBuffer(dAtA[:size])
  5849. }
  5850. func (m *ValidatorUpdate) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5851. i := len(dAtA)
  5852. _ = i
  5853. var l int
  5854. _ = l
  5855. if m.Power != 0 {
  5856. i = encodeVarintTypes(dAtA, i, uint64(m.Power))
  5857. i--
  5858. dAtA[i] = 0x10
  5859. }
  5860. {
  5861. size, err := m.PubKey.MarshalToSizedBuffer(dAtA[:i])
  5862. if err != nil {
  5863. return 0, err
  5864. }
  5865. i -= size
  5866. i = encodeVarintTypes(dAtA, i, uint64(size))
  5867. }
  5868. i--
  5869. dAtA[i] = 0xa
  5870. return len(dAtA) - i, nil
  5871. }
  5872. func (m *VoteInfo) Marshal() (dAtA []byte, err error) {
  5873. size := m.Size()
  5874. dAtA = make([]byte, size)
  5875. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5876. if err != nil {
  5877. return nil, err
  5878. }
  5879. return dAtA[:n], nil
  5880. }
  5881. func (m *VoteInfo) MarshalTo(dAtA []byte) (int, error) {
  5882. size := m.Size()
  5883. return m.MarshalToSizedBuffer(dAtA[:size])
  5884. }
  5885. func (m *VoteInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5886. i := len(dAtA)
  5887. _ = i
  5888. var l int
  5889. _ = l
  5890. if m.SignedLastBlock {
  5891. i--
  5892. if m.SignedLastBlock {
  5893. dAtA[i] = 1
  5894. } else {
  5895. dAtA[i] = 0
  5896. }
  5897. i--
  5898. dAtA[i] = 0x10
  5899. }
  5900. {
  5901. size, err := m.Validator.MarshalToSizedBuffer(dAtA[:i])
  5902. if err != nil {
  5903. return 0, err
  5904. }
  5905. i -= size
  5906. i = encodeVarintTypes(dAtA, i, uint64(size))
  5907. }
  5908. i--
  5909. dAtA[i] = 0xa
  5910. return len(dAtA) - i, nil
  5911. }
  5912. func (m *Evidence) Marshal() (dAtA []byte, err error) {
  5913. size := m.Size()
  5914. dAtA = make([]byte, size)
  5915. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5916. if err != nil {
  5917. return nil, err
  5918. }
  5919. return dAtA[:n], nil
  5920. }
  5921. func (m *Evidence) MarshalTo(dAtA []byte) (int, error) {
  5922. size := m.Size()
  5923. return m.MarshalToSizedBuffer(dAtA[:size])
  5924. }
  5925. func (m *Evidence) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5926. i := len(dAtA)
  5927. _ = i
  5928. var l int
  5929. _ = l
  5930. if m.TotalVotingPower != 0 {
  5931. i = encodeVarintTypes(dAtA, i, uint64(m.TotalVotingPower))
  5932. i--
  5933. dAtA[i] = 0x28
  5934. }
  5935. n49, err49 := github_com_gogo_protobuf_types.StdTimeMarshalTo(m.Time, dAtA[i-github_com_gogo_protobuf_types.SizeOfStdTime(m.Time):])
  5936. if err49 != nil {
  5937. return 0, err49
  5938. }
  5939. i -= n49
  5940. i = encodeVarintTypes(dAtA, i, uint64(n49))
  5941. i--
  5942. dAtA[i] = 0x22
  5943. if m.Height != 0 {
  5944. i = encodeVarintTypes(dAtA, i, uint64(m.Height))
  5945. i--
  5946. dAtA[i] = 0x18
  5947. }
  5948. {
  5949. size, err := m.Validator.MarshalToSizedBuffer(dAtA[:i])
  5950. if err != nil {
  5951. return 0, err
  5952. }
  5953. i -= size
  5954. i = encodeVarintTypes(dAtA, i, uint64(size))
  5955. }
  5956. i--
  5957. dAtA[i] = 0x12
  5958. if m.Type != 0 {
  5959. i = encodeVarintTypes(dAtA, i, uint64(m.Type))
  5960. i--
  5961. dAtA[i] = 0x8
  5962. }
  5963. return len(dAtA) - i, nil
  5964. }
  5965. func (m *Snapshot) Marshal() (dAtA []byte, err error) {
  5966. size := m.Size()
  5967. dAtA = make([]byte, size)
  5968. n, err := m.MarshalToSizedBuffer(dAtA[:size])
  5969. if err != nil {
  5970. return nil, err
  5971. }
  5972. return dAtA[:n], nil
  5973. }
  5974. func (m *Snapshot) MarshalTo(dAtA []byte) (int, error) {
  5975. size := m.Size()
  5976. return m.MarshalToSizedBuffer(dAtA[:size])
  5977. }
  5978. func (m *Snapshot) MarshalToSizedBuffer(dAtA []byte) (int, error) {
  5979. i := len(dAtA)
  5980. _ = i
  5981. var l int
  5982. _ = l
  5983. if len(m.Metadata) > 0 {
  5984. i -= len(m.Metadata)
  5985. copy(dAtA[i:], m.Metadata)
  5986. i = encodeVarintTypes(dAtA, i, uint64(len(m.Metadata)))
  5987. i--
  5988. dAtA[i] = 0x2a
  5989. }
  5990. if len(m.Hash) > 0 {
  5991. i -= len(m.Hash)
  5992. copy(dAtA[i:], m.Hash)
  5993. i = encodeVarintTypes(dAtA, i, uint64(len(m.Hash)))
  5994. i--
  5995. dAtA[i] = 0x22
  5996. }
  5997. if m.Chunks != 0 {
  5998. i = encodeVarintTypes(dAtA, i, uint64(m.Chunks))
  5999. i--
  6000. dAtA[i] = 0x18
  6001. }
  6002. if m.Format != 0 {
  6003. i = encodeVarintTypes(dAtA, i, uint64(m.Format))
  6004. i--
  6005. dAtA[i] = 0x10
  6006. }
  6007. if m.Height != 0 {
  6008. i = encodeVarintTypes(dAtA, i, uint64(m.Height))
  6009. i--
  6010. dAtA[i] = 0x8
  6011. }
  6012. return len(dAtA) - i, nil
  6013. }
  6014. func encodeVarintTypes(dAtA []byte, offset int, v uint64) int {
  6015. offset -= sovTypes(v)
  6016. base := offset
  6017. for v >= 1<<7 {
  6018. dAtA[offset] = uint8(v&0x7f | 0x80)
  6019. v >>= 7
  6020. offset++
  6021. }
  6022. dAtA[offset] = uint8(v)
  6023. return base
  6024. }
  6025. func (m *Request) Size() (n int) {
  6026. if m == nil {
  6027. return 0
  6028. }
  6029. var l int
  6030. _ = l
  6031. if m.Value != nil {
  6032. n += m.Value.Size()
  6033. }
  6034. return n
  6035. }
  6036. func (m *Request_Echo) Size() (n int) {
  6037. if m == nil {
  6038. return 0
  6039. }
  6040. var l int
  6041. _ = l
  6042. if m.Echo != nil {
  6043. l = m.Echo.Size()
  6044. n += 1 + l + sovTypes(uint64(l))
  6045. }
  6046. return n
  6047. }
  6048. func (m *Request_Flush) Size() (n int) {
  6049. if m == nil {
  6050. return 0
  6051. }
  6052. var l int
  6053. _ = l
  6054. if m.Flush != nil {
  6055. l = m.Flush.Size()
  6056. n += 1 + l + sovTypes(uint64(l))
  6057. }
  6058. return n
  6059. }
  6060. func (m *Request_Info) Size() (n int) {
  6061. if m == nil {
  6062. return 0
  6063. }
  6064. var l int
  6065. _ = l
  6066. if m.Info != nil {
  6067. l = m.Info.Size()
  6068. n += 1 + l + sovTypes(uint64(l))
  6069. }
  6070. return n
  6071. }
  6072. func (m *Request_SetOption) Size() (n int) {
  6073. if m == nil {
  6074. return 0
  6075. }
  6076. var l int
  6077. _ = l
  6078. if m.SetOption != nil {
  6079. l = m.SetOption.Size()
  6080. n += 1 + l + sovTypes(uint64(l))
  6081. }
  6082. return n
  6083. }
  6084. func (m *Request_InitChain) Size() (n int) {
  6085. if m == nil {
  6086. return 0
  6087. }
  6088. var l int
  6089. _ = l
  6090. if m.InitChain != nil {
  6091. l = m.InitChain.Size()
  6092. n += 1 + l + sovTypes(uint64(l))
  6093. }
  6094. return n
  6095. }
  6096. func (m *Request_Query) Size() (n int) {
  6097. if m == nil {
  6098. return 0
  6099. }
  6100. var l int
  6101. _ = l
  6102. if m.Query != nil {
  6103. l = m.Query.Size()
  6104. n += 1 + l + sovTypes(uint64(l))
  6105. }
  6106. return n
  6107. }
  6108. func (m *Request_BeginBlock) Size() (n int) {
  6109. if m == nil {
  6110. return 0
  6111. }
  6112. var l int
  6113. _ = l
  6114. if m.BeginBlock != nil {
  6115. l = m.BeginBlock.Size()
  6116. n += 1 + l + sovTypes(uint64(l))
  6117. }
  6118. return n
  6119. }
  6120. func (m *Request_CheckTx) Size() (n int) {
  6121. if m == nil {
  6122. return 0
  6123. }
  6124. var l int
  6125. _ = l
  6126. if m.CheckTx != nil {
  6127. l = m.CheckTx.Size()
  6128. n += 1 + l + sovTypes(uint64(l))
  6129. }
  6130. return n
  6131. }
  6132. func (m *Request_DeliverTx) Size() (n int) {
  6133. if m == nil {
  6134. return 0
  6135. }
  6136. var l int
  6137. _ = l
  6138. if m.DeliverTx != nil {
  6139. l = m.DeliverTx.Size()
  6140. n += 1 + l + sovTypes(uint64(l))
  6141. }
  6142. return n
  6143. }
  6144. func (m *Request_EndBlock) Size() (n int) {
  6145. if m == nil {
  6146. return 0
  6147. }
  6148. var l int
  6149. _ = l
  6150. if m.EndBlock != nil {
  6151. l = m.EndBlock.Size()
  6152. n += 1 + l + sovTypes(uint64(l))
  6153. }
  6154. return n
  6155. }
  6156. func (m *Request_Commit) Size() (n int) {
  6157. if m == nil {
  6158. return 0
  6159. }
  6160. var l int
  6161. _ = l
  6162. if m.Commit != nil {
  6163. l = m.Commit.Size()
  6164. n += 1 + l + sovTypes(uint64(l))
  6165. }
  6166. return n
  6167. }
  6168. func (m *Request_ListSnapshots) Size() (n int) {
  6169. if m == nil {
  6170. return 0
  6171. }
  6172. var l int
  6173. _ = l
  6174. if m.ListSnapshots != nil {
  6175. l = m.ListSnapshots.Size()
  6176. n += 1 + l + sovTypes(uint64(l))
  6177. }
  6178. return n
  6179. }
  6180. func (m *Request_OfferSnapshot) Size() (n int) {
  6181. if m == nil {
  6182. return 0
  6183. }
  6184. var l int
  6185. _ = l
  6186. if m.OfferSnapshot != nil {
  6187. l = m.OfferSnapshot.Size()
  6188. n += 1 + l + sovTypes(uint64(l))
  6189. }
  6190. return n
  6191. }
  6192. func (m *Request_LoadSnapshotChunk) Size() (n int) {
  6193. if m == nil {
  6194. return 0
  6195. }
  6196. var l int
  6197. _ = l
  6198. if m.LoadSnapshotChunk != nil {
  6199. l = m.LoadSnapshotChunk.Size()
  6200. n += 1 + l + sovTypes(uint64(l))
  6201. }
  6202. return n
  6203. }
  6204. func (m *Request_ApplySnapshotChunk) Size() (n int) {
  6205. if m == nil {
  6206. return 0
  6207. }
  6208. var l int
  6209. _ = l
  6210. if m.ApplySnapshotChunk != nil {
  6211. l = m.ApplySnapshotChunk.Size()
  6212. n += 1 + l + sovTypes(uint64(l))
  6213. }
  6214. return n
  6215. }
  6216. func (m *RequestEcho) Size() (n int) {
  6217. if m == nil {
  6218. return 0
  6219. }
  6220. var l int
  6221. _ = l
  6222. l = len(m.Message)
  6223. if l > 0 {
  6224. n += 1 + l + sovTypes(uint64(l))
  6225. }
  6226. return n
  6227. }
  6228. func (m *RequestFlush) Size() (n int) {
  6229. if m == nil {
  6230. return 0
  6231. }
  6232. var l int
  6233. _ = l
  6234. return n
  6235. }
  6236. func (m *RequestInfo) Size() (n int) {
  6237. if m == nil {
  6238. return 0
  6239. }
  6240. var l int
  6241. _ = l
  6242. l = len(m.Version)
  6243. if l > 0 {
  6244. n += 1 + l + sovTypes(uint64(l))
  6245. }
  6246. if m.BlockVersion != 0 {
  6247. n += 1 + sovTypes(uint64(m.BlockVersion))
  6248. }
  6249. if m.P2PVersion != 0 {
  6250. n += 1 + sovTypes(uint64(m.P2PVersion))
  6251. }
  6252. return n
  6253. }
  6254. func (m *RequestSetOption) Size() (n int) {
  6255. if m == nil {
  6256. return 0
  6257. }
  6258. var l int
  6259. _ = l
  6260. l = len(m.Key)
  6261. if l > 0 {
  6262. n += 1 + l + sovTypes(uint64(l))
  6263. }
  6264. l = len(m.Value)
  6265. if l > 0 {
  6266. n += 1 + l + sovTypes(uint64(l))
  6267. }
  6268. return n
  6269. }
  6270. func (m *RequestInitChain) Size() (n int) {
  6271. if m == nil {
  6272. return 0
  6273. }
  6274. var l int
  6275. _ = l
  6276. l = github_com_gogo_protobuf_types.SizeOfStdTime(m.Time)
  6277. n += 1 + l + sovTypes(uint64(l))
  6278. l = len(m.ChainId)
  6279. if l > 0 {
  6280. n += 1 + l + sovTypes(uint64(l))
  6281. }
  6282. if m.ConsensusParams != nil {
  6283. l = m.ConsensusParams.Size()
  6284. n += 1 + l + sovTypes(uint64(l))
  6285. }
  6286. if len(m.Validators) > 0 {
  6287. for _, e := range m.Validators {
  6288. l = e.Size()
  6289. n += 1 + l + sovTypes(uint64(l))
  6290. }
  6291. }
  6292. l = len(m.AppStateBytes)
  6293. if l > 0 {
  6294. n += 1 + l + sovTypes(uint64(l))
  6295. }
  6296. if m.InitialHeight != 0 {
  6297. n += 1 + sovTypes(uint64(m.InitialHeight))
  6298. }
  6299. return n
  6300. }
  6301. func (m *RequestQuery) Size() (n int) {
  6302. if m == nil {
  6303. return 0
  6304. }
  6305. var l int
  6306. _ = l
  6307. l = len(m.Data)
  6308. if l > 0 {
  6309. n += 1 + l + sovTypes(uint64(l))
  6310. }
  6311. l = len(m.Path)
  6312. if l > 0 {
  6313. n += 1 + l + sovTypes(uint64(l))
  6314. }
  6315. if m.Height != 0 {
  6316. n += 1 + sovTypes(uint64(m.Height))
  6317. }
  6318. if m.Prove {
  6319. n += 2
  6320. }
  6321. return n
  6322. }
  6323. func (m *RequestBeginBlock) Size() (n int) {
  6324. if m == nil {
  6325. return 0
  6326. }
  6327. var l int
  6328. _ = l
  6329. l = len(m.Hash)
  6330. if l > 0 {
  6331. n += 1 + l + sovTypes(uint64(l))
  6332. }
  6333. l = m.Header.Size()
  6334. n += 1 + l + sovTypes(uint64(l))
  6335. l = m.LastCommitInfo.Size()
  6336. n += 1 + l + sovTypes(uint64(l))
  6337. if len(m.ByzantineValidators) > 0 {
  6338. for _, e := range m.ByzantineValidators {
  6339. l = e.Size()
  6340. n += 1 + l + sovTypes(uint64(l))
  6341. }
  6342. }
  6343. return n
  6344. }
  6345. func (m *RequestCheckTx) Size() (n int) {
  6346. if m == nil {
  6347. return 0
  6348. }
  6349. var l int
  6350. _ = l
  6351. l = len(m.Tx)
  6352. if l > 0 {
  6353. n += 1 + l + sovTypes(uint64(l))
  6354. }
  6355. if m.Type != 0 {
  6356. n += 1 + sovTypes(uint64(m.Type))
  6357. }
  6358. return n
  6359. }
  6360. func (m *RequestDeliverTx) Size() (n int) {
  6361. if m == nil {
  6362. return 0
  6363. }
  6364. var l int
  6365. _ = l
  6366. l = len(m.Tx)
  6367. if l > 0 {
  6368. n += 1 + l + sovTypes(uint64(l))
  6369. }
  6370. return n
  6371. }
  6372. func (m *RequestEndBlock) Size() (n int) {
  6373. if m == nil {
  6374. return 0
  6375. }
  6376. var l int
  6377. _ = l
  6378. if m.Height != 0 {
  6379. n += 1 + sovTypes(uint64(m.Height))
  6380. }
  6381. return n
  6382. }
  6383. func (m *RequestCommit) Size() (n int) {
  6384. if m == nil {
  6385. return 0
  6386. }
  6387. var l int
  6388. _ = l
  6389. return n
  6390. }
  6391. func (m *RequestListSnapshots) Size() (n int) {
  6392. if m == nil {
  6393. return 0
  6394. }
  6395. var l int
  6396. _ = l
  6397. return n
  6398. }
  6399. func (m *RequestOfferSnapshot) Size() (n int) {
  6400. if m == nil {
  6401. return 0
  6402. }
  6403. var l int
  6404. _ = l
  6405. if m.Snapshot != nil {
  6406. l = m.Snapshot.Size()
  6407. n += 1 + l + sovTypes(uint64(l))
  6408. }
  6409. l = len(m.AppHash)
  6410. if l > 0 {
  6411. n += 1 + l + sovTypes(uint64(l))
  6412. }
  6413. return n
  6414. }
  6415. func (m *RequestLoadSnapshotChunk) Size() (n int) {
  6416. if m == nil {
  6417. return 0
  6418. }
  6419. var l int
  6420. _ = l
  6421. if m.Height != 0 {
  6422. n += 1 + sovTypes(uint64(m.Height))
  6423. }
  6424. if m.Format != 0 {
  6425. n += 1 + sovTypes(uint64(m.Format))
  6426. }
  6427. if m.Chunk != 0 {
  6428. n += 1 + sovTypes(uint64(m.Chunk))
  6429. }
  6430. return n
  6431. }
  6432. func (m *RequestApplySnapshotChunk) Size() (n int) {
  6433. if m == nil {
  6434. return 0
  6435. }
  6436. var l int
  6437. _ = l
  6438. if m.Index != 0 {
  6439. n += 1 + sovTypes(uint64(m.Index))
  6440. }
  6441. l = len(m.Chunk)
  6442. if l > 0 {
  6443. n += 1 + l + sovTypes(uint64(l))
  6444. }
  6445. l = len(m.Sender)
  6446. if l > 0 {
  6447. n += 1 + l + sovTypes(uint64(l))
  6448. }
  6449. return n
  6450. }
  6451. func (m *Response) Size() (n int) {
  6452. if m == nil {
  6453. return 0
  6454. }
  6455. var l int
  6456. _ = l
  6457. if m.Value != nil {
  6458. n += m.Value.Size()
  6459. }
  6460. return n
  6461. }
  6462. func (m *Response_Exception) Size() (n int) {
  6463. if m == nil {
  6464. return 0
  6465. }
  6466. var l int
  6467. _ = l
  6468. if m.Exception != nil {
  6469. l = m.Exception.Size()
  6470. n += 1 + l + sovTypes(uint64(l))
  6471. }
  6472. return n
  6473. }
  6474. func (m *Response_Echo) Size() (n int) {
  6475. if m == nil {
  6476. return 0
  6477. }
  6478. var l int
  6479. _ = l
  6480. if m.Echo != nil {
  6481. l = m.Echo.Size()
  6482. n += 1 + l + sovTypes(uint64(l))
  6483. }
  6484. return n
  6485. }
  6486. func (m *Response_Flush) Size() (n int) {
  6487. if m == nil {
  6488. return 0
  6489. }
  6490. var l int
  6491. _ = l
  6492. if m.Flush != nil {
  6493. l = m.Flush.Size()
  6494. n += 1 + l + sovTypes(uint64(l))
  6495. }
  6496. return n
  6497. }
  6498. func (m *Response_Info) Size() (n int) {
  6499. if m == nil {
  6500. return 0
  6501. }
  6502. var l int
  6503. _ = l
  6504. if m.Info != nil {
  6505. l = m.Info.Size()
  6506. n += 1 + l + sovTypes(uint64(l))
  6507. }
  6508. return n
  6509. }
  6510. func (m *Response_SetOption) Size() (n int) {
  6511. if m == nil {
  6512. return 0
  6513. }
  6514. var l int
  6515. _ = l
  6516. if m.SetOption != nil {
  6517. l = m.SetOption.Size()
  6518. n += 1 + l + sovTypes(uint64(l))
  6519. }
  6520. return n
  6521. }
  6522. func (m *Response_InitChain) Size() (n int) {
  6523. if m == nil {
  6524. return 0
  6525. }
  6526. var l int
  6527. _ = l
  6528. if m.InitChain != nil {
  6529. l = m.InitChain.Size()
  6530. n += 1 + l + sovTypes(uint64(l))
  6531. }
  6532. return n
  6533. }
  6534. func (m *Response_Query) Size() (n int) {
  6535. if m == nil {
  6536. return 0
  6537. }
  6538. var l int
  6539. _ = l
  6540. if m.Query != nil {
  6541. l = m.Query.Size()
  6542. n += 1 + l + sovTypes(uint64(l))
  6543. }
  6544. return n
  6545. }
  6546. func (m *Response_BeginBlock) Size() (n int) {
  6547. if m == nil {
  6548. return 0
  6549. }
  6550. var l int
  6551. _ = l
  6552. if m.BeginBlock != nil {
  6553. l = m.BeginBlock.Size()
  6554. n += 1 + l + sovTypes(uint64(l))
  6555. }
  6556. return n
  6557. }
  6558. func (m *Response_CheckTx) Size() (n int) {
  6559. if m == nil {
  6560. return 0
  6561. }
  6562. var l int
  6563. _ = l
  6564. if m.CheckTx != nil {
  6565. l = m.CheckTx.Size()
  6566. n += 1 + l + sovTypes(uint64(l))
  6567. }
  6568. return n
  6569. }
  6570. func (m *Response_DeliverTx) Size() (n int) {
  6571. if m == nil {
  6572. return 0
  6573. }
  6574. var l int
  6575. _ = l
  6576. if m.DeliverTx != nil {
  6577. l = m.DeliverTx.Size()
  6578. n += 1 + l + sovTypes(uint64(l))
  6579. }
  6580. return n
  6581. }
  6582. func (m *Response_EndBlock) Size() (n int) {
  6583. if m == nil {
  6584. return 0
  6585. }
  6586. var l int
  6587. _ = l
  6588. if m.EndBlock != nil {
  6589. l = m.EndBlock.Size()
  6590. n += 1 + l + sovTypes(uint64(l))
  6591. }
  6592. return n
  6593. }
  6594. func (m *Response_Commit) Size() (n int) {
  6595. if m == nil {
  6596. return 0
  6597. }
  6598. var l int
  6599. _ = l
  6600. if m.Commit != nil {
  6601. l = m.Commit.Size()
  6602. n += 1 + l + sovTypes(uint64(l))
  6603. }
  6604. return n
  6605. }
  6606. func (m *Response_ListSnapshots) Size() (n int) {
  6607. if m == nil {
  6608. return 0
  6609. }
  6610. var l int
  6611. _ = l
  6612. if m.ListSnapshots != nil {
  6613. l = m.ListSnapshots.Size()
  6614. n += 1 + l + sovTypes(uint64(l))
  6615. }
  6616. return n
  6617. }
  6618. func (m *Response_OfferSnapshot) Size() (n int) {
  6619. if m == nil {
  6620. return 0
  6621. }
  6622. var l int
  6623. _ = l
  6624. if m.OfferSnapshot != nil {
  6625. l = m.OfferSnapshot.Size()
  6626. n += 1 + l + sovTypes(uint64(l))
  6627. }
  6628. return n
  6629. }
  6630. func (m *Response_LoadSnapshotChunk) Size() (n int) {
  6631. if m == nil {
  6632. return 0
  6633. }
  6634. var l int
  6635. _ = l
  6636. if m.LoadSnapshotChunk != nil {
  6637. l = m.LoadSnapshotChunk.Size()
  6638. n += 1 + l + sovTypes(uint64(l))
  6639. }
  6640. return n
  6641. }
  6642. func (m *Response_ApplySnapshotChunk) Size() (n int) {
  6643. if m == nil {
  6644. return 0
  6645. }
  6646. var l int
  6647. _ = l
  6648. if m.ApplySnapshotChunk != nil {
  6649. l = m.ApplySnapshotChunk.Size()
  6650. n += 2 + l + sovTypes(uint64(l))
  6651. }
  6652. return n
  6653. }
  6654. func (m *ResponseException) Size() (n int) {
  6655. if m == nil {
  6656. return 0
  6657. }
  6658. var l int
  6659. _ = l
  6660. l = len(m.Error)
  6661. if l > 0 {
  6662. n += 1 + l + sovTypes(uint64(l))
  6663. }
  6664. return n
  6665. }
  6666. func (m *ResponseEcho) Size() (n int) {
  6667. if m == nil {
  6668. return 0
  6669. }
  6670. var l int
  6671. _ = l
  6672. l = len(m.Message)
  6673. if l > 0 {
  6674. n += 1 + l + sovTypes(uint64(l))
  6675. }
  6676. return n
  6677. }
  6678. func (m *ResponseFlush) Size() (n int) {
  6679. if m == nil {
  6680. return 0
  6681. }
  6682. var l int
  6683. _ = l
  6684. return n
  6685. }
  6686. func (m *ResponseInfo) Size() (n int) {
  6687. if m == nil {
  6688. return 0
  6689. }
  6690. var l int
  6691. _ = l
  6692. l = len(m.Data)
  6693. if l > 0 {
  6694. n += 1 + l + sovTypes(uint64(l))
  6695. }
  6696. l = len(m.Version)
  6697. if l > 0 {
  6698. n += 1 + l + sovTypes(uint64(l))
  6699. }
  6700. if m.AppVersion != 0 {
  6701. n += 1 + sovTypes(uint64(m.AppVersion))
  6702. }
  6703. if m.LastBlockHeight != 0 {
  6704. n += 1 + sovTypes(uint64(m.LastBlockHeight))
  6705. }
  6706. l = len(m.LastBlockAppHash)
  6707. if l > 0 {
  6708. n += 1 + l + sovTypes(uint64(l))
  6709. }
  6710. return n
  6711. }
  6712. func (m *ResponseSetOption) Size() (n int) {
  6713. if m == nil {
  6714. return 0
  6715. }
  6716. var l int
  6717. _ = l
  6718. if m.Code != 0 {
  6719. n += 1 + sovTypes(uint64(m.Code))
  6720. }
  6721. l = len(m.Log)
  6722. if l > 0 {
  6723. n += 1 + l + sovTypes(uint64(l))
  6724. }
  6725. l = len(m.Info)
  6726. if l > 0 {
  6727. n += 1 + l + sovTypes(uint64(l))
  6728. }
  6729. return n
  6730. }
  6731. func (m *ResponseInitChain) Size() (n int) {
  6732. if m == nil {
  6733. return 0
  6734. }
  6735. var l int
  6736. _ = l
  6737. if m.ConsensusParams != nil {
  6738. l = m.ConsensusParams.Size()
  6739. n += 1 + l + sovTypes(uint64(l))
  6740. }
  6741. if len(m.Validators) > 0 {
  6742. for _, e := range m.Validators {
  6743. l = e.Size()
  6744. n += 1 + l + sovTypes(uint64(l))
  6745. }
  6746. }
  6747. l = len(m.AppHash)
  6748. if l > 0 {
  6749. n += 1 + l + sovTypes(uint64(l))
  6750. }
  6751. return n
  6752. }
  6753. func (m *ResponseQuery) Size() (n int) {
  6754. if m == nil {
  6755. return 0
  6756. }
  6757. var l int
  6758. _ = l
  6759. if m.Code != 0 {
  6760. n += 1 + sovTypes(uint64(m.Code))
  6761. }
  6762. l = len(m.Log)
  6763. if l > 0 {
  6764. n += 1 + l + sovTypes(uint64(l))
  6765. }
  6766. l = len(m.Info)
  6767. if l > 0 {
  6768. n += 1 + l + sovTypes(uint64(l))
  6769. }
  6770. if m.Index != 0 {
  6771. n += 1 + sovTypes(uint64(m.Index))
  6772. }
  6773. l = len(m.Key)
  6774. if l > 0 {
  6775. n += 1 + l + sovTypes(uint64(l))
  6776. }
  6777. l = len(m.Value)
  6778. if l > 0 {
  6779. n += 1 + l + sovTypes(uint64(l))
  6780. }
  6781. if m.ProofOps != nil {
  6782. l = m.ProofOps.Size()
  6783. n += 1 + l + sovTypes(uint64(l))
  6784. }
  6785. if m.Height != 0 {
  6786. n += 1 + sovTypes(uint64(m.Height))
  6787. }
  6788. l = len(m.Codespace)
  6789. if l > 0 {
  6790. n += 1 + l + sovTypes(uint64(l))
  6791. }
  6792. return n
  6793. }
  6794. func (m *ResponseBeginBlock) Size() (n int) {
  6795. if m == nil {
  6796. return 0
  6797. }
  6798. var l int
  6799. _ = l
  6800. if len(m.Events) > 0 {
  6801. for _, e := range m.Events {
  6802. l = e.Size()
  6803. n += 1 + l + sovTypes(uint64(l))
  6804. }
  6805. }
  6806. return n
  6807. }
  6808. func (m *ResponseCheckTx) Size() (n int) {
  6809. if m == nil {
  6810. return 0
  6811. }
  6812. var l int
  6813. _ = l
  6814. if m.Code != 0 {
  6815. n += 1 + sovTypes(uint64(m.Code))
  6816. }
  6817. l = len(m.Data)
  6818. if l > 0 {
  6819. n += 1 + l + sovTypes(uint64(l))
  6820. }
  6821. l = len(m.Log)
  6822. if l > 0 {
  6823. n += 1 + l + sovTypes(uint64(l))
  6824. }
  6825. l = len(m.Info)
  6826. if l > 0 {
  6827. n += 1 + l + sovTypes(uint64(l))
  6828. }
  6829. if m.GasWanted != 0 {
  6830. n += 1 + sovTypes(uint64(m.GasWanted))
  6831. }
  6832. if m.GasUsed != 0 {
  6833. n += 1 + sovTypes(uint64(m.GasUsed))
  6834. }
  6835. if len(m.Events) > 0 {
  6836. for _, e := range m.Events {
  6837. l = e.Size()
  6838. n += 1 + l + sovTypes(uint64(l))
  6839. }
  6840. }
  6841. l = len(m.Codespace)
  6842. if l > 0 {
  6843. n += 1 + l + sovTypes(uint64(l))
  6844. }
  6845. return n
  6846. }
  6847. func (m *ResponseDeliverTx) Size() (n int) {
  6848. if m == nil {
  6849. return 0
  6850. }
  6851. var l int
  6852. _ = l
  6853. if m.Code != 0 {
  6854. n += 1 + sovTypes(uint64(m.Code))
  6855. }
  6856. l = len(m.Data)
  6857. if l > 0 {
  6858. n += 1 + l + sovTypes(uint64(l))
  6859. }
  6860. l = len(m.Log)
  6861. if l > 0 {
  6862. n += 1 + l + sovTypes(uint64(l))
  6863. }
  6864. l = len(m.Info)
  6865. if l > 0 {
  6866. n += 1 + l + sovTypes(uint64(l))
  6867. }
  6868. if m.GasWanted != 0 {
  6869. n += 1 + sovTypes(uint64(m.GasWanted))
  6870. }
  6871. if m.GasUsed != 0 {
  6872. n += 1 + sovTypes(uint64(m.GasUsed))
  6873. }
  6874. if len(m.Events) > 0 {
  6875. for _, e := range m.Events {
  6876. l = e.Size()
  6877. n += 1 + l + sovTypes(uint64(l))
  6878. }
  6879. }
  6880. l = len(m.Codespace)
  6881. if l > 0 {
  6882. n += 1 + l + sovTypes(uint64(l))
  6883. }
  6884. return n
  6885. }
  6886. func (m *ResponseEndBlock) Size() (n int) {
  6887. if m == nil {
  6888. return 0
  6889. }
  6890. var l int
  6891. _ = l
  6892. if len(m.ValidatorUpdates) > 0 {
  6893. for _, e := range m.ValidatorUpdates {
  6894. l = e.Size()
  6895. n += 1 + l + sovTypes(uint64(l))
  6896. }
  6897. }
  6898. if m.ConsensusParamUpdates != nil {
  6899. l = m.ConsensusParamUpdates.Size()
  6900. n += 1 + l + sovTypes(uint64(l))
  6901. }
  6902. if len(m.Events) > 0 {
  6903. for _, e := range m.Events {
  6904. l = e.Size()
  6905. n += 1 + l + sovTypes(uint64(l))
  6906. }
  6907. }
  6908. return n
  6909. }
  6910. func (m *ResponseCommit) Size() (n int) {
  6911. if m == nil {
  6912. return 0
  6913. }
  6914. var l int
  6915. _ = l
  6916. l = len(m.Data)
  6917. if l > 0 {
  6918. n += 1 + l + sovTypes(uint64(l))
  6919. }
  6920. if m.RetainHeight != 0 {
  6921. n += 1 + sovTypes(uint64(m.RetainHeight))
  6922. }
  6923. return n
  6924. }
  6925. func (m *ResponseListSnapshots) Size() (n int) {
  6926. if m == nil {
  6927. return 0
  6928. }
  6929. var l int
  6930. _ = l
  6931. if len(m.Snapshots) > 0 {
  6932. for _, e := range m.Snapshots {
  6933. l = e.Size()
  6934. n += 1 + l + sovTypes(uint64(l))
  6935. }
  6936. }
  6937. return n
  6938. }
  6939. func (m *ResponseOfferSnapshot) Size() (n int) {
  6940. if m == nil {
  6941. return 0
  6942. }
  6943. var l int
  6944. _ = l
  6945. if m.Result != 0 {
  6946. n += 1 + sovTypes(uint64(m.Result))
  6947. }
  6948. return n
  6949. }
  6950. func (m *ResponseLoadSnapshotChunk) Size() (n int) {
  6951. if m == nil {
  6952. return 0
  6953. }
  6954. var l int
  6955. _ = l
  6956. l = len(m.Chunk)
  6957. if l > 0 {
  6958. n += 1 + l + sovTypes(uint64(l))
  6959. }
  6960. return n
  6961. }
  6962. func (m *ResponseApplySnapshotChunk) Size() (n int) {
  6963. if m == nil {
  6964. return 0
  6965. }
  6966. var l int
  6967. _ = l
  6968. if m.Result != 0 {
  6969. n += 1 + sovTypes(uint64(m.Result))
  6970. }
  6971. if len(m.RefetchChunks) > 0 {
  6972. l = 0
  6973. for _, e := range m.RefetchChunks {
  6974. l += sovTypes(uint64(e))
  6975. }
  6976. n += 1 + sovTypes(uint64(l)) + l
  6977. }
  6978. if len(m.RejectSenders) > 0 {
  6979. for _, s := range m.RejectSenders {
  6980. l = len(s)
  6981. n += 1 + l + sovTypes(uint64(l))
  6982. }
  6983. }
  6984. return n
  6985. }
  6986. func (m *ConsensusParams) Size() (n int) {
  6987. if m == nil {
  6988. return 0
  6989. }
  6990. var l int
  6991. _ = l
  6992. if m.Block != nil {
  6993. l = m.Block.Size()
  6994. n += 1 + l + sovTypes(uint64(l))
  6995. }
  6996. if m.Evidence != nil {
  6997. l = m.Evidence.Size()
  6998. n += 1 + l + sovTypes(uint64(l))
  6999. }
  7000. if m.Validator != nil {
  7001. l = m.Validator.Size()
  7002. n += 1 + l + sovTypes(uint64(l))
  7003. }
  7004. if m.Version != nil {
  7005. l = m.Version.Size()
  7006. n += 1 + l + sovTypes(uint64(l))
  7007. }
  7008. return n
  7009. }
  7010. func (m *BlockParams) Size() (n int) {
  7011. if m == nil {
  7012. return 0
  7013. }
  7014. var l int
  7015. _ = l
  7016. if m.MaxBytes != 0 {
  7017. n += 1 + sovTypes(uint64(m.MaxBytes))
  7018. }
  7019. if m.MaxGas != 0 {
  7020. n += 1 + sovTypes(uint64(m.MaxGas))
  7021. }
  7022. return n
  7023. }
  7024. func (m *LastCommitInfo) Size() (n int) {
  7025. if m == nil {
  7026. return 0
  7027. }
  7028. var l int
  7029. _ = l
  7030. if m.Round != 0 {
  7031. n += 1 + sovTypes(uint64(m.Round))
  7032. }
  7033. if len(m.Votes) > 0 {
  7034. for _, e := range m.Votes {
  7035. l = e.Size()
  7036. n += 1 + l + sovTypes(uint64(l))
  7037. }
  7038. }
  7039. return n
  7040. }
  7041. func (m *Event) Size() (n int) {
  7042. if m == nil {
  7043. return 0
  7044. }
  7045. var l int
  7046. _ = l
  7047. l = len(m.Type)
  7048. if l > 0 {
  7049. n += 1 + l + sovTypes(uint64(l))
  7050. }
  7051. if len(m.Attributes) > 0 {
  7052. for _, e := range m.Attributes {
  7053. l = e.Size()
  7054. n += 1 + l + sovTypes(uint64(l))
  7055. }
  7056. }
  7057. return n
  7058. }
  7059. func (m *EventAttribute) Size() (n int) {
  7060. if m == nil {
  7061. return 0
  7062. }
  7063. var l int
  7064. _ = l
  7065. l = len(m.Key)
  7066. if l > 0 {
  7067. n += 1 + l + sovTypes(uint64(l))
  7068. }
  7069. l = len(m.Value)
  7070. if l > 0 {
  7071. n += 1 + l + sovTypes(uint64(l))
  7072. }
  7073. if m.Index {
  7074. n += 2
  7075. }
  7076. return n
  7077. }
  7078. func (m *TxResult) Size() (n int) {
  7079. if m == nil {
  7080. return 0
  7081. }
  7082. var l int
  7083. _ = l
  7084. if m.Height != 0 {
  7085. n += 1 + sovTypes(uint64(m.Height))
  7086. }
  7087. if m.Index != 0 {
  7088. n += 1 + sovTypes(uint64(m.Index))
  7089. }
  7090. l = len(m.Tx)
  7091. if l > 0 {
  7092. n += 1 + l + sovTypes(uint64(l))
  7093. }
  7094. l = m.Result.Size()
  7095. n += 1 + l + sovTypes(uint64(l))
  7096. return n
  7097. }
  7098. func (m *Validator) Size() (n int) {
  7099. if m == nil {
  7100. return 0
  7101. }
  7102. var l int
  7103. _ = l
  7104. l = len(m.Address)
  7105. if l > 0 {
  7106. n += 1 + l + sovTypes(uint64(l))
  7107. }
  7108. if m.Power != 0 {
  7109. n += 1 + sovTypes(uint64(m.Power))
  7110. }
  7111. return n
  7112. }
  7113. func (m *ValidatorUpdate) Size() (n int) {
  7114. if m == nil {
  7115. return 0
  7116. }
  7117. var l int
  7118. _ = l
  7119. l = m.PubKey.Size()
  7120. n += 1 + l + sovTypes(uint64(l))
  7121. if m.Power != 0 {
  7122. n += 1 + sovTypes(uint64(m.Power))
  7123. }
  7124. return n
  7125. }
  7126. func (m *VoteInfo) Size() (n int) {
  7127. if m == nil {
  7128. return 0
  7129. }
  7130. var l int
  7131. _ = l
  7132. l = m.Validator.Size()
  7133. n += 1 + l + sovTypes(uint64(l))
  7134. if m.SignedLastBlock {
  7135. n += 2
  7136. }
  7137. return n
  7138. }
  7139. func (m *Evidence) Size() (n int) {
  7140. if m == nil {
  7141. return 0
  7142. }
  7143. var l int
  7144. _ = l
  7145. if m.Type != 0 {
  7146. n += 1 + sovTypes(uint64(m.Type))
  7147. }
  7148. l = m.Validator.Size()
  7149. n += 1 + l + sovTypes(uint64(l))
  7150. if m.Height != 0 {
  7151. n += 1 + sovTypes(uint64(m.Height))
  7152. }
  7153. l = github_com_gogo_protobuf_types.SizeOfStdTime(m.Time)
  7154. n += 1 + l + sovTypes(uint64(l))
  7155. if m.TotalVotingPower != 0 {
  7156. n += 1 + sovTypes(uint64(m.TotalVotingPower))
  7157. }
  7158. return n
  7159. }
  7160. func (m *Snapshot) Size() (n int) {
  7161. if m == nil {
  7162. return 0
  7163. }
  7164. var l int
  7165. _ = l
  7166. if m.Height != 0 {
  7167. n += 1 + sovTypes(uint64(m.Height))
  7168. }
  7169. if m.Format != 0 {
  7170. n += 1 + sovTypes(uint64(m.Format))
  7171. }
  7172. if m.Chunks != 0 {
  7173. n += 1 + sovTypes(uint64(m.Chunks))
  7174. }
  7175. l = len(m.Hash)
  7176. if l > 0 {
  7177. n += 1 + l + sovTypes(uint64(l))
  7178. }
  7179. l = len(m.Metadata)
  7180. if l > 0 {
  7181. n += 1 + l + sovTypes(uint64(l))
  7182. }
  7183. return n
  7184. }
  7185. func sovTypes(x uint64) (n int) {
  7186. return (math_bits.Len64(x|1) + 6) / 7
  7187. }
  7188. func sozTypes(x uint64) (n int) {
  7189. return sovTypes(uint64((x << 1) ^ uint64((int64(x) >> 63))))
  7190. }
  7191. func (m *Request) Unmarshal(dAtA []byte) error {
  7192. l := len(dAtA)
  7193. iNdEx := 0
  7194. for iNdEx < l {
  7195. preIndex := iNdEx
  7196. var wire uint64
  7197. for shift := uint(0); ; shift += 7 {
  7198. if shift >= 64 {
  7199. return ErrIntOverflowTypes
  7200. }
  7201. if iNdEx >= l {
  7202. return io.ErrUnexpectedEOF
  7203. }
  7204. b := dAtA[iNdEx]
  7205. iNdEx++
  7206. wire |= uint64(b&0x7F) << shift
  7207. if b < 0x80 {
  7208. break
  7209. }
  7210. }
  7211. fieldNum := int32(wire >> 3)
  7212. wireType := int(wire & 0x7)
  7213. if wireType == 4 {
  7214. return fmt.Errorf("proto: Request: wiretype end group for non-group")
  7215. }
  7216. if fieldNum <= 0 {
  7217. return fmt.Errorf("proto: Request: illegal tag %d (wire type %d)", fieldNum, wire)
  7218. }
  7219. switch fieldNum {
  7220. case 1:
  7221. if wireType != 2 {
  7222. return fmt.Errorf("proto: wrong wireType = %d for field Echo", wireType)
  7223. }
  7224. var msglen int
  7225. for shift := uint(0); ; shift += 7 {
  7226. if shift >= 64 {
  7227. return ErrIntOverflowTypes
  7228. }
  7229. if iNdEx >= l {
  7230. return io.ErrUnexpectedEOF
  7231. }
  7232. b := dAtA[iNdEx]
  7233. iNdEx++
  7234. msglen |= int(b&0x7F) << shift
  7235. if b < 0x80 {
  7236. break
  7237. }
  7238. }
  7239. if msglen < 0 {
  7240. return ErrInvalidLengthTypes
  7241. }
  7242. postIndex := iNdEx + msglen
  7243. if postIndex < 0 {
  7244. return ErrInvalidLengthTypes
  7245. }
  7246. if postIndex > l {
  7247. return io.ErrUnexpectedEOF
  7248. }
  7249. v := &RequestEcho{}
  7250. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7251. return err
  7252. }
  7253. m.Value = &Request_Echo{v}
  7254. iNdEx = postIndex
  7255. case 2:
  7256. if wireType != 2 {
  7257. return fmt.Errorf("proto: wrong wireType = %d for field Flush", wireType)
  7258. }
  7259. var msglen int
  7260. for shift := uint(0); ; shift += 7 {
  7261. if shift >= 64 {
  7262. return ErrIntOverflowTypes
  7263. }
  7264. if iNdEx >= l {
  7265. return io.ErrUnexpectedEOF
  7266. }
  7267. b := dAtA[iNdEx]
  7268. iNdEx++
  7269. msglen |= int(b&0x7F) << shift
  7270. if b < 0x80 {
  7271. break
  7272. }
  7273. }
  7274. if msglen < 0 {
  7275. return ErrInvalidLengthTypes
  7276. }
  7277. postIndex := iNdEx + msglen
  7278. if postIndex < 0 {
  7279. return ErrInvalidLengthTypes
  7280. }
  7281. if postIndex > l {
  7282. return io.ErrUnexpectedEOF
  7283. }
  7284. v := &RequestFlush{}
  7285. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7286. return err
  7287. }
  7288. m.Value = &Request_Flush{v}
  7289. iNdEx = postIndex
  7290. case 3:
  7291. if wireType != 2 {
  7292. return fmt.Errorf("proto: wrong wireType = %d for field Info", wireType)
  7293. }
  7294. var msglen int
  7295. for shift := uint(0); ; shift += 7 {
  7296. if shift >= 64 {
  7297. return ErrIntOverflowTypes
  7298. }
  7299. if iNdEx >= l {
  7300. return io.ErrUnexpectedEOF
  7301. }
  7302. b := dAtA[iNdEx]
  7303. iNdEx++
  7304. msglen |= int(b&0x7F) << shift
  7305. if b < 0x80 {
  7306. break
  7307. }
  7308. }
  7309. if msglen < 0 {
  7310. return ErrInvalidLengthTypes
  7311. }
  7312. postIndex := iNdEx + msglen
  7313. if postIndex < 0 {
  7314. return ErrInvalidLengthTypes
  7315. }
  7316. if postIndex > l {
  7317. return io.ErrUnexpectedEOF
  7318. }
  7319. v := &RequestInfo{}
  7320. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7321. return err
  7322. }
  7323. m.Value = &Request_Info{v}
  7324. iNdEx = postIndex
  7325. case 4:
  7326. if wireType != 2 {
  7327. return fmt.Errorf("proto: wrong wireType = %d for field SetOption", wireType)
  7328. }
  7329. var msglen int
  7330. for shift := uint(0); ; shift += 7 {
  7331. if shift >= 64 {
  7332. return ErrIntOverflowTypes
  7333. }
  7334. if iNdEx >= l {
  7335. return io.ErrUnexpectedEOF
  7336. }
  7337. b := dAtA[iNdEx]
  7338. iNdEx++
  7339. msglen |= int(b&0x7F) << shift
  7340. if b < 0x80 {
  7341. break
  7342. }
  7343. }
  7344. if msglen < 0 {
  7345. return ErrInvalidLengthTypes
  7346. }
  7347. postIndex := iNdEx + msglen
  7348. if postIndex < 0 {
  7349. return ErrInvalidLengthTypes
  7350. }
  7351. if postIndex > l {
  7352. return io.ErrUnexpectedEOF
  7353. }
  7354. v := &RequestSetOption{}
  7355. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7356. return err
  7357. }
  7358. m.Value = &Request_SetOption{v}
  7359. iNdEx = postIndex
  7360. case 5:
  7361. if wireType != 2 {
  7362. return fmt.Errorf("proto: wrong wireType = %d for field InitChain", wireType)
  7363. }
  7364. var msglen int
  7365. for shift := uint(0); ; shift += 7 {
  7366. if shift >= 64 {
  7367. return ErrIntOverflowTypes
  7368. }
  7369. if iNdEx >= l {
  7370. return io.ErrUnexpectedEOF
  7371. }
  7372. b := dAtA[iNdEx]
  7373. iNdEx++
  7374. msglen |= int(b&0x7F) << shift
  7375. if b < 0x80 {
  7376. break
  7377. }
  7378. }
  7379. if msglen < 0 {
  7380. return ErrInvalidLengthTypes
  7381. }
  7382. postIndex := iNdEx + msglen
  7383. if postIndex < 0 {
  7384. return ErrInvalidLengthTypes
  7385. }
  7386. if postIndex > l {
  7387. return io.ErrUnexpectedEOF
  7388. }
  7389. v := &RequestInitChain{}
  7390. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7391. return err
  7392. }
  7393. m.Value = &Request_InitChain{v}
  7394. iNdEx = postIndex
  7395. case 6:
  7396. if wireType != 2 {
  7397. return fmt.Errorf("proto: wrong wireType = %d for field Query", wireType)
  7398. }
  7399. var msglen int
  7400. for shift := uint(0); ; shift += 7 {
  7401. if shift >= 64 {
  7402. return ErrIntOverflowTypes
  7403. }
  7404. if iNdEx >= l {
  7405. return io.ErrUnexpectedEOF
  7406. }
  7407. b := dAtA[iNdEx]
  7408. iNdEx++
  7409. msglen |= int(b&0x7F) << shift
  7410. if b < 0x80 {
  7411. break
  7412. }
  7413. }
  7414. if msglen < 0 {
  7415. return ErrInvalidLengthTypes
  7416. }
  7417. postIndex := iNdEx + msglen
  7418. if postIndex < 0 {
  7419. return ErrInvalidLengthTypes
  7420. }
  7421. if postIndex > l {
  7422. return io.ErrUnexpectedEOF
  7423. }
  7424. v := &RequestQuery{}
  7425. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7426. return err
  7427. }
  7428. m.Value = &Request_Query{v}
  7429. iNdEx = postIndex
  7430. case 7:
  7431. if wireType != 2 {
  7432. return fmt.Errorf("proto: wrong wireType = %d for field BeginBlock", wireType)
  7433. }
  7434. var msglen int
  7435. for shift := uint(0); ; shift += 7 {
  7436. if shift >= 64 {
  7437. return ErrIntOverflowTypes
  7438. }
  7439. if iNdEx >= l {
  7440. return io.ErrUnexpectedEOF
  7441. }
  7442. b := dAtA[iNdEx]
  7443. iNdEx++
  7444. msglen |= int(b&0x7F) << shift
  7445. if b < 0x80 {
  7446. break
  7447. }
  7448. }
  7449. if msglen < 0 {
  7450. return ErrInvalidLengthTypes
  7451. }
  7452. postIndex := iNdEx + msglen
  7453. if postIndex < 0 {
  7454. return ErrInvalidLengthTypes
  7455. }
  7456. if postIndex > l {
  7457. return io.ErrUnexpectedEOF
  7458. }
  7459. v := &RequestBeginBlock{}
  7460. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7461. return err
  7462. }
  7463. m.Value = &Request_BeginBlock{v}
  7464. iNdEx = postIndex
  7465. case 8:
  7466. if wireType != 2 {
  7467. return fmt.Errorf("proto: wrong wireType = %d for field CheckTx", wireType)
  7468. }
  7469. var msglen int
  7470. for shift := uint(0); ; shift += 7 {
  7471. if shift >= 64 {
  7472. return ErrIntOverflowTypes
  7473. }
  7474. if iNdEx >= l {
  7475. return io.ErrUnexpectedEOF
  7476. }
  7477. b := dAtA[iNdEx]
  7478. iNdEx++
  7479. msglen |= int(b&0x7F) << shift
  7480. if b < 0x80 {
  7481. break
  7482. }
  7483. }
  7484. if msglen < 0 {
  7485. return ErrInvalidLengthTypes
  7486. }
  7487. postIndex := iNdEx + msglen
  7488. if postIndex < 0 {
  7489. return ErrInvalidLengthTypes
  7490. }
  7491. if postIndex > l {
  7492. return io.ErrUnexpectedEOF
  7493. }
  7494. v := &RequestCheckTx{}
  7495. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7496. return err
  7497. }
  7498. m.Value = &Request_CheckTx{v}
  7499. iNdEx = postIndex
  7500. case 9:
  7501. if wireType != 2 {
  7502. return fmt.Errorf("proto: wrong wireType = %d for field DeliverTx", wireType)
  7503. }
  7504. var msglen int
  7505. for shift := uint(0); ; shift += 7 {
  7506. if shift >= 64 {
  7507. return ErrIntOverflowTypes
  7508. }
  7509. if iNdEx >= l {
  7510. return io.ErrUnexpectedEOF
  7511. }
  7512. b := dAtA[iNdEx]
  7513. iNdEx++
  7514. msglen |= int(b&0x7F) << shift
  7515. if b < 0x80 {
  7516. break
  7517. }
  7518. }
  7519. if msglen < 0 {
  7520. return ErrInvalidLengthTypes
  7521. }
  7522. postIndex := iNdEx + msglen
  7523. if postIndex < 0 {
  7524. return ErrInvalidLengthTypes
  7525. }
  7526. if postIndex > l {
  7527. return io.ErrUnexpectedEOF
  7528. }
  7529. v := &RequestDeliverTx{}
  7530. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7531. return err
  7532. }
  7533. m.Value = &Request_DeliverTx{v}
  7534. iNdEx = postIndex
  7535. case 10:
  7536. if wireType != 2 {
  7537. return fmt.Errorf("proto: wrong wireType = %d for field EndBlock", wireType)
  7538. }
  7539. var msglen int
  7540. for shift := uint(0); ; shift += 7 {
  7541. if shift >= 64 {
  7542. return ErrIntOverflowTypes
  7543. }
  7544. if iNdEx >= l {
  7545. return io.ErrUnexpectedEOF
  7546. }
  7547. b := dAtA[iNdEx]
  7548. iNdEx++
  7549. msglen |= int(b&0x7F) << shift
  7550. if b < 0x80 {
  7551. break
  7552. }
  7553. }
  7554. if msglen < 0 {
  7555. return ErrInvalidLengthTypes
  7556. }
  7557. postIndex := iNdEx + msglen
  7558. if postIndex < 0 {
  7559. return ErrInvalidLengthTypes
  7560. }
  7561. if postIndex > l {
  7562. return io.ErrUnexpectedEOF
  7563. }
  7564. v := &RequestEndBlock{}
  7565. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7566. return err
  7567. }
  7568. m.Value = &Request_EndBlock{v}
  7569. iNdEx = postIndex
  7570. case 11:
  7571. if wireType != 2 {
  7572. return fmt.Errorf("proto: wrong wireType = %d for field Commit", wireType)
  7573. }
  7574. var msglen int
  7575. for shift := uint(0); ; shift += 7 {
  7576. if shift >= 64 {
  7577. return ErrIntOverflowTypes
  7578. }
  7579. if iNdEx >= l {
  7580. return io.ErrUnexpectedEOF
  7581. }
  7582. b := dAtA[iNdEx]
  7583. iNdEx++
  7584. msglen |= int(b&0x7F) << shift
  7585. if b < 0x80 {
  7586. break
  7587. }
  7588. }
  7589. if msglen < 0 {
  7590. return ErrInvalidLengthTypes
  7591. }
  7592. postIndex := iNdEx + msglen
  7593. if postIndex < 0 {
  7594. return ErrInvalidLengthTypes
  7595. }
  7596. if postIndex > l {
  7597. return io.ErrUnexpectedEOF
  7598. }
  7599. v := &RequestCommit{}
  7600. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7601. return err
  7602. }
  7603. m.Value = &Request_Commit{v}
  7604. iNdEx = postIndex
  7605. case 12:
  7606. if wireType != 2 {
  7607. return fmt.Errorf("proto: wrong wireType = %d for field ListSnapshots", wireType)
  7608. }
  7609. var msglen int
  7610. for shift := uint(0); ; shift += 7 {
  7611. if shift >= 64 {
  7612. return ErrIntOverflowTypes
  7613. }
  7614. if iNdEx >= l {
  7615. return io.ErrUnexpectedEOF
  7616. }
  7617. b := dAtA[iNdEx]
  7618. iNdEx++
  7619. msglen |= int(b&0x7F) << shift
  7620. if b < 0x80 {
  7621. break
  7622. }
  7623. }
  7624. if msglen < 0 {
  7625. return ErrInvalidLengthTypes
  7626. }
  7627. postIndex := iNdEx + msglen
  7628. if postIndex < 0 {
  7629. return ErrInvalidLengthTypes
  7630. }
  7631. if postIndex > l {
  7632. return io.ErrUnexpectedEOF
  7633. }
  7634. v := &RequestListSnapshots{}
  7635. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7636. return err
  7637. }
  7638. m.Value = &Request_ListSnapshots{v}
  7639. iNdEx = postIndex
  7640. case 13:
  7641. if wireType != 2 {
  7642. return fmt.Errorf("proto: wrong wireType = %d for field OfferSnapshot", wireType)
  7643. }
  7644. var msglen int
  7645. for shift := uint(0); ; shift += 7 {
  7646. if shift >= 64 {
  7647. return ErrIntOverflowTypes
  7648. }
  7649. if iNdEx >= l {
  7650. return io.ErrUnexpectedEOF
  7651. }
  7652. b := dAtA[iNdEx]
  7653. iNdEx++
  7654. msglen |= int(b&0x7F) << shift
  7655. if b < 0x80 {
  7656. break
  7657. }
  7658. }
  7659. if msglen < 0 {
  7660. return ErrInvalidLengthTypes
  7661. }
  7662. postIndex := iNdEx + msglen
  7663. if postIndex < 0 {
  7664. return ErrInvalidLengthTypes
  7665. }
  7666. if postIndex > l {
  7667. return io.ErrUnexpectedEOF
  7668. }
  7669. v := &RequestOfferSnapshot{}
  7670. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7671. return err
  7672. }
  7673. m.Value = &Request_OfferSnapshot{v}
  7674. iNdEx = postIndex
  7675. case 14:
  7676. if wireType != 2 {
  7677. return fmt.Errorf("proto: wrong wireType = %d for field LoadSnapshotChunk", wireType)
  7678. }
  7679. var msglen int
  7680. for shift := uint(0); ; shift += 7 {
  7681. if shift >= 64 {
  7682. return ErrIntOverflowTypes
  7683. }
  7684. if iNdEx >= l {
  7685. return io.ErrUnexpectedEOF
  7686. }
  7687. b := dAtA[iNdEx]
  7688. iNdEx++
  7689. msglen |= int(b&0x7F) << shift
  7690. if b < 0x80 {
  7691. break
  7692. }
  7693. }
  7694. if msglen < 0 {
  7695. return ErrInvalidLengthTypes
  7696. }
  7697. postIndex := iNdEx + msglen
  7698. if postIndex < 0 {
  7699. return ErrInvalidLengthTypes
  7700. }
  7701. if postIndex > l {
  7702. return io.ErrUnexpectedEOF
  7703. }
  7704. v := &RequestLoadSnapshotChunk{}
  7705. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7706. return err
  7707. }
  7708. m.Value = &Request_LoadSnapshotChunk{v}
  7709. iNdEx = postIndex
  7710. case 15:
  7711. if wireType != 2 {
  7712. return fmt.Errorf("proto: wrong wireType = %d for field ApplySnapshotChunk", wireType)
  7713. }
  7714. var msglen int
  7715. for shift := uint(0); ; shift += 7 {
  7716. if shift >= 64 {
  7717. return ErrIntOverflowTypes
  7718. }
  7719. if iNdEx >= l {
  7720. return io.ErrUnexpectedEOF
  7721. }
  7722. b := dAtA[iNdEx]
  7723. iNdEx++
  7724. msglen |= int(b&0x7F) << shift
  7725. if b < 0x80 {
  7726. break
  7727. }
  7728. }
  7729. if msglen < 0 {
  7730. return ErrInvalidLengthTypes
  7731. }
  7732. postIndex := iNdEx + msglen
  7733. if postIndex < 0 {
  7734. return ErrInvalidLengthTypes
  7735. }
  7736. if postIndex > l {
  7737. return io.ErrUnexpectedEOF
  7738. }
  7739. v := &RequestApplySnapshotChunk{}
  7740. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  7741. return err
  7742. }
  7743. m.Value = &Request_ApplySnapshotChunk{v}
  7744. iNdEx = postIndex
  7745. default:
  7746. iNdEx = preIndex
  7747. skippy, err := skipTypes(dAtA[iNdEx:])
  7748. if err != nil {
  7749. return err
  7750. }
  7751. if skippy < 0 {
  7752. return ErrInvalidLengthTypes
  7753. }
  7754. if (iNdEx + skippy) < 0 {
  7755. return ErrInvalidLengthTypes
  7756. }
  7757. if (iNdEx + skippy) > l {
  7758. return io.ErrUnexpectedEOF
  7759. }
  7760. iNdEx += skippy
  7761. }
  7762. }
  7763. if iNdEx > l {
  7764. return io.ErrUnexpectedEOF
  7765. }
  7766. return nil
  7767. }
  7768. func (m *RequestEcho) Unmarshal(dAtA []byte) error {
  7769. l := len(dAtA)
  7770. iNdEx := 0
  7771. for iNdEx < l {
  7772. preIndex := iNdEx
  7773. var wire uint64
  7774. for shift := uint(0); ; shift += 7 {
  7775. if shift >= 64 {
  7776. return ErrIntOverflowTypes
  7777. }
  7778. if iNdEx >= l {
  7779. return io.ErrUnexpectedEOF
  7780. }
  7781. b := dAtA[iNdEx]
  7782. iNdEx++
  7783. wire |= uint64(b&0x7F) << shift
  7784. if b < 0x80 {
  7785. break
  7786. }
  7787. }
  7788. fieldNum := int32(wire >> 3)
  7789. wireType := int(wire & 0x7)
  7790. if wireType == 4 {
  7791. return fmt.Errorf("proto: RequestEcho: wiretype end group for non-group")
  7792. }
  7793. if fieldNum <= 0 {
  7794. return fmt.Errorf("proto: RequestEcho: illegal tag %d (wire type %d)", fieldNum, wire)
  7795. }
  7796. switch fieldNum {
  7797. case 1:
  7798. if wireType != 2 {
  7799. return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
  7800. }
  7801. var stringLen uint64
  7802. for shift := uint(0); ; shift += 7 {
  7803. if shift >= 64 {
  7804. return ErrIntOverflowTypes
  7805. }
  7806. if iNdEx >= l {
  7807. return io.ErrUnexpectedEOF
  7808. }
  7809. b := dAtA[iNdEx]
  7810. iNdEx++
  7811. stringLen |= uint64(b&0x7F) << shift
  7812. if b < 0x80 {
  7813. break
  7814. }
  7815. }
  7816. intStringLen := int(stringLen)
  7817. if intStringLen < 0 {
  7818. return ErrInvalidLengthTypes
  7819. }
  7820. postIndex := iNdEx + intStringLen
  7821. if postIndex < 0 {
  7822. return ErrInvalidLengthTypes
  7823. }
  7824. if postIndex > l {
  7825. return io.ErrUnexpectedEOF
  7826. }
  7827. m.Message = string(dAtA[iNdEx:postIndex])
  7828. iNdEx = postIndex
  7829. default:
  7830. iNdEx = preIndex
  7831. skippy, err := skipTypes(dAtA[iNdEx:])
  7832. if err != nil {
  7833. return err
  7834. }
  7835. if skippy < 0 {
  7836. return ErrInvalidLengthTypes
  7837. }
  7838. if (iNdEx + skippy) < 0 {
  7839. return ErrInvalidLengthTypes
  7840. }
  7841. if (iNdEx + skippy) > l {
  7842. return io.ErrUnexpectedEOF
  7843. }
  7844. iNdEx += skippy
  7845. }
  7846. }
  7847. if iNdEx > l {
  7848. return io.ErrUnexpectedEOF
  7849. }
  7850. return nil
  7851. }
  7852. func (m *RequestFlush) Unmarshal(dAtA []byte) error {
  7853. l := len(dAtA)
  7854. iNdEx := 0
  7855. for iNdEx < l {
  7856. preIndex := iNdEx
  7857. var wire uint64
  7858. for shift := uint(0); ; shift += 7 {
  7859. if shift >= 64 {
  7860. return ErrIntOverflowTypes
  7861. }
  7862. if iNdEx >= l {
  7863. return io.ErrUnexpectedEOF
  7864. }
  7865. b := dAtA[iNdEx]
  7866. iNdEx++
  7867. wire |= uint64(b&0x7F) << shift
  7868. if b < 0x80 {
  7869. break
  7870. }
  7871. }
  7872. fieldNum := int32(wire >> 3)
  7873. wireType := int(wire & 0x7)
  7874. if wireType == 4 {
  7875. return fmt.Errorf("proto: RequestFlush: wiretype end group for non-group")
  7876. }
  7877. if fieldNum <= 0 {
  7878. return fmt.Errorf("proto: RequestFlush: illegal tag %d (wire type %d)", fieldNum, wire)
  7879. }
  7880. switch fieldNum {
  7881. default:
  7882. iNdEx = preIndex
  7883. skippy, err := skipTypes(dAtA[iNdEx:])
  7884. if err != nil {
  7885. return err
  7886. }
  7887. if skippy < 0 {
  7888. return ErrInvalidLengthTypes
  7889. }
  7890. if (iNdEx + skippy) < 0 {
  7891. return ErrInvalidLengthTypes
  7892. }
  7893. if (iNdEx + skippy) > l {
  7894. return io.ErrUnexpectedEOF
  7895. }
  7896. iNdEx += skippy
  7897. }
  7898. }
  7899. if iNdEx > l {
  7900. return io.ErrUnexpectedEOF
  7901. }
  7902. return nil
  7903. }
  7904. func (m *RequestInfo) Unmarshal(dAtA []byte) error {
  7905. l := len(dAtA)
  7906. iNdEx := 0
  7907. for iNdEx < l {
  7908. preIndex := iNdEx
  7909. var wire uint64
  7910. for shift := uint(0); ; shift += 7 {
  7911. if shift >= 64 {
  7912. return ErrIntOverflowTypes
  7913. }
  7914. if iNdEx >= l {
  7915. return io.ErrUnexpectedEOF
  7916. }
  7917. b := dAtA[iNdEx]
  7918. iNdEx++
  7919. wire |= uint64(b&0x7F) << shift
  7920. if b < 0x80 {
  7921. break
  7922. }
  7923. }
  7924. fieldNum := int32(wire >> 3)
  7925. wireType := int(wire & 0x7)
  7926. if wireType == 4 {
  7927. return fmt.Errorf("proto: RequestInfo: wiretype end group for non-group")
  7928. }
  7929. if fieldNum <= 0 {
  7930. return fmt.Errorf("proto: RequestInfo: illegal tag %d (wire type %d)", fieldNum, wire)
  7931. }
  7932. switch fieldNum {
  7933. case 1:
  7934. if wireType != 2 {
  7935. return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType)
  7936. }
  7937. var stringLen uint64
  7938. for shift := uint(0); ; shift += 7 {
  7939. if shift >= 64 {
  7940. return ErrIntOverflowTypes
  7941. }
  7942. if iNdEx >= l {
  7943. return io.ErrUnexpectedEOF
  7944. }
  7945. b := dAtA[iNdEx]
  7946. iNdEx++
  7947. stringLen |= uint64(b&0x7F) << shift
  7948. if b < 0x80 {
  7949. break
  7950. }
  7951. }
  7952. intStringLen := int(stringLen)
  7953. if intStringLen < 0 {
  7954. return ErrInvalidLengthTypes
  7955. }
  7956. postIndex := iNdEx + intStringLen
  7957. if postIndex < 0 {
  7958. return ErrInvalidLengthTypes
  7959. }
  7960. if postIndex > l {
  7961. return io.ErrUnexpectedEOF
  7962. }
  7963. m.Version = string(dAtA[iNdEx:postIndex])
  7964. iNdEx = postIndex
  7965. case 2:
  7966. if wireType != 0 {
  7967. return fmt.Errorf("proto: wrong wireType = %d for field BlockVersion", wireType)
  7968. }
  7969. m.BlockVersion = 0
  7970. for shift := uint(0); ; shift += 7 {
  7971. if shift >= 64 {
  7972. return ErrIntOverflowTypes
  7973. }
  7974. if iNdEx >= l {
  7975. return io.ErrUnexpectedEOF
  7976. }
  7977. b := dAtA[iNdEx]
  7978. iNdEx++
  7979. m.BlockVersion |= uint64(b&0x7F) << shift
  7980. if b < 0x80 {
  7981. break
  7982. }
  7983. }
  7984. case 3:
  7985. if wireType != 0 {
  7986. return fmt.Errorf("proto: wrong wireType = %d for field P2PVersion", wireType)
  7987. }
  7988. m.P2PVersion = 0
  7989. for shift := uint(0); ; shift += 7 {
  7990. if shift >= 64 {
  7991. return ErrIntOverflowTypes
  7992. }
  7993. if iNdEx >= l {
  7994. return io.ErrUnexpectedEOF
  7995. }
  7996. b := dAtA[iNdEx]
  7997. iNdEx++
  7998. m.P2PVersion |= uint64(b&0x7F) << shift
  7999. if b < 0x80 {
  8000. break
  8001. }
  8002. }
  8003. default:
  8004. iNdEx = preIndex
  8005. skippy, err := skipTypes(dAtA[iNdEx:])
  8006. if err != nil {
  8007. return err
  8008. }
  8009. if skippy < 0 {
  8010. return ErrInvalidLengthTypes
  8011. }
  8012. if (iNdEx + skippy) < 0 {
  8013. return ErrInvalidLengthTypes
  8014. }
  8015. if (iNdEx + skippy) > l {
  8016. return io.ErrUnexpectedEOF
  8017. }
  8018. iNdEx += skippy
  8019. }
  8020. }
  8021. if iNdEx > l {
  8022. return io.ErrUnexpectedEOF
  8023. }
  8024. return nil
  8025. }
  8026. func (m *RequestSetOption) Unmarshal(dAtA []byte) error {
  8027. l := len(dAtA)
  8028. iNdEx := 0
  8029. for iNdEx < l {
  8030. preIndex := iNdEx
  8031. var wire uint64
  8032. for shift := uint(0); ; shift += 7 {
  8033. if shift >= 64 {
  8034. return ErrIntOverflowTypes
  8035. }
  8036. if iNdEx >= l {
  8037. return io.ErrUnexpectedEOF
  8038. }
  8039. b := dAtA[iNdEx]
  8040. iNdEx++
  8041. wire |= uint64(b&0x7F) << shift
  8042. if b < 0x80 {
  8043. break
  8044. }
  8045. }
  8046. fieldNum := int32(wire >> 3)
  8047. wireType := int(wire & 0x7)
  8048. if wireType == 4 {
  8049. return fmt.Errorf("proto: RequestSetOption: wiretype end group for non-group")
  8050. }
  8051. if fieldNum <= 0 {
  8052. return fmt.Errorf("proto: RequestSetOption: illegal tag %d (wire type %d)", fieldNum, wire)
  8053. }
  8054. switch fieldNum {
  8055. case 1:
  8056. if wireType != 2 {
  8057. return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
  8058. }
  8059. var stringLen uint64
  8060. for shift := uint(0); ; shift += 7 {
  8061. if shift >= 64 {
  8062. return ErrIntOverflowTypes
  8063. }
  8064. if iNdEx >= l {
  8065. return io.ErrUnexpectedEOF
  8066. }
  8067. b := dAtA[iNdEx]
  8068. iNdEx++
  8069. stringLen |= uint64(b&0x7F) << shift
  8070. if b < 0x80 {
  8071. break
  8072. }
  8073. }
  8074. intStringLen := int(stringLen)
  8075. if intStringLen < 0 {
  8076. return ErrInvalidLengthTypes
  8077. }
  8078. postIndex := iNdEx + intStringLen
  8079. if postIndex < 0 {
  8080. return ErrInvalidLengthTypes
  8081. }
  8082. if postIndex > l {
  8083. return io.ErrUnexpectedEOF
  8084. }
  8085. m.Key = string(dAtA[iNdEx:postIndex])
  8086. iNdEx = postIndex
  8087. case 2:
  8088. if wireType != 2 {
  8089. return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
  8090. }
  8091. var stringLen uint64
  8092. for shift := uint(0); ; shift += 7 {
  8093. if shift >= 64 {
  8094. return ErrIntOverflowTypes
  8095. }
  8096. if iNdEx >= l {
  8097. return io.ErrUnexpectedEOF
  8098. }
  8099. b := dAtA[iNdEx]
  8100. iNdEx++
  8101. stringLen |= uint64(b&0x7F) << shift
  8102. if b < 0x80 {
  8103. break
  8104. }
  8105. }
  8106. intStringLen := int(stringLen)
  8107. if intStringLen < 0 {
  8108. return ErrInvalidLengthTypes
  8109. }
  8110. postIndex := iNdEx + intStringLen
  8111. if postIndex < 0 {
  8112. return ErrInvalidLengthTypes
  8113. }
  8114. if postIndex > l {
  8115. return io.ErrUnexpectedEOF
  8116. }
  8117. m.Value = string(dAtA[iNdEx:postIndex])
  8118. iNdEx = postIndex
  8119. default:
  8120. iNdEx = preIndex
  8121. skippy, err := skipTypes(dAtA[iNdEx:])
  8122. if err != nil {
  8123. return err
  8124. }
  8125. if skippy < 0 {
  8126. return ErrInvalidLengthTypes
  8127. }
  8128. if (iNdEx + skippy) < 0 {
  8129. return ErrInvalidLengthTypes
  8130. }
  8131. if (iNdEx + skippy) > l {
  8132. return io.ErrUnexpectedEOF
  8133. }
  8134. iNdEx += skippy
  8135. }
  8136. }
  8137. if iNdEx > l {
  8138. return io.ErrUnexpectedEOF
  8139. }
  8140. return nil
  8141. }
  8142. func (m *RequestInitChain) Unmarshal(dAtA []byte) error {
  8143. l := len(dAtA)
  8144. iNdEx := 0
  8145. for iNdEx < l {
  8146. preIndex := iNdEx
  8147. var wire uint64
  8148. for shift := uint(0); ; shift += 7 {
  8149. if shift >= 64 {
  8150. return ErrIntOverflowTypes
  8151. }
  8152. if iNdEx >= l {
  8153. return io.ErrUnexpectedEOF
  8154. }
  8155. b := dAtA[iNdEx]
  8156. iNdEx++
  8157. wire |= uint64(b&0x7F) << shift
  8158. if b < 0x80 {
  8159. break
  8160. }
  8161. }
  8162. fieldNum := int32(wire >> 3)
  8163. wireType := int(wire & 0x7)
  8164. if wireType == 4 {
  8165. return fmt.Errorf("proto: RequestInitChain: wiretype end group for non-group")
  8166. }
  8167. if fieldNum <= 0 {
  8168. return fmt.Errorf("proto: RequestInitChain: illegal tag %d (wire type %d)", fieldNum, wire)
  8169. }
  8170. switch fieldNum {
  8171. case 1:
  8172. if wireType != 2 {
  8173. return fmt.Errorf("proto: wrong wireType = %d for field Time", wireType)
  8174. }
  8175. var msglen int
  8176. for shift := uint(0); ; shift += 7 {
  8177. if shift >= 64 {
  8178. return ErrIntOverflowTypes
  8179. }
  8180. if iNdEx >= l {
  8181. return io.ErrUnexpectedEOF
  8182. }
  8183. b := dAtA[iNdEx]
  8184. iNdEx++
  8185. msglen |= int(b&0x7F) << shift
  8186. if b < 0x80 {
  8187. break
  8188. }
  8189. }
  8190. if msglen < 0 {
  8191. return ErrInvalidLengthTypes
  8192. }
  8193. postIndex := iNdEx + msglen
  8194. if postIndex < 0 {
  8195. return ErrInvalidLengthTypes
  8196. }
  8197. if postIndex > l {
  8198. return io.ErrUnexpectedEOF
  8199. }
  8200. if err := github_com_gogo_protobuf_types.StdTimeUnmarshal(&m.Time, dAtA[iNdEx:postIndex]); err != nil {
  8201. return err
  8202. }
  8203. iNdEx = postIndex
  8204. case 2:
  8205. if wireType != 2 {
  8206. return fmt.Errorf("proto: wrong wireType = %d for field ChainId", wireType)
  8207. }
  8208. var stringLen uint64
  8209. for shift := uint(0); ; shift += 7 {
  8210. if shift >= 64 {
  8211. return ErrIntOverflowTypes
  8212. }
  8213. if iNdEx >= l {
  8214. return io.ErrUnexpectedEOF
  8215. }
  8216. b := dAtA[iNdEx]
  8217. iNdEx++
  8218. stringLen |= uint64(b&0x7F) << shift
  8219. if b < 0x80 {
  8220. break
  8221. }
  8222. }
  8223. intStringLen := int(stringLen)
  8224. if intStringLen < 0 {
  8225. return ErrInvalidLengthTypes
  8226. }
  8227. postIndex := iNdEx + intStringLen
  8228. if postIndex < 0 {
  8229. return ErrInvalidLengthTypes
  8230. }
  8231. if postIndex > l {
  8232. return io.ErrUnexpectedEOF
  8233. }
  8234. m.ChainId = string(dAtA[iNdEx:postIndex])
  8235. iNdEx = postIndex
  8236. case 3:
  8237. if wireType != 2 {
  8238. return fmt.Errorf("proto: wrong wireType = %d for field ConsensusParams", wireType)
  8239. }
  8240. var msglen int
  8241. for shift := uint(0); ; shift += 7 {
  8242. if shift >= 64 {
  8243. return ErrIntOverflowTypes
  8244. }
  8245. if iNdEx >= l {
  8246. return io.ErrUnexpectedEOF
  8247. }
  8248. b := dAtA[iNdEx]
  8249. iNdEx++
  8250. msglen |= int(b&0x7F) << shift
  8251. if b < 0x80 {
  8252. break
  8253. }
  8254. }
  8255. if msglen < 0 {
  8256. return ErrInvalidLengthTypes
  8257. }
  8258. postIndex := iNdEx + msglen
  8259. if postIndex < 0 {
  8260. return ErrInvalidLengthTypes
  8261. }
  8262. if postIndex > l {
  8263. return io.ErrUnexpectedEOF
  8264. }
  8265. if m.ConsensusParams == nil {
  8266. m.ConsensusParams = &ConsensusParams{}
  8267. }
  8268. if err := m.ConsensusParams.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  8269. return err
  8270. }
  8271. iNdEx = postIndex
  8272. case 4:
  8273. if wireType != 2 {
  8274. return fmt.Errorf("proto: wrong wireType = %d for field Validators", wireType)
  8275. }
  8276. var msglen int
  8277. for shift := uint(0); ; shift += 7 {
  8278. if shift >= 64 {
  8279. return ErrIntOverflowTypes
  8280. }
  8281. if iNdEx >= l {
  8282. return io.ErrUnexpectedEOF
  8283. }
  8284. b := dAtA[iNdEx]
  8285. iNdEx++
  8286. msglen |= int(b&0x7F) << shift
  8287. if b < 0x80 {
  8288. break
  8289. }
  8290. }
  8291. if msglen < 0 {
  8292. return ErrInvalidLengthTypes
  8293. }
  8294. postIndex := iNdEx + msglen
  8295. if postIndex < 0 {
  8296. return ErrInvalidLengthTypes
  8297. }
  8298. if postIndex > l {
  8299. return io.ErrUnexpectedEOF
  8300. }
  8301. m.Validators = append(m.Validators, ValidatorUpdate{})
  8302. if err := m.Validators[len(m.Validators)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  8303. return err
  8304. }
  8305. iNdEx = postIndex
  8306. case 5:
  8307. if wireType != 2 {
  8308. return fmt.Errorf("proto: wrong wireType = %d for field AppStateBytes", wireType)
  8309. }
  8310. var byteLen int
  8311. for shift := uint(0); ; shift += 7 {
  8312. if shift >= 64 {
  8313. return ErrIntOverflowTypes
  8314. }
  8315. if iNdEx >= l {
  8316. return io.ErrUnexpectedEOF
  8317. }
  8318. b := dAtA[iNdEx]
  8319. iNdEx++
  8320. byteLen |= int(b&0x7F) << shift
  8321. if b < 0x80 {
  8322. break
  8323. }
  8324. }
  8325. if byteLen < 0 {
  8326. return ErrInvalidLengthTypes
  8327. }
  8328. postIndex := iNdEx + byteLen
  8329. if postIndex < 0 {
  8330. return ErrInvalidLengthTypes
  8331. }
  8332. if postIndex > l {
  8333. return io.ErrUnexpectedEOF
  8334. }
  8335. m.AppStateBytes = append(m.AppStateBytes[:0], dAtA[iNdEx:postIndex]...)
  8336. if m.AppStateBytes == nil {
  8337. m.AppStateBytes = []byte{}
  8338. }
  8339. iNdEx = postIndex
  8340. case 6:
  8341. if wireType != 0 {
  8342. return fmt.Errorf("proto: wrong wireType = %d for field InitialHeight", wireType)
  8343. }
  8344. m.InitialHeight = 0
  8345. for shift := uint(0); ; shift += 7 {
  8346. if shift >= 64 {
  8347. return ErrIntOverflowTypes
  8348. }
  8349. if iNdEx >= l {
  8350. return io.ErrUnexpectedEOF
  8351. }
  8352. b := dAtA[iNdEx]
  8353. iNdEx++
  8354. m.InitialHeight |= int64(b&0x7F) << shift
  8355. if b < 0x80 {
  8356. break
  8357. }
  8358. }
  8359. default:
  8360. iNdEx = preIndex
  8361. skippy, err := skipTypes(dAtA[iNdEx:])
  8362. if err != nil {
  8363. return err
  8364. }
  8365. if skippy < 0 {
  8366. return ErrInvalidLengthTypes
  8367. }
  8368. if (iNdEx + skippy) < 0 {
  8369. return ErrInvalidLengthTypes
  8370. }
  8371. if (iNdEx + skippy) > l {
  8372. return io.ErrUnexpectedEOF
  8373. }
  8374. iNdEx += skippy
  8375. }
  8376. }
  8377. if iNdEx > l {
  8378. return io.ErrUnexpectedEOF
  8379. }
  8380. return nil
  8381. }
  8382. func (m *RequestQuery) Unmarshal(dAtA []byte) error {
  8383. l := len(dAtA)
  8384. iNdEx := 0
  8385. for iNdEx < l {
  8386. preIndex := iNdEx
  8387. var wire uint64
  8388. for shift := uint(0); ; shift += 7 {
  8389. if shift >= 64 {
  8390. return ErrIntOverflowTypes
  8391. }
  8392. if iNdEx >= l {
  8393. return io.ErrUnexpectedEOF
  8394. }
  8395. b := dAtA[iNdEx]
  8396. iNdEx++
  8397. wire |= uint64(b&0x7F) << shift
  8398. if b < 0x80 {
  8399. break
  8400. }
  8401. }
  8402. fieldNum := int32(wire >> 3)
  8403. wireType := int(wire & 0x7)
  8404. if wireType == 4 {
  8405. return fmt.Errorf("proto: RequestQuery: wiretype end group for non-group")
  8406. }
  8407. if fieldNum <= 0 {
  8408. return fmt.Errorf("proto: RequestQuery: illegal tag %d (wire type %d)", fieldNum, wire)
  8409. }
  8410. switch fieldNum {
  8411. case 1:
  8412. if wireType != 2 {
  8413. return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
  8414. }
  8415. var byteLen int
  8416. for shift := uint(0); ; shift += 7 {
  8417. if shift >= 64 {
  8418. return ErrIntOverflowTypes
  8419. }
  8420. if iNdEx >= l {
  8421. return io.ErrUnexpectedEOF
  8422. }
  8423. b := dAtA[iNdEx]
  8424. iNdEx++
  8425. byteLen |= int(b&0x7F) << shift
  8426. if b < 0x80 {
  8427. break
  8428. }
  8429. }
  8430. if byteLen < 0 {
  8431. return ErrInvalidLengthTypes
  8432. }
  8433. postIndex := iNdEx + byteLen
  8434. if postIndex < 0 {
  8435. return ErrInvalidLengthTypes
  8436. }
  8437. if postIndex > l {
  8438. return io.ErrUnexpectedEOF
  8439. }
  8440. m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
  8441. if m.Data == nil {
  8442. m.Data = []byte{}
  8443. }
  8444. iNdEx = postIndex
  8445. case 2:
  8446. if wireType != 2 {
  8447. return fmt.Errorf("proto: wrong wireType = %d for field Path", wireType)
  8448. }
  8449. var stringLen uint64
  8450. for shift := uint(0); ; shift += 7 {
  8451. if shift >= 64 {
  8452. return ErrIntOverflowTypes
  8453. }
  8454. if iNdEx >= l {
  8455. return io.ErrUnexpectedEOF
  8456. }
  8457. b := dAtA[iNdEx]
  8458. iNdEx++
  8459. stringLen |= uint64(b&0x7F) << shift
  8460. if b < 0x80 {
  8461. break
  8462. }
  8463. }
  8464. intStringLen := int(stringLen)
  8465. if intStringLen < 0 {
  8466. return ErrInvalidLengthTypes
  8467. }
  8468. postIndex := iNdEx + intStringLen
  8469. if postIndex < 0 {
  8470. return ErrInvalidLengthTypes
  8471. }
  8472. if postIndex > l {
  8473. return io.ErrUnexpectedEOF
  8474. }
  8475. m.Path = string(dAtA[iNdEx:postIndex])
  8476. iNdEx = postIndex
  8477. case 3:
  8478. if wireType != 0 {
  8479. return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType)
  8480. }
  8481. m.Height = 0
  8482. for shift := uint(0); ; shift += 7 {
  8483. if shift >= 64 {
  8484. return ErrIntOverflowTypes
  8485. }
  8486. if iNdEx >= l {
  8487. return io.ErrUnexpectedEOF
  8488. }
  8489. b := dAtA[iNdEx]
  8490. iNdEx++
  8491. m.Height |= int64(b&0x7F) << shift
  8492. if b < 0x80 {
  8493. break
  8494. }
  8495. }
  8496. case 4:
  8497. if wireType != 0 {
  8498. return fmt.Errorf("proto: wrong wireType = %d for field Prove", wireType)
  8499. }
  8500. var v int
  8501. for shift := uint(0); ; shift += 7 {
  8502. if shift >= 64 {
  8503. return ErrIntOverflowTypes
  8504. }
  8505. if iNdEx >= l {
  8506. return io.ErrUnexpectedEOF
  8507. }
  8508. b := dAtA[iNdEx]
  8509. iNdEx++
  8510. v |= int(b&0x7F) << shift
  8511. if b < 0x80 {
  8512. break
  8513. }
  8514. }
  8515. m.Prove = bool(v != 0)
  8516. default:
  8517. iNdEx = preIndex
  8518. skippy, err := skipTypes(dAtA[iNdEx:])
  8519. if err != nil {
  8520. return err
  8521. }
  8522. if skippy < 0 {
  8523. return ErrInvalidLengthTypes
  8524. }
  8525. if (iNdEx + skippy) < 0 {
  8526. return ErrInvalidLengthTypes
  8527. }
  8528. if (iNdEx + skippy) > l {
  8529. return io.ErrUnexpectedEOF
  8530. }
  8531. iNdEx += skippy
  8532. }
  8533. }
  8534. if iNdEx > l {
  8535. return io.ErrUnexpectedEOF
  8536. }
  8537. return nil
  8538. }
  8539. func (m *RequestBeginBlock) Unmarshal(dAtA []byte) error {
  8540. l := len(dAtA)
  8541. iNdEx := 0
  8542. for iNdEx < l {
  8543. preIndex := iNdEx
  8544. var wire uint64
  8545. for shift := uint(0); ; shift += 7 {
  8546. if shift >= 64 {
  8547. return ErrIntOverflowTypes
  8548. }
  8549. if iNdEx >= l {
  8550. return io.ErrUnexpectedEOF
  8551. }
  8552. b := dAtA[iNdEx]
  8553. iNdEx++
  8554. wire |= uint64(b&0x7F) << shift
  8555. if b < 0x80 {
  8556. break
  8557. }
  8558. }
  8559. fieldNum := int32(wire >> 3)
  8560. wireType := int(wire & 0x7)
  8561. if wireType == 4 {
  8562. return fmt.Errorf("proto: RequestBeginBlock: wiretype end group for non-group")
  8563. }
  8564. if fieldNum <= 0 {
  8565. return fmt.Errorf("proto: RequestBeginBlock: illegal tag %d (wire type %d)", fieldNum, wire)
  8566. }
  8567. switch fieldNum {
  8568. case 1:
  8569. if wireType != 2 {
  8570. return fmt.Errorf("proto: wrong wireType = %d for field Hash", wireType)
  8571. }
  8572. var byteLen int
  8573. for shift := uint(0); ; shift += 7 {
  8574. if shift >= 64 {
  8575. return ErrIntOverflowTypes
  8576. }
  8577. if iNdEx >= l {
  8578. return io.ErrUnexpectedEOF
  8579. }
  8580. b := dAtA[iNdEx]
  8581. iNdEx++
  8582. byteLen |= int(b&0x7F) << shift
  8583. if b < 0x80 {
  8584. break
  8585. }
  8586. }
  8587. if byteLen < 0 {
  8588. return ErrInvalidLengthTypes
  8589. }
  8590. postIndex := iNdEx + byteLen
  8591. if postIndex < 0 {
  8592. return ErrInvalidLengthTypes
  8593. }
  8594. if postIndex > l {
  8595. return io.ErrUnexpectedEOF
  8596. }
  8597. m.Hash = append(m.Hash[:0], dAtA[iNdEx:postIndex]...)
  8598. if m.Hash == nil {
  8599. m.Hash = []byte{}
  8600. }
  8601. iNdEx = postIndex
  8602. case 2:
  8603. if wireType != 2 {
  8604. return fmt.Errorf("proto: wrong wireType = %d for field Header", wireType)
  8605. }
  8606. var msglen int
  8607. for shift := uint(0); ; shift += 7 {
  8608. if shift >= 64 {
  8609. return ErrIntOverflowTypes
  8610. }
  8611. if iNdEx >= l {
  8612. return io.ErrUnexpectedEOF
  8613. }
  8614. b := dAtA[iNdEx]
  8615. iNdEx++
  8616. msglen |= int(b&0x7F) << shift
  8617. if b < 0x80 {
  8618. break
  8619. }
  8620. }
  8621. if msglen < 0 {
  8622. return ErrInvalidLengthTypes
  8623. }
  8624. postIndex := iNdEx + msglen
  8625. if postIndex < 0 {
  8626. return ErrInvalidLengthTypes
  8627. }
  8628. if postIndex > l {
  8629. return io.ErrUnexpectedEOF
  8630. }
  8631. if err := m.Header.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  8632. return err
  8633. }
  8634. iNdEx = postIndex
  8635. case 3:
  8636. if wireType != 2 {
  8637. return fmt.Errorf("proto: wrong wireType = %d for field LastCommitInfo", wireType)
  8638. }
  8639. var msglen int
  8640. for shift := uint(0); ; shift += 7 {
  8641. if shift >= 64 {
  8642. return ErrIntOverflowTypes
  8643. }
  8644. if iNdEx >= l {
  8645. return io.ErrUnexpectedEOF
  8646. }
  8647. b := dAtA[iNdEx]
  8648. iNdEx++
  8649. msglen |= int(b&0x7F) << shift
  8650. if b < 0x80 {
  8651. break
  8652. }
  8653. }
  8654. if msglen < 0 {
  8655. return ErrInvalidLengthTypes
  8656. }
  8657. postIndex := iNdEx + msglen
  8658. if postIndex < 0 {
  8659. return ErrInvalidLengthTypes
  8660. }
  8661. if postIndex > l {
  8662. return io.ErrUnexpectedEOF
  8663. }
  8664. if err := m.LastCommitInfo.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  8665. return err
  8666. }
  8667. iNdEx = postIndex
  8668. case 4:
  8669. if wireType != 2 {
  8670. return fmt.Errorf("proto: wrong wireType = %d for field ByzantineValidators", wireType)
  8671. }
  8672. var msglen int
  8673. for shift := uint(0); ; shift += 7 {
  8674. if shift >= 64 {
  8675. return ErrIntOverflowTypes
  8676. }
  8677. if iNdEx >= l {
  8678. return io.ErrUnexpectedEOF
  8679. }
  8680. b := dAtA[iNdEx]
  8681. iNdEx++
  8682. msglen |= int(b&0x7F) << shift
  8683. if b < 0x80 {
  8684. break
  8685. }
  8686. }
  8687. if msglen < 0 {
  8688. return ErrInvalidLengthTypes
  8689. }
  8690. postIndex := iNdEx + msglen
  8691. if postIndex < 0 {
  8692. return ErrInvalidLengthTypes
  8693. }
  8694. if postIndex > l {
  8695. return io.ErrUnexpectedEOF
  8696. }
  8697. m.ByzantineValidators = append(m.ByzantineValidators, Evidence{})
  8698. if err := m.ByzantineValidators[len(m.ByzantineValidators)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  8699. return err
  8700. }
  8701. iNdEx = postIndex
  8702. default:
  8703. iNdEx = preIndex
  8704. skippy, err := skipTypes(dAtA[iNdEx:])
  8705. if err != nil {
  8706. return err
  8707. }
  8708. if skippy < 0 {
  8709. return ErrInvalidLengthTypes
  8710. }
  8711. if (iNdEx + skippy) < 0 {
  8712. return ErrInvalidLengthTypes
  8713. }
  8714. if (iNdEx + skippy) > l {
  8715. return io.ErrUnexpectedEOF
  8716. }
  8717. iNdEx += skippy
  8718. }
  8719. }
  8720. if iNdEx > l {
  8721. return io.ErrUnexpectedEOF
  8722. }
  8723. return nil
  8724. }
  8725. func (m *RequestCheckTx) Unmarshal(dAtA []byte) error {
  8726. l := len(dAtA)
  8727. iNdEx := 0
  8728. for iNdEx < l {
  8729. preIndex := iNdEx
  8730. var wire uint64
  8731. for shift := uint(0); ; shift += 7 {
  8732. if shift >= 64 {
  8733. return ErrIntOverflowTypes
  8734. }
  8735. if iNdEx >= l {
  8736. return io.ErrUnexpectedEOF
  8737. }
  8738. b := dAtA[iNdEx]
  8739. iNdEx++
  8740. wire |= uint64(b&0x7F) << shift
  8741. if b < 0x80 {
  8742. break
  8743. }
  8744. }
  8745. fieldNum := int32(wire >> 3)
  8746. wireType := int(wire & 0x7)
  8747. if wireType == 4 {
  8748. return fmt.Errorf("proto: RequestCheckTx: wiretype end group for non-group")
  8749. }
  8750. if fieldNum <= 0 {
  8751. return fmt.Errorf("proto: RequestCheckTx: illegal tag %d (wire type %d)", fieldNum, wire)
  8752. }
  8753. switch fieldNum {
  8754. case 1:
  8755. if wireType != 2 {
  8756. return fmt.Errorf("proto: wrong wireType = %d for field Tx", wireType)
  8757. }
  8758. var byteLen int
  8759. for shift := uint(0); ; shift += 7 {
  8760. if shift >= 64 {
  8761. return ErrIntOverflowTypes
  8762. }
  8763. if iNdEx >= l {
  8764. return io.ErrUnexpectedEOF
  8765. }
  8766. b := dAtA[iNdEx]
  8767. iNdEx++
  8768. byteLen |= int(b&0x7F) << shift
  8769. if b < 0x80 {
  8770. break
  8771. }
  8772. }
  8773. if byteLen < 0 {
  8774. return ErrInvalidLengthTypes
  8775. }
  8776. postIndex := iNdEx + byteLen
  8777. if postIndex < 0 {
  8778. return ErrInvalidLengthTypes
  8779. }
  8780. if postIndex > l {
  8781. return io.ErrUnexpectedEOF
  8782. }
  8783. m.Tx = append(m.Tx[:0], dAtA[iNdEx:postIndex]...)
  8784. if m.Tx == nil {
  8785. m.Tx = []byte{}
  8786. }
  8787. iNdEx = postIndex
  8788. case 2:
  8789. if wireType != 0 {
  8790. return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
  8791. }
  8792. m.Type = 0
  8793. for shift := uint(0); ; shift += 7 {
  8794. if shift >= 64 {
  8795. return ErrIntOverflowTypes
  8796. }
  8797. if iNdEx >= l {
  8798. return io.ErrUnexpectedEOF
  8799. }
  8800. b := dAtA[iNdEx]
  8801. iNdEx++
  8802. m.Type |= CheckTxType(b&0x7F) << shift
  8803. if b < 0x80 {
  8804. break
  8805. }
  8806. }
  8807. default:
  8808. iNdEx = preIndex
  8809. skippy, err := skipTypes(dAtA[iNdEx:])
  8810. if err != nil {
  8811. return err
  8812. }
  8813. if skippy < 0 {
  8814. return ErrInvalidLengthTypes
  8815. }
  8816. if (iNdEx + skippy) < 0 {
  8817. return ErrInvalidLengthTypes
  8818. }
  8819. if (iNdEx + skippy) > l {
  8820. return io.ErrUnexpectedEOF
  8821. }
  8822. iNdEx += skippy
  8823. }
  8824. }
  8825. if iNdEx > l {
  8826. return io.ErrUnexpectedEOF
  8827. }
  8828. return nil
  8829. }
  8830. func (m *RequestDeliverTx) Unmarshal(dAtA []byte) error {
  8831. l := len(dAtA)
  8832. iNdEx := 0
  8833. for iNdEx < l {
  8834. preIndex := iNdEx
  8835. var wire uint64
  8836. for shift := uint(0); ; shift += 7 {
  8837. if shift >= 64 {
  8838. return ErrIntOverflowTypes
  8839. }
  8840. if iNdEx >= l {
  8841. return io.ErrUnexpectedEOF
  8842. }
  8843. b := dAtA[iNdEx]
  8844. iNdEx++
  8845. wire |= uint64(b&0x7F) << shift
  8846. if b < 0x80 {
  8847. break
  8848. }
  8849. }
  8850. fieldNum := int32(wire >> 3)
  8851. wireType := int(wire & 0x7)
  8852. if wireType == 4 {
  8853. return fmt.Errorf("proto: RequestDeliverTx: wiretype end group for non-group")
  8854. }
  8855. if fieldNum <= 0 {
  8856. return fmt.Errorf("proto: RequestDeliverTx: illegal tag %d (wire type %d)", fieldNum, wire)
  8857. }
  8858. switch fieldNum {
  8859. case 1:
  8860. if wireType != 2 {
  8861. return fmt.Errorf("proto: wrong wireType = %d for field Tx", wireType)
  8862. }
  8863. var byteLen int
  8864. for shift := uint(0); ; shift += 7 {
  8865. if shift >= 64 {
  8866. return ErrIntOverflowTypes
  8867. }
  8868. if iNdEx >= l {
  8869. return io.ErrUnexpectedEOF
  8870. }
  8871. b := dAtA[iNdEx]
  8872. iNdEx++
  8873. byteLen |= int(b&0x7F) << shift
  8874. if b < 0x80 {
  8875. break
  8876. }
  8877. }
  8878. if byteLen < 0 {
  8879. return ErrInvalidLengthTypes
  8880. }
  8881. postIndex := iNdEx + byteLen
  8882. if postIndex < 0 {
  8883. return ErrInvalidLengthTypes
  8884. }
  8885. if postIndex > l {
  8886. return io.ErrUnexpectedEOF
  8887. }
  8888. m.Tx = append(m.Tx[:0], dAtA[iNdEx:postIndex]...)
  8889. if m.Tx == nil {
  8890. m.Tx = []byte{}
  8891. }
  8892. iNdEx = postIndex
  8893. default:
  8894. iNdEx = preIndex
  8895. skippy, err := skipTypes(dAtA[iNdEx:])
  8896. if err != nil {
  8897. return err
  8898. }
  8899. if skippy < 0 {
  8900. return ErrInvalidLengthTypes
  8901. }
  8902. if (iNdEx + skippy) < 0 {
  8903. return ErrInvalidLengthTypes
  8904. }
  8905. if (iNdEx + skippy) > l {
  8906. return io.ErrUnexpectedEOF
  8907. }
  8908. iNdEx += skippy
  8909. }
  8910. }
  8911. if iNdEx > l {
  8912. return io.ErrUnexpectedEOF
  8913. }
  8914. return nil
  8915. }
  8916. func (m *RequestEndBlock) Unmarshal(dAtA []byte) error {
  8917. l := len(dAtA)
  8918. iNdEx := 0
  8919. for iNdEx < l {
  8920. preIndex := iNdEx
  8921. var wire uint64
  8922. for shift := uint(0); ; shift += 7 {
  8923. if shift >= 64 {
  8924. return ErrIntOverflowTypes
  8925. }
  8926. if iNdEx >= l {
  8927. return io.ErrUnexpectedEOF
  8928. }
  8929. b := dAtA[iNdEx]
  8930. iNdEx++
  8931. wire |= uint64(b&0x7F) << shift
  8932. if b < 0x80 {
  8933. break
  8934. }
  8935. }
  8936. fieldNum := int32(wire >> 3)
  8937. wireType := int(wire & 0x7)
  8938. if wireType == 4 {
  8939. return fmt.Errorf("proto: RequestEndBlock: wiretype end group for non-group")
  8940. }
  8941. if fieldNum <= 0 {
  8942. return fmt.Errorf("proto: RequestEndBlock: illegal tag %d (wire type %d)", fieldNum, wire)
  8943. }
  8944. switch fieldNum {
  8945. case 1:
  8946. if wireType != 0 {
  8947. return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType)
  8948. }
  8949. m.Height = 0
  8950. for shift := uint(0); ; shift += 7 {
  8951. if shift >= 64 {
  8952. return ErrIntOverflowTypes
  8953. }
  8954. if iNdEx >= l {
  8955. return io.ErrUnexpectedEOF
  8956. }
  8957. b := dAtA[iNdEx]
  8958. iNdEx++
  8959. m.Height |= int64(b&0x7F) << shift
  8960. if b < 0x80 {
  8961. break
  8962. }
  8963. }
  8964. default:
  8965. iNdEx = preIndex
  8966. skippy, err := skipTypes(dAtA[iNdEx:])
  8967. if err != nil {
  8968. return err
  8969. }
  8970. if skippy < 0 {
  8971. return ErrInvalidLengthTypes
  8972. }
  8973. if (iNdEx + skippy) < 0 {
  8974. return ErrInvalidLengthTypes
  8975. }
  8976. if (iNdEx + skippy) > l {
  8977. return io.ErrUnexpectedEOF
  8978. }
  8979. iNdEx += skippy
  8980. }
  8981. }
  8982. if iNdEx > l {
  8983. return io.ErrUnexpectedEOF
  8984. }
  8985. return nil
  8986. }
  8987. func (m *RequestCommit) Unmarshal(dAtA []byte) error {
  8988. l := len(dAtA)
  8989. iNdEx := 0
  8990. for iNdEx < l {
  8991. preIndex := iNdEx
  8992. var wire uint64
  8993. for shift := uint(0); ; shift += 7 {
  8994. if shift >= 64 {
  8995. return ErrIntOverflowTypes
  8996. }
  8997. if iNdEx >= l {
  8998. return io.ErrUnexpectedEOF
  8999. }
  9000. b := dAtA[iNdEx]
  9001. iNdEx++
  9002. wire |= uint64(b&0x7F) << shift
  9003. if b < 0x80 {
  9004. break
  9005. }
  9006. }
  9007. fieldNum := int32(wire >> 3)
  9008. wireType := int(wire & 0x7)
  9009. if wireType == 4 {
  9010. return fmt.Errorf("proto: RequestCommit: wiretype end group for non-group")
  9011. }
  9012. if fieldNum <= 0 {
  9013. return fmt.Errorf("proto: RequestCommit: illegal tag %d (wire type %d)", fieldNum, wire)
  9014. }
  9015. switch fieldNum {
  9016. default:
  9017. iNdEx = preIndex
  9018. skippy, err := skipTypes(dAtA[iNdEx:])
  9019. if err != nil {
  9020. return err
  9021. }
  9022. if skippy < 0 {
  9023. return ErrInvalidLengthTypes
  9024. }
  9025. if (iNdEx + skippy) < 0 {
  9026. return ErrInvalidLengthTypes
  9027. }
  9028. if (iNdEx + skippy) > l {
  9029. return io.ErrUnexpectedEOF
  9030. }
  9031. iNdEx += skippy
  9032. }
  9033. }
  9034. if iNdEx > l {
  9035. return io.ErrUnexpectedEOF
  9036. }
  9037. return nil
  9038. }
  9039. func (m *RequestListSnapshots) Unmarshal(dAtA []byte) error {
  9040. l := len(dAtA)
  9041. iNdEx := 0
  9042. for iNdEx < l {
  9043. preIndex := iNdEx
  9044. var wire uint64
  9045. for shift := uint(0); ; shift += 7 {
  9046. if shift >= 64 {
  9047. return ErrIntOverflowTypes
  9048. }
  9049. if iNdEx >= l {
  9050. return io.ErrUnexpectedEOF
  9051. }
  9052. b := dAtA[iNdEx]
  9053. iNdEx++
  9054. wire |= uint64(b&0x7F) << shift
  9055. if b < 0x80 {
  9056. break
  9057. }
  9058. }
  9059. fieldNum := int32(wire >> 3)
  9060. wireType := int(wire & 0x7)
  9061. if wireType == 4 {
  9062. return fmt.Errorf("proto: RequestListSnapshots: wiretype end group for non-group")
  9063. }
  9064. if fieldNum <= 0 {
  9065. return fmt.Errorf("proto: RequestListSnapshots: illegal tag %d (wire type %d)", fieldNum, wire)
  9066. }
  9067. switch fieldNum {
  9068. default:
  9069. iNdEx = preIndex
  9070. skippy, err := skipTypes(dAtA[iNdEx:])
  9071. if err != nil {
  9072. return err
  9073. }
  9074. if skippy < 0 {
  9075. return ErrInvalidLengthTypes
  9076. }
  9077. if (iNdEx + skippy) < 0 {
  9078. return ErrInvalidLengthTypes
  9079. }
  9080. if (iNdEx + skippy) > l {
  9081. return io.ErrUnexpectedEOF
  9082. }
  9083. iNdEx += skippy
  9084. }
  9085. }
  9086. if iNdEx > l {
  9087. return io.ErrUnexpectedEOF
  9088. }
  9089. return nil
  9090. }
  9091. func (m *RequestOfferSnapshot) Unmarshal(dAtA []byte) error {
  9092. l := len(dAtA)
  9093. iNdEx := 0
  9094. for iNdEx < l {
  9095. preIndex := iNdEx
  9096. var wire uint64
  9097. for shift := uint(0); ; shift += 7 {
  9098. if shift >= 64 {
  9099. return ErrIntOverflowTypes
  9100. }
  9101. if iNdEx >= l {
  9102. return io.ErrUnexpectedEOF
  9103. }
  9104. b := dAtA[iNdEx]
  9105. iNdEx++
  9106. wire |= uint64(b&0x7F) << shift
  9107. if b < 0x80 {
  9108. break
  9109. }
  9110. }
  9111. fieldNum := int32(wire >> 3)
  9112. wireType := int(wire & 0x7)
  9113. if wireType == 4 {
  9114. return fmt.Errorf("proto: RequestOfferSnapshot: wiretype end group for non-group")
  9115. }
  9116. if fieldNum <= 0 {
  9117. return fmt.Errorf("proto: RequestOfferSnapshot: illegal tag %d (wire type %d)", fieldNum, wire)
  9118. }
  9119. switch fieldNum {
  9120. case 1:
  9121. if wireType != 2 {
  9122. return fmt.Errorf("proto: wrong wireType = %d for field Snapshot", wireType)
  9123. }
  9124. var msglen int
  9125. for shift := uint(0); ; shift += 7 {
  9126. if shift >= 64 {
  9127. return ErrIntOverflowTypes
  9128. }
  9129. if iNdEx >= l {
  9130. return io.ErrUnexpectedEOF
  9131. }
  9132. b := dAtA[iNdEx]
  9133. iNdEx++
  9134. msglen |= int(b&0x7F) << shift
  9135. if b < 0x80 {
  9136. break
  9137. }
  9138. }
  9139. if msglen < 0 {
  9140. return ErrInvalidLengthTypes
  9141. }
  9142. postIndex := iNdEx + msglen
  9143. if postIndex < 0 {
  9144. return ErrInvalidLengthTypes
  9145. }
  9146. if postIndex > l {
  9147. return io.ErrUnexpectedEOF
  9148. }
  9149. if m.Snapshot == nil {
  9150. m.Snapshot = &Snapshot{}
  9151. }
  9152. if err := m.Snapshot.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9153. return err
  9154. }
  9155. iNdEx = postIndex
  9156. case 2:
  9157. if wireType != 2 {
  9158. return fmt.Errorf("proto: wrong wireType = %d for field AppHash", wireType)
  9159. }
  9160. var byteLen int
  9161. for shift := uint(0); ; shift += 7 {
  9162. if shift >= 64 {
  9163. return ErrIntOverflowTypes
  9164. }
  9165. if iNdEx >= l {
  9166. return io.ErrUnexpectedEOF
  9167. }
  9168. b := dAtA[iNdEx]
  9169. iNdEx++
  9170. byteLen |= int(b&0x7F) << shift
  9171. if b < 0x80 {
  9172. break
  9173. }
  9174. }
  9175. if byteLen < 0 {
  9176. return ErrInvalidLengthTypes
  9177. }
  9178. postIndex := iNdEx + byteLen
  9179. if postIndex < 0 {
  9180. return ErrInvalidLengthTypes
  9181. }
  9182. if postIndex > l {
  9183. return io.ErrUnexpectedEOF
  9184. }
  9185. m.AppHash = append(m.AppHash[:0], dAtA[iNdEx:postIndex]...)
  9186. if m.AppHash == nil {
  9187. m.AppHash = []byte{}
  9188. }
  9189. iNdEx = postIndex
  9190. default:
  9191. iNdEx = preIndex
  9192. skippy, err := skipTypes(dAtA[iNdEx:])
  9193. if err != nil {
  9194. return err
  9195. }
  9196. if skippy < 0 {
  9197. return ErrInvalidLengthTypes
  9198. }
  9199. if (iNdEx + skippy) < 0 {
  9200. return ErrInvalidLengthTypes
  9201. }
  9202. if (iNdEx + skippy) > l {
  9203. return io.ErrUnexpectedEOF
  9204. }
  9205. iNdEx += skippy
  9206. }
  9207. }
  9208. if iNdEx > l {
  9209. return io.ErrUnexpectedEOF
  9210. }
  9211. return nil
  9212. }
  9213. func (m *RequestLoadSnapshotChunk) Unmarshal(dAtA []byte) error {
  9214. l := len(dAtA)
  9215. iNdEx := 0
  9216. for iNdEx < l {
  9217. preIndex := iNdEx
  9218. var wire uint64
  9219. for shift := uint(0); ; shift += 7 {
  9220. if shift >= 64 {
  9221. return ErrIntOverflowTypes
  9222. }
  9223. if iNdEx >= l {
  9224. return io.ErrUnexpectedEOF
  9225. }
  9226. b := dAtA[iNdEx]
  9227. iNdEx++
  9228. wire |= uint64(b&0x7F) << shift
  9229. if b < 0x80 {
  9230. break
  9231. }
  9232. }
  9233. fieldNum := int32(wire >> 3)
  9234. wireType := int(wire & 0x7)
  9235. if wireType == 4 {
  9236. return fmt.Errorf("proto: RequestLoadSnapshotChunk: wiretype end group for non-group")
  9237. }
  9238. if fieldNum <= 0 {
  9239. return fmt.Errorf("proto: RequestLoadSnapshotChunk: illegal tag %d (wire type %d)", fieldNum, wire)
  9240. }
  9241. switch fieldNum {
  9242. case 1:
  9243. if wireType != 0 {
  9244. return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType)
  9245. }
  9246. m.Height = 0
  9247. for shift := uint(0); ; shift += 7 {
  9248. if shift >= 64 {
  9249. return ErrIntOverflowTypes
  9250. }
  9251. if iNdEx >= l {
  9252. return io.ErrUnexpectedEOF
  9253. }
  9254. b := dAtA[iNdEx]
  9255. iNdEx++
  9256. m.Height |= uint64(b&0x7F) << shift
  9257. if b < 0x80 {
  9258. break
  9259. }
  9260. }
  9261. case 2:
  9262. if wireType != 0 {
  9263. return fmt.Errorf("proto: wrong wireType = %d for field Format", wireType)
  9264. }
  9265. m.Format = 0
  9266. for shift := uint(0); ; shift += 7 {
  9267. if shift >= 64 {
  9268. return ErrIntOverflowTypes
  9269. }
  9270. if iNdEx >= l {
  9271. return io.ErrUnexpectedEOF
  9272. }
  9273. b := dAtA[iNdEx]
  9274. iNdEx++
  9275. m.Format |= uint32(b&0x7F) << shift
  9276. if b < 0x80 {
  9277. break
  9278. }
  9279. }
  9280. case 3:
  9281. if wireType != 0 {
  9282. return fmt.Errorf("proto: wrong wireType = %d for field Chunk", wireType)
  9283. }
  9284. m.Chunk = 0
  9285. for shift := uint(0); ; shift += 7 {
  9286. if shift >= 64 {
  9287. return ErrIntOverflowTypes
  9288. }
  9289. if iNdEx >= l {
  9290. return io.ErrUnexpectedEOF
  9291. }
  9292. b := dAtA[iNdEx]
  9293. iNdEx++
  9294. m.Chunk |= uint32(b&0x7F) << shift
  9295. if b < 0x80 {
  9296. break
  9297. }
  9298. }
  9299. default:
  9300. iNdEx = preIndex
  9301. skippy, err := skipTypes(dAtA[iNdEx:])
  9302. if err != nil {
  9303. return err
  9304. }
  9305. if skippy < 0 {
  9306. return ErrInvalidLengthTypes
  9307. }
  9308. if (iNdEx + skippy) < 0 {
  9309. return ErrInvalidLengthTypes
  9310. }
  9311. if (iNdEx + skippy) > l {
  9312. return io.ErrUnexpectedEOF
  9313. }
  9314. iNdEx += skippy
  9315. }
  9316. }
  9317. if iNdEx > l {
  9318. return io.ErrUnexpectedEOF
  9319. }
  9320. return nil
  9321. }
  9322. func (m *RequestApplySnapshotChunk) Unmarshal(dAtA []byte) error {
  9323. l := len(dAtA)
  9324. iNdEx := 0
  9325. for iNdEx < l {
  9326. preIndex := iNdEx
  9327. var wire uint64
  9328. for shift := uint(0); ; shift += 7 {
  9329. if shift >= 64 {
  9330. return ErrIntOverflowTypes
  9331. }
  9332. if iNdEx >= l {
  9333. return io.ErrUnexpectedEOF
  9334. }
  9335. b := dAtA[iNdEx]
  9336. iNdEx++
  9337. wire |= uint64(b&0x7F) << shift
  9338. if b < 0x80 {
  9339. break
  9340. }
  9341. }
  9342. fieldNum := int32(wire >> 3)
  9343. wireType := int(wire & 0x7)
  9344. if wireType == 4 {
  9345. return fmt.Errorf("proto: RequestApplySnapshotChunk: wiretype end group for non-group")
  9346. }
  9347. if fieldNum <= 0 {
  9348. return fmt.Errorf("proto: RequestApplySnapshotChunk: illegal tag %d (wire type %d)", fieldNum, wire)
  9349. }
  9350. switch fieldNum {
  9351. case 1:
  9352. if wireType != 0 {
  9353. return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType)
  9354. }
  9355. m.Index = 0
  9356. for shift := uint(0); ; shift += 7 {
  9357. if shift >= 64 {
  9358. return ErrIntOverflowTypes
  9359. }
  9360. if iNdEx >= l {
  9361. return io.ErrUnexpectedEOF
  9362. }
  9363. b := dAtA[iNdEx]
  9364. iNdEx++
  9365. m.Index |= uint32(b&0x7F) << shift
  9366. if b < 0x80 {
  9367. break
  9368. }
  9369. }
  9370. case 2:
  9371. if wireType != 2 {
  9372. return fmt.Errorf("proto: wrong wireType = %d for field Chunk", wireType)
  9373. }
  9374. var byteLen int
  9375. for shift := uint(0); ; shift += 7 {
  9376. if shift >= 64 {
  9377. return ErrIntOverflowTypes
  9378. }
  9379. if iNdEx >= l {
  9380. return io.ErrUnexpectedEOF
  9381. }
  9382. b := dAtA[iNdEx]
  9383. iNdEx++
  9384. byteLen |= int(b&0x7F) << shift
  9385. if b < 0x80 {
  9386. break
  9387. }
  9388. }
  9389. if byteLen < 0 {
  9390. return ErrInvalidLengthTypes
  9391. }
  9392. postIndex := iNdEx + byteLen
  9393. if postIndex < 0 {
  9394. return ErrInvalidLengthTypes
  9395. }
  9396. if postIndex > l {
  9397. return io.ErrUnexpectedEOF
  9398. }
  9399. m.Chunk = append(m.Chunk[:0], dAtA[iNdEx:postIndex]...)
  9400. if m.Chunk == nil {
  9401. m.Chunk = []byte{}
  9402. }
  9403. iNdEx = postIndex
  9404. case 3:
  9405. if wireType != 2 {
  9406. return fmt.Errorf("proto: wrong wireType = %d for field Sender", wireType)
  9407. }
  9408. var stringLen uint64
  9409. for shift := uint(0); ; shift += 7 {
  9410. if shift >= 64 {
  9411. return ErrIntOverflowTypes
  9412. }
  9413. if iNdEx >= l {
  9414. return io.ErrUnexpectedEOF
  9415. }
  9416. b := dAtA[iNdEx]
  9417. iNdEx++
  9418. stringLen |= uint64(b&0x7F) << shift
  9419. if b < 0x80 {
  9420. break
  9421. }
  9422. }
  9423. intStringLen := int(stringLen)
  9424. if intStringLen < 0 {
  9425. return ErrInvalidLengthTypes
  9426. }
  9427. postIndex := iNdEx + intStringLen
  9428. if postIndex < 0 {
  9429. return ErrInvalidLengthTypes
  9430. }
  9431. if postIndex > l {
  9432. return io.ErrUnexpectedEOF
  9433. }
  9434. m.Sender = string(dAtA[iNdEx:postIndex])
  9435. iNdEx = postIndex
  9436. default:
  9437. iNdEx = preIndex
  9438. skippy, err := skipTypes(dAtA[iNdEx:])
  9439. if err != nil {
  9440. return err
  9441. }
  9442. if skippy < 0 {
  9443. return ErrInvalidLengthTypes
  9444. }
  9445. if (iNdEx + skippy) < 0 {
  9446. return ErrInvalidLengthTypes
  9447. }
  9448. if (iNdEx + skippy) > l {
  9449. return io.ErrUnexpectedEOF
  9450. }
  9451. iNdEx += skippy
  9452. }
  9453. }
  9454. if iNdEx > l {
  9455. return io.ErrUnexpectedEOF
  9456. }
  9457. return nil
  9458. }
  9459. func (m *Response) Unmarshal(dAtA []byte) error {
  9460. l := len(dAtA)
  9461. iNdEx := 0
  9462. for iNdEx < l {
  9463. preIndex := iNdEx
  9464. var wire uint64
  9465. for shift := uint(0); ; shift += 7 {
  9466. if shift >= 64 {
  9467. return ErrIntOverflowTypes
  9468. }
  9469. if iNdEx >= l {
  9470. return io.ErrUnexpectedEOF
  9471. }
  9472. b := dAtA[iNdEx]
  9473. iNdEx++
  9474. wire |= uint64(b&0x7F) << shift
  9475. if b < 0x80 {
  9476. break
  9477. }
  9478. }
  9479. fieldNum := int32(wire >> 3)
  9480. wireType := int(wire & 0x7)
  9481. if wireType == 4 {
  9482. return fmt.Errorf("proto: Response: wiretype end group for non-group")
  9483. }
  9484. if fieldNum <= 0 {
  9485. return fmt.Errorf("proto: Response: illegal tag %d (wire type %d)", fieldNum, wire)
  9486. }
  9487. switch fieldNum {
  9488. case 1:
  9489. if wireType != 2 {
  9490. return fmt.Errorf("proto: wrong wireType = %d for field Exception", wireType)
  9491. }
  9492. var msglen int
  9493. for shift := uint(0); ; shift += 7 {
  9494. if shift >= 64 {
  9495. return ErrIntOverflowTypes
  9496. }
  9497. if iNdEx >= l {
  9498. return io.ErrUnexpectedEOF
  9499. }
  9500. b := dAtA[iNdEx]
  9501. iNdEx++
  9502. msglen |= int(b&0x7F) << shift
  9503. if b < 0x80 {
  9504. break
  9505. }
  9506. }
  9507. if msglen < 0 {
  9508. return ErrInvalidLengthTypes
  9509. }
  9510. postIndex := iNdEx + msglen
  9511. if postIndex < 0 {
  9512. return ErrInvalidLengthTypes
  9513. }
  9514. if postIndex > l {
  9515. return io.ErrUnexpectedEOF
  9516. }
  9517. v := &ResponseException{}
  9518. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9519. return err
  9520. }
  9521. m.Value = &Response_Exception{v}
  9522. iNdEx = postIndex
  9523. case 2:
  9524. if wireType != 2 {
  9525. return fmt.Errorf("proto: wrong wireType = %d for field Echo", wireType)
  9526. }
  9527. var msglen int
  9528. for shift := uint(0); ; shift += 7 {
  9529. if shift >= 64 {
  9530. return ErrIntOverflowTypes
  9531. }
  9532. if iNdEx >= l {
  9533. return io.ErrUnexpectedEOF
  9534. }
  9535. b := dAtA[iNdEx]
  9536. iNdEx++
  9537. msglen |= int(b&0x7F) << shift
  9538. if b < 0x80 {
  9539. break
  9540. }
  9541. }
  9542. if msglen < 0 {
  9543. return ErrInvalidLengthTypes
  9544. }
  9545. postIndex := iNdEx + msglen
  9546. if postIndex < 0 {
  9547. return ErrInvalidLengthTypes
  9548. }
  9549. if postIndex > l {
  9550. return io.ErrUnexpectedEOF
  9551. }
  9552. v := &ResponseEcho{}
  9553. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9554. return err
  9555. }
  9556. m.Value = &Response_Echo{v}
  9557. iNdEx = postIndex
  9558. case 3:
  9559. if wireType != 2 {
  9560. return fmt.Errorf("proto: wrong wireType = %d for field Flush", wireType)
  9561. }
  9562. var msglen int
  9563. for shift := uint(0); ; shift += 7 {
  9564. if shift >= 64 {
  9565. return ErrIntOverflowTypes
  9566. }
  9567. if iNdEx >= l {
  9568. return io.ErrUnexpectedEOF
  9569. }
  9570. b := dAtA[iNdEx]
  9571. iNdEx++
  9572. msglen |= int(b&0x7F) << shift
  9573. if b < 0x80 {
  9574. break
  9575. }
  9576. }
  9577. if msglen < 0 {
  9578. return ErrInvalidLengthTypes
  9579. }
  9580. postIndex := iNdEx + msglen
  9581. if postIndex < 0 {
  9582. return ErrInvalidLengthTypes
  9583. }
  9584. if postIndex > l {
  9585. return io.ErrUnexpectedEOF
  9586. }
  9587. v := &ResponseFlush{}
  9588. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9589. return err
  9590. }
  9591. m.Value = &Response_Flush{v}
  9592. iNdEx = postIndex
  9593. case 4:
  9594. if wireType != 2 {
  9595. return fmt.Errorf("proto: wrong wireType = %d for field Info", wireType)
  9596. }
  9597. var msglen int
  9598. for shift := uint(0); ; shift += 7 {
  9599. if shift >= 64 {
  9600. return ErrIntOverflowTypes
  9601. }
  9602. if iNdEx >= l {
  9603. return io.ErrUnexpectedEOF
  9604. }
  9605. b := dAtA[iNdEx]
  9606. iNdEx++
  9607. msglen |= int(b&0x7F) << shift
  9608. if b < 0x80 {
  9609. break
  9610. }
  9611. }
  9612. if msglen < 0 {
  9613. return ErrInvalidLengthTypes
  9614. }
  9615. postIndex := iNdEx + msglen
  9616. if postIndex < 0 {
  9617. return ErrInvalidLengthTypes
  9618. }
  9619. if postIndex > l {
  9620. return io.ErrUnexpectedEOF
  9621. }
  9622. v := &ResponseInfo{}
  9623. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9624. return err
  9625. }
  9626. m.Value = &Response_Info{v}
  9627. iNdEx = postIndex
  9628. case 5:
  9629. if wireType != 2 {
  9630. return fmt.Errorf("proto: wrong wireType = %d for field SetOption", wireType)
  9631. }
  9632. var msglen int
  9633. for shift := uint(0); ; shift += 7 {
  9634. if shift >= 64 {
  9635. return ErrIntOverflowTypes
  9636. }
  9637. if iNdEx >= l {
  9638. return io.ErrUnexpectedEOF
  9639. }
  9640. b := dAtA[iNdEx]
  9641. iNdEx++
  9642. msglen |= int(b&0x7F) << shift
  9643. if b < 0x80 {
  9644. break
  9645. }
  9646. }
  9647. if msglen < 0 {
  9648. return ErrInvalidLengthTypes
  9649. }
  9650. postIndex := iNdEx + msglen
  9651. if postIndex < 0 {
  9652. return ErrInvalidLengthTypes
  9653. }
  9654. if postIndex > l {
  9655. return io.ErrUnexpectedEOF
  9656. }
  9657. v := &ResponseSetOption{}
  9658. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9659. return err
  9660. }
  9661. m.Value = &Response_SetOption{v}
  9662. iNdEx = postIndex
  9663. case 6:
  9664. if wireType != 2 {
  9665. return fmt.Errorf("proto: wrong wireType = %d for field InitChain", wireType)
  9666. }
  9667. var msglen int
  9668. for shift := uint(0); ; shift += 7 {
  9669. if shift >= 64 {
  9670. return ErrIntOverflowTypes
  9671. }
  9672. if iNdEx >= l {
  9673. return io.ErrUnexpectedEOF
  9674. }
  9675. b := dAtA[iNdEx]
  9676. iNdEx++
  9677. msglen |= int(b&0x7F) << shift
  9678. if b < 0x80 {
  9679. break
  9680. }
  9681. }
  9682. if msglen < 0 {
  9683. return ErrInvalidLengthTypes
  9684. }
  9685. postIndex := iNdEx + msglen
  9686. if postIndex < 0 {
  9687. return ErrInvalidLengthTypes
  9688. }
  9689. if postIndex > l {
  9690. return io.ErrUnexpectedEOF
  9691. }
  9692. v := &ResponseInitChain{}
  9693. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9694. return err
  9695. }
  9696. m.Value = &Response_InitChain{v}
  9697. iNdEx = postIndex
  9698. case 7:
  9699. if wireType != 2 {
  9700. return fmt.Errorf("proto: wrong wireType = %d for field Query", wireType)
  9701. }
  9702. var msglen int
  9703. for shift := uint(0); ; shift += 7 {
  9704. if shift >= 64 {
  9705. return ErrIntOverflowTypes
  9706. }
  9707. if iNdEx >= l {
  9708. return io.ErrUnexpectedEOF
  9709. }
  9710. b := dAtA[iNdEx]
  9711. iNdEx++
  9712. msglen |= int(b&0x7F) << shift
  9713. if b < 0x80 {
  9714. break
  9715. }
  9716. }
  9717. if msglen < 0 {
  9718. return ErrInvalidLengthTypes
  9719. }
  9720. postIndex := iNdEx + msglen
  9721. if postIndex < 0 {
  9722. return ErrInvalidLengthTypes
  9723. }
  9724. if postIndex > l {
  9725. return io.ErrUnexpectedEOF
  9726. }
  9727. v := &ResponseQuery{}
  9728. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9729. return err
  9730. }
  9731. m.Value = &Response_Query{v}
  9732. iNdEx = postIndex
  9733. case 8:
  9734. if wireType != 2 {
  9735. return fmt.Errorf("proto: wrong wireType = %d for field BeginBlock", wireType)
  9736. }
  9737. var msglen int
  9738. for shift := uint(0); ; shift += 7 {
  9739. if shift >= 64 {
  9740. return ErrIntOverflowTypes
  9741. }
  9742. if iNdEx >= l {
  9743. return io.ErrUnexpectedEOF
  9744. }
  9745. b := dAtA[iNdEx]
  9746. iNdEx++
  9747. msglen |= int(b&0x7F) << shift
  9748. if b < 0x80 {
  9749. break
  9750. }
  9751. }
  9752. if msglen < 0 {
  9753. return ErrInvalidLengthTypes
  9754. }
  9755. postIndex := iNdEx + msglen
  9756. if postIndex < 0 {
  9757. return ErrInvalidLengthTypes
  9758. }
  9759. if postIndex > l {
  9760. return io.ErrUnexpectedEOF
  9761. }
  9762. v := &ResponseBeginBlock{}
  9763. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9764. return err
  9765. }
  9766. m.Value = &Response_BeginBlock{v}
  9767. iNdEx = postIndex
  9768. case 9:
  9769. if wireType != 2 {
  9770. return fmt.Errorf("proto: wrong wireType = %d for field CheckTx", wireType)
  9771. }
  9772. var msglen int
  9773. for shift := uint(0); ; shift += 7 {
  9774. if shift >= 64 {
  9775. return ErrIntOverflowTypes
  9776. }
  9777. if iNdEx >= l {
  9778. return io.ErrUnexpectedEOF
  9779. }
  9780. b := dAtA[iNdEx]
  9781. iNdEx++
  9782. msglen |= int(b&0x7F) << shift
  9783. if b < 0x80 {
  9784. break
  9785. }
  9786. }
  9787. if msglen < 0 {
  9788. return ErrInvalidLengthTypes
  9789. }
  9790. postIndex := iNdEx + msglen
  9791. if postIndex < 0 {
  9792. return ErrInvalidLengthTypes
  9793. }
  9794. if postIndex > l {
  9795. return io.ErrUnexpectedEOF
  9796. }
  9797. v := &ResponseCheckTx{}
  9798. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9799. return err
  9800. }
  9801. m.Value = &Response_CheckTx{v}
  9802. iNdEx = postIndex
  9803. case 10:
  9804. if wireType != 2 {
  9805. return fmt.Errorf("proto: wrong wireType = %d for field DeliverTx", wireType)
  9806. }
  9807. var msglen int
  9808. for shift := uint(0); ; shift += 7 {
  9809. if shift >= 64 {
  9810. return ErrIntOverflowTypes
  9811. }
  9812. if iNdEx >= l {
  9813. return io.ErrUnexpectedEOF
  9814. }
  9815. b := dAtA[iNdEx]
  9816. iNdEx++
  9817. msglen |= int(b&0x7F) << shift
  9818. if b < 0x80 {
  9819. break
  9820. }
  9821. }
  9822. if msglen < 0 {
  9823. return ErrInvalidLengthTypes
  9824. }
  9825. postIndex := iNdEx + msglen
  9826. if postIndex < 0 {
  9827. return ErrInvalidLengthTypes
  9828. }
  9829. if postIndex > l {
  9830. return io.ErrUnexpectedEOF
  9831. }
  9832. v := &ResponseDeliverTx{}
  9833. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9834. return err
  9835. }
  9836. m.Value = &Response_DeliverTx{v}
  9837. iNdEx = postIndex
  9838. case 11:
  9839. if wireType != 2 {
  9840. return fmt.Errorf("proto: wrong wireType = %d for field EndBlock", wireType)
  9841. }
  9842. var msglen int
  9843. for shift := uint(0); ; shift += 7 {
  9844. if shift >= 64 {
  9845. return ErrIntOverflowTypes
  9846. }
  9847. if iNdEx >= l {
  9848. return io.ErrUnexpectedEOF
  9849. }
  9850. b := dAtA[iNdEx]
  9851. iNdEx++
  9852. msglen |= int(b&0x7F) << shift
  9853. if b < 0x80 {
  9854. break
  9855. }
  9856. }
  9857. if msglen < 0 {
  9858. return ErrInvalidLengthTypes
  9859. }
  9860. postIndex := iNdEx + msglen
  9861. if postIndex < 0 {
  9862. return ErrInvalidLengthTypes
  9863. }
  9864. if postIndex > l {
  9865. return io.ErrUnexpectedEOF
  9866. }
  9867. v := &ResponseEndBlock{}
  9868. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9869. return err
  9870. }
  9871. m.Value = &Response_EndBlock{v}
  9872. iNdEx = postIndex
  9873. case 12:
  9874. if wireType != 2 {
  9875. return fmt.Errorf("proto: wrong wireType = %d for field Commit", wireType)
  9876. }
  9877. var msglen int
  9878. for shift := uint(0); ; shift += 7 {
  9879. if shift >= 64 {
  9880. return ErrIntOverflowTypes
  9881. }
  9882. if iNdEx >= l {
  9883. return io.ErrUnexpectedEOF
  9884. }
  9885. b := dAtA[iNdEx]
  9886. iNdEx++
  9887. msglen |= int(b&0x7F) << shift
  9888. if b < 0x80 {
  9889. break
  9890. }
  9891. }
  9892. if msglen < 0 {
  9893. return ErrInvalidLengthTypes
  9894. }
  9895. postIndex := iNdEx + msglen
  9896. if postIndex < 0 {
  9897. return ErrInvalidLengthTypes
  9898. }
  9899. if postIndex > l {
  9900. return io.ErrUnexpectedEOF
  9901. }
  9902. v := &ResponseCommit{}
  9903. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9904. return err
  9905. }
  9906. m.Value = &Response_Commit{v}
  9907. iNdEx = postIndex
  9908. case 13:
  9909. if wireType != 2 {
  9910. return fmt.Errorf("proto: wrong wireType = %d for field ListSnapshots", wireType)
  9911. }
  9912. var msglen int
  9913. for shift := uint(0); ; shift += 7 {
  9914. if shift >= 64 {
  9915. return ErrIntOverflowTypes
  9916. }
  9917. if iNdEx >= l {
  9918. return io.ErrUnexpectedEOF
  9919. }
  9920. b := dAtA[iNdEx]
  9921. iNdEx++
  9922. msglen |= int(b&0x7F) << shift
  9923. if b < 0x80 {
  9924. break
  9925. }
  9926. }
  9927. if msglen < 0 {
  9928. return ErrInvalidLengthTypes
  9929. }
  9930. postIndex := iNdEx + msglen
  9931. if postIndex < 0 {
  9932. return ErrInvalidLengthTypes
  9933. }
  9934. if postIndex > l {
  9935. return io.ErrUnexpectedEOF
  9936. }
  9937. v := &ResponseListSnapshots{}
  9938. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9939. return err
  9940. }
  9941. m.Value = &Response_ListSnapshots{v}
  9942. iNdEx = postIndex
  9943. case 14:
  9944. if wireType != 2 {
  9945. return fmt.Errorf("proto: wrong wireType = %d for field OfferSnapshot", wireType)
  9946. }
  9947. var msglen int
  9948. for shift := uint(0); ; shift += 7 {
  9949. if shift >= 64 {
  9950. return ErrIntOverflowTypes
  9951. }
  9952. if iNdEx >= l {
  9953. return io.ErrUnexpectedEOF
  9954. }
  9955. b := dAtA[iNdEx]
  9956. iNdEx++
  9957. msglen |= int(b&0x7F) << shift
  9958. if b < 0x80 {
  9959. break
  9960. }
  9961. }
  9962. if msglen < 0 {
  9963. return ErrInvalidLengthTypes
  9964. }
  9965. postIndex := iNdEx + msglen
  9966. if postIndex < 0 {
  9967. return ErrInvalidLengthTypes
  9968. }
  9969. if postIndex > l {
  9970. return io.ErrUnexpectedEOF
  9971. }
  9972. v := &ResponseOfferSnapshot{}
  9973. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  9974. return err
  9975. }
  9976. m.Value = &Response_OfferSnapshot{v}
  9977. iNdEx = postIndex
  9978. case 15:
  9979. if wireType != 2 {
  9980. return fmt.Errorf("proto: wrong wireType = %d for field LoadSnapshotChunk", wireType)
  9981. }
  9982. var msglen int
  9983. for shift := uint(0); ; shift += 7 {
  9984. if shift >= 64 {
  9985. return ErrIntOverflowTypes
  9986. }
  9987. if iNdEx >= l {
  9988. return io.ErrUnexpectedEOF
  9989. }
  9990. b := dAtA[iNdEx]
  9991. iNdEx++
  9992. msglen |= int(b&0x7F) << shift
  9993. if b < 0x80 {
  9994. break
  9995. }
  9996. }
  9997. if msglen < 0 {
  9998. return ErrInvalidLengthTypes
  9999. }
  10000. postIndex := iNdEx + msglen
  10001. if postIndex < 0 {
  10002. return ErrInvalidLengthTypes
  10003. }
  10004. if postIndex > l {
  10005. return io.ErrUnexpectedEOF
  10006. }
  10007. v := &ResponseLoadSnapshotChunk{}
  10008. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  10009. return err
  10010. }
  10011. m.Value = &Response_LoadSnapshotChunk{v}
  10012. iNdEx = postIndex
  10013. case 16:
  10014. if wireType != 2 {
  10015. return fmt.Errorf("proto: wrong wireType = %d for field ApplySnapshotChunk", wireType)
  10016. }
  10017. var msglen int
  10018. for shift := uint(0); ; shift += 7 {
  10019. if shift >= 64 {
  10020. return ErrIntOverflowTypes
  10021. }
  10022. if iNdEx >= l {
  10023. return io.ErrUnexpectedEOF
  10024. }
  10025. b := dAtA[iNdEx]
  10026. iNdEx++
  10027. msglen |= int(b&0x7F) << shift
  10028. if b < 0x80 {
  10029. break
  10030. }
  10031. }
  10032. if msglen < 0 {
  10033. return ErrInvalidLengthTypes
  10034. }
  10035. postIndex := iNdEx + msglen
  10036. if postIndex < 0 {
  10037. return ErrInvalidLengthTypes
  10038. }
  10039. if postIndex > l {
  10040. return io.ErrUnexpectedEOF
  10041. }
  10042. v := &ResponseApplySnapshotChunk{}
  10043. if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  10044. return err
  10045. }
  10046. m.Value = &Response_ApplySnapshotChunk{v}
  10047. iNdEx = postIndex
  10048. default:
  10049. iNdEx = preIndex
  10050. skippy, err := skipTypes(dAtA[iNdEx:])
  10051. if err != nil {
  10052. return err
  10053. }
  10054. if skippy < 0 {
  10055. return ErrInvalidLengthTypes
  10056. }
  10057. if (iNdEx + skippy) < 0 {
  10058. return ErrInvalidLengthTypes
  10059. }
  10060. if (iNdEx + skippy) > l {
  10061. return io.ErrUnexpectedEOF
  10062. }
  10063. iNdEx += skippy
  10064. }
  10065. }
  10066. if iNdEx > l {
  10067. return io.ErrUnexpectedEOF
  10068. }
  10069. return nil
  10070. }
  10071. func (m *ResponseException) Unmarshal(dAtA []byte) error {
  10072. l := len(dAtA)
  10073. iNdEx := 0
  10074. for iNdEx < l {
  10075. preIndex := iNdEx
  10076. var wire uint64
  10077. for shift := uint(0); ; shift += 7 {
  10078. if shift >= 64 {
  10079. return ErrIntOverflowTypes
  10080. }
  10081. if iNdEx >= l {
  10082. return io.ErrUnexpectedEOF
  10083. }
  10084. b := dAtA[iNdEx]
  10085. iNdEx++
  10086. wire |= uint64(b&0x7F) << shift
  10087. if b < 0x80 {
  10088. break
  10089. }
  10090. }
  10091. fieldNum := int32(wire >> 3)
  10092. wireType := int(wire & 0x7)
  10093. if wireType == 4 {
  10094. return fmt.Errorf("proto: ResponseException: wiretype end group for non-group")
  10095. }
  10096. if fieldNum <= 0 {
  10097. return fmt.Errorf("proto: ResponseException: illegal tag %d (wire type %d)", fieldNum, wire)
  10098. }
  10099. switch fieldNum {
  10100. case 1:
  10101. if wireType != 2 {
  10102. return fmt.Errorf("proto: wrong wireType = %d for field Error", wireType)
  10103. }
  10104. var stringLen uint64
  10105. for shift := uint(0); ; shift += 7 {
  10106. if shift >= 64 {
  10107. return ErrIntOverflowTypes
  10108. }
  10109. if iNdEx >= l {
  10110. return io.ErrUnexpectedEOF
  10111. }
  10112. b := dAtA[iNdEx]
  10113. iNdEx++
  10114. stringLen |= uint64(b&0x7F) << shift
  10115. if b < 0x80 {
  10116. break
  10117. }
  10118. }
  10119. intStringLen := int(stringLen)
  10120. if intStringLen < 0 {
  10121. return ErrInvalidLengthTypes
  10122. }
  10123. postIndex := iNdEx + intStringLen
  10124. if postIndex < 0 {
  10125. return ErrInvalidLengthTypes
  10126. }
  10127. if postIndex > l {
  10128. return io.ErrUnexpectedEOF
  10129. }
  10130. m.Error = string(dAtA[iNdEx:postIndex])
  10131. iNdEx = postIndex
  10132. default:
  10133. iNdEx = preIndex
  10134. skippy, err := skipTypes(dAtA[iNdEx:])
  10135. if err != nil {
  10136. return err
  10137. }
  10138. if skippy < 0 {
  10139. return ErrInvalidLengthTypes
  10140. }
  10141. if (iNdEx + skippy) < 0 {
  10142. return ErrInvalidLengthTypes
  10143. }
  10144. if (iNdEx + skippy) > l {
  10145. return io.ErrUnexpectedEOF
  10146. }
  10147. iNdEx += skippy
  10148. }
  10149. }
  10150. if iNdEx > l {
  10151. return io.ErrUnexpectedEOF
  10152. }
  10153. return nil
  10154. }
  10155. func (m *ResponseEcho) Unmarshal(dAtA []byte) error {
  10156. l := len(dAtA)
  10157. iNdEx := 0
  10158. for iNdEx < l {
  10159. preIndex := iNdEx
  10160. var wire uint64
  10161. for shift := uint(0); ; shift += 7 {
  10162. if shift >= 64 {
  10163. return ErrIntOverflowTypes
  10164. }
  10165. if iNdEx >= l {
  10166. return io.ErrUnexpectedEOF
  10167. }
  10168. b := dAtA[iNdEx]
  10169. iNdEx++
  10170. wire |= uint64(b&0x7F) << shift
  10171. if b < 0x80 {
  10172. break
  10173. }
  10174. }
  10175. fieldNum := int32(wire >> 3)
  10176. wireType := int(wire & 0x7)
  10177. if wireType == 4 {
  10178. return fmt.Errorf("proto: ResponseEcho: wiretype end group for non-group")
  10179. }
  10180. if fieldNum <= 0 {
  10181. return fmt.Errorf("proto: ResponseEcho: illegal tag %d (wire type %d)", fieldNum, wire)
  10182. }
  10183. switch fieldNum {
  10184. case 1:
  10185. if wireType != 2 {
  10186. return fmt.Errorf("proto: wrong wireType = %d for field Message", wireType)
  10187. }
  10188. var stringLen uint64
  10189. for shift := uint(0); ; shift += 7 {
  10190. if shift >= 64 {
  10191. return ErrIntOverflowTypes
  10192. }
  10193. if iNdEx >= l {
  10194. return io.ErrUnexpectedEOF
  10195. }
  10196. b := dAtA[iNdEx]
  10197. iNdEx++
  10198. stringLen |= uint64(b&0x7F) << shift
  10199. if b < 0x80 {
  10200. break
  10201. }
  10202. }
  10203. intStringLen := int(stringLen)
  10204. if intStringLen < 0 {
  10205. return ErrInvalidLengthTypes
  10206. }
  10207. postIndex := iNdEx + intStringLen
  10208. if postIndex < 0 {
  10209. return ErrInvalidLengthTypes
  10210. }
  10211. if postIndex > l {
  10212. return io.ErrUnexpectedEOF
  10213. }
  10214. m.Message = string(dAtA[iNdEx:postIndex])
  10215. iNdEx = postIndex
  10216. default:
  10217. iNdEx = preIndex
  10218. skippy, err := skipTypes(dAtA[iNdEx:])
  10219. if err != nil {
  10220. return err
  10221. }
  10222. if skippy < 0 {
  10223. return ErrInvalidLengthTypes
  10224. }
  10225. if (iNdEx + skippy) < 0 {
  10226. return ErrInvalidLengthTypes
  10227. }
  10228. if (iNdEx + skippy) > l {
  10229. return io.ErrUnexpectedEOF
  10230. }
  10231. iNdEx += skippy
  10232. }
  10233. }
  10234. if iNdEx > l {
  10235. return io.ErrUnexpectedEOF
  10236. }
  10237. return nil
  10238. }
  10239. func (m *ResponseFlush) Unmarshal(dAtA []byte) error {
  10240. l := len(dAtA)
  10241. iNdEx := 0
  10242. for iNdEx < l {
  10243. preIndex := iNdEx
  10244. var wire uint64
  10245. for shift := uint(0); ; shift += 7 {
  10246. if shift >= 64 {
  10247. return ErrIntOverflowTypes
  10248. }
  10249. if iNdEx >= l {
  10250. return io.ErrUnexpectedEOF
  10251. }
  10252. b := dAtA[iNdEx]
  10253. iNdEx++
  10254. wire |= uint64(b&0x7F) << shift
  10255. if b < 0x80 {
  10256. break
  10257. }
  10258. }
  10259. fieldNum := int32(wire >> 3)
  10260. wireType := int(wire & 0x7)
  10261. if wireType == 4 {
  10262. return fmt.Errorf("proto: ResponseFlush: wiretype end group for non-group")
  10263. }
  10264. if fieldNum <= 0 {
  10265. return fmt.Errorf("proto: ResponseFlush: illegal tag %d (wire type %d)", fieldNum, wire)
  10266. }
  10267. switch fieldNum {
  10268. default:
  10269. iNdEx = preIndex
  10270. skippy, err := skipTypes(dAtA[iNdEx:])
  10271. if err != nil {
  10272. return err
  10273. }
  10274. if skippy < 0 {
  10275. return ErrInvalidLengthTypes
  10276. }
  10277. if (iNdEx + skippy) < 0 {
  10278. return ErrInvalidLengthTypes
  10279. }
  10280. if (iNdEx + skippy) > l {
  10281. return io.ErrUnexpectedEOF
  10282. }
  10283. iNdEx += skippy
  10284. }
  10285. }
  10286. if iNdEx > l {
  10287. return io.ErrUnexpectedEOF
  10288. }
  10289. return nil
  10290. }
  10291. func (m *ResponseInfo) Unmarshal(dAtA []byte) error {
  10292. l := len(dAtA)
  10293. iNdEx := 0
  10294. for iNdEx < l {
  10295. preIndex := iNdEx
  10296. var wire uint64
  10297. for shift := uint(0); ; shift += 7 {
  10298. if shift >= 64 {
  10299. return ErrIntOverflowTypes
  10300. }
  10301. if iNdEx >= l {
  10302. return io.ErrUnexpectedEOF
  10303. }
  10304. b := dAtA[iNdEx]
  10305. iNdEx++
  10306. wire |= uint64(b&0x7F) << shift
  10307. if b < 0x80 {
  10308. break
  10309. }
  10310. }
  10311. fieldNum := int32(wire >> 3)
  10312. wireType := int(wire & 0x7)
  10313. if wireType == 4 {
  10314. return fmt.Errorf("proto: ResponseInfo: wiretype end group for non-group")
  10315. }
  10316. if fieldNum <= 0 {
  10317. return fmt.Errorf("proto: ResponseInfo: illegal tag %d (wire type %d)", fieldNum, wire)
  10318. }
  10319. switch fieldNum {
  10320. case 1:
  10321. if wireType != 2 {
  10322. return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
  10323. }
  10324. var stringLen uint64
  10325. for shift := uint(0); ; shift += 7 {
  10326. if shift >= 64 {
  10327. return ErrIntOverflowTypes
  10328. }
  10329. if iNdEx >= l {
  10330. return io.ErrUnexpectedEOF
  10331. }
  10332. b := dAtA[iNdEx]
  10333. iNdEx++
  10334. stringLen |= uint64(b&0x7F) << shift
  10335. if b < 0x80 {
  10336. break
  10337. }
  10338. }
  10339. intStringLen := int(stringLen)
  10340. if intStringLen < 0 {
  10341. return ErrInvalidLengthTypes
  10342. }
  10343. postIndex := iNdEx + intStringLen
  10344. if postIndex < 0 {
  10345. return ErrInvalidLengthTypes
  10346. }
  10347. if postIndex > l {
  10348. return io.ErrUnexpectedEOF
  10349. }
  10350. m.Data = string(dAtA[iNdEx:postIndex])
  10351. iNdEx = postIndex
  10352. case 2:
  10353. if wireType != 2 {
  10354. return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType)
  10355. }
  10356. var stringLen uint64
  10357. for shift := uint(0); ; shift += 7 {
  10358. if shift >= 64 {
  10359. return ErrIntOverflowTypes
  10360. }
  10361. if iNdEx >= l {
  10362. return io.ErrUnexpectedEOF
  10363. }
  10364. b := dAtA[iNdEx]
  10365. iNdEx++
  10366. stringLen |= uint64(b&0x7F) << shift
  10367. if b < 0x80 {
  10368. break
  10369. }
  10370. }
  10371. intStringLen := int(stringLen)
  10372. if intStringLen < 0 {
  10373. return ErrInvalidLengthTypes
  10374. }
  10375. postIndex := iNdEx + intStringLen
  10376. if postIndex < 0 {
  10377. return ErrInvalidLengthTypes
  10378. }
  10379. if postIndex > l {
  10380. return io.ErrUnexpectedEOF
  10381. }
  10382. m.Version = string(dAtA[iNdEx:postIndex])
  10383. iNdEx = postIndex
  10384. case 3:
  10385. if wireType != 0 {
  10386. return fmt.Errorf("proto: wrong wireType = %d for field AppVersion", wireType)
  10387. }
  10388. m.AppVersion = 0
  10389. for shift := uint(0); ; shift += 7 {
  10390. if shift >= 64 {
  10391. return ErrIntOverflowTypes
  10392. }
  10393. if iNdEx >= l {
  10394. return io.ErrUnexpectedEOF
  10395. }
  10396. b := dAtA[iNdEx]
  10397. iNdEx++
  10398. m.AppVersion |= uint64(b&0x7F) << shift
  10399. if b < 0x80 {
  10400. break
  10401. }
  10402. }
  10403. case 4:
  10404. if wireType != 0 {
  10405. return fmt.Errorf("proto: wrong wireType = %d for field LastBlockHeight", wireType)
  10406. }
  10407. m.LastBlockHeight = 0
  10408. for shift := uint(0); ; shift += 7 {
  10409. if shift >= 64 {
  10410. return ErrIntOverflowTypes
  10411. }
  10412. if iNdEx >= l {
  10413. return io.ErrUnexpectedEOF
  10414. }
  10415. b := dAtA[iNdEx]
  10416. iNdEx++
  10417. m.LastBlockHeight |= int64(b&0x7F) << shift
  10418. if b < 0x80 {
  10419. break
  10420. }
  10421. }
  10422. case 5:
  10423. if wireType != 2 {
  10424. return fmt.Errorf("proto: wrong wireType = %d for field LastBlockAppHash", wireType)
  10425. }
  10426. var byteLen int
  10427. for shift := uint(0); ; shift += 7 {
  10428. if shift >= 64 {
  10429. return ErrIntOverflowTypes
  10430. }
  10431. if iNdEx >= l {
  10432. return io.ErrUnexpectedEOF
  10433. }
  10434. b := dAtA[iNdEx]
  10435. iNdEx++
  10436. byteLen |= int(b&0x7F) << shift
  10437. if b < 0x80 {
  10438. break
  10439. }
  10440. }
  10441. if byteLen < 0 {
  10442. return ErrInvalidLengthTypes
  10443. }
  10444. postIndex := iNdEx + byteLen
  10445. if postIndex < 0 {
  10446. return ErrInvalidLengthTypes
  10447. }
  10448. if postIndex > l {
  10449. return io.ErrUnexpectedEOF
  10450. }
  10451. m.LastBlockAppHash = append(m.LastBlockAppHash[:0], dAtA[iNdEx:postIndex]...)
  10452. if m.LastBlockAppHash == nil {
  10453. m.LastBlockAppHash = []byte{}
  10454. }
  10455. iNdEx = postIndex
  10456. default:
  10457. iNdEx = preIndex
  10458. skippy, err := skipTypes(dAtA[iNdEx:])
  10459. if err != nil {
  10460. return err
  10461. }
  10462. if skippy < 0 {
  10463. return ErrInvalidLengthTypes
  10464. }
  10465. if (iNdEx + skippy) < 0 {
  10466. return ErrInvalidLengthTypes
  10467. }
  10468. if (iNdEx + skippy) > l {
  10469. return io.ErrUnexpectedEOF
  10470. }
  10471. iNdEx += skippy
  10472. }
  10473. }
  10474. if iNdEx > l {
  10475. return io.ErrUnexpectedEOF
  10476. }
  10477. return nil
  10478. }
  10479. func (m *ResponseSetOption) Unmarshal(dAtA []byte) error {
  10480. l := len(dAtA)
  10481. iNdEx := 0
  10482. for iNdEx < l {
  10483. preIndex := iNdEx
  10484. var wire uint64
  10485. for shift := uint(0); ; shift += 7 {
  10486. if shift >= 64 {
  10487. return ErrIntOverflowTypes
  10488. }
  10489. if iNdEx >= l {
  10490. return io.ErrUnexpectedEOF
  10491. }
  10492. b := dAtA[iNdEx]
  10493. iNdEx++
  10494. wire |= uint64(b&0x7F) << shift
  10495. if b < 0x80 {
  10496. break
  10497. }
  10498. }
  10499. fieldNum := int32(wire >> 3)
  10500. wireType := int(wire & 0x7)
  10501. if wireType == 4 {
  10502. return fmt.Errorf("proto: ResponseSetOption: wiretype end group for non-group")
  10503. }
  10504. if fieldNum <= 0 {
  10505. return fmt.Errorf("proto: ResponseSetOption: illegal tag %d (wire type %d)", fieldNum, wire)
  10506. }
  10507. switch fieldNum {
  10508. case 1:
  10509. if wireType != 0 {
  10510. return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType)
  10511. }
  10512. m.Code = 0
  10513. for shift := uint(0); ; shift += 7 {
  10514. if shift >= 64 {
  10515. return ErrIntOverflowTypes
  10516. }
  10517. if iNdEx >= l {
  10518. return io.ErrUnexpectedEOF
  10519. }
  10520. b := dAtA[iNdEx]
  10521. iNdEx++
  10522. m.Code |= uint32(b&0x7F) << shift
  10523. if b < 0x80 {
  10524. break
  10525. }
  10526. }
  10527. case 3:
  10528. if wireType != 2 {
  10529. return fmt.Errorf("proto: wrong wireType = %d for field Log", wireType)
  10530. }
  10531. var stringLen uint64
  10532. for shift := uint(0); ; shift += 7 {
  10533. if shift >= 64 {
  10534. return ErrIntOverflowTypes
  10535. }
  10536. if iNdEx >= l {
  10537. return io.ErrUnexpectedEOF
  10538. }
  10539. b := dAtA[iNdEx]
  10540. iNdEx++
  10541. stringLen |= uint64(b&0x7F) << shift
  10542. if b < 0x80 {
  10543. break
  10544. }
  10545. }
  10546. intStringLen := int(stringLen)
  10547. if intStringLen < 0 {
  10548. return ErrInvalidLengthTypes
  10549. }
  10550. postIndex := iNdEx + intStringLen
  10551. if postIndex < 0 {
  10552. return ErrInvalidLengthTypes
  10553. }
  10554. if postIndex > l {
  10555. return io.ErrUnexpectedEOF
  10556. }
  10557. m.Log = string(dAtA[iNdEx:postIndex])
  10558. iNdEx = postIndex
  10559. case 4:
  10560. if wireType != 2 {
  10561. return fmt.Errorf("proto: wrong wireType = %d for field Info", wireType)
  10562. }
  10563. var stringLen uint64
  10564. for shift := uint(0); ; shift += 7 {
  10565. if shift >= 64 {
  10566. return ErrIntOverflowTypes
  10567. }
  10568. if iNdEx >= l {
  10569. return io.ErrUnexpectedEOF
  10570. }
  10571. b := dAtA[iNdEx]
  10572. iNdEx++
  10573. stringLen |= uint64(b&0x7F) << shift
  10574. if b < 0x80 {
  10575. break
  10576. }
  10577. }
  10578. intStringLen := int(stringLen)
  10579. if intStringLen < 0 {
  10580. return ErrInvalidLengthTypes
  10581. }
  10582. postIndex := iNdEx + intStringLen
  10583. if postIndex < 0 {
  10584. return ErrInvalidLengthTypes
  10585. }
  10586. if postIndex > l {
  10587. return io.ErrUnexpectedEOF
  10588. }
  10589. m.Info = string(dAtA[iNdEx:postIndex])
  10590. iNdEx = postIndex
  10591. default:
  10592. iNdEx = preIndex
  10593. skippy, err := skipTypes(dAtA[iNdEx:])
  10594. if err != nil {
  10595. return err
  10596. }
  10597. if skippy < 0 {
  10598. return ErrInvalidLengthTypes
  10599. }
  10600. if (iNdEx + skippy) < 0 {
  10601. return ErrInvalidLengthTypes
  10602. }
  10603. if (iNdEx + skippy) > l {
  10604. return io.ErrUnexpectedEOF
  10605. }
  10606. iNdEx += skippy
  10607. }
  10608. }
  10609. if iNdEx > l {
  10610. return io.ErrUnexpectedEOF
  10611. }
  10612. return nil
  10613. }
  10614. func (m *ResponseInitChain) Unmarshal(dAtA []byte) error {
  10615. l := len(dAtA)
  10616. iNdEx := 0
  10617. for iNdEx < l {
  10618. preIndex := iNdEx
  10619. var wire uint64
  10620. for shift := uint(0); ; shift += 7 {
  10621. if shift >= 64 {
  10622. return ErrIntOverflowTypes
  10623. }
  10624. if iNdEx >= l {
  10625. return io.ErrUnexpectedEOF
  10626. }
  10627. b := dAtA[iNdEx]
  10628. iNdEx++
  10629. wire |= uint64(b&0x7F) << shift
  10630. if b < 0x80 {
  10631. break
  10632. }
  10633. }
  10634. fieldNum := int32(wire >> 3)
  10635. wireType := int(wire & 0x7)
  10636. if wireType == 4 {
  10637. return fmt.Errorf("proto: ResponseInitChain: wiretype end group for non-group")
  10638. }
  10639. if fieldNum <= 0 {
  10640. return fmt.Errorf("proto: ResponseInitChain: illegal tag %d (wire type %d)", fieldNum, wire)
  10641. }
  10642. switch fieldNum {
  10643. case 1:
  10644. if wireType != 2 {
  10645. return fmt.Errorf("proto: wrong wireType = %d for field ConsensusParams", wireType)
  10646. }
  10647. var msglen int
  10648. for shift := uint(0); ; shift += 7 {
  10649. if shift >= 64 {
  10650. return ErrIntOverflowTypes
  10651. }
  10652. if iNdEx >= l {
  10653. return io.ErrUnexpectedEOF
  10654. }
  10655. b := dAtA[iNdEx]
  10656. iNdEx++
  10657. msglen |= int(b&0x7F) << shift
  10658. if b < 0x80 {
  10659. break
  10660. }
  10661. }
  10662. if msglen < 0 {
  10663. return ErrInvalidLengthTypes
  10664. }
  10665. postIndex := iNdEx + msglen
  10666. if postIndex < 0 {
  10667. return ErrInvalidLengthTypes
  10668. }
  10669. if postIndex > l {
  10670. return io.ErrUnexpectedEOF
  10671. }
  10672. if m.ConsensusParams == nil {
  10673. m.ConsensusParams = &ConsensusParams{}
  10674. }
  10675. if err := m.ConsensusParams.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  10676. return err
  10677. }
  10678. iNdEx = postIndex
  10679. case 2:
  10680. if wireType != 2 {
  10681. return fmt.Errorf("proto: wrong wireType = %d for field Validators", wireType)
  10682. }
  10683. var msglen int
  10684. for shift := uint(0); ; shift += 7 {
  10685. if shift >= 64 {
  10686. return ErrIntOverflowTypes
  10687. }
  10688. if iNdEx >= l {
  10689. return io.ErrUnexpectedEOF
  10690. }
  10691. b := dAtA[iNdEx]
  10692. iNdEx++
  10693. msglen |= int(b&0x7F) << shift
  10694. if b < 0x80 {
  10695. break
  10696. }
  10697. }
  10698. if msglen < 0 {
  10699. return ErrInvalidLengthTypes
  10700. }
  10701. postIndex := iNdEx + msglen
  10702. if postIndex < 0 {
  10703. return ErrInvalidLengthTypes
  10704. }
  10705. if postIndex > l {
  10706. return io.ErrUnexpectedEOF
  10707. }
  10708. m.Validators = append(m.Validators, ValidatorUpdate{})
  10709. if err := m.Validators[len(m.Validators)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  10710. return err
  10711. }
  10712. iNdEx = postIndex
  10713. case 3:
  10714. if wireType != 2 {
  10715. return fmt.Errorf("proto: wrong wireType = %d for field AppHash", wireType)
  10716. }
  10717. var byteLen int
  10718. for shift := uint(0); ; shift += 7 {
  10719. if shift >= 64 {
  10720. return ErrIntOverflowTypes
  10721. }
  10722. if iNdEx >= l {
  10723. return io.ErrUnexpectedEOF
  10724. }
  10725. b := dAtA[iNdEx]
  10726. iNdEx++
  10727. byteLen |= int(b&0x7F) << shift
  10728. if b < 0x80 {
  10729. break
  10730. }
  10731. }
  10732. if byteLen < 0 {
  10733. return ErrInvalidLengthTypes
  10734. }
  10735. postIndex := iNdEx + byteLen
  10736. if postIndex < 0 {
  10737. return ErrInvalidLengthTypes
  10738. }
  10739. if postIndex > l {
  10740. return io.ErrUnexpectedEOF
  10741. }
  10742. m.AppHash = append(m.AppHash[:0], dAtA[iNdEx:postIndex]...)
  10743. if m.AppHash == nil {
  10744. m.AppHash = []byte{}
  10745. }
  10746. iNdEx = postIndex
  10747. default:
  10748. iNdEx = preIndex
  10749. skippy, err := skipTypes(dAtA[iNdEx:])
  10750. if err != nil {
  10751. return err
  10752. }
  10753. if skippy < 0 {
  10754. return ErrInvalidLengthTypes
  10755. }
  10756. if (iNdEx + skippy) < 0 {
  10757. return ErrInvalidLengthTypes
  10758. }
  10759. if (iNdEx + skippy) > l {
  10760. return io.ErrUnexpectedEOF
  10761. }
  10762. iNdEx += skippy
  10763. }
  10764. }
  10765. if iNdEx > l {
  10766. return io.ErrUnexpectedEOF
  10767. }
  10768. return nil
  10769. }
  10770. func (m *ResponseQuery) Unmarshal(dAtA []byte) error {
  10771. l := len(dAtA)
  10772. iNdEx := 0
  10773. for iNdEx < l {
  10774. preIndex := iNdEx
  10775. var wire uint64
  10776. for shift := uint(0); ; shift += 7 {
  10777. if shift >= 64 {
  10778. return ErrIntOverflowTypes
  10779. }
  10780. if iNdEx >= l {
  10781. return io.ErrUnexpectedEOF
  10782. }
  10783. b := dAtA[iNdEx]
  10784. iNdEx++
  10785. wire |= uint64(b&0x7F) << shift
  10786. if b < 0x80 {
  10787. break
  10788. }
  10789. }
  10790. fieldNum := int32(wire >> 3)
  10791. wireType := int(wire & 0x7)
  10792. if wireType == 4 {
  10793. return fmt.Errorf("proto: ResponseQuery: wiretype end group for non-group")
  10794. }
  10795. if fieldNum <= 0 {
  10796. return fmt.Errorf("proto: ResponseQuery: illegal tag %d (wire type %d)", fieldNum, wire)
  10797. }
  10798. switch fieldNum {
  10799. case 1:
  10800. if wireType != 0 {
  10801. return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType)
  10802. }
  10803. m.Code = 0
  10804. for shift := uint(0); ; shift += 7 {
  10805. if shift >= 64 {
  10806. return ErrIntOverflowTypes
  10807. }
  10808. if iNdEx >= l {
  10809. return io.ErrUnexpectedEOF
  10810. }
  10811. b := dAtA[iNdEx]
  10812. iNdEx++
  10813. m.Code |= uint32(b&0x7F) << shift
  10814. if b < 0x80 {
  10815. break
  10816. }
  10817. }
  10818. case 3:
  10819. if wireType != 2 {
  10820. return fmt.Errorf("proto: wrong wireType = %d for field Log", wireType)
  10821. }
  10822. var stringLen uint64
  10823. for shift := uint(0); ; shift += 7 {
  10824. if shift >= 64 {
  10825. return ErrIntOverflowTypes
  10826. }
  10827. if iNdEx >= l {
  10828. return io.ErrUnexpectedEOF
  10829. }
  10830. b := dAtA[iNdEx]
  10831. iNdEx++
  10832. stringLen |= uint64(b&0x7F) << shift
  10833. if b < 0x80 {
  10834. break
  10835. }
  10836. }
  10837. intStringLen := int(stringLen)
  10838. if intStringLen < 0 {
  10839. return ErrInvalidLengthTypes
  10840. }
  10841. postIndex := iNdEx + intStringLen
  10842. if postIndex < 0 {
  10843. return ErrInvalidLengthTypes
  10844. }
  10845. if postIndex > l {
  10846. return io.ErrUnexpectedEOF
  10847. }
  10848. m.Log = string(dAtA[iNdEx:postIndex])
  10849. iNdEx = postIndex
  10850. case 4:
  10851. if wireType != 2 {
  10852. return fmt.Errorf("proto: wrong wireType = %d for field Info", wireType)
  10853. }
  10854. var stringLen uint64
  10855. for shift := uint(0); ; shift += 7 {
  10856. if shift >= 64 {
  10857. return ErrIntOverflowTypes
  10858. }
  10859. if iNdEx >= l {
  10860. return io.ErrUnexpectedEOF
  10861. }
  10862. b := dAtA[iNdEx]
  10863. iNdEx++
  10864. stringLen |= uint64(b&0x7F) << shift
  10865. if b < 0x80 {
  10866. break
  10867. }
  10868. }
  10869. intStringLen := int(stringLen)
  10870. if intStringLen < 0 {
  10871. return ErrInvalidLengthTypes
  10872. }
  10873. postIndex := iNdEx + intStringLen
  10874. if postIndex < 0 {
  10875. return ErrInvalidLengthTypes
  10876. }
  10877. if postIndex > l {
  10878. return io.ErrUnexpectedEOF
  10879. }
  10880. m.Info = string(dAtA[iNdEx:postIndex])
  10881. iNdEx = postIndex
  10882. case 5:
  10883. if wireType != 0 {
  10884. return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType)
  10885. }
  10886. m.Index = 0
  10887. for shift := uint(0); ; shift += 7 {
  10888. if shift >= 64 {
  10889. return ErrIntOverflowTypes
  10890. }
  10891. if iNdEx >= l {
  10892. return io.ErrUnexpectedEOF
  10893. }
  10894. b := dAtA[iNdEx]
  10895. iNdEx++
  10896. m.Index |= int64(b&0x7F) << shift
  10897. if b < 0x80 {
  10898. break
  10899. }
  10900. }
  10901. case 6:
  10902. if wireType != 2 {
  10903. return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
  10904. }
  10905. var byteLen int
  10906. for shift := uint(0); ; shift += 7 {
  10907. if shift >= 64 {
  10908. return ErrIntOverflowTypes
  10909. }
  10910. if iNdEx >= l {
  10911. return io.ErrUnexpectedEOF
  10912. }
  10913. b := dAtA[iNdEx]
  10914. iNdEx++
  10915. byteLen |= int(b&0x7F) << shift
  10916. if b < 0x80 {
  10917. break
  10918. }
  10919. }
  10920. if byteLen < 0 {
  10921. return ErrInvalidLengthTypes
  10922. }
  10923. postIndex := iNdEx + byteLen
  10924. if postIndex < 0 {
  10925. return ErrInvalidLengthTypes
  10926. }
  10927. if postIndex > l {
  10928. return io.ErrUnexpectedEOF
  10929. }
  10930. m.Key = append(m.Key[:0], dAtA[iNdEx:postIndex]...)
  10931. if m.Key == nil {
  10932. m.Key = []byte{}
  10933. }
  10934. iNdEx = postIndex
  10935. case 7:
  10936. if wireType != 2 {
  10937. return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
  10938. }
  10939. var byteLen int
  10940. for shift := uint(0); ; shift += 7 {
  10941. if shift >= 64 {
  10942. return ErrIntOverflowTypes
  10943. }
  10944. if iNdEx >= l {
  10945. return io.ErrUnexpectedEOF
  10946. }
  10947. b := dAtA[iNdEx]
  10948. iNdEx++
  10949. byteLen |= int(b&0x7F) << shift
  10950. if b < 0x80 {
  10951. break
  10952. }
  10953. }
  10954. if byteLen < 0 {
  10955. return ErrInvalidLengthTypes
  10956. }
  10957. postIndex := iNdEx + byteLen
  10958. if postIndex < 0 {
  10959. return ErrInvalidLengthTypes
  10960. }
  10961. if postIndex > l {
  10962. return io.ErrUnexpectedEOF
  10963. }
  10964. m.Value = append(m.Value[:0], dAtA[iNdEx:postIndex]...)
  10965. if m.Value == nil {
  10966. m.Value = []byte{}
  10967. }
  10968. iNdEx = postIndex
  10969. case 8:
  10970. if wireType != 2 {
  10971. return fmt.Errorf("proto: wrong wireType = %d for field ProofOps", wireType)
  10972. }
  10973. var msglen int
  10974. for shift := uint(0); ; shift += 7 {
  10975. if shift >= 64 {
  10976. return ErrIntOverflowTypes
  10977. }
  10978. if iNdEx >= l {
  10979. return io.ErrUnexpectedEOF
  10980. }
  10981. b := dAtA[iNdEx]
  10982. iNdEx++
  10983. msglen |= int(b&0x7F) << shift
  10984. if b < 0x80 {
  10985. break
  10986. }
  10987. }
  10988. if msglen < 0 {
  10989. return ErrInvalidLengthTypes
  10990. }
  10991. postIndex := iNdEx + msglen
  10992. if postIndex < 0 {
  10993. return ErrInvalidLengthTypes
  10994. }
  10995. if postIndex > l {
  10996. return io.ErrUnexpectedEOF
  10997. }
  10998. if m.ProofOps == nil {
  10999. m.ProofOps = &crypto.ProofOps{}
  11000. }
  11001. if err := m.ProofOps.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  11002. return err
  11003. }
  11004. iNdEx = postIndex
  11005. case 9:
  11006. if wireType != 0 {
  11007. return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType)
  11008. }
  11009. m.Height = 0
  11010. for shift := uint(0); ; shift += 7 {
  11011. if shift >= 64 {
  11012. return ErrIntOverflowTypes
  11013. }
  11014. if iNdEx >= l {
  11015. return io.ErrUnexpectedEOF
  11016. }
  11017. b := dAtA[iNdEx]
  11018. iNdEx++
  11019. m.Height |= int64(b&0x7F) << shift
  11020. if b < 0x80 {
  11021. break
  11022. }
  11023. }
  11024. case 10:
  11025. if wireType != 2 {
  11026. return fmt.Errorf("proto: wrong wireType = %d for field Codespace", wireType)
  11027. }
  11028. var stringLen uint64
  11029. for shift := uint(0); ; shift += 7 {
  11030. if shift >= 64 {
  11031. return ErrIntOverflowTypes
  11032. }
  11033. if iNdEx >= l {
  11034. return io.ErrUnexpectedEOF
  11035. }
  11036. b := dAtA[iNdEx]
  11037. iNdEx++
  11038. stringLen |= uint64(b&0x7F) << shift
  11039. if b < 0x80 {
  11040. break
  11041. }
  11042. }
  11043. intStringLen := int(stringLen)
  11044. if intStringLen < 0 {
  11045. return ErrInvalidLengthTypes
  11046. }
  11047. postIndex := iNdEx + intStringLen
  11048. if postIndex < 0 {
  11049. return ErrInvalidLengthTypes
  11050. }
  11051. if postIndex > l {
  11052. return io.ErrUnexpectedEOF
  11053. }
  11054. m.Codespace = string(dAtA[iNdEx:postIndex])
  11055. iNdEx = postIndex
  11056. default:
  11057. iNdEx = preIndex
  11058. skippy, err := skipTypes(dAtA[iNdEx:])
  11059. if err != nil {
  11060. return err
  11061. }
  11062. if skippy < 0 {
  11063. return ErrInvalidLengthTypes
  11064. }
  11065. if (iNdEx + skippy) < 0 {
  11066. return ErrInvalidLengthTypes
  11067. }
  11068. if (iNdEx + skippy) > l {
  11069. return io.ErrUnexpectedEOF
  11070. }
  11071. iNdEx += skippy
  11072. }
  11073. }
  11074. if iNdEx > l {
  11075. return io.ErrUnexpectedEOF
  11076. }
  11077. return nil
  11078. }
  11079. func (m *ResponseBeginBlock) Unmarshal(dAtA []byte) error {
  11080. l := len(dAtA)
  11081. iNdEx := 0
  11082. for iNdEx < l {
  11083. preIndex := iNdEx
  11084. var wire uint64
  11085. for shift := uint(0); ; shift += 7 {
  11086. if shift >= 64 {
  11087. return ErrIntOverflowTypes
  11088. }
  11089. if iNdEx >= l {
  11090. return io.ErrUnexpectedEOF
  11091. }
  11092. b := dAtA[iNdEx]
  11093. iNdEx++
  11094. wire |= uint64(b&0x7F) << shift
  11095. if b < 0x80 {
  11096. break
  11097. }
  11098. }
  11099. fieldNum := int32(wire >> 3)
  11100. wireType := int(wire & 0x7)
  11101. if wireType == 4 {
  11102. return fmt.Errorf("proto: ResponseBeginBlock: wiretype end group for non-group")
  11103. }
  11104. if fieldNum <= 0 {
  11105. return fmt.Errorf("proto: ResponseBeginBlock: illegal tag %d (wire type %d)", fieldNum, wire)
  11106. }
  11107. switch fieldNum {
  11108. case 1:
  11109. if wireType != 2 {
  11110. return fmt.Errorf("proto: wrong wireType = %d for field Events", wireType)
  11111. }
  11112. var msglen int
  11113. for shift := uint(0); ; shift += 7 {
  11114. if shift >= 64 {
  11115. return ErrIntOverflowTypes
  11116. }
  11117. if iNdEx >= l {
  11118. return io.ErrUnexpectedEOF
  11119. }
  11120. b := dAtA[iNdEx]
  11121. iNdEx++
  11122. msglen |= int(b&0x7F) << shift
  11123. if b < 0x80 {
  11124. break
  11125. }
  11126. }
  11127. if msglen < 0 {
  11128. return ErrInvalidLengthTypes
  11129. }
  11130. postIndex := iNdEx + msglen
  11131. if postIndex < 0 {
  11132. return ErrInvalidLengthTypes
  11133. }
  11134. if postIndex > l {
  11135. return io.ErrUnexpectedEOF
  11136. }
  11137. m.Events = append(m.Events, Event{})
  11138. if err := m.Events[len(m.Events)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  11139. return err
  11140. }
  11141. iNdEx = postIndex
  11142. default:
  11143. iNdEx = preIndex
  11144. skippy, err := skipTypes(dAtA[iNdEx:])
  11145. if err != nil {
  11146. return err
  11147. }
  11148. if skippy < 0 {
  11149. return ErrInvalidLengthTypes
  11150. }
  11151. if (iNdEx + skippy) < 0 {
  11152. return ErrInvalidLengthTypes
  11153. }
  11154. if (iNdEx + skippy) > l {
  11155. return io.ErrUnexpectedEOF
  11156. }
  11157. iNdEx += skippy
  11158. }
  11159. }
  11160. if iNdEx > l {
  11161. return io.ErrUnexpectedEOF
  11162. }
  11163. return nil
  11164. }
  11165. func (m *ResponseCheckTx) Unmarshal(dAtA []byte) error {
  11166. l := len(dAtA)
  11167. iNdEx := 0
  11168. for iNdEx < l {
  11169. preIndex := iNdEx
  11170. var wire uint64
  11171. for shift := uint(0); ; shift += 7 {
  11172. if shift >= 64 {
  11173. return ErrIntOverflowTypes
  11174. }
  11175. if iNdEx >= l {
  11176. return io.ErrUnexpectedEOF
  11177. }
  11178. b := dAtA[iNdEx]
  11179. iNdEx++
  11180. wire |= uint64(b&0x7F) << shift
  11181. if b < 0x80 {
  11182. break
  11183. }
  11184. }
  11185. fieldNum := int32(wire >> 3)
  11186. wireType := int(wire & 0x7)
  11187. if wireType == 4 {
  11188. return fmt.Errorf("proto: ResponseCheckTx: wiretype end group for non-group")
  11189. }
  11190. if fieldNum <= 0 {
  11191. return fmt.Errorf("proto: ResponseCheckTx: illegal tag %d (wire type %d)", fieldNum, wire)
  11192. }
  11193. switch fieldNum {
  11194. case 1:
  11195. if wireType != 0 {
  11196. return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType)
  11197. }
  11198. m.Code = 0
  11199. for shift := uint(0); ; shift += 7 {
  11200. if shift >= 64 {
  11201. return ErrIntOverflowTypes
  11202. }
  11203. if iNdEx >= l {
  11204. return io.ErrUnexpectedEOF
  11205. }
  11206. b := dAtA[iNdEx]
  11207. iNdEx++
  11208. m.Code |= uint32(b&0x7F) << shift
  11209. if b < 0x80 {
  11210. break
  11211. }
  11212. }
  11213. case 2:
  11214. if wireType != 2 {
  11215. return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
  11216. }
  11217. var byteLen int
  11218. for shift := uint(0); ; shift += 7 {
  11219. if shift >= 64 {
  11220. return ErrIntOverflowTypes
  11221. }
  11222. if iNdEx >= l {
  11223. return io.ErrUnexpectedEOF
  11224. }
  11225. b := dAtA[iNdEx]
  11226. iNdEx++
  11227. byteLen |= int(b&0x7F) << shift
  11228. if b < 0x80 {
  11229. break
  11230. }
  11231. }
  11232. if byteLen < 0 {
  11233. return ErrInvalidLengthTypes
  11234. }
  11235. postIndex := iNdEx + byteLen
  11236. if postIndex < 0 {
  11237. return ErrInvalidLengthTypes
  11238. }
  11239. if postIndex > l {
  11240. return io.ErrUnexpectedEOF
  11241. }
  11242. m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
  11243. if m.Data == nil {
  11244. m.Data = []byte{}
  11245. }
  11246. iNdEx = postIndex
  11247. case 3:
  11248. if wireType != 2 {
  11249. return fmt.Errorf("proto: wrong wireType = %d for field Log", wireType)
  11250. }
  11251. var stringLen uint64
  11252. for shift := uint(0); ; shift += 7 {
  11253. if shift >= 64 {
  11254. return ErrIntOverflowTypes
  11255. }
  11256. if iNdEx >= l {
  11257. return io.ErrUnexpectedEOF
  11258. }
  11259. b := dAtA[iNdEx]
  11260. iNdEx++
  11261. stringLen |= uint64(b&0x7F) << shift
  11262. if b < 0x80 {
  11263. break
  11264. }
  11265. }
  11266. intStringLen := int(stringLen)
  11267. if intStringLen < 0 {
  11268. return ErrInvalidLengthTypes
  11269. }
  11270. postIndex := iNdEx + intStringLen
  11271. if postIndex < 0 {
  11272. return ErrInvalidLengthTypes
  11273. }
  11274. if postIndex > l {
  11275. return io.ErrUnexpectedEOF
  11276. }
  11277. m.Log = string(dAtA[iNdEx:postIndex])
  11278. iNdEx = postIndex
  11279. case 4:
  11280. if wireType != 2 {
  11281. return fmt.Errorf("proto: wrong wireType = %d for field Info", wireType)
  11282. }
  11283. var stringLen uint64
  11284. for shift := uint(0); ; shift += 7 {
  11285. if shift >= 64 {
  11286. return ErrIntOverflowTypes
  11287. }
  11288. if iNdEx >= l {
  11289. return io.ErrUnexpectedEOF
  11290. }
  11291. b := dAtA[iNdEx]
  11292. iNdEx++
  11293. stringLen |= uint64(b&0x7F) << shift
  11294. if b < 0x80 {
  11295. break
  11296. }
  11297. }
  11298. intStringLen := int(stringLen)
  11299. if intStringLen < 0 {
  11300. return ErrInvalidLengthTypes
  11301. }
  11302. postIndex := iNdEx + intStringLen
  11303. if postIndex < 0 {
  11304. return ErrInvalidLengthTypes
  11305. }
  11306. if postIndex > l {
  11307. return io.ErrUnexpectedEOF
  11308. }
  11309. m.Info = string(dAtA[iNdEx:postIndex])
  11310. iNdEx = postIndex
  11311. case 5:
  11312. if wireType != 0 {
  11313. return fmt.Errorf("proto: wrong wireType = %d for field GasWanted", wireType)
  11314. }
  11315. m.GasWanted = 0
  11316. for shift := uint(0); ; shift += 7 {
  11317. if shift >= 64 {
  11318. return ErrIntOverflowTypes
  11319. }
  11320. if iNdEx >= l {
  11321. return io.ErrUnexpectedEOF
  11322. }
  11323. b := dAtA[iNdEx]
  11324. iNdEx++
  11325. m.GasWanted |= int64(b&0x7F) << shift
  11326. if b < 0x80 {
  11327. break
  11328. }
  11329. }
  11330. case 6:
  11331. if wireType != 0 {
  11332. return fmt.Errorf("proto: wrong wireType = %d for field GasUsed", wireType)
  11333. }
  11334. m.GasUsed = 0
  11335. for shift := uint(0); ; shift += 7 {
  11336. if shift >= 64 {
  11337. return ErrIntOverflowTypes
  11338. }
  11339. if iNdEx >= l {
  11340. return io.ErrUnexpectedEOF
  11341. }
  11342. b := dAtA[iNdEx]
  11343. iNdEx++
  11344. m.GasUsed |= int64(b&0x7F) << shift
  11345. if b < 0x80 {
  11346. break
  11347. }
  11348. }
  11349. case 7:
  11350. if wireType != 2 {
  11351. return fmt.Errorf("proto: wrong wireType = %d for field Events", wireType)
  11352. }
  11353. var msglen int
  11354. for shift := uint(0); ; shift += 7 {
  11355. if shift >= 64 {
  11356. return ErrIntOverflowTypes
  11357. }
  11358. if iNdEx >= l {
  11359. return io.ErrUnexpectedEOF
  11360. }
  11361. b := dAtA[iNdEx]
  11362. iNdEx++
  11363. msglen |= int(b&0x7F) << shift
  11364. if b < 0x80 {
  11365. break
  11366. }
  11367. }
  11368. if msglen < 0 {
  11369. return ErrInvalidLengthTypes
  11370. }
  11371. postIndex := iNdEx + msglen
  11372. if postIndex < 0 {
  11373. return ErrInvalidLengthTypes
  11374. }
  11375. if postIndex > l {
  11376. return io.ErrUnexpectedEOF
  11377. }
  11378. m.Events = append(m.Events, Event{})
  11379. if err := m.Events[len(m.Events)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  11380. return err
  11381. }
  11382. iNdEx = postIndex
  11383. case 8:
  11384. if wireType != 2 {
  11385. return fmt.Errorf("proto: wrong wireType = %d for field Codespace", wireType)
  11386. }
  11387. var stringLen uint64
  11388. for shift := uint(0); ; shift += 7 {
  11389. if shift >= 64 {
  11390. return ErrIntOverflowTypes
  11391. }
  11392. if iNdEx >= l {
  11393. return io.ErrUnexpectedEOF
  11394. }
  11395. b := dAtA[iNdEx]
  11396. iNdEx++
  11397. stringLen |= uint64(b&0x7F) << shift
  11398. if b < 0x80 {
  11399. break
  11400. }
  11401. }
  11402. intStringLen := int(stringLen)
  11403. if intStringLen < 0 {
  11404. return ErrInvalidLengthTypes
  11405. }
  11406. postIndex := iNdEx + intStringLen
  11407. if postIndex < 0 {
  11408. return ErrInvalidLengthTypes
  11409. }
  11410. if postIndex > l {
  11411. return io.ErrUnexpectedEOF
  11412. }
  11413. m.Codespace = string(dAtA[iNdEx:postIndex])
  11414. iNdEx = postIndex
  11415. default:
  11416. iNdEx = preIndex
  11417. skippy, err := skipTypes(dAtA[iNdEx:])
  11418. if err != nil {
  11419. return err
  11420. }
  11421. if skippy < 0 {
  11422. return ErrInvalidLengthTypes
  11423. }
  11424. if (iNdEx + skippy) < 0 {
  11425. return ErrInvalidLengthTypes
  11426. }
  11427. if (iNdEx + skippy) > l {
  11428. return io.ErrUnexpectedEOF
  11429. }
  11430. iNdEx += skippy
  11431. }
  11432. }
  11433. if iNdEx > l {
  11434. return io.ErrUnexpectedEOF
  11435. }
  11436. return nil
  11437. }
  11438. func (m *ResponseDeliverTx) Unmarshal(dAtA []byte) error {
  11439. l := len(dAtA)
  11440. iNdEx := 0
  11441. for iNdEx < l {
  11442. preIndex := iNdEx
  11443. var wire uint64
  11444. for shift := uint(0); ; shift += 7 {
  11445. if shift >= 64 {
  11446. return ErrIntOverflowTypes
  11447. }
  11448. if iNdEx >= l {
  11449. return io.ErrUnexpectedEOF
  11450. }
  11451. b := dAtA[iNdEx]
  11452. iNdEx++
  11453. wire |= uint64(b&0x7F) << shift
  11454. if b < 0x80 {
  11455. break
  11456. }
  11457. }
  11458. fieldNum := int32(wire >> 3)
  11459. wireType := int(wire & 0x7)
  11460. if wireType == 4 {
  11461. return fmt.Errorf("proto: ResponseDeliverTx: wiretype end group for non-group")
  11462. }
  11463. if fieldNum <= 0 {
  11464. return fmt.Errorf("proto: ResponseDeliverTx: illegal tag %d (wire type %d)", fieldNum, wire)
  11465. }
  11466. switch fieldNum {
  11467. case 1:
  11468. if wireType != 0 {
  11469. return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType)
  11470. }
  11471. m.Code = 0
  11472. for shift := uint(0); ; shift += 7 {
  11473. if shift >= 64 {
  11474. return ErrIntOverflowTypes
  11475. }
  11476. if iNdEx >= l {
  11477. return io.ErrUnexpectedEOF
  11478. }
  11479. b := dAtA[iNdEx]
  11480. iNdEx++
  11481. m.Code |= uint32(b&0x7F) << shift
  11482. if b < 0x80 {
  11483. break
  11484. }
  11485. }
  11486. case 2:
  11487. if wireType != 2 {
  11488. return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
  11489. }
  11490. var byteLen int
  11491. for shift := uint(0); ; shift += 7 {
  11492. if shift >= 64 {
  11493. return ErrIntOverflowTypes
  11494. }
  11495. if iNdEx >= l {
  11496. return io.ErrUnexpectedEOF
  11497. }
  11498. b := dAtA[iNdEx]
  11499. iNdEx++
  11500. byteLen |= int(b&0x7F) << shift
  11501. if b < 0x80 {
  11502. break
  11503. }
  11504. }
  11505. if byteLen < 0 {
  11506. return ErrInvalidLengthTypes
  11507. }
  11508. postIndex := iNdEx + byteLen
  11509. if postIndex < 0 {
  11510. return ErrInvalidLengthTypes
  11511. }
  11512. if postIndex > l {
  11513. return io.ErrUnexpectedEOF
  11514. }
  11515. m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
  11516. if m.Data == nil {
  11517. m.Data = []byte{}
  11518. }
  11519. iNdEx = postIndex
  11520. case 3:
  11521. if wireType != 2 {
  11522. return fmt.Errorf("proto: wrong wireType = %d for field Log", wireType)
  11523. }
  11524. var stringLen uint64
  11525. for shift := uint(0); ; shift += 7 {
  11526. if shift >= 64 {
  11527. return ErrIntOverflowTypes
  11528. }
  11529. if iNdEx >= l {
  11530. return io.ErrUnexpectedEOF
  11531. }
  11532. b := dAtA[iNdEx]
  11533. iNdEx++
  11534. stringLen |= uint64(b&0x7F) << shift
  11535. if b < 0x80 {
  11536. break
  11537. }
  11538. }
  11539. intStringLen := int(stringLen)
  11540. if intStringLen < 0 {
  11541. return ErrInvalidLengthTypes
  11542. }
  11543. postIndex := iNdEx + intStringLen
  11544. if postIndex < 0 {
  11545. return ErrInvalidLengthTypes
  11546. }
  11547. if postIndex > l {
  11548. return io.ErrUnexpectedEOF
  11549. }
  11550. m.Log = string(dAtA[iNdEx:postIndex])
  11551. iNdEx = postIndex
  11552. case 4:
  11553. if wireType != 2 {
  11554. return fmt.Errorf("proto: wrong wireType = %d for field Info", wireType)
  11555. }
  11556. var stringLen uint64
  11557. for shift := uint(0); ; shift += 7 {
  11558. if shift >= 64 {
  11559. return ErrIntOverflowTypes
  11560. }
  11561. if iNdEx >= l {
  11562. return io.ErrUnexpectedEOF
  11563. }
  11564. b := dAtA[iNdEx]
  11565. iNdEx++
  11566. stringLen |= uint64(b&0x7F) << shift
  11567. if b < 0x80 {
  11568. break
  11569. }
  11570. }
  11571. intStringLen := int(stringLen)
  11572. if intStringLen < 0 {
  11573. return ErrInvalidLengthTypes
  11574. }
  11575. postIndex := iNdEx + intStringLen
  11576. if postIndex < 0 {
  11577. return ErrInvalidLengthTypes
  11578. }
  11579. if postIndex > l {
  11580. return io.ErrUnexpectedEOF
  11581. }
  11582. m.Info = string(dAtA[iNdEx:postIndex])
  11583. iNdEx = postIndex
  11584. case 5:
  11585. if wireType != 0 {
  11586. return fmt.Errorf("proto: wrong wireType = %d for field GasWanted", wireType)
  11587. }
  11588. m.GasWanted = 0
  11589. for shift := uint(0); ; shift += 7 {
  11590. if shift >= 64 {
  11591. return ErrIntOverflowTypes
  11592. }
  11593. if iNdEx >= l {
  11594. return io.ErrUnexpectedEOF
  11595. }
  11596. b := dAtA[iNdEx]
  11597. iNdEx++
  11598. m.GasWanted |= int64(b&0x7F) << shift
  11599. if b < 0x80 {
  11600. break
  11601. }
  11602. }
  11603. case 6:
  11604. if wireType != 0 {
  11605. return fmt.Errorf("proto: wrong wireType = %d for field GasUsed", wireType)
  11606. }
  11607. m.GasUsed = 0
  11608. for shift := uint(0); ; shift += 7 {
  11609. if shift >= 64 {
  11610. return ErrIntOverflowTypes
  11611. }
  11612. if iNdEx >= l {
  11613. return io.ErrUnexpectedEOF
  11614. }
  11615. b := dAtA[iNdEx]
  11616. iNdEx++
  11617. m.GasUsed |= int64(b&0x7F) << shift
  11618. if b < 0x80 {
  11619. break
  11620. }
  11621. }
  11622. case 7:
  11623. if wireType != 2 {
  11624. return fmt.Errorf("proto: wrong wireType = %d for field Events", wireType)
  11625. }
  11626. var msglen int
  11627. for shift := uint(0); ; shift += 7 {
  11628. if shift >= 64 {
  11629. return ErrIntOverflowTypes
  11630. }
  11631. if iNdEx >= l {
  11632. return io.ErrUnexpectedEOF
  11633. }
  11634. b := dAtA[iNdEx]
  11635. iNdEx++
  11636. msglen |= int(b&0x7F) << shift
  11637. if b < 0x80 {
  11638. break
  11639. }
  11640. }
  11641. if msglen < 0 {
  11642. return ErrInvalidLengthTypes
  11643. }
  11644. postIndex := iNdEx + msglen
  11645. if postIndex < 0 {
  11646. return ErrInvalidLengthTypes
  11647. }
  11648. if postIndex > l {
  11649. return io.ErrUnexpectedEOF
  11650. }
  11651. m.Events = append(m.Events, Event{})
  11652. if err := m.Events[len(m.Events)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  11653. return err
  11654. }
  11655. iNdEx = postIndex
  11656. case 8:
  11657. if wireType != 2 {
  11658. return fmt.Errorf("proto: wrong wireType = %d for field Codespace", wireType)
  11659. }
  11660. var stringLen uint64
  11661. for shift := uint(0); ; shift += 7 {
  11662. if shift >= 64 {
  11663. return ErrIntOverflowTypes
  11664. }
  11665. if iNdEx >= l {
  11666. return io.ErrUnexpectedEOF
  11667. }
  11668. b := dAtA[iNdEx]
  11669. iNdEx++
  11670. stringLen |= uint64(b&0x7F) << shift
  11671. if b < 0x80 {
  11672. break
  11673. }
  11674. }
  11675. intStringLen := int(stringLen)
  11676. if intStringLen < 0 {
  11677. return ErrInvalidLengthTypes
  11678. }
  11679. postIndex := iNdEx + intStringLen
  11680. if postIndex < 0 {
  11681. return ErrInvalidLengthTypes
  11682. }
  11683. if postIndex > l {
  11684. return io.ErrUnexpectedEOF
  11685. }
  11686. m.Codespace = string(dAtA[iNdEx:postIndex])
  11687. iNdEx = postIndex
  11688. default:
  11689. iNdEx = preIndex
  11690. skippy, err := skipTypes(dAtA[iNdEx:])
  11691. if err != nil {
  11692. return err
  11693. }
  11694. if skippy < 0 {
  11695. return ErrInvalidLengthTypes
  11696. }
  11697. if (iNdEx + skippy) < 0 {
  11698. return ErrInvalidLengthTypes
  11699. }
  11700. if (iNdEx + skippy) > l {
  11701. return io.ErrUnexpectedEOF
  11702. }
  11703. iNdEx += skippy
  11704. }
  11705. }
  11706. if iNdEx > l {
  11707. return io.ErrUnexpectedEOF
  11708. }
  11709. return nil
  11710. }
  11711. func (m *ResponseEndBlock) Unmarshal(dAtA []byte) error {
  11712. l := len(dAtA)
  11713. iNdEx := 0
  11714. for iNdEx < l {
  11715. preIndex := iNdEx
  11716. var wire uint64
  11717. for shift := uint(0); ; shift += 7 {
  11718. if shift >= 64 {
  11719. return ErrIntOverflowTypes
  11720. }
  11721. if iNdEx >= l {
  11722. return io.ErrUnexpectedEOF
  11723. }
  11724. b := dAtA[iNdEx]
  11725. iNdEx++
  11726. wire |= uint64(b&0x7F) << shift
  11727. if b < 0x80 {
  11728. break
  11729. }
  11730. }
  11731. fieldNum := int32(wire >> 3)
  11732. wireType := int(wire & 0x7)
  11733. if wireType == 4 {
  11734. return fmt.Errorf("proto: ResponseEndBlock: wiretype end group for non-group")
  11735. }
  11736. if fieldNum <= 0 {
  11737. return fmt.Errorf("proto: ResponseEndBlock: illegal tag %d (wire type %d)", fieldNum, wire)
  11738. }
  11739. switch fieldNum {
  11740. case 1:
  11741. if wireType != 2 {
  11742. return fmt.Errorf("proto: wrong wireType = %d for field ValidatorUpdates", wireType)
  11743. }
  11744. var msglen int
  11745. for shift := uint(0); ; shift += 7 {
  11746. if shift >= 64 {
  11747. return ErrIntOverflowTypes
  11748. }
  11749. if iNdEx >= l {
  11750. return io.ErrUnexpectedEOF
  11751. }
  11752. b := dAtA[iNdEx]
  11753. iNdEx++
  11754. msglen |= int(b&0x7F) << shift
  11755. if b < 0x80 {
  11756. break
  11757. }
  11758. }
  11759. if msglen < 0 {
  11760. return ErrInvalidLengthTypes
  11761. }
  11762. postIndex := iNdEx + msglen
  11763. if postIndex < 0 {
  11764. return ErrInvalidLengthTypes
  11765. }
  11766. if postIndex > l {
  11767. return io.ErrUnexpectedEOF
  11768. }
  11769. m.ValidatorUpdates = append(m.ValidatorUpdates, ValidatorUpdate{})
  11770. if err := m.ValidatorUpdates[len(m.ValidatorUpdates)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  11771. return err
  11772. }
  11773. iNdEx = postIndex
  11774. case 2:
  11775. if wireType != 2 {
  11776. return fmt.Errorf("proto: wrong wireType = %d for field ConsensusParamUpdates", wireType)
  11777. }
  11778. var msglen int
  11779. for shift := uint(0); ; shift += 7 {
  11780. if shift >= 64 {
  11781. return ErrIntOverflowTypes
  11782. }
  11783. if iNdEx >= l {
  11784. return io.ErrUnexpectedEOF
  11785. }
  11786. b := dAtA[iNdEx]
  11787. iNdEx++
  11788. msglen |= int(b&0x7F) << shift
  11789. if b < 0x80 {
  11790. break
  11791. }
  11792. }
  11793. if msglen < 0 {
  11794. return ErrInvalidLengthTypes
  11795. }
  11796. postIndex := iNdEx + msglen
  11797. if postIndex < 0 {
  11798. return ErrInvalidLengthTypes
  11799. }
  11800. if postIndex > l {
  11801. return io.ErrUnexpectedEOF
  11802. }
  11803. if m.ConsensusParamUpdates == nil {
  11804. m.ConsensusParamUpdates = &ConsensusParams{}
  11805. }
  11806. if err := m.ConsensusParamUpdates.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  11807. return err
  11808. }
  11809. iNdEx = postIndex
  11810. case 3:
  11811. if wireType != 2 {
  11812. return fmt.Errorf("proto: wrong wireType = %d for field Events", wireType)
  11813. }
  11814. var msglen int
  11815. for shift := uint(0); ; shift += 7 {
  11816. if shift >= 64 {
  11817. return ErrIntOverflowTypes
  11818. }
  11819. if iNdEx >= l {
  11820. return io.ErrUnexpectedEOF
  11821. }
  11822. b := dAtA[iNdEx]
  11823. iNdEx++
  11824. msglen |= int(b&0x7F) << shift
  11825. if b < 0x80 {
  11826. break
  11827. }
  11828. }
  11829. if msglen < 0 {
  11830. return ErrInvalidLengthTypes
  11831. }
  11832. postIndex := iNdEx + msglen
  11833. if postIndex < 0 {
  11834. return ErrInvalidLengthTypes
  11835. }
  11836. if postIndex > l {
  11837. return io.ErrUnexpectedEOF
  11838. }
  11839. m.Events = append(m.Events, Event{})
  11840. if err := m.Events[len(m.Events)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  11841. return err
  11842. }
  11843. iNdEx = postIndex
  11844. default:
  11845. iNdEx = preIndex
  11846. skippy, err := skipTypes(dAtA[iNdEx:])
  11847. if err != nil {
  11848. return err
  11849. }
  11850. if skippy < 0 {
  11851. return ErrInvalidLengthTypes
  11852. }
  11853. if (iNdEx + skippy) < 0 {
  11854. return ErrInvalidLengthTypes
  11855. }
  11856. if (iNdEx + skippy) > l {
  11857. return io.ErrUnexpectedEOF
  11858. }
  11859. iNdEx += skippy
  11860. }
  11861. }
  11862. if iNdEx > l {
  11863. return io.ErrUnexpectedEOF
  11864. }
  11865. return nil
  11866. }
  11867. func (m *ResponseCommit) Unmarshal(dAtA []byte) error {
  11868. l := len(dAtA)
  11869. iNdEx := 0
  11870. for iNdEx < l {
  11871. preIndex := iNdEx
  11872. var wire uint64
  11873. for shift := uint(0); ; shift += 7 {
  11874. if shift >= 64 {
  11875. return ErrIntOverflowTypes
  11876. }
  11877. if iNdEx >= l {
  11878. return io.ErrUnexpectedEOF
  11879. }
  11880. b := dAtA[iNdEx]
  11881. iNdEx++
  11882. wire |= uint64(b&0x7F) << shift
  11883. if b < 0x80 {
  11884. break
  11885. }
  11886. }
  11887. fieldNum := int32(wire >> 3)
  11888. wireType := int(wire & 0x7)
  11889. if wireType == 4 {
  11890. return fmt.Errorf("proto: ResponseCommit: wiretype end group for non-group")
  11891. }
  11892. if fieldNum <= 0 {
  11893. return fmt.Errorf("proto: ResponseCommit: illegal tag %d (wire type %d)", fieldNum, wire)
  11894. }
  11895. switch fieldNum {
  11896. case 2:
  11897. if wireType != 2 {
  11898. return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType)
  11899. }
  11900. var byteLen int
  11901. for shift := uint(0); ; shift += 7 {
  11902. if shift >= 64 {
  11903. return ErrIntOverflowTypes
  11904. }
  11905. if iNdEx >= l {
  11906. return io.ErrUnexpectedEOF
  11907. }
  11908. b := dAtA[iNdEx]
  11909. iNdEx++
  11910. byteLen |= int(b&0x7F) << shift
  11911. if b < 0x80 {
  11912. break
  11913. }
  11914. }
  11915. if byteLen < 0 {
  11916. return ErrInvalidLengthTypes
  11917. }
  11918. postIndex := iNdEx + byteLen
  11919. if postIndex < 0 {
  11920. return ErrInvalidLengthTypes
  11921. }
  11922. if postIndex > l {
  11923. return io.ErrUnexpectedEOF
  11924. }
  11925. m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...)
  11926. if m.Data == nil {
  11927. m.Data = []byte{}
  11928. }
  11929. iNdEx = postIndex
  11930. case 3:
  11931. if wireType != 0 {
  11932. return fmt.Errorf("proto: wrong wireType = %d for field RetainHeight", wireType)
  11933. }
  11934. m.RetainHeight = 0
  11935. for shift := uint(0); ; shift += 7 {
  11936. if shift >= 64 {
  11937. return ErrIntOverflowTypes
  11938. }
  11939. if iNdEx >= l {
  11940. return io.ErrUnexpectedEOF
  11941. }
  11942. b := dAtA[iNdEx]
  11943. iNdEx++
  11944. m.RetainHeight |= int64(b&0x7F) << shift
  11945. if b < 0x80 {
  11946. break
  11947. }
  11948. }
  11949. default:
  11950. iNdEx = preIndex
  11951. skippy, err := skipTypes(dAtA[iNdEx:])
  11952. if err != nil {
  11953. return err
  11954. }
  11955. if skippy < 0 {
  11956. return ErrInvalidLengthTypes
  11957. }
  11958. if (iNdEx + skippy) < 0 {
  11959. return ErrInvalidLengthTypes
  11960. }
  11961. if (iNdEx + skippy) > l {
  11962. return io.ErrUnexpectedEOF
  11963. }
  11964. iNdEx += skippy
  11965. }
  11966. }
  11967. if iNdEx > l {
  11968. return io.ErrUnexpectedEOF
  11969. }
  11970. return nil
  11971. }
  11972. func (m *ResponseListSnapshots) Unmarshal(dAtA []byte) error {
  11973. l := len(dAtA)
  11974. iNdEx := 0
  11975. for iNdEx < l {
  11976. preIndex := iNdEx
  11977. var wire uint64
  11978. for shift := uint(0); ; shift += 7 {
  11979. if shift >= 64 {
  11980. return ErrIntOverflowTypes
  11981. }
  11982. if iNdEx >= l {
  11983. return io.ErrUnexpectedEOF
  11984. }
  11985. b := dAtA[iNdEx]
  11986. iNdEx++
  11987. wire |= uint64(b&0x7F) << shift
  11988. if b < 0x80 {
  11989. break
  11990. }
  11991. }
  11992. fieldNum := int32(wire >> 3)
  11993. wireType := int(wire & 0x7)
  11994. if wireType == 4 {
  11995. return fmt.Errorf("proto: ResponseListSnapshots: wiretype end group for non-group")
  11996. }
  11997. if fieldNum <= 0 {
  11998. return fmt.Errorf("proto: ResponseListSnapshots: illegal tag %d (wire type %d)", fieldNum, wire)
  11999. }
  12000. switch fieldNum {
  12001. case 1:
  12002. if wireType != 2 {
  12003. return fmt.Errorf("proto: wrong wireType = %d for field Snapshots", wireType)
  12004. }
  12005. var msglen int
  12006. for shift := uint(0); ; shift += 7 {
  12007. if shift >= 64 {
  12008. return ErrIntOverflowTypes
  12009. }
  12010. if iNdEx >= l {
  12011. return io.ErrUnexpectedEOF
  12012. }
  12013. b := dAtA[iNdEx]
  12014. iNdEx++
  12015. msglen |= int(b&0x7F) << shift
  12016. if b < 0x80 {
  12017. break
  12018. }
  12019. }
  12020. if msglen < 0 {
  12021. return ErrInvalidLengthTypes
  12022. }
  12023. postIndex := iNdEx + msglen
  12024. if postIndex < 0 {
  12025. return ErrInvalidLengthTypes
  12026. }
  12027. if postIndex > l {
  12028. return io.ErrUnexpectedEOF
  12029. }
  12030. m.Snapshots = append(m.Snapshots, &Snapshot{})
  12031. if err := m.Snapshots[len(m.Snapshots)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  12032. return err
  12033. }
  12034. iNdEx = postIndex
  12035. default:
  12036. iNdEx = preIndex
  12037. skippy, err := skipTypes(dAtA[iNdEx:])
  12038. if err != nil {
  12039. return err
  12040. }
  12041. if skippy < 0 {
  12042. return ErrInvalidLengthTypes
  12043. }
  12044. if (iNdEx + skippy) < 0 {
  12045. return ErrInvalidLengthTypes
  12046. }
  12047. if (iNdEx + skippy) > l {
  12048. return io.ErrUnexpectedEOF
  12049. }
  12050. iNdEx += skippy
  12051. }
  12052. }
  12053. if iNdEx > l {
  12054. return io.ErrUnexpectedEOF
  12055. }
  12056. return nil
  12057. }
  12058. func (m *ResponseOfferSnapshot) Unmarshal(dAtA []byte) error {
  12059. l := len(dAtA)
  12060. iNdEx := 0
  12061. for iNdEx < l {
  12062. preIndex := iNdEx
  12063. var wire uint64
  12064. for shift := uint(0); ; shift += 7 {
  12065. if shift >= 64 {
  12066. return ErrIntOverflowTypes
  12067. }
  12068. if iNdEx >= l {
  12069. return io.ErrUnexpectedEOF
  12070. }
  12071. b := dAtA[iNdEx]
  12072. iNdEx++
  12073. wire |= uint64(b&0x7F) << shift
  12074. if b < 0x80 {
  12075. break
  12076. }
  12077. }
  12078. fieldNum := int32(wire >> 3)
  12079. wireType := int(wire & 0x7)
  12080. if wireType == 4 {
  12081. return fmt.Errorf("proto: ResponseOfferSnapshot: wiretype end group for non-group")
  12082. }
  12083. if fieldNum <= 0 {
  12084. return fmt.Errorf("proto: ResponseOfferSnapshot: illegal tag %d (wire type %d)", fieldNum, wire)
  12085. }
  12086. switch fieldNum {
  12087. case 1:
  12088. if wireType != 0 {
  12089. return fmt.Errorf("proto: wrong wireType = %d for field Result", wireType)
  12090. }
  12091. m.Result = 0
  12092. for shift := uint(0); ; shift += 7 {
  12093. if shift >= 64 {
  12094. return ErrIntOverflowTypes
  12095. }
  12096. if iNdEx >= l {
  12097. return io.ErrUnexpectedEOF
  12098. }
  12099. b := dAtA[iNdEx]
  12100. iNdEx++
  12101. m.Result |= ResponseOfferSnapshot_Result(b&0x7F) << shift
  12102. if b < 0x80 {
  12103. break
  12104. }
  12105. }
  12106. default:
  12107. iNdEx = preIndex
  12108. skippy, err := skipTypes(dAtA[iNdEx:])
  12109. if err != nil {
  12110. return err
  12111. }
  12112. if skippy < 0 {
  12113. return ErrInvalidLengthTypes
  12114. }
  12115. if (iNdEx + skippy) < 0 {
  12116. return ErrInvalidLengthTypes
  12117. }
  12118. if (iNdEx + skippy) > l {
  12119. return io.ErrUnexpectedEOF
  12120. }
  12121. iNdEx += skippy
  12122. }
  12123. }
  12124. if iNdEx > l {
  12125. return io.ErrUnexpectedEOF
  12126. }
  12127. return nil
  12128. }
  12129. func (m *ResponseLoadSnapshotChunk) Unmarshal(dAtA []byte) error {
  12130. l := len(dAtA)
  12131. iNdEx := 0
  12132. for iNdEx < l {
  12133. preIndex := iNdEx
  12134. var wire uint64
  12135. for shift := uint(0); ; shift += 7 {
  12136. if shift >= 64 {
  12137. return ErrIntOverflowTypes
  12138. }
  12139. if iNdEx >= l {
  12140. return io.ErrUnexpectedEOF
  12141. }
  12142. b := dAtA[iNdEx]
  12143. iNdEx++
  12144. wire |= uint64(b&0x7F) << shift
  12145. if b < 0x80 {
  12146. break
  12147. }
  12148. }
  12149. fieldNum := int32(wire >> 3)
  12150. wireType := int(wire & 0x7)
  12151. if wireType == 4 {
  12152. return fmt.Errorf("proto: ResponseLoadSnapshotChunk: wiretype end group for non-group")
  12153. }
  12154. if fieldNum <= 0 {
  12155. return fmt.Errorf("proto: ResponseLoadSnapshotChunk: illegal tag %d (wire type %d)", fieldNum, wire)
  12156. }
  12157. switch fieldNum {
  12158. case 1:
  12159. if wireType != 2 {
  12160. return fmt.Errorf("proto: wrong wireType = %d for field Chunk", wireType)
  12161. }
  12162. var byteLen int
  12163. for shift := uint(0); ; shift += 7 {
  12164. if shift >= 64 {
  12165. return ErrIntOverflowTypes
  12166. }
  12167. if iNdEx >= l {
  12168. return io.ErrUnexpectedEOF
  12169. }
  12170. b := dAtA[iNdEx]
  12171. iNdEx++
  12172. byteLen |= int(b&0x7F) << shift
  12173. if b < 0x80 {
  12174. break
  12175. }
  12176. }
  12177. if byteLen < 0 {
  12178. return ErrInvalidLengthTypes
  12179. }
  12180. postIndex := iNdEx + byteLen
  12181. if postIndex < 0 {
  12182. return ErrInvalidLengthTypes
  12183. }
  12184. if postIndex > l {
  12185. return io.ErrUnexpectedEOF
  12186. }
  12187. m.Chunk = append(m.Chunk[:0], dAtA[iNdEx:postIndex]...)
  12188. if m.Chunk == nil {
  12189. m.Chunk = []byte{}
  12190. }
  12191. iNdEx = postIndex
  12192. default:
  12193. iNdEx = preIndex
  12194. skippy, err := skipTypes(dAtA[iNdEx:])
  12195. if err != nil {
  12196. return err
  12197. }
  12198. if skippy < 0 {
  12199. return ErrInvalidLengthTypes
  12200. }
  12201. if (iNdEx + skippy) < 0 {
  12202. return ErrInvalidLengthTypes
  12203. }
  12204. if (iNdEx + skippy) > l {
  12205. return io.ErrUnexpectedEOF
  12206. }
  12207. iNdEx += skippy
  12208. }
  12209. }
  12210. if iNdEx > l {
  12211. return io.ErrUnexpectedEOF
  12212. }
  12213. return nil
  12214. }
  12215. func (m *ResponseApplySnapshotChunk) Unmarshal(dAtA []byte) error {
  12216. l := len(dAtA)
  12217. iNdEx := 0
  12218. for iNdEx < l {
  12219. preIndex := iNdEx
  12220. var wire uint64
  12221. for shift := uint(0); ; shift += 7 {
  12222. if shift >= 64 {
  12223. return ErrIntOverflowTypes
  12224. }
  12225. if iNdEx >= l {
  12226. return io.ErrUnexpectedEOF
  12227. }
  12228. b := dAtA[iNdEx]
  12229. iNdEx++
  12230. wire |= uint64(b&0x7F) << shift
  12231. if b < 0x80 {
  12232. break
  12233. }
  12234. }
  12235. fieldNum := int32(wire >> 3)
  12236. wireType := int(wire & 0x7)
  12237. if wireType == 4 {
  12238. return fmt.Errorf("proto: ResponseApplySnapshotChunk: wiretype end group for non-group")
  12239. }
  12240. if fieldNum <= 0 {
  12241. return fmt.Errorf("proto: ResponseApplySnapshotChunk: illegal tag %d (wire type %d)", fieldNum, wire)
  12242. }
  12243. switch fieldNum {
  12244. case 1:
  12245. if wireType != 0 {
  12246. return fmt.Errorf("proto: wrong wireType = %d for field Result", wireType)
  12247. }
  12248. m.Result = 0
  12249. for shift := uint(0); ; shift += 7 {
  12250. if shift >= 64 {
  12251. return ErrIntOverflowTypes
  12252. }
  12253. if iNdEx >= l {
  12254. return io.ErrUnexpectedEOF
  12255. }
  12256. b := dAtA[iNdEx]
  12257. iNdEx++
  12258. m.Result |= ResponseApplySnapshotChunk_Result(b&0x7F) << shift
  12259. if b < 0x80 {
  12260. break
  12261. }
  12262. }
  12263. case 2:
  12264. if wireType == 0 {
  12265. var v uint32
  12266. for shift := uint(0); ; shift += 7 {
  12267. if shift >= 64 {
  12268. return ErrIntOverflowTypes
  12269. }
  12270. if iNdEx >= l {
  12271. return io.ErrUnexpectedEOF
  12272. }
  12273. b := dAtA[iNdEx]
  12274. iNdEx++
  12275. v |= uint32(b&0x7F) << shift
  12276. if b < 0x80 {
  12277. break
  12278. }
  12279. }
  12280. m.RefetchChunks = append(m.RefetchChunks, v)
  12281. } else if wireType == 2 {
  12282. var packedLen int
  12283. for shift := uint(0); ; shift += 7 {
  12284. if shift >= 64 {
  12285. return ErrIntOverflowTypes
  12286. }
  12287. if iNdEx >= l {
  12288. return io.ErrUnexpectedEOF
  12289. }
  12290. b := dAtA[iNdEx]
  12291. iNdEx++
  12292. packedLen |= int(b&0x7F) << shift
  12293. if b < 0x80 {
  12294. break
  12295. }
  12296. }
  12297. if packedLen < 0 {
  12298. return ErrInvalidLengthTypes
  12299. }
  12300. postIndex := iNdEx + packedLen
  12301. if postIndex < 0 {
  12302. return ErrInvalidLengthTypes
  12303. }
  12304. if postIndex > l {
  12305. return io.ErrUnexpectedEOF
  12306. }
  12307. var elementCount int
  12308. var count int
  12309. for _, integer := range dAtA[iNdEx:postIndex] {
  12310. if integer < 128 {
  12311. count++
  12312. }
  12313. }
  12314. elementCount = count
  12315. if elementCount != 0 && len(m.RefetchChunks) == 0 {
  12316. m.RefetchChunks = make([]uint32, 0, elementCount)
  12317. }
  12318. for iNdEx < postIndex {
  12319. var v uint32
  12320. for shift := uint(0); ; shift += 7 {
  12321. if shift >= 64 {
  12322. return ErrIntOverflowTypes
  12323. }
  12324. if iNdEx >= l {
  12325. return io.ErrUnexpectedEOF
  12326. }
  12327. b := dAtA[iNdEx]
  12328. iNdEx++
  12329. v |= uint32(b&0x7F) << shift
  12330. if b < 0x80 {
  12331. break
  12332. }
  12333. }
  12334. m.RefetchChunks = append(m.RefetchChunks, v)
  12335. }
  12336. } else {
  12337. return fmt.Errorf("proto: wrong wireType = %d for field RefetchChunks", wireType)
  12338. }
  12339. case 3:
  12340. if wireType != 2 {
  12341. return fmt.Errorf("proto: wrong wireType = %d for field RejectSenders", wireType)
  12342. }
  12343. var stringLen uint64
  12344. for shift := uint(0); ; shift += 7 {
  12345. if shift >= 64 {
  12346. return ErrIntOverflowTypes
  12347. }
  12348. if iNdEx >= l {
  12349. return io.ErrUnexpectedEOF
  12350. }
  12351. b := dAtA[iNdEx]
  12352. iNdEx++
  12353. stringLen |= uint64(b&0x7F) << shift
  12354. if b < 0x80 {
  12355. break
  12356. }
  12357. }
  12358. intStringLen := int(stringLen)
  12359. if intStringLen < 0 {
  12360. return ErrInvalidLengthTypes
  12361. }
  12362. postIndex := iNdEx + intStringLen
  12363. if postIndex < 0 {
  12364. return ErrInvalidLengthTypes
  12365. }
  12366. if postIndex > l {
  12367. return io.ErrUnexpectedEOF
  12368. }
  12369. m.RejectSenders = append(m.RejectSenders, string(dAtA[iNdEx:postIndex]))
  12370. iNdEx = postIndex
  12371. default:
  12372. iNdEx = preIndex
  12373. skippy, err := skipTypes(dAtA[iNdEx:])
  12374. if err != nil {
  12375. return err
  12376. }
  12377. if skippy < 0 {
  12378. return ErrInvalidLengthTypes
  12379. }
  12380. if (iNdEx + skippy) < 0 {
  12381. return ErrInvalidLengthTypes
  12382. }
  12383. if (iNdEx + skippy) > l {
  12384. return io.ErrUnexpectedEOF
  12385. }
  12386. iNdEx += skippy
  12387. }
  12388. }
  12389. if iNdEx > l {
  12390. return io.ErrUnexpectedEOF
  12391. }
  12392. return nil
  12393. }
  12394. func (m *ConsensusParams) Unmarshal(dAtA []byte) error {
  12395. l := len(dAtA)
  12396. iNdEx := 0
  12397. for iNdEx < l {
  12398. preIndex := iNdEx
  12399. var wire uint64
  12400. for shift := uint(0); ; shift += 7 {
  12401. if shift >= 64 {
  12402. return ErrIntOverflowTypes
  12403. }
  12404. if iNdEx >= l {
  12405. return io.ErrUnexpectedEOF
  12406. }
  12407. b := dAtA[iNdEx]
  12408. iNdEx++
  12409. wire |= uint64(b&0x7F) << shift
  12410. if b < 0x80 {
  12411. break
  12412. }
  12413. }
  12414. fieldNum := int32(wire >> 3)
  12415. wireType := int(wire & 0x7)
  12416. if wireType == 4 {
  12417. return fmt.Errorf("proto: ConsensusParams: wiretype end group for non-group")
  12418. }
  12419. if fieldNum <= 0 {
  12420. return fmt.Errorf("proto: ConsensusParams: illegal tag %d (wire type %d)", fieldNum, wire)
  12421. }
  12422. switch fieldNum {
  12423. case 1:
  12424. if wireType != 2 {
  12425. return fmt.Errorf("proto: wrong wireType = %d for field Block", wireType)
  12426. }
  12427. var msglen int
  12428. for shift := uint(0); ; shift += 7 {
  12429. if shift >= 64 {
  12430. return ErrIntOverflowTypes
  12431. }
  12432. if iNdEx >= l {
  12433. return io.ErrUnexpectedEOF
  12434. }
  12435. b := dAtA[iNdEx]
  12436. iNdEx++
  12437. msglen |= int(b&0x7F) << shift
  12438. if b < 0x80 {
  12439. break
  12440. }
  12441. }
  12442. if msglen < 0 {
  12443. return ErrInvalidLengthTypes
  12444. }
  12445. postIndex := iNdEx + msglen
  12446. if postIndex < 0 {
  12447. return ErrInvalidLengthTypes
  12448. }
  12449. if postIndex > l {
  12450. return io.ErrUnexpectedEOF
  12451. }
  12452. if m.Block == nil {
  12453. m.Block = &BlockParams{}
  12454. }
  12455. if err := m.Block.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  12456. return err
  12457. }
  12458. iNdEx = postIndex
  12459. case 2:
  12460. if wireType != 2 {
  12461. return fmt.Errorf("proto: wrong wireType = %d for field Evidence", wireType)
  12462. }
  12463. var msglen int
  12464. for shift := uint(0); ; shift += 7 {
  12465. if shift >= 64 {
  12466. return ErrIntOverflowTypes
  12467. }
  12468. if iNdEx >= l {
  12469. return io.ErrUnexpectedEOF
  12470. }
  12471. b := dAtA[iNdEx]
  12472. iNdEx++
  12473. msglen |= int(b&0x7F) << shift
  12474. if b < 0x80 {
  12475. break
  12476. }
  12477. }
  12478. if msglen < 0 {
  12479. return ErrInvalidLengthTypes
  12480. }
  12481. postIndex := iNdEx + msglen
  12482. if postIndex < 0 {
  12483. return ErrInvalidLengthTypes
  12484. }
  12485. if postIndex > l {
  12486. return io.ErrUnexpectedEOF
  12487. }
  12488. if m.Evidence == nil {
  12489. m.Evidence = &types1.EvidenceParams{}
  12490. }
  12491. if err := m.Evidence.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  12492. return err
  12493. }
  12494. iNdEx = postIndex
  12495. case 3:
  12496. if wireType != 2 {
  12497. return fmt.Errorf("proto: wrong wireType = %d for field Validator", wireType)
  12498. }
  12499. var msglen int
  12500. for shift := uint(0); ; shift += 7 {
  12501. if shift >= 64 {
  12502. return ErrIntOverflowTypes
  12503. }
  12504. if iNdEx >= l {
  12505. return io.ErrUnexpectedEOF
  12506. }
  12507. b := dAtA[iNdEx]
  12508. iNdEx++
  12509. msglen |= int(b&0x7F) << shift
  12510. if b < 0x80 {
  12511. break
  12512. }
  12513. }
  12514. if msglen < 0 {
  12515. return ErrInvalidLengthTypes
  12516. }
  12517. postIndex := iNdEx + msglen
  12518. if postIndex < 0 {
  12519. return ErrInvalidLengthTypes
  12520. }
  12521. if postIndex > l {
  12522. return io.ErrUnexpectedEOF
  12523. }
  12524. if m.Validator == nil {
  12525. m.Validator = &types1.ValidatorParams{}
  12526. }
  12527. if err := m.Validator.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  12528. return err
  12529. }
  12530. iNdEx = postIndex
  12531. case 4:
  12532. if wireType != 2 {
  12533. return fmt.Errorf("proto: wrong wireType = %d for field Version", wireType)
  12534. }
  12535. var msglen int
  12536. for shift := uint(0); ; shift += 7 {
  12537. if shift >= 64 {
  12538. return ErrIntOverflowTypes
  12539. }
  12540. if iNdEx >= l {
  12541. return io.ErrUnexpectedEOF
  12542. }
  12543. b := dAtA[iNdEx]
  12544. iNdEx++
  12545. msglen |= int(b&0x7F) << shift
  12546. if b < 0x80 {
  12547. break
  12548. }
  12549. }
  12550. if msglen < 0 {
  12551. return ErrInvalidLengthTypes
  12552. }
  12553. postIndex := iNdEx + msglen
  12554. if postIndex < 0 {
  12555. return ErrInvalidLengthTypes
  12556. }
  12557. if postIndex > l {
  12558. return io.ErrUnexpectedEOF
  12559. }
  12560. if m.Version == nil {
  12561. m.Version = &types1.VersionParams{}
  12562. }
  12563. if err := m.Version.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  12564. return err
  12565. }
  12566. iNdEx = postIndex
  12567. default:
  12568. iNdEx = preIndex
  12569. skippy, err := skipTypes(dAtA[iNdEx:])
  12570. if err != nil {
  12571. return err
  12572. }
  12573. if skippy < 0 {
  12574. return ErrInvalidLengthTypes
  12575. }
  12576. if (iNdEx + skippy) < 0 {
  12577. return ErrInvalidLengthTypes
  12578. }
  12579. if (iNdEx + skippy) > l {
  12580. return io.ErrUnexpectedEOF
  12581. }
  12582. iNdEx += skippy
  12583. }
  12584. }
  12585. if iNdEx > l {
  12586. return io.ErrUnexpectedEOF
  12587. }
  12588. return nil
  12589. }
  12590. func (m *BlockParams) Unmarshal(dAtA []byte) error {
  12591. l := len(dAtA)
  12592. iNdEx := 0
  12593. for iNdEx < l {
  12594. preIndex := iNdEx
  12595. var wire uint64
  12596. for shift := uint(0); ; shift += 7 {
  12597. if shift >= 64 {
  12598. return ErrIntOverflowTypes
  12599. }
  12600. if iNdEx >= l {
  12601. return io.ErrUnexpectedEOF
  12602. }
  12603. b := dAtA[iNdEx]
  12604. iNdEx++
  12605. wire |= uint64(b&0x7F) << shift
  12606. if b < 0x80 {
  12607. break
  12608. }
  12609. }
  12610. fieldNum := int32(wire >> 3)
  12611. wireType := int(wire & 0x7)
  12612. if wireType == 4 {
  12613. return fmt.Errorf("proto: BlockParams: wiretype end group for non-group")
  12614. }
  12615. if fieldNum <= 0 {
  12616. return fmt.Errorf("proto: BlockParams: illegal tag %d (wire type %d)", fieldNum, wire)
  12617. }
  12618. switch fieldNum {
  12619. case 1:
  12620. if wireType != 0 {
  12621. return fmt.Errorf("proto: wrong wireType = %d for field MaxBytes", wireType)
  12622. }
  12623. m.MaxBytes = 0
  12624. for shift := uint(0); ; shift += 7 {
  12625. if shift >= 64 {
  12626. return ErrIntOverflowTypes
  12627. }
  12628. if iNdEx >= l {
  12629. return io.ErrUnexpectedEOF
  12630. }
  12631. b := dAtA[iNdEx]
  12632. iNdEx++
  12633. m.MaxBytes |= int64(b&0x7F) << shift
  12634. if b < 0x80 {
  12635. break
  12636. }
  12637. }
  12638. case 2:
  12639. if wireType != 0 {
  12640. return fmt.Errorf("proto: wrong wireType = %d for field MaxGas", wireType)
  12641. }
  12642. m.MaxGas = 0
  12643. for shift := uint(0); ; shift += 7 {
  12644. if shift >= 64 {
  12645. return ErrIntOverflowTypes
  12646. }
  12647. if iNdEx >= l {
  12648. return io.ErrUnexpectedEOF
  12649. }
  12650. b := dAtA[iNdEx]
  12651. iNdEx++
  12652. m.MaxGas |= int64(b&0x7F) << shift
  12653. if b < 0x80 {
  12654. break
  12655. }
  12656. }
  12657. default:
  12658. iNdEx = preIndex
  12659. skippy, err := skipTypes(dAtA[iNdEx:])
  12660. if err != nil {
  12661. return err
  12662. }
  12663. if skippy < 0 {
  12664. return ErrInvalidLengthTypes
  12665. }
  12666. if (iNdEx + skippy) < 0 {
  12667. return ErrInvalidLengthTypes
  12668. }
  12669. if (iNdEx + skippy) > l {
  12670. return io.ErrUnexpectedEOF
  12671. }
  12672. iNdEx += skippy
  12673. }
  12674. }
  12675. if iNdEx > l {
  12676. return io.ErrUnexpectedEOF
  12677. }
  12678. return nil
  12679. }
  12680. func (m *LastCommitInfo) Unmarshal(dAtA []byte) error {
  12681. l := len(dAtA)
  12682. iNdEx := 0
  12683. for iNdEx < l {
  12684. preIndex := iNdEx
  12685. var wire uint64
  12686. for shift := uint(0); ; shift += 7 {
  12687. if shift >= 64 {
  12688. return ErrIntOverflowTypes
  12689. }
  12690. if iNdEx >= l {
  12691. return io.ErrUnexpectedEOF
  12692. }
  12693. b := dAtA[iNdEx]
  12694. iNdEx++
  12695. wire |= uint64(b&0x7F) << shift
  12696. if b < 0x80 {
  12697. break
  12698. }
  12699. }
  12700. fieldNum := int32(wire >> 3)
  12701. wireType := int(wire & 0x7)
  12702. if wireType == 4 {
  12703. return fmt.Errorf("proto: LastCommitInfo: wiretype end group for non-group")
  12704. }
  12705. if fieldNum <= 0 {
  12706. return fmt.Errorf("proto: LastCommitInfo: illegal tag %d (wire type %d)", fieldNum, wire)
  12707. }
  12708. switch fieldNum {
  12709. case 1:
  12710. if wireType != 0 {
  12711. return fmt.Errorf("proto: wrong wireType = %d for field Round", wireType)
  12712. }
  12713. m.Round = 0
  12714. for shift := uint(0); ; shift += 7 {
  12715. if shift >= 64 {
  12716. return ErrIntOverflowTypes
  12717. }
  12718. if iNdEx >= l {
  12719. return io.ErrUnexpectedEOF
  12720. }
  12721. b := dAtA[iNdEx]
  12722. iNdEx++
  12723. m.Round |= int32(b&0x7F) << shift
  12724. if b < 0x80 {
  12725. break
  12726. }
  12727. }
  12728. case 2:
  12729. if wireType != 2 {
  12730. return fmt.Errorf("proto: wrong wireType = %d for field Votes", wireType)
  12731. }
  12732. var msglen int
  12733. for shift := uint(0); ; shift += 7 {
  12734. if shift >= 64 {
  12735. return ErrIntOverflowTypes
  12736. }
  12737. if iNdEx >= l {
  12738. return io.ErrUnexpectedEOF
  12739. }
  12740. b := dAtA[iNdEx]
  12741. iNdEx++
  12742. msglen |= int(b&0x7F) << shift
  12743. if b < 0x80 {
  12744. break
  12745. }
  12746. }
  12747. if msglen < 0 {
  12748. return ErrInvalidLengthTypes
  12749. }
  12750. postIndex := iNdEx + msglen
  12751. if postIndex < 0 {
  12752. return ErrInvalidLengthTypes
  12753. }
  12754. if postIndex > l {
  12755. return io.ErrUnexpectedEOF
  12756. }
  12757. m.Votes = append(m.Votes, VoteInfo{})
  12758. if err := m.Votes[len(m.Votes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  12759. return err
  12760. }
  12761. iNdEx = postIndex
  12762. default:
  12763. iNdEx = preIndex
  12764. skippy, err := skipTypes(dAtA[iNdEx:])
  12765. if err != nil {
  12766. return err
  12767. }
  12768. if skippy < 0 {
  12769. return ErrInvalidLengthTypes
  12770. }
  12771. if (iNdEx + skippy) < 0 {
  12772. return ErrInvalidLengthTypes
  12773. }
  12774. if (iNdEx + skippy) > l {
  12775. return io.ErrUnexpectedEOF
  12776. }
  12777. iNdEx += skippy
  12778. }
  12779. }
  12780. if iNdEx > l {
  12781. return io.ErrUnexpectedEOF
  12782. }
  12783. return nil
  12784. }
  12785. func (m *Event) Unmarshal(dAtA []byte) error {
  12786. l := len(dAtA)
  12787. iNdEx := 0
  12788. for iNdEx < l {
  12789. preIndex := iNdEx
  12790. var wire uint64
  12791. for shift := uint(0); ; shift += 7 {
  12792. if shift >= 64 {
  12793. return ErrIntOverflowTypes
  12794. }
  12795. if iNdEx >= l {
  12796. return io.ErrUnexpectedEOF
  12797. }
  12798. b := dAtA[iNdEx]
  12799. iNdEx++
  12800. wire |= uint64(b&0x7F) << shift
  12801. if b < 0x80 {
  12802. break
  12803. }
  12804. }
  12805. fieldNum := int32(wire >> 3)
  12806. wireType := int(wire & 0x7)
  12807. if wireType == 4 {
  12808. return fmt.Errorf("proto: Event: wiretype end group for non-group")
  12809. }
  12810. if fieldNum <= 0 {
  12811. return fmt.Errorf("proto: Event: illegal tag %d (wire type %d)", fieldNum, wire)
  12812. }
  12813. switch fieldNum {
  12814. case 1:
  12815. if wireType != 2 {
  12816. return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
  12817. }
  12818. var stringLen uint64
  12819. for shift := uint(0); ; shift += 7 {
  12820. if shift >= 64 {
  12821. return ErrIntOverflowTypes
  12822. }
  12823. if iNdEx >= l {
  12824. return io.ErrUnexpectedEOF
  12825. }
  12826. b := dAtA[iNdEx]
  12827. iNdEx++
  12828. stringLen |= uint64(b&0x7F) << shift
  12829. if b < 0x80 {
  12830. break
  12831. }
  12832. }
  12833. intStringLen := int(stringLen)
  12834. if intStringLen < 0 {
  12835. return ErrInvalidLengthTypes
  12836. }
  12837. postIndex := iNdEx + intStringLen
  12838. if postIndex < 0 {
  12839. return ErrInvalidLengthTypes
  12840. }
  12841. if postIndex > l {
  12842. return io.ErrUnexpectedEOF
  12843. }
  12844. m.Type = string(dAtA[iNdEx:postIndex])
  12845. iNdEx = postIndex
  12846. case 2:
  12847. if wireType != 2 {
  12848. return fmt.Errorf("proto: wrong wireType = %d for field Attributes", wireType)
  12849. }
  12850. var msglen int
  12851. for shift := uint(0); ; shift += 7 {
  12852. if shift >= 64 {
  12853. return ErrIntOverflowTypes
  12854. }
  12855. if iNdEx >= l {
  12856. return io.ErrUnexpectedEOF
  12857. }
  12858. b := dAtA[iNdEx]
  12859. iNdEx++
  12860. msglen |= int(b&0x7F) << shift
  12861. if b < 0x80 {
  12862. break
  12863. }
  12864. }
  12865. if msglen < 0 {
  12866. return ErrInvalidLengthTypes
  12867. }
  12868. postIndex := iNdEx + msglen
  12869. if postIndex < 0 {
  12870. return ErrInvalidLengthTypes
  12871. }
  12872. if postIndex > l {
  12873. return io.ErrUnexpectedEOF
  12874. }
  12875. m.Attributes = append(m.Attributes, EventAttribute{})
  12876. if err := m.Attributes[len(m.Attributes)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  12877. return err
  12878. }
  12879. iNdEx = postIndex
  12880. default:
  12881. iNdEx = preIndex
  12882. skippy, err := skipTypes(dAtA[iNdEx:])
  12883. if err != nil {
  12884. return err
  12885. }
  12886. if skippy < 0 {
  12887. return ErrInvalidLengthTypes
  12888. }
  12889. if (iNdEx + skippy) < 0 {
  12890. return ErrInvalidLengthTypes
  12891. }
  12892. if (iNdEx + skippy) > l {
  12893. return io.ErrUnexpectedEOF
  12894. }
  12895. iNdEx += skippy
  12896. }
  12897. }
  12898. if iNdEx > l {
  12899. return io.ErrUnexpectedEOF
  12900. }
  12901. return nil
  12902. }
  12903. func (m *EventAttribute) Unmarshal(dAtA []byte) error {
  12904. l := len(dAtA)
  12905. iNdEx := 0
  12906. for iNdEx < l {
  12907. preIndex := iNdEx
  12908. var wire uint64
  12909. for shift := uint(0); ; shift += 7 {
  12910. if shift >= 64 {
  12911. return ErrIntOverflowTypes
  12912. }
  12913. if iNdEx >= l {
  12914. return io.ErrUnexpectedEOF
  12915. }
  12916. b := dAtA[iNdEx]
  12917. iNdEx++
  12918. wire |= uint64(b&0x7F) << shift
  12919. if b < 0x80 {
  12920. break
  12921. }
  12922. }
  12923. fieldNum := int32(wire >> 3)
  12924. wireType := int(wire & 0x7)
  12925. if wireType == 4 {
  12926. return fmt.Errorf("proto: EventAttribute: wiretype end group for non-group")
  12927. }
  12928. if fieldNum <= 0 {
  12929. return fmt.Errorf("proto: EventAttribute: illegal tag %d (wire type %d)", fieldNum, wire)
  12930. }
  12931. switch fieldNum {
  12932. case 1:
  12933. if wireType != 2 {
  12934. return fmt.Errorf("proto: wrong wireType = %d for field Key", wireType)
  12935. }
  12936. var byteLen int
  12937. for shift := uint(0); ; shift += 7 {
  12938. if shift >= 64 {
  12939. return ErrIntOverflowTypes
  12940. }
  12941. if iNdEx >= l {
  12942. return io.ErrUnexpectedEOF
  12943. }
  12944. b := dAtA[iNdEx]
  12945. iNdEx++
  12946. byteLen |= int(b&0x7F) << shift
  12947. if b < 0x80 {
  12948. break
  12949. }
  12950. }
  12951. if byteLen < 0 {
  12952. return ErrInvalidLengthTypes
  12953. }
  12954. postIndex := iNdEx + byteLen
  12955. if postIndex < 0 {
  12956. return ErrInvalidLengthTypes
  12957. }
  12958. if postIndex > l {
  12959. return io.ErrUnexpectedEOF
  12960. }
  12961. m.Key = append(m.Key[:0], dAtA[iNdEx:postIndex]...)
  12962. if m.Key == nil {
  12963. m.Key = []byte{}
  12964. }
  12965. iNdEx = postIndex
  12966. case 2:
  12967. if wireType != 2 {
  12968. return fmt.Errorf("proto: wrong wireType = %d for field Value", wireType)
  12969. }
  12970. var byteLen int
  12971. for shift := uint(0); ; shift += 7 {
  12972. if shift >= 64 {
  12973. return ErrIntOverflowTypes
  12974. }
  12975. if iNdEx >= l {
  12976. return io.ErrUnexpectedEOF
  12977. }
  12978. b := dAtA[iNdEx]
  12979. iNdEx++
  12980. byteLen |= int(b&0x7F) << shift
  12981. if b < 0x80 {
  12982. break
  12983. }
  12984. }
  12985. if byteLen < 0 {
  12986. return ErrInvalidLengthTypes
  12987. }
  12988. postIndex := iNdEx + byteLen
  12989. if postIndex < 0 {
  12990. return ErrInvalidLengthTypes
  12991. }
  12992. if postIndex > l {
  12993. return io.ErrUnexpectedEOF
  12994. }
  12995. m.Value = append(m.Value[:0], dAtA[iNdEx:postIndex]...)
  12996. if m.Value == nil {
  12997. m.Value = []byte{}
  12998. }
  12999. iNdEx = postIndex
  13000. case 3:
  13001. if wireType != 0 {
  13002. return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType)
  13003. }
  13004. var v int
  13005. for shift := uint(0); ; shift += 7 {
  13006. if shift >= 64 {
  13007. return ErrIntOverflowTypes
  13008. }
  13009. if iNdEx >= l {
  13010. return io.ErrUnexpectedEOF
  13011. }
  13012. b := dAtA[iNdEx]
  13013. iNdEx++
  13014. v |= int(b&0x7F) << shift
  13015. if b < 0x80 {
  13016. break
  13017. }
  13018. }
  13019. m.Index = bool(v != 0)
  13020. default:
  13021. iNdEx = preIndex
  13022. skippy, err := skipTypes(dAtA[iNdEx:])
  13023. if err != nil {
  13024. return err
  13025. }
  13026. if skippy < 0 {
  13027. return ErrInvalidLengthTypes
  13028. }
  13029. if (iNdEx + skippy) < 0 {
  13030. return ErrInvalidLengthTypes
  13031. }
  13032. if (iNdEx + skippy) > l {
  13033. return io.ErrUnexpectedEOF
  13034. }
  13035. iNdEx += skippy
  13036. }
  13037. }
  13038. if iNdEx > l {
  13039. return io.ErrUnexpectedEOF
  13040. }
  13041. return nil
  13042. }
  13043. func (m *TxResult) Unmarshal(dAtA []byte) error {
  13044. l := len(dAtA)
  13045. iNdEx := 0
  13046. for iNdEx < l {
  13047. preIndex := iNdEx
  13048. var wire uint64
  13049. for shift := uint(0); ; shift += 7 {
  13050. if shift >= 64 {
  13051. return ErrIntOverflowTypes
  13052. }
  13053. if iNdEx >= l {
  13054. return io.ErrUnexpectedEOF
  13055. }
  13056. b := dAtA[iNdEx]
  13057. iNdEx++
  13058. wire |= uint64(b&0x7F) << shift
  13059. if b < 0x80 {
  13060. break
  13061. }
  13062. }
  13063. fieldNum := int32(wire >> 3)
  13064. wireType := int(wire & 0x7)
  13065. if wireType == 4 {
  13066. return fmt.Errorf("proto: TxResult: wiretype end group for non-group")
  13067. }
  13068. if fieldNum <= 0 {
  13069. return fmt.Errorf("proto: TxResult: illegal tag %d (wire type %d)", fieldNum, wire)
  13070. }
  13071. switch fieldNum {
  13072. case 1:
  13073. if wireType != 0 {
  13074. return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType)
  13075. }
  13076. m.Height = 0
  13077. for shift := uint(0); ; shift += 7 {
  13078. if shift >= 64 {
  13079. return ErrIntOverflowTypes
  13080. }
  13081. if iNdEx >= l {
  13082. return io.ErrUnexpectedEOF
  13083. }
  13084. b := dAtA[iNdEx]
  13085. iNdEx++
  13086. m.Height |= int64(b&0x7F) << shift
  13087. if b < 0x80 {
  13088. break
  13089. }
  13090. }
  13091. case 2:
  13092. if wireType != 0 {
  13093. return fmt.Errorf("proto: wrong wireType = %d for field Index", wireType)
  13094. }
  13095. m.Index = 0
  13096. for shift := uint(0); ; shift += 7 {
  13097. if shift >= 64 {
  13098. return ErrIntOverflowTypes
  13099. }
  13100. if iNdEx >= l {
  13101. return io.ErrUnexpectedEOF
  13102. }
  13103. b := dAtA[iNdEx]
  13104. iNdEx++
  13105. m.Index |= uint32(b&0x7F) << shift
  13106. if b < 0x80 {
  13107. break
  13108. }
  13109. }
  13110. case 3:
  13111. if wireType != 2 {
  13112. return fmt.Errorf("proto: wrong wireType = %d for field Tx", wireType)
  13113. }
  13114. var byteLen int
  13115. for shift := uint(0); ; shift += 7 {
  13116. if shift >= 64 {
  13117. return ErrIntOverflowTypes
  13118. }
  13119. if iNdEx >= l {
  13120. return io.ErrUnexpectedEOF
  13121. }
  13122. b := dAtA[iNdEx]
  13123. iNdEx++
  13124. byteLen |= int(b&0x7F) << shift
  13125. if b < 0x80 {
  13126. break
  13127. }
  13128. }
  13129. if byteLen < 0 {
  13130. return ErrInvalidLengthTypes
  13131. }
  13132. postIndex := iNdEx + byteLen
  13133. if postIndex < 0 {
  13134. return ErrInvalidLengthTypes
  13135. }
  13136. if postIndex > l {
  13137. return io.ErrUnexpectedEOF
  13138. }
  13139. m.Tx = append(m.Tx[:0], dAtA[iNdEx:postIndex]...)
  13140. if m.Tx == nil {
  13141. m.Tx = []byte{}
  13142. }
  13143. iNdEx = postIndex
  13144. case 4:
  13145. if wireType != 2 {
  13146. return fmt.Errorf("proto: wrong wireType = %d for field Result", wireType)
  13147. }
  13148. var msglen int
  13149. for shift := uint(0); ; shift += 7 {
  13150. if shift >= 64 {
  13151. return ErrIntOverflowTypes
  13152. }
  13153. if iNdEx >= l {
  13154. return io.ErrUnexpectedEOF
  13155. }
  13156. b := dAtA[iNdEx]
  13157. iNdEx++
  13158. msglen |= int(b&0x7F) << shift
  13159. if b < 0x80 {
  13160. break
  13161. }
  13162. }
  13163. if msglen < 0 {
  13164. return ErrInvalidLengthTypes
  13165. }
  13166. postIndex := iNdEx + msglen
  13167. if postIndex < 0 {
  13168. return ErrInvalidLengthTypes
  13169. }
  13170. if postIndex > l {
  13171. return io.ErrUnexpectedEOF
  13172. }
  13173. if err := m.Result.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  13174. return err
  13175. }
  13176. iNdEx = postIndex
  13177. default:
  13178. iNdEx = preIndex
  13179. skippy, err := skipTypes(dAtA[iNdEx:])
  13180. if err != nil {
  13181. return err
  13182. }
  13183. if skippy < 0 {
  13184. return ErrInvalidLengthTypes
  13185. }
  13186. if (iNdEx + skippy) < 0 {
  13187. return ErrInvalidLengthTypes
  13188. }
  13189. if (iNdEx + skippy) > l {
  13190. return io.ErrUnexpectedEOF
  13191. }
  13192. iNdEx += skippy
  13193. }
  13194. }
  13195. if iNdEx > l {
  13196. return io.ErrUnexpectedEOF
  13197. }
  13198. return nil
  13199. }
  13200. func (m *Validator) Unmarshal(dAtA []byte) error {
  13201. l := len(dAtA)
  13202. iNdEx := 0
  13203. for iNdEx < l {
  13204. preIndex := iNdEx
  13205. var wire uint64
  13206. for shift := uint(0); ; shift += 7 {
  13207. if shift >= 64 {
  13208. return ErrIntOverflowTypes
  13209. }
  13210. if iNdEx >= l {
  13211. return io.ErrUnexpectedEOF
  13212. }
  13213. b := dAtA[iNdEx]
  13214. iNdEx++
  13215. wire |= uint64(b&0x7F) << shift
  13216. if b < 0x80 {
  13217. break
  13218. }
  13219. }
  13220. fieldNum := int32(wire >> 3)
  13221. wireType := int(wire & 0x7)
  13222. if wireType == 4 {
  13223. return fmt.Errorf("proto: Validator: wiretype end group for non-group")
  13224. }
  13225. if fieldNum <= 0 {
  13226. return fmt.Errorf("proto: Validator: illegal tag %d (wire type %d)", fieldNum, wire)
  13227. }
  13228. switch fieldNum {
  13229. case 1:
  13230. if wireType != 2 {
  13231. return fmt.Errorf("proto: wrong wireType = %d for field Address", wireType)
  13232. }
  13233. var byteLen int
  13234. for shift := uint(0); ; shift += 7 {
  13235. if shift >= 64 {
  13236. return ErrIntOverflowTypes
  13237. }
  13238. if iNdEx >= l {
  13239. return io.ErrUnexpectedEOF
  13240. }
  13241. b := dAtA[iNdEx]
  13242. iNdEx++
  13243. byteLen |= int(b&0x7F) << shift
  13244. if b < 0x80 {
  13245. break
  13246. }
  13247. }
  13248. if byteLen < 0 {
  13249. return ErrInvalidLengthTypes
  13250. }
  13251. postIndex := iNdEx + byteLen
  13252. if postIndex < 0 {
  13253. return ErrInvalidLengthTypes
  13254. }
  13255. if postIndex > l {
  13256. return io.ErrUnexpectedEOF
  13257. }
  13258. m.Address = append(m.Address[:0], dAtA[iNdEx:postIndex]...)
  13259. if m.Address == nil {
  13260. m.Address = []byte{}
  13261. }
  13262. iNdEx = postIndex
  13263. case 3:
  13264. if wireType != 0 {
  13265. return fmt.Errorf("proto: wrong wireType = %d for field Power", wireType)
  13266. }
  13267. m.Power = 0
  13268. for shift := uint(0); ; shift += 7 {
  13269. if shift >= 64 {
  13270. return ErrIntOverflowTypes
  13271. }
  13272. if iNdEx >= l {
  13273. return io.ErrUnexpectedEOF
  13274. }
  13275. b := dAtA[iNdEx]
  13276. iNdEx++
  13277. m.Power |= int64(b&0x7F) << shift
  13278. if b < 0x80 {
  13279. break
  13280. }
  13281. }
  13282. default:
  13283. iNdEx = preIndex
  13284. skippy, err := skipTypes(dAtA[iNdEx:])
  13285. if err != nil {
  13286. return err
  13287. }
  13288. if skippy < 0 {
  13289. return ErrInvalidLengthTypes
  13290. }
  13291. if (iNdEx + skippy) < 0 {
  13292. return ErrInvalidLengthTypes
  13293. }
  13294. if (iNdEx + skippy) > l {
  13295. return io.ErrUnexpectedEOF
  13296. }
  13297. iNdEx += skippy
  13298. }
  13299. }
  13300. if iNdEx > l {
  13301. return io.ErrUnexpectedEOF
  13302. }
  13303. return nil
  13304. }
  13305. func (m *ValidatorUpdate) Unmarshal(dAtA []byte) error {
  13306. l := len(dAtA)
  13307. iNdEx := 0
  13308. for iNdEx < l {
  13309. preIndex := iNdEx
  13310. var wire uint64
  13311. for shift := uint(0); ; shift += 7 {
  13312. if shift >= 64 {
  13313. return ErrIntOverflowTypes
  13314. }
  13315. if iNdEx >= l {
  13316. return io.ErrUnexpectedEOF
  13317. }
  13318. b := dAtA[iNdEx]
  13319. iNdEx++
  13320. wire |= uint64(b&0x7F) << shift
  13321. if b < 0x80 {
  13322. break
  13323. }
  13324. }
  13325. fieldNum := int32(wire >> 3)
  13326. wireType := int(wire & 0x7)
  13327. if wireType == 4 {
  13328. return fmt.Errorf("proto: ValidatorUpdate: wiretype end group for non-group")
  13329. }
  13330. if fieldNum <= 0 {
  13331. return fmt.Errorf("proto: ValidatorUpdate: illegal tag %d (wire type %d)", fieldNum, wire)
  13332. }
  13333. switch fieldNum {
  13334. case 1:
  13335. if wireType != 2 {
  13336. return fmt.Errorf("proto: wrong wireType = %d for field PubKey", wireType)
  13337. }
  13338. var msglen int
  13339. for shift := uint(0); ; shift += 7 {
  13340. if shift >= 64 {
  13341. return ErrIntOverflowTypes
  13342. }
  13343. if iNdEx >= l {
  13344. return io.ErrUnexpectedEOF
  13345. }
  13346. b := dAtA[iNdEx]
  13347. iNdEx++
  13348. msglen |= int(b&0x7F) << shift
  13349. if b < 0x80 {
  13350. break
  13351. }
  13352. }
  13353. if msglen < 0 {
  13354. return ErrInvalidLengthTypes
  13355. }
  13356. postIndex := iNdEx + msglen
  13357. if postIndex < 0 {
  13358. return ErrInvalidLengthTypes
  13359. }
  13360. if postIndex > l {
  13361. return io.ErrUnexpectedEOF
  13362. }
  13363. if err := m.PubKey.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  13364. return err
  13365. }
  13366. iNdEx = postIndex
  13367. case 2:
  13368. if wireType != 0 {
  13369. return fmt.Errorf("proto: wrong wireType = %d for field Power", wireType)
  13370. }
  13371. m.Power = 0
  13372. for shift := uint(0); ; shift += 7 {
  13373. if shift >= 64 {
  13374. return ErrIntOverflowTypes
  13375. }
  13376. if iNdEx >= l {
  13377. return io.ErrUnexpectedEOF
  13378. }
  13379. b := dAtA[iNdEx]
  13380. iNdEx++
  13381. m.Power |= int64(b&0x7F) << shift
  13382. if b < 0x80 {
  13383. break
  13384. }
  13385. }
  13386. default:
  13387. iNdEx = preIndex
  13388. skippy, err := skipTypes(dAtA[iNdEx:])
  13389. if err != nil {
  13390. return err
  13391. }
  13392. if skippy < 0 {
  13393. return ErrInvalidLengthTypes
  13394. }
  13395. if (iNdEx + skippy) < 0 {
  13396. return ErrInvalidLengthTypes
  13397. }
  13398. if (iNdEx + skippy) > l {
  13399. return io.ErrUnexpectedEOF
  13400. }
  13401. iNdEx += skippy
  13402. }
  13403. }
  13404. if iNdEx > l {
  13405. return io.ErrUnexpectedEOF
  13406. }
  13407. return nil
  13408. }
  13409. func (m *VoteInfo) Unmarshal(dAtA []byte) error {
  13410. l := len(dAtA)
  13411. iNdEx := 0
  13412. for iNdEx < l {
  13413. preIndex := iNdEx
  13414. var wire uint64
  13415. for shift := uint(0); ; shift += 7 {
  13416. if shift >= 64 {
  13417. return ErrIntOverflowTypes
  13418. }
  13419. if iNdEx >= l {
  13420. return io.ErrUnexpectedEOF
  13421. }
  13422. b := dAtA[iNdEx]
  13423. iNdEx++
  13424. wire |= uint64(b&0x7F) << shift
  13425. if b < 0x80 {
  13426. break
  13427. }
  13428. }
  13429. fieldNum := int32(wire >> 3)
  13430. wireType := int(wire & 0x7)
  13431. if wireType == 4 {
  13432. return fmt.Errorf("proto: VoteInfo: wiretype end group for non-group")
  13433. }
  13434. if fieldNum <= 0 {
  13435. return fmt.Errorf("proto: VoteInfo: illegal tag %d (wire type %d)", fieldNum, wire)
  13436. }
  13437. switch fieldNum {
  13438. case 1:
  13439. if wireType != 2 {
  13440. return fmt.Errorf("proto: wrong wireType = %d for field Validator", wireType)
  13441. }
  13442. var msglen int
  13443. for shift := uint(0); ; shift += 7 {
  13444. if shift >= 64 {
  13445. return ErrIntOverflowTypes
  13446. }
  13447. if iNdEx >= l {
  13448. return io.ErrUnexpectedEOF
  13449. }
  13450. b := dAtA[iNdEx]
  13451. iNdEx++
  13452. msglen |= int(b&0x7F) << shift
  13453. if b < 0x80 {
  13454. break
  13455. }
  13456. }
  13457. if msglen < 0 {
  13458. return ErrInvalidLengthTypes
  13459. }
  13460. postIndex := iNdEx + msglen
  13461. if postIndex < 0 {
  13462. return ErrInvalidLengthTypes
  13463. }
  13464. if postIndex > l {
  13465. return io.ErrUnexpectedEOF
  13466. }
  13467. if err := m.Validator.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  13468. return err
  13469. }
  13470. iNdEx = postIndex
  13471. case 2:
  13472. if wireType != 0 {
  13473. return fmt.Errorf("proto: wrong wireType = %d for field SignedLastBlock", wireType)
  13474. }
  13475. var v int
  13476. for shift := uint(0); ; shift += 7 {
  13477. if shift >= 64 {
  13478. return ErrIntOverflowTypes
  13479. }
  13480. if iNdEx >= l {
  13481. return io.ErrUnexpectedEOF
  13482. }
  13483. b := dAtA[iNdEx]
  13484. iNdEx++
  13485. v |= int(b&0x7F) << shift
  13486. if b < 0x80 {
  13487. break
  13488. }
  13489. }
  13490. m.SignedLastBlock = bool(v != 0)
  13491. default:
  13492. iNdEx = preIndex
  13493. skippy, err := skipTypes(dAtA[iNdEx:])
  13494. if err != nil {
  13495. return err
  13496. }
  13497. if skippy < 0 {
  13498. return ErrInvalidLengthTypes
  13499. }
  13500. if (iNdEx + skippy) < 0 {
  13501. return ErrInvalidLengthTypes
  13502. }
  13503. if (iNdEx + skippy) > l {
  13504. return io.ErrUnexpectedEOF
  13505. }
  13506. iNdEx += skippy
  13507. }
  13508. }
  13509. if iNdEx > l {
  13510. return io.ErrUnexpectedEOF
  13511. }
  13512. return nil
  13513. }
  13514. func (m *Evidence) Unmarshal(dAtA []byte) error {
  13515. l := len(dAtA)
  13516. iNdEx := 0
  13517. for iNdEx < l {
  13518. preIndex := iNdEx
  13519. var wire uint64
  13520. for shift := uint(0); ; shift += 7 {
  13521. if shift >= 64 {
  13522. return ErrIntOverflowTypes
  13523. }
  13524. if iNdEx >= l {
  13525. return io.ErrUnexpectedEOF
  13526. }
  13527. b := dAtA[iNdEx]
  13528. iNdEx++
  13529. wire |= uint64(b&0x7F) << shift
  13530. if b < 0x80 {
  13531. break
  13532. }
  13533. }
  13534. fieldNum := int32(wire >> 3)
  13535. wireType := int(wire & 0x7)
  13536. if wireType == 4 {
  13537. return fmt.Errorf("proto: Evidence: wiretype end group for non-group")
  13538. }
  13539. if fieldNum <= 0 {
  13540. return fmt.Errorf("proto: Evidence: illegal tag %d (wire type %d)", fieldNum, wire)
  13541. }
  13542. switch fieldNum {
  13543. case 1:
  13544. if wireType != 0 {
  13545. return fmt.Errorf("proto: wrong wireType = %d for field Type", wireType)
  13546. }
  13547. m.Type = 0
  13548. for shift := uint(0); ; shift += 7 {
  13549. if shift >= 64 {
  13550. return ErrIntOverflowTypes
  13551. }
  13552. if iNdEx >= l {
  13553. return io.ErrUnexpectedEOF
  13554. }
  13555. b := dAtA[iNdEx]
  13556. iNdEx++
  13557. m.Type |= EvidenceType(b&0x7F) << shift
  13558. if b < 0x80 {
  13559. break
  13560. }
  13561. }
  13562. case 2:
  13563. if wireType != 2 {
  13564. return fmt.Errorf("proto: wrong wireType = %d for field Validator", wireType)
  13565. }
  13566. var msglen int
  13567. for shift := uint(0); ; shift += 7 {
  13568. if shift >= 64 {
  13569. return ErrIntOverflowTypes
  13570. }
  13571. if iNdEx >= l {
  13572. return io.ErrUnexpectedEOF
  13573. }
  13574. b := dAtA[iNdEx]
  13575. iNdEx++
  13576. msglen |= int(b&0x7F) << shift
  13577. if b < 0x80 {
  13578. break
  13579. }
  13580. }
  13581. if msglen < 0 {
  13582. return ErrInvalidLengthTypes
  13583. }
  13584. postIndex := iNdEx + msglen
  13585. if postIndex < 0 {
  13586. return ErrInvalidLengthTypes
  13587. }
  13588. if postIndex > l {
  13589. return io.ErrUnexpectedEOF
  13590. }
  13591. if err := m.Validator.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
  13592. return err
  13593. }
  13594. iNdEx = postIndex
  13595. case 3:
  13596. if wireType != 0 {
  13597. return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType)
  13598. }
  13599. m.Height = 0
  13600. for shift := uint(0); ; shift += 7 {
  13601. if shift >= 64 {
  13602. return ErrIntOverflowTypes
  13603. }
  13604. if iNdEx >= l {
  13605. return io.ErrUnexpectedEOF
  13606. }
  13607. b := dAtA[iNdEx]
  13608. iNdEx++
  13609. m.Height |= int64(b&0x7F) << shift
  13610. if b < 0x80 {
  13611. break
  13612. }
  13613. }
  13614. case 4:
  13615. if wireType != 2 {
  13616. return fmt.Errorf("proto: wrong wireType = %d for field Time", wireType)
  13617. }
  13618. var msglen int
  13619. for shift := uint(0); ; shift += 7 {
  13620. if shift >= 64 {
  13621. return ErrIntOverflowTypes
  13622. }
  13623. if iNdEx >= l {
  13624. return io.ErrUnexpectedEOF
  13625. }
  13626. b := dAtA[iNdEx]
  13627. iNdEx++
  13628. msglen |= int(b&0x7F) << shift
  13629. if b < 0x80 {
  13630. break
  13631. }
  13632. }
  13633. if msglen < 0 {
  13634. return ErrInvalidLengthTypes
  13635. }
  13636. postIndex := iNdEx + msglen
  13637. if postIndex < 0 {
  13638. return ErrInvalidLengthTypes
  13639. }
  13640. if postIndex > l {
  13641. return io.ErrUnexpectedEOF
  13642. }
  13643. if err := github_com_gogo_protobuf_types.StdTimeUnmarshal(&m.Time, dAtA[iNdEx:postIndex]); err != nil {
  13644. return err
  13645. }
  13646. iNdEx = postIndex
  13647. case 5:
  13648. if wireType != 0 {
  13649. return fmt.Errorf("proto: wrong wireType = %d for field TotalVotingPower", wireType)
  13650. }
  13651. m.TotalVotingPower = 0
  13652. for shift := uint(0); ; shift += 7 {
  13653. if shift >= 64 {
  13654. return ErrIntOverflowTypes
  13655. }
  13656. if iNdEx >= l {
  13657. return io.ErrUnexpectedEOF
  13658. }
  13659. b := dAtA[iNdEx]
  13660. iNdEx++
  13661. m.TotalVotingPower |= int64(b&0x7F) << shift
  13662. if b < 0x80 {
  13663. break
  13664. }
  13665. }
  13666. default:
  13667. iNdEx = preIndex
  13668. skippy, err := skipTypes(dAtA[iNdEx:])
  13669. if err != nil {
  13670. return err
  13671. }
  13672. if skippy < 0 {
  13673. return ErrInvalidLengthTypes
  13674. }
  13675. if (iNdEx + skippy) < 0 {
  13676. return ErrInvalidLengthTypes
  13677. }
  13678. if (iNdEx + skippy) > l {
  13679. return io.ErrUnexpectedEOF
  13680. }
  13681. iNdEx += skippy
  13682. }
  13683. }
  13684. if iNdEx > l {
  13685. return io.ErrUnexpectedEOF
  13686. }
  13687. return nil
  13688. }
  13689. func (m *Snapshot) Unmarshal(dAtA []byte) error {
  13690. l := len(dAtA)
  13691. iNdEx := 0
  13692. for iNdEx < l {
  13693. preIndex := iNdEx
  13694. var wire uint64
  13695. for shift := uint(0); ; shift += 7 {
  13696. if shift >= 64 {
  13697. return ErrIntOverflowTypes
  13698. }
  13699. if iNdEx >= l {
  13700. return io.ErrUnexpectedEOF
  13701. }
  13702. b := dAtA[iNdEx]
  13703. iNdEx++
  13704. wire |= uint64(b&0x7F) << shift
  13705. if b < 0x80 {
  13706. break
  13707. }
  13708. }
  13709. fieldNum := int32(wire >> 3)
  13710. wireType := int(wire & 0x7)
  13711. if wireType == 4 {
  13712. return fmt.Errorf("proto: Snapshot: wiretype end group for non-group")
  13713. }
  13714. if fieldNum <= 0 {
  13715. return fmt.Errorf("proto: Snapshot: illegal tag %d (wire type %d)", fieldNum, wire)
  13716. }
  13717. switch fieldNum {
  13718. case 1:
  13719. if wireType != 0 {
  13720. return fmt.Errorf("proto: wrong wireType = %d for field Height", wireType)
  13721. }
  13722. m.Height = 0
  13723. for shift := uint(0); ; shift += 7 {
  13724. if shift >= 64 {
  13725. return ErrIntOverflowTypes
  13726. }
  13727. if iNdEx >= l {
  13728. return io.ErrUnexpectedEOF
  13729. }
  13730. b := dAtA[iNdEx]
  13731. iNdEx++
  13732. m.Height |= uint64(b&0x7F) << shift
  13733. if b < 0x80 {
  13734. break
  13735. }
  13736. }
  13737. case 2:
  13738. if wireType != 0 {
  13739. return fmt.Errorf("proto: wrong wireType = %d for field Format", wireType)
  13740. }
  13741. m.Format = 0
  13742. for shift := uint(0); ; shift += 7 {
  13743. if shift >= 64 {
  13744. return ErrIntOverflowTypes
  13745. }
  13746. if iNdEx >= l {
  13747. return io.ErrUnexpectedEOF
  13748. }
  13749. b := dAtA[iNdEx]
  13750. iNdEx++
  13751. m.Format |= uint32(b&0x7F) << shift
  13752. if b < 0x80 {
  13753. break
  13754. }
  13755. }
  13756. case 3:
  13757. if wireType != 0 {
  13758. return fmt.Errorf("proto: wrong wireType = %d for field Chunks", wireType)
  13759. }
  13760. m.Chunks = 0
  13761. for shift := uint(0); ; shift += 7 {
  13762. if shift >= 64 {
  13763. return ErrIntOverflowTypes
  13764. }
  13765. if iNdEx >= l {
  13766. return io.ErrUnexpectedEOF
  13767. }
  13768. b := dAtA[iNdEx]
  13769. iNdEx++
  13770. m.Chunks |= uint32(b&0x7F) << shift
  13771. if b < 0x80 {
  13772. break
  13773. }
  13774. }
  13775. case 4:
  13776. if wireType != 2 {
  13777. return fmt.Errorf("proto: wrong wireType = %d for field Hash", wireType)
  13778. }
  13779. var byteLen int
  13780. for shift := uint(0); ; shift += 7 {
  13781. if shift >= 64 {
  13782. return ErrIntOverflowTypes
  13783. }
  13784. if iNdEx >= l {
  13785. return io.ErrUnexpectedEOF
  13786. }
  13787. b := dAtA[iNdEx]
  13788. iNdEx++
  13789. byteLen |= int(b&0x7F) << shift
  13790. if b < 0x80 {
  13791. break
  13792. }
  13793. }
  13794. if byteLen < 0 {
  13795. return ErrInvalidLengthTypes
  13796. }
  13797. postIndex := iNdEx + byteLen
  13798. if postIndex < 0 {
  13799. return ErrInvalidLengthTypes
  13800. }
  13801. if postIndex > l {
  13802. return io.ErrUnexpectedEOF
  13803. }
  13804. m.Hash = append(m.Hash[:0], dAtA[iNdEx:postIndex]...)
  13805. if m.Hash == nil {
  13806. m.Hash = []byte{}
  13807. }
  13808. iNdEx = postIndex
  13809. case 5:
  13810. if wireType != 2 {
  13811. return fmt.Errorf("proto: wrong wireType = %d for field Metadata", wireType)
  13812. }
  13813. var byteLen int
  13814. for shift := uint(0); ; shift += 7 {
  13815. if shift >= 64 {
  13816. return ErrIntOverflowTypes
  13817. }
  13818. if iNdEx >= l {
  13819. return io.ErrUnexpectedEOF
  13820. }
  13821. b := dAtA[iNdEx]
  13822. iNdEx++
  13823. byteLen |= int(b&0x7F) << shift
  13824. if b < 0x80 {
  13825. break
  13826. }
  13827. }
  13828. if byteLen < 0 {
  13829. return ErrInvalidLengthTypes
  13830. }
  13831. postIndex := iNdEx + byteLen
  13832. if postIndex < 0 {
  13833. return ErrInvalidLengthTypes
  13834. }
  13835. if postIndex > l {
  13836. return io.ErrUnexpectedEOF
  13837. }
  13838. m.Metadata = append(m.Metadata[:0], dAtA[iNdEx:postIndex]...)
  13839. if m.Metadata == nil {
  13840. m.Metadata = []byte{}
  13841. }
  13842. iNdEx = postIndex
  13843. default:
  13844. iNdEx = preIndex
  13845. skippy, err := skipTypes(dAtA[iNdEx:])
  13846. if err != nil {
  13847. return err
  13848. }
  13849. if skippy < 0 {
  13850. return ErrInvalidLengthTypes
  13851. }
  13852. if (iNdEx + skippy) < 0 {
  13853. return ErrInvalidLengthTypes
  13854. }
  13855. if (iNdEx + skippy) > l {
  13856. return io.ErrUnexpectedEOF
  13857. }
  13858. iNdEx += skippy
  13859. }
  13860. }
  13861. if iNdEx > l {
  13862. return io.ErrUnexpectedEOF
  13863. }
  13864. return nil
  13865. }
  13866. func skipTypes(dAtA []byte) (n int, err error) {
  13867. l := len(dAtA)
  13868. iNdEx := 0
  13869. depth := 0
  13870. for iNdEx < l {
  13871. var wire uint64
  13872. for shift := uint(0); ; shift += 7 {
  13873. if shift >= 64 {
  13874. return 0, ErrIntOverflowTypes
  13875. }
  13876. if iNdEx >= l {
  13877. return 0, io.ErrUnexpectedEOF
  13878. }
  13879. b := dAtA[iNdEx]
  13880. iNdEx++
  13881. wire |= (uint64(b) & 0x7F) << shift
  13882. if b < 0x80 {
  13883. break
  13884. }
  13885. }
  13886. wireType := int(wire & 0x7)
  13887. switch wireType {
  13888. case 0:
  13889. for shift := uint(0); ; shift += 7 {
  13890. if shift >= 64 {
  13891. return 0, ErrIntOverflowTypes
  13892. }
  13893. if iNdEx >= l {
  13894. return 0, io.ErrUnexpectedEOF
  13895. }
  13896. iNdEx++
  13897. if dAtA[iNdEx-1] < 0x80 {
  13898. break
  13899. }
  13900. }
  13901. case 1:
  13902. iNdEx += 8
  13903. case 2:
  13904. var length int
  13905. for shift := uint(0); ; shift += 7 {
  13906. if shift >= 64 {
  13907. return 0, ErrIntOverflowTypes
  13908. }
  13909. if iNdEx >= l {
  13910. return 0, io.ErrUnexpectedEOF
  13911. }
  13912. b := dAtA[iNdEx]
  13913. iNdEx++
  13914. length |= (int(b) & 0x7F) << shift
  13915. if b < 0x80 {
  13916. break
  13917. }
  13918. }
  13919. if length < 0 {
  13920. return 0, ErrInvalidLengthTypes
  13921. }
  13922. iNdEx += length
  13923. case 3:
  13924. depth++
  13925. case 4:
  13926. if depth == 0 {
  13927. return 0, ErrUnexpectedEndOfGroupTypes
  13928. }
  13929. depth--
  13930. case 5:
  13931. iNdEx += 4
  13932. default:
  13933. return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
  13934. }
  13935. if iNdEx < 0 {
  13936. return 0, ErrInvalidLengthTypes
  13937. }
  13938. if depth == 0 {
  13939. return iNdEx, nil
  13940. }
  13941. }
  13942. return 0, io.ErrUnexpectedEOF
  13943. }
  13944. var (
  13945. ErrInvalidLengthTypes = fmt.Errorf("proto: negative length found during unmarshaling")
  13946. ErrIntOverflowTypes = fmt.Errorf("proto: integer overflow")
  13947. ErrUnexpectedEndOfGroupTypes = fmt.Errorf("proto: unexpected end of group")
  13948. )