## Description these proto files are meant to help unblock ibc in their quest of migrating the ibc module to proto. Closes: #XXXpull/4878/head
@ -0,0 +1,75 @@ | |||
package encoding | |||
import ( | |||
"errors" | |||
"fmt" | |||
"github.com/tendermint/tendermint/crypto" | |||
"github.com/tendermint/tendermint/crypto/ed25519" | |||
pc "github.com/tendermint/tendermint/proto/crypto/keys" | |||
) | |||
// PubKeyToProto takes crypto.PubKey and transforms it to a protobuf Pubkey | |||
func PubKeyToProto(k crypto.PubKey) (pc.PublicKey, error) { | |||
var kp pc.PublicKey | |||
switch k := k.(type) { | |||
case ed25519.PubKeyEd25519: | |||
kp = pc.PublicKey{ | |||
Sum: &pc.PublicKey_Ed25519{ | |||
Ed25519: k[:], | |||
}, | |||
} | |||
default: | |||
return kp, fmt.Errorf("toproto: key type %v is not supported", k) | |||
} | |||
return kp, nil | |||
} | |||
// PubKeyFromProto takes a protobuf Pubkey and transforms it to a crypto.Pubkey | |||
func PubKeyFromProto(k pc.PublicKey) (crypto.PubKey, error) { | |||
switch k := k.Sum.(type) { | |||
case *pc.PublicKey_Ed25519: | |||
if len(k.Ed25519) != ed25519.PubKeyEd25519Size { | |||
return nil, fmt.Errorf("invalid size for PubKeyEd25519. Got %d, expected %d", | |||
len(k.Ed25519), ed25519.PubKeyEd25519Size) | |||
} | |||
var pk ed25519.PubKeyEd25519 | |||
copy(pk[:], k.Ed25519) | |||
return pk, nil | |||
default: | |||
return nil, fmt.Errorf("fromproto: key type %v is not supported", k) | |||
} | |||
} | |||
// PrivKeyToProto takes crypto.PrivKey and transforms it to a protobuf PrivKey | |||
func PrivKeyToProto(k crypto.PrivKey) (pc.PrivateKey, error) { | |||
var kp pc.PrivateKey | |||
switch k := k.(type) { | |||
case ed25519.PrivKeyEd25519: | |||
kp = pc.PrivateKey{ | |||
Sum: &pc.PrivateKey_Ed25519{ | |||
Ed25519: k[:], | |||
}, | |||
} | |||
default: | |||
return kp, errors.New("toproto: key type is not supported") | |||
} | |||
return kp, nil | |||
} | |||
// PrivKeyFromProto takes a protobuf PrivateKey and transforms it to a crypto.PrivKey | |||
func PrivKeyFromProto(k pc.PrivateKey) (crypto.PrivKey, error) { | |||
switch k := k.Sum.(type) { | |||
case *pc.PrivateKey_Ed25519: | |||
if len(k.Ed25519) != ed25519.PubKeyEd25519Size { | |||
return nil, fmt.Errorf("invalid size for PubKeyEd25519. Got %d, expected %d", | |||
len(k.Ed25519), ed25519.PubKeyEd25519Size) | |||
} | |||
var pk ed25519.PrivKeyEd25519 | |||
copy(pk[:], k.Ed25519) | |||
return pk, nil | |||
default: | |||
return nil, errors.New("fromproto: key type not supported") | |||
} | |||
} |
@ -0,0 +1,389 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/blockchain/msgs.proto | |||
package blockchain | |||
import ( | |||
fmt "fmt" | |||
_ "github.com/gogo/protobuf/gogoproto" | |||
proto "github.com/gogo/protobuf/proto" | |||
types "github.com/tendermint/tendermint/proto/types" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
// BlockRequest requests a block for a specific height | |||
type BlockRequest struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *BlockRequest) Reset() { *m = BlockRequest{} } | |||
func (m *BlockRequest) String() string { return proto.CompactTextString(m) } | |||
func (*BlockRequest) ProtoMessage() {} | |||
func (*BlockRequest) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_ecf660069f8bb334, []int{0} | |||
} | |||
func (m *BlockRequest) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_BlockRequest.Unmarshal(m, b) | |||
} | |||
func (m *BlockRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_BlockRequest.Marshal(b, m, deterministic) | |||
} | |||
func (m *BlockRequest) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_BlockRequest.Merge(m, src) | |||
} | |||
func (m *BlockRequest) XXX_Size() int { | |||
return xxx_messageInfo_BlockRequest.Size(m) | |||
} | |||
func (m *BlockRequest) XXX_DiscardUnknown() { | |||
xxx_messageInfo_BlockRequest.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_BlockRequest proto.InternalMessageInfo | |||
func (m *BlockRequest) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
// NoBlockResponse informs the node that the peer does not have block at the requested height | |||
type NoBlockResponse struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *NoBlockResponse) Reset() { *m = NoBlockResponse{} } | |||
func (m *NoBlockResponse) String() string { return proto.CompactTextString(m) } | |||
func (*NoBlockResponse) ProtoMessage() {} | |||
func (*NoBlockResponse) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_ecf660069f8bb334, []int{1} | |||
} | |||
func (m *NoBlockResponse) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_NoBlockResponse.Unmarshal(m, b) | |||
} | |||
func (m *NoBlockResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_NoBlockResponse.Marshal(b, m, deterministic) | |||
} | |||
func (m *NoBlockResponse) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_NoBlockResponse.Merge(m, src) | |||
} | |||
func (m *NoBlockResponse) XXX_Size() int { | |||
return xxx_messageInfo_NoBlockResponse.Size(m) | |||
} | |||
func (m *NoBlockResponse) XXX_DiscardUnknown() { | |||
xxx_messageInfo_NoBlockResponse.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_NoBlockResponse proto.InternalMessageInfo | |||
func (m *NoBlockResponse) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
// BlockResponse returns block to the requested | |||
type BlockResponse struct { | |||
Block types.Block `protobuf:"bytes,1,opt,name=block,proto3" json:"block"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *BlockResponse) Reset() { *m = BlockResponse{} } | |||
func (m *BlockResponse) String() string { return proto.CompactTextString(m) } | |||
func (*BlockResponse) ProtoMessage() {} | |||
func (*BlockResponse) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_ecf660069f8bb334, []int{2} | |||
} | |||
func (m *BlockResponse) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_BlockResponse.Unmarshal(m, b) | |||
} | |||
func (m *BlockResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_BlockResponse.Marshal(b, m, deterministic) | |||
} | |||
func (m *BlockResponse) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_BlockResponse.Merge(m, src) | |||
} | |||
func (m *BlockResponse) XXX_Size() int { | |||
return xxx_messageInfo_BlockResponse.Size(m) | |||
} | |||
func (m *BlockResponse) XXX_DiscardUnknown() { | |||
xxx_messageInfo_BlockResponse.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_BlockResponse proto.InternalMessageInfo | |||
func (m *BlockResponse) GetBlock() types.Block { | |||
if m != nil { | |||
return m.Block | |||
} | |||
return types.Block{} | |||
} | |||
// StatusRequest requests the status of a node (Height & Base) | |||
type StatusRequest struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Base int64 `protobuf:"varint,2,opt,name=base,proto3" json:"base,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *StatusRequest) Reset() { *m = StatusRequest{} } | |||
func (m *StatusRequest) String() string { return proto.CompactTextString(m) } | |||
func (*StatusRequest) ProtoMessage() {} | |||
func (*StatusRequest) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_ecf660069f8bb334, []int{3} | |||
} | |||
func (m *StatusRequest) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_StatusRequest.Unmarshal(m, b) | |||
} | |||
func (m *StatusRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_StatusRequest.Marshal(b, m, deterministic) | |||
} | |||
func (m *StatusRequest) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_StatusRequest.Merge(m, src) | |||
} | |||
func (m *StatusRequest) XXX_Size() int { | |||
return xxx_messageInfo_StatusRequest.Size(m) | |||
} | |||
func (m *StatusRequest) XXX_DiscardUnknown() { | |||
xxx_messageInfo_StatusRequest.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_StatusRequest proto.InternalMessageInfo | |||
func (m *StatusRequest) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *StatusRequest) GetBase() int64 { | |||
if m != nil { | |||
return m.Base | |||
} | |||
return 0 | |||
} | |||
// StatusResponse is a peer response to infrom their status | |||
type StatusResponse struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Base int64 `protobuf:"varint,2,opt,name=base,proto3" json:"base,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *StatusResponse) Reset() { *m = StatusResponse{} } | |||
func (m *StatusResponse) String() string { return proto.CompactTextString(m) } | |||
func (*StatusResponse) ProtoMessage() {} | |||
func (*StatusResponse) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_ecf660069f8bb334, []int{4} | |||
} | |||
func (m *StatusResponse) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_StatusResponse.Unmarshal(m, b) | |||
} | |||
func (m *StatusResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_StatusResponse.Marshal(b, m, deterministic) | |||
} | |||
func (m *StatusResponse) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_StatusResponse.Merge(m, src) | |||
} | |||
func (m *StatusResponse) XXX_Size() int { | |||
return xxx_messageInfo_StatusResponse.Size(m) | |||
} | |||
func (m *StatusResponse) XXX_DiscardUnknown() { | |||
xxx_messageInfo_StatusResponse.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_StatusResponse proto.InternalMessageInfo | |||
func (m *StatusResponse) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *StatusResponse) GetBase() int64 { | |||
if m != nil { | |||
return m.Base | |||
} | |||
return 0 | |||
} | |||
type Message struct { | |||
// Types that are valid to be assigned to Sum: | |||
// *Message_BlockRequest | |||
// *Message_NoBlockResponse | |||
// *Message_BlockResponse | |||
// *Message_StatusRequest | |||
// *Message_StatusResponse | |||
Sum isMessage_Sum `protobuf_oneof:"sum"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *Message) Reset() { *m = Message{} } | |||
func (m *Message) String() string { return proto.CompactTextString(m) } | |||
func (*Message) ProtoMessage() {} | |||
func (*Message) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_ecf660069f8bb334, []int{5} | |||
} | |||
func (m *Message) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_Message.Unmarshal(m, b) | |||
} | |||
func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_Message.Marshal(b, m, deterministic) | |||
} | |||
func (m *Message) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_Message.Merge(m, src) | |||
} | |||
func (m *Message) XXX_Size() int { | |||
return xxx_messageInfo_Message.Size(m) | |||
} | |||
func (m *Message) XXX_DiscardUnknown() { | |||
xxx_messageInfo_Message.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_Message proto.InternalMessageInfo | |||
type isMessage_Sum interface { | |||
isMessage_Sum() | |||
} | |||
type Message_BlockRequest struct { | |||
BlockRequest *BlockRequest `protobuf:"bytes,1,opt,name=block_request,json=blockRequest,proto3,oneof" json:"block_request,omitempty"` | |||
} | |||
type Message_NoBlockResponse struct { | |||
NoBlockResponse *NoBlockResponse `protobuf:"bytes,2,opt,name=no_block_response,json=noBlockResponse,proto3,oneof" json:"no_block_response,omitempty"` | |||
} | |||
type Message_BlockResponse struct { | |||
BlockResponse *BlockResponse `protobuf:"bytes,3,opt,name=block_response,json=blockResponse,proto3,oneof" json:"block_response,omitempty"` | |||
} | |||
type Message_StatusRequest struct { | |||
StatusRequest *StatusRequest `protobuf:"bytes,4,opt,name=status_request,json=statusRequest,proto3,oneof" json:"status_request,omitempty"` | |||
} | |||
type Message_StatusResponse struct { | |||
StatusResponse *StatusResponse `protobuf:"bytes,5,opt,name=status_response,json=statusResponse,proto3,oneof" json:"status_response,omitempty"` | |||
} | |||
func (*Message_BlockRequest) isMessage_Sum() {} | |||
func (*Message_NoBlockResponse) isMessage_Sum() {} | |||
func (*Message_BlockResponse) isMessage_Sum() {} | |||
func (*Message_StatusRequest) isMessage_Sum() {} | |||
func (*Message_StatusResponse) isMessage_Sum() {} | |||
func (m *Message) GetSum() isMessage_Sum { | |||
if m != nil { | |||
return m.Sum | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetBlockRequest() *BlockRequest { | |||
if x, ok := m.GetSum().(*Message_BlockRequest); ok { | |||
return x.BlockRequest | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetNoBlockResponse() *NoBlockResponse { | |||
if x, ok := m.GetSum().(*Message_NoBlockResponse); ok { | |||
return x.NoBlockResponse | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetBlockResponse() *BlockResponse { | |||
if x, ok := m.GetSum().(*Message_BlockResponse); ok { | |||
return x.BlockResponse | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetStatusRequest() *StatusRequest { | |||
if x, ok := m.GetSum().(*Message_StatusRequest); ok { | |||
return x.StatusRequest | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetStatusResponse() *StatusResponse { | |||
if x, ok := m.GetSum().(*Message_StatusResponse); ok { | |||
return x.StatusResponse | |||
} | |||
return nil | |||
} | |||
// XXX_OneofWrappers is for the internal use of the proto package. | |||
func (*Message) XXX_OneofWrappers() []interface{} { | |||
return []interface{}{ | |||
(*Message_BlockRequest)(nil), | |||
(*Message_NoBlockResponse)(nil), | |||
(*Message_BlockResponse)(nil), | |||
(*Message_StatusRequest)(nil), | |||
(*Message_StatusResponse)(nil), | |||
} | |||
} | |||
func init() { | |||
proto.RegisterType((*BlockRequest)(nil), "tendermint.proto.blockchain.BlockRequest") | |||
proto.RegisterType((*NoBlockResponse)(nil), "tendermint.proto.blockchain.NoBlockResponse") | |||
proto.RegisterType((*BlockResponse)(nil), "tendermint.proto.blockchain.BlockResponse") | |||
proto.RegisterType((*StatusRequest)(nil), "tendermint.proto.blockchain.StatusRequest") | |||
proto.RegisterType((*StatusResponse)(nil), "tendermint.proto.blockchain.StatusResponse") | |||
proto.RegisterType((*Message)(nil), "tendermint.proto.blockchain.Message") | |||
} | |||
func init() { proto.RegisterFile("proto/blockchain/msgs.proto", fileDescriptor_ecf660069f8bb334) } | |||
var fileDescriptor_ecf660069f8bb334 = []byte{ | |||
// 369 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x8c, 0x93, 0xc1, 0x4e, 0xc2, 0x40, | |||
0x10, 0x86, 0xc1, 0x02, 0x26, 0x03, 0x85, 0xd8, 0x83, 0x12, 0x88, 0xd1, 0xf4, 0x40, 0x44, 0xcd, | |||
0x36, 0xc2, 0xc9, 0xe8, 0xa9, 0x27, 0x62, 0xa2, 0x31, 0x25, 0xf1, 0xc0, 0x85, 0xb4, 0xb0, 0x69, | |||
0x1b, 0x6d, 0xb7, 0x76, 0xb6, 0x07, 0xde, 0xce, 0xa3, 0x4f, 0xe1, 0xb3, 0x18, 0x76, 0x4b, 0xa1, | |||
0x55, 0xb1, 0xb7, 0xdd, 0xbf, 0x33, 0xdf, 0xfc, 0x3b, 0x7f, 0x0a, 0xfd, 0x28, 0x66, 0x9c, 0x19, | |||
0xce, 0x1b, 0x5b, 0xbc, 0x2e, 0x3c, 0xdb, 0x0f, 0x8d, 0x00, 0x5d, 0x24, 0x42, 0xd5, 0xfa, 0x9c, | |||
0x86, 0x4b, 0x1a, 0x07, 0x7e, 0xc8, 0xa5, 0x42, 0xb6, 0x75, 0xbd, 0x01, 0xf7, 0xfc, 0x78, 0x39, | |||
0x8f, 0xec, 0x98, 0xaf, 0x0c, 0x49, 0x71, 0x99, 0xcb, 0xb6, 0x27, 0xd9, 0xd2, 0x3b, 0x91, 0x0a, | |||
0x5f, 0x45, 0x14, 0xe5, 0x1c, 0xf9, 0x41, 0x1f, 0x40, 0xcb, 0x5c, 0x5f, 0x2d, 0xfa, 0x9e, 0x50, | |||
0xe4, 0xda, 0x31, 0x34, 0x3c, 0xea, 0xbb, 0x1e, 0xef, 0x56, 0xcf, 0xab, 0x17, 0x8a, 0x95, 0xde, | |||
0xf4, 0x21, 0x74, 0x9e, 0x58, 0x5a, 0x89, 0x11, 0x0b, 0x91, 0xfe, 0x59, 0xfa, 0x00, 0x6a, 0xbe, | |||
0xf0, 0x16, 0xea, 0x62, 0xa4, 0xa8, 0x6b, 0x8e, 0x4e, 0xc9, 0x8f, 0x17, 0x09, 0x5f, 0x44, 0x74, | |||
0x99, 0xb5, 0xcf, 0xaf, 0xb3, 0x8a, 0x25, 0x3b, 0xf4, 0x3b, 0x50, 0xa7, 0xdc, 0xe6, 0x09, 0xfe, | |||
0xe3, 0x4f, 0xd3, 0xa0, 0xe6, 0xd8, 0x48, 0xbb, 0x07, 0x42, 0x15, 0x67, 0xfd, 0x1e, 0xda, 0x9b, | |||
0xe6, 0xfd, 0x96, 0x7f, 0xed, 0xfe, 0x50, 0xe0, 0xf0, 0x91, 0x22, 0xda, 0x2e, 0xd5, 0x9e, 0x41, | |||
0x15, 0x7e, 0xe6, 0xb1, 0xb4, 0x91, 0xbe, 0x64, 0x48, 0xf6, 0x64, 0x43, 0x76, 0xf7, 0x3a, 0xa9, | |||
0x58, 0x2d, 0x67, 0x77, 0xcf, 0x33, 0x38, 0x0a, 0xd9, 0x7c, 0x03, 0x95, 0xf6, 0xc4, 0xf8, 0xe6, | |||
0xe8, 0x7a, 0x2f, 0xb5, 0x90, 0xc2, 0xa4, 0x62, 0x75, 0xc2, 0x42, 0x30, 0x53, 0x68, 0x17, 0xc0, | |||
0x8a, 0x00, 0x5f, 0x96, 0xb1, 0x9b, 0x61, 0x55, 0xa7, 0x08, 0x45, 0xb1, 0xcc, 0x6c, 0x07, 0xb5, | |||
0x12, 0xd0, 0x5c, 0x78, 0x6b, 0x28, 0xe6, 0xd2, 0x7c, 0x81, 0x4e, 0x06, 0x4d, 0xad, 0xd6, 0x05, | |||
0xf5, 0xaa, 0x14, 0x35, 0xf3, 0xda, 0xc6, 0x9c, 0x62, 0xd6, 0x41, 0xc1, 0x24, 0x30, 0xc7, 0xb3, | |||
0x1b, 0xd7, 0xe7, 0x5e, 0xe2, 0x90, 0x05, 0x0b, 0x8c, 0x2d, 0x71, 0xf7, 0x58, 0xfc, 0xf5, 0x9c, | |||
0x86, 0x50, 0xc6, 0xdf, 0x01, 0x00, 0x00, 0xff, 0xff, 0xb8, 0xb9, 0x72, 0x28, 0x95, 0x03, 0x00, | |||
0x00, | |||
} |
@ -0,0 +1,44 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.blockchain; | |||
option go_package = "github.com/tendermint/tendermint/proto/blockchain"; | |||
import "third_party/proto/gogoproto/gogo.proto"; | |||
import "proto/types/block.proto"; | |||
// BlockRequest requests a block for a specific height | |||
message BlockRequest { | |||
int64 height = 1; | |||
} | |||
// NoBlockResponse informs the node that the peer does not have block at the requested height | |||
message NoBlockResponse { | |||
int64 height = 1; | |||
} | |||
// BlockResponse returns block to the requested | |||
message BlockResponse { | |||
tendermint.proto.types.Block block = 1 [(gogoproto.nullable) = false]; | |||
} | |||
// StatusRequest requests the status of a node (Height & Base) | |||
message StatusRequest { | |||
int64 height = 1; | |||
int64 base = 2; | |||
} | |||
// StatusResponse is a peer response to infrom their status | |||
message StatusResponse { | |||
int64 height = 1; | |||
int64 base = 2; | |||
} | |||
message Message { | |||
oneof sum { | |||
BlockRequest block_request = 1; | |||
NoBlockResponse no_block_response = 2; | |||
BlockResponse block_response = 3; | |||
StatusRequest status_request = 4; | |||
StatusResponse status_response = 5; | |||
} | |||
} |
@ -0,0 +1,794 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/consensus/msgs.proto | |||
package consensus | |||
import ( | |||
fmt "fmt" | |||
_ "github.com/gogo/protobuf/gogoproto" | |||
proto "github.com/gogo/protobuf/proto" | |||
bits "github.com/tendermint/tendermint/proto/libs/bits" | |||
types "github.com/tendermint/tendermint/proto/types" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
// NewRoundStepMessage is sent for every step taken in the ConsensusState. | |||
// For every height/round/step transition | |||
type NewRoundStep struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Round int32 `protobuf:"varint,2,opt,name=round,proto3" json:"round,omitempty"` | |||
Step uint32 `protobuf:"varint,3,opt,name=step,proto3" json:"step,omitempty"` | |||
SecondsSinceStartTime int64 `protobuf:"varint,4,opt,name=seconds_since_start_time,json=secondsSinceStartTime,proto3" json:"seconds_since_start_time,omitempty"` | |||
LastCommitRound int32 `protobuf:"varint,5,opt,name=last_commit_round,json=lastCommitRound,proto3" json:"last_commit_round,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *NewRoundStep) Reset() { *m = NewRoundStep{} } | |||
func (m *NewRoundStep) String() string { return proto.CompactTextString(m) } | |||
func (*NewRoundStep) ProtoMessage() {} | |||
func (*NewRoundStep) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{0} | |||
} | |||
func (m *NewRoundStep) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_NewRoundStep.Unmarshal(m, b) | |||
} | |||
func (m *NewRoundStep) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_NewRoundStep.Marshal(b, m, deterministic) | |||
} | |||
func (m *NewRoundStep) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_NewRoundStep.Merge(m, src) | |||
} | |||
func (m *NewRoundStep) XXX_Size() int { | |||
return xxx_messageInfo_NewRoundStep.Size(m) | |||
} | |||
func (m *NewRoundStep) XXX_DiscardUnknown() { | |||
xxx_messageInfo_NewRoundStep.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_NewRoundStep proto.InternalMessageInfo | |||
func (m *NewRoundStep) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *NewRoundStep) GetRound() int32 { | |||
if m != nil { | |||
return m.Round | |||
} | |||
return 0 | |||
} | |||
func (m *NewRoundStep) GetStep() uint32 { | |||
if m != nil { | |||
return m.Step | |||
} | |||
return 0 | |||
} | |||
func (m *NewRoundStep) GetSecondsSinceStartTime() int64 { | |||
if m != nil { | |||
return m.SecondsSinceStartTime | |||
} | |||
return 0 | |||
} | |||
func (m *NewRoundStep) GetLastCommitRound() int32 { | |||
if m != nil { | |||
return m.LastCommitRound | |||
} | |||
return 0 | |||
} | |||
// NewValidBlockMessage is sent when a validator observes a valid block B in some round r, | |||
//i.e., there is a Proposal for block B and 2/3+ prevotes for the block B in the round r. | |||
// In case the block is also committed, then IsCommit flag is set to true. | |||
type NewValidBlock struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Round int32 `protobuf:"varint,2,opt,name=round,proto3" json:"round,omitempty"` | |||
BlockPartsHeader types.PartSetHeader `protobuf:"bytes,3,opt,name=block_parts_header,json=blockPartsHeader,proto3" json:"block_parts_header"` | |||
BlockParts *bits.BitArray `protobuf:"bytes,4,opt,name=block_parts,json=blockParts,proto3" json:"block_parts,omitempty"` | |||
IsCommit bool `protobuf:"varint,5,opt,name=is_commit,json=isCommit,proto3" json:"is_commit,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *NewValidBlock) Reset() { *m = NewValidBlock{} } | |||
func (m *NewValidBlock) String() string { return proto.CompactTextString(m) } | |||
func (*NewValidBlock) ProtoMessage() {} | |||
func (*NewValidBlock) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{1} | |||
} | |||
func (m *NewValidBlock) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_NewValidBlock.Unmarshal(m, b) | |||
} | |||
func (m *NewValidBlock) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_NewValidBlock.Marshal(b, m, deterministic) | |||
} | |||
func (m *NewValidBlock) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_NewValidBlock.Merge(m, src) | |||
} | |||
func (m *NewValidBlock) XXX_Size() int { | |||
return xxx_messageInfo_NewValidBlock.Size(m) | |||
} | |||
func (m *NewValidBlock) XXX_DiscardUnknown() { | |||
xxx_messageInfo_NewValidBlock.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_NewValidBlock proto.InternalMessageInfo | |||
func (m *NewValidBlock) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *NewValidBlock) GetRound() int32 { | |||
if m != nil { | |||
return m.Round | |||
} | |||
return 0 | |||
} | |||
func (m *NewValidBlock) GetBlockPartsHeader() types.PartSetHeader { | |||
if m != nil { | |||
return m.BlockPartsHeader | |||
} | |||
return types.PartSetHeader{} | |||
} | |||
func (m *NewValidBlock) GetBlockParts() *bits.BitArray { | |||
if m != nil { | |||
return m.BlockParts | |||
} | |||
return nil | |||
} | |||
func (m *NewValidBlock) GetIsCommit() bool { | |||
if m != nil { | |||
return m.IsCommit | |||
} | |||
return false | |||
} | |||
// ProposalMessage is sent when a new block is proposed. | |||
type Proposal struct { | |||
Proposal types.Proposal `protobuf:"bytes,1,opt,name=proposal,proto3" json:"proposal"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *Proposal) Reset() { *m = Proposal{} } | |||
func (m *Proposal) String() string { return proto.CompactTextString(m) } | |||
func (*Proposal) ProtoMessage() {} | |||
func (*Proposal) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{2} | |||
} | |||
func (m *Proposal) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_Proposal.Unmarshal(m, b) | |||
} | |||
func (m *Proposal) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_Proposal.Marshal(b, m, deterministic) | |||
} | |||
func (m *Proposal) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_Proposal.Merge(m, src) | |||
} | |||
func (m *Proposal) XXX_Size() int { | |||
return xxx_messageInfo_Proposal.Size(m) | |||
} | |||
func (m *Proposal) XXX_DiscardUnknown() { | |||
xxx_messageInfo_Proposal.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_Proposal proto.InternalMessageInfo | |||
func (m *Proposal) GetProposal() types.Proposal { | |||
if m != nil { | |||
return m.Proposal | |||
} | |||
return types.Proposal{} | |||
} | |||
// ProposalPOLMessage is sent when a previous proposal is re-proposed. | |||
type ProposalPOL struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
ProposalPolRound int32 `protobuf:"varint,2,opt,name=proposal_pol_round,json=proposalPolRound,proto3" json:"proposal_pol_round,omitempty"` | |||
ProposalPol bits.BitArray `protobuf:"bytes,3,opt,name=proposal_pol,json=proposalPol,proto3" json:"proposal_pol"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *ProposalPOL) Reset() { *m = ProposalPOL{} } | |||
func (m *ProposalPOL) String() string { return proto.CompactTextString(m) } | |||
func (*ProposalPOL) ProtoMessage() {} | |||
func (*ProposalPOL) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{3} | |||
} | |||
func (m *ProposalPOL) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_ProposalPOL.Unmarshal(m, b) | |||
} | |||
func (m *ProposalPOL) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_ProposalPOL.Marshal(b, m, deterministic) | |||
} | |||
func (m *ProposalPOL) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_ProposalPOL.Merge(m, src) | |||
} | |||
func (m *ProposalPOL) XXX_Size() int { | |||
return xxx_messageInfo_ProposalPOL.Size(m) | |||
} | |||
func (m *ProposalPOL) XXX_DiscardUnknown() { | |||
xxx_messageInfo_ProposalPOL.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_ProposalPOL proto.InternalMessageInfo | |||
func (m *ProposalPOL) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *ProposalPOL) GetProposalPolRound() int32 { | |||
if m != nil { | |||
return m.ProposalPolRound | |||
} | |||
return 0 | |||
} | |||
func (m *ProposalPOL) GetProposalPol() bits.BitArray { | |||
if m != nil { | |||
return m.ProposalPol | |||
} | |||
return bits.BitArray{} | |||
} | |||
// BlockPartMessage is sent when gossipping a piece of the proposed block. | |||
type BlockPart struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Round int32 `protobuf:"varint,2,opt,name=round,proto3" json:"round,omitempty"` | |||
Part types.Part `protobuf:"bytes,3,opt,name=part,proto3" json:"part"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *BlockPart) Reset() { *m = BlockPart{} } | |||
func (m *BlockPart) String() string { return proto.CompactTextString(m) } | |||
func (*BlockPart) ProtoMessage() {} | |||
func (*BlockPart) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{4} | |||
} | |||
func (m *BlockPart) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_BlockPart.Unmarshal(m, b) | |||
} | |||
func (m *BlockPart) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_BlockPart.Marshal(b, m, deterministic) | |||
} | |||
func (m *BlockPart) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_BlockPart.Merge(m, src) | |||
} | |||
func (m *BlockPart) XXX_Size() int { | |||
return xxx_messageInfo_BlockPart.Size(m) | |||
} | |||
func (m *BlockPart) XXX_DiscardUnknown() { | |||
xxx_messageInfo_BlockPart.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_BlockPart proto.InternalMessageInfo | |||
func (m *BlockPart) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *BlockPart) GetRound() int32 { | |||
if m != nil { | |||
return m.Round | |||
} | |||
return 0 | |||
} | |||
func (m *BlockPart) GetPart() types.Part { | |||
if m != nil { | |||
return m.Part | |||
} | |||
return types.Part{} | |||
} | |||
// VoteMessage is sent when voting for a proposal (or lack thereof). | |||
type Vote struct { | |||
Vote *types.Vote `protobuf:"bytes,1,opt,name=vote,proto3" json:"vote,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *Vote) Reset() { *m = Vote{} } | |||
func (m *Vote) String() string { return proto.CompactTextString(m) } | |||
func (*Vote) ProtoMessage() {} | |||
func (*Vote) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{5} | |||
} | |||
func (m *Vote) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_Vote.Unmarshal(m, b) | |||
} | |||
func (m *Vote) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_Vote.Marshal(b, m, deterministic) | |||
} | |||
func (m *Vote) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_Vote.Merge(m, src) | |||
} | |||
func (m *Vote) XXX_Size() int { | |||
return xxx_messageInfo_Vote.Size(m) | |||
} | |||
func (m *Vote) XXX_DiscardUnknown() { | |||
xxx_messageInfo_Vote.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_Vote proto.InternalMessageInfo | |||
func (m *Vote) GetVote() *types.Vote { | |||
if m != nil { | |||
return m.Vote | |||
} | |||
return nil | |||
} | |||
// HasVoteMessage is sent to indicate that a particular vote has been received. | |||
type HasVote struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Round int32 `protobuf:"varint,2,opt,name=round,proto3" json:"round,omitempty"` | |||
Type types.SignedMsgType `protobuf:"varint,3,opt,name=type,proto3,enum=tendermint.proto.types.SignedMsgType" json:"type,omitempty"` | |||
Index uint32 `protobuf:"varint,4,opt,name=index,proto3" json:"index,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *HasVote) Reset() { *m = HasVote{} } | |||
func (m *HasVote) String() string { return proto.CompactTextString(m) } | |||
func (*HasVote) ProtoMessage() {} | |||
func (*HasVote) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{6} | |||
} | |||
func (m *HasVote) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_HasVote.Unmarshal(m, b) | |||
} | |||
func (m *HasVote) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_HasVote.Marshal(b, m, deterministic) | |||
} | |||
func (m *HasVote) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_HasVote.Merge(m, src) | |||
} | |||
func (m *HasVote) XXX_Size() int { | |||
return xxx_messageInfo_HasVote.Size(m) | |||
} | |||
func (m *HasVote) XXX_DiscardUnknown() { | |||
xxx_messageInfo_HasVote.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_HasVote proto.InternalMessageInfo | |||
func (m *HasVote) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *HasVote) GetRound() int32 { | |||
if m != nil { | |||
return m.Round | |||
} | |||
return 0 | |||
} | |||
func (m *HasVote) GetType() types.SignedMsgType { | |||
if m != nil { | |||
return m.Type | |||
} | |||
return types.SIGNED_MSG_TYPE_UNKNOWN | |||
} | |||
func (m *HasVote) GetIndex() uint32 { | |||
if m != nil { | |||
return m.Index | |||
} | |||
return 0 | |||
} | |||
// VoteSetMaj23Message is sent to indicate that a given BlockID has seen +2/3 votes. | |||
type VoteSetMaj23 struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Round int32 `protobuf:"varint,2,opt,name=round,proto3" json:"round,omitempty"` | |||
Type types.SignedMsgType `protobuf:"varint,3,opt,name=type,proto3,enum=tendermint.proto.types.SignedMsgType" json:"type,omitempty"` | |||
BlockID types.BlockID `protobuf:"bytes,4,opt,name=block_id,json=blockId,proto3" json:"block_id"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *VoteSetMaj23) Reset() { *m = VoteSetMaj23{} } | |||
func (m *VoteSetMaj23) String() string { return proto.CompactTextString(m) } | |||
func (*VoteSetMaj23) ProtoMessage() {} | |||
func (*VoteSetMaj23) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{7} | |||
} | |||
func (m *VoteSetMaj23) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_VoteSetMaj23.Unmarshal(m, b) | |||
} | |||
func (m *VoteSetMaj23) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_VoteSetMaj23.Marshal(b, m, deterministic) | |||
} | |||
func (m *VoteSetMaj23) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_VoteSetMaj23.Merge(m, src) | |||
} | |||
func (m *VoteSetMaj23) XXX_Size() int { | |||
return xxx_messageInfo_VoteSetMaj23.Size(m) | |||
} | |||
func (m *VoteSetMaj23) XXX_DiscardUnknown() { | |||
xxx_messageInfo_VoteSetMaj23.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_VoteSetMaj23 proto.InternalMessageInfo | |||
func (m *VoteSetMaj23) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *VoteSetMaj23) GetRound() int32 { | |||
if m != nil { | |||
return m.Round | |||
} | |||
return 0 | |||
} | |||
func (m *VoteSetMaj23) GetType() types.SignedMsgType { | |||
if m != nil { | |||
return m.Type | |||
} | |||
return types.SIGNED_MSG_TYPE_UNKNOWN | |||
} | |||
func (m *VoteSetMaj23) GetBlockID() types.BlockID { | |||
if m != nil { | |||
return m.BlockID | |||
} | |||
return types.BlockID{} | |||
} | |||
// VoteSetBitsMessage is sent to communicate the bit-array of votes seen for the BlockID. | |||
type VoteSetBits struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Round int32 `protobuf:"varint,2,opt,name=round,proto3" json:"round,omitempty"` | |||
Type types.SignedMsgType `protobuf:"varint,3,opt,name=type,proto3,enum=tendermint.proto.types.SignedMsgType" json:"type,omitempty"` | |||
BlockID types.BlockID `protobuf:"bytes,4,opt,name=block_id,json=blockId,proto3" json:"block_id"` | |||
Votes bits.BitArray `protobuf:"bytes,5,opt,name=votes,proto3" json:"votes"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *VoteSetBits) Reset() { *m = VoteSetBits{} } | |||
func (m *VoteSetBits) String() string { return proto.CompactTextString(m) } | |||
func (*VoteSetBits) ProtoMessage() {} | |||
func (*VoteSetBits) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{8} | |||
} | |||
func (m *VoteSetBits) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_VoteSetBits.Unmarshal(m, b) | |||
} | |||
func (m *VoteSetBits) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_VoteSetBits.Marshal(b, m, deterministic) | |||
} | |||
func (m *VoteSetBits) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_VoteSetBits.Merge(m, src) | |||
} | |||
func (m *VoteSetBits) XXX_Size() int { | |||
return xxx_messageInfo_VoteSetBits.Size(m) | |||
} | |||
func (m *VoteSetBits) XXX_DiscardUnknown() { | |||
xxx_messageInfo_VoteSetBits.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_VoteSetBits proto.InternalMessageInfo | |||
func (m *VoteSetBits) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *VoteSetBits) GetRound() int32 { | |||
if m != nil { | |||
return m.Round | |||
} | |||
return 0 | |||
} | |||
func (m *VoteSetBits) GetType() types.SignedMsgType { | |||
if m != nil { | |||
return m.Type | |||
} | |||
return types.SIGNED_MSG_TYPE_UNKNOWN | |||
} | |||
func (m *VoteSetBits) GetBlockID() types.BlockID { | |||
if m != nil { | |||
return m.BlockID | |||
} | |||
return types.BlockID{} | |||
} | |||
func (m *VoteSetBits) GetVotes() bits.BitArray { | |||
if m != nil { | |||
return m.Votes | |||
} | |||
return bits.BitArray{} | |||
} | |||
type Message struct { | |||
// Types that are valid to be assigned to Sum: | |||
// *Message_NewRoundStep | |||
// *Message_NewValidBlock | |||
// *Message_Proposal | |||
// *Message_ProposalPol | |||
// *Message_BlockPart | |||
// *Message_Vote | |||
// *Message_HasVote | |||
// *Message_VoteSetMaj23 | |||
// *Message_VoteSetBits | |||
Sum isMessage_Sum `protobuf_oneof:"sum"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *Message) Reset() { *m = Message{} } | |||
func (m *Message) String() string { return proto.CompactTextString(m) } | |||
func (*Message) ProtoMessage() {} | |||
func (*Message) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9de64017f8b3fc88, []int{9} | |||
} | |||
func (m *Message) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_Message.Unmarshal(m, b) | |||
} | |||
func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_Message.Marshal(b, m, deterministic) | |||
} | |||
func (m *Message) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_Message.Merge(m, src) | |||
} | |||
func (m *Message) XXX_Size() int { | |||
return xxx_messageInfo_Message.Size(m) | |||
} | |||
func (m *Message) XXX_DiscardUnknown() { | |||
xxx_messageInfo_Message.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_Message proto.InternalMessageInfo | |||
type isMessage_Sum interface { | |||
isMessage_Sum() | |||
} | |||
type Message_NewRoundStep struct { | |||
NewRoundStep *NewRoundStep `protobuf:"bytes,1,opt,name=new_round_step,json=newRoundStep,proto3,oneof" json:"new_round_step,omitempty"` | |||
} | |||
type Message_NewValidBlock struct { | |||
NewValidBlock *NewValidBlock `protobuf:"bytes,2,opt,name=new_valid_block,json=newValidBlock,proto3,oneof" json:"new_valid_block,omitempty"` | |||
} | |||
type Message_Proposal struct { | |||
Proposal *Proposal `protobuf:"bytes,3,opt,name=proposal,proto3,oneof" json:"proposal,omitempty"` | |||
} | |||
type Message_ProposalPol struct { | |||
ProposalPol *ProposalPOL `protobuf:"bytes,4,opt,name=proposal_pol,json=proposalPol,proto3,oneof" json:"proposal_pol,omitempty"` | |||
} | |||
type Message_BlockPart struct { | |||
BlockPart *BlockPart `protobuf:"bytes,5,opt,name=block_part,json=blockPart,proto3,oneof" json:"block_part,omitempty"` | |||
} | |||
type Message_Vote struct { | |||
Vote *Vote `protobuf:"bytes,6,opt,name=vote,proto3,oneof" json:"vote,omitempty"` | |||
} | |||
type Message_HasVote struct { | |||
HasVote *HasVote `protobuf:"bytes,7,opt,name=has_vote,json=hasVote,proto3,oneof" json:"has_vote,omitempty"` | |||
} | |||
type Message_VoteSetMaj23 struct { | |||
VoteSetMaj23 *VoteSetMaj23 `protobuf:"bytes,8,opt,name=vote_set_maj23,json=voteSetMaj23,proto3,oneof" json:"vote_set_maj23,omitempty"` | |||
} | |||
type Message_VoteSetBits struct { | |||
VoteSetBits *VoteSetBits `protobuf:"bytes,9,opt,name=vote_set_bits,json=voteSetBits,proto3,oneof" json:"vote_set_bits,omitempty"` | |||
} | |||
func (*Message_NewRoundStep) isMessage_Sum() {} | |||
func (*Message_NewValidBlock) isMessage_Sum() {} | |||
func (*Message_Proposal) isMessage_Sum() {} | |||
func (*Message_ProposalPol) isMessage_Sum() {} | |||
func (*Message_BlockPart) isMessage_Sum() {} | |||
func (*Message_Vote) isMessage_Sum() {} | |||
func (*Message_HasVote) isMessage_Sum() {} | |||
func (*Message_VoteSetMaj23) isMessage_Sum() {} | |||
func (*Message_VoteSetBits) isMessage_Sum() {} | |||
func (m *Message) GetSum() isMessage_Sum { | |||
if m != nil { | |||
return m.Sum | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetNewRoundStep() *NewRoundStep { | |||
if x, ok := m.GetSum().(*Message_NewRoundStep); ok { | |||
return x.NewRoundStep | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetNewValidBlock() *NewValidBlock { | |||
if x, ok := m.GetSum().(*Message_NewValidBlock); ok { | |||
return x.NewValidBlock | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetProposal() *Proposal { | |||
if x, ok := m.GetSum().(*Message_Proposal); ok { | |||
return x.Proposal | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetProposalPol() *ProposalPOL { | |||
if x, ok := m.GetSum().(*Message_ProposalPol); ok { | |||
return x.ProposalPol | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetBlockPart() *BlockPart { | |||
if x, ok := m.GetSum().(*Message_BlockPart); ok { | |||
return x.BlockPart | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetVote() *Vote { | |||
if x, ok := m.GetSum().(*Message_Vote); ok { | |||
return x.Vote | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetHasVote() *HasVote { | |||
if x, ok := m.GetSum().(*Message_HasVote); ok { | |||
return x.HasVote | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetVoteSetMaj23() *VoteSetMaj23 { | |||
if x, ok := m.GetSum().(*Message_VoteSetMaj23); ok { | |||
return x.VoteSetMaj23 | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetVoteSetBits() *VoteSetBits { | |||
if x, ok := m.GetSum().(*Message_VoteSetBits); ok { | |||
return x.VoteSetBits | |||
} | |||
return nil | |||
} | |||
// XXX_OneofWrappers is for the internal use of the proto package. | |||
func (*Message) XXX_OneofWrappers() []interface{} { | |||
return []interface{}{ | |||
(*Message_NewRoundStep)(nil), | |||
(*Message_NewValidBlock)(nil), | |||
(*Message_Proposal)(nil), | |||
(*Message_ProposalPol)(nil), | |||
(*Message_BlockPart)(nil), | |||
(*Message_Vote)(nil), | |||
(*Message_HasVote)(nil), | |||
(*Message_VoteSetMaj23)(nil), | |||
(*Message_VoteSetBits)(nil), | |||
} | |||
} | |||
func init() { | |||
proto.RegisterType((*NewRoundStep)(nil), "tendermint.proto.consensus.NewRoundStep") | |||
proto.RegisterType((*NewValidBlock)(nil), "tendermint.proto.consensus.NewValidBlock") | |||
proto.RegisterType((*Proposal)(nil), "tendermint.proto.consensus.Proposal") | |||
proto.RegisterType((*ProposalPOL)(nil), "tendermint.proto.consensus.ProposalPOL") | |||
proto.RegisterType((*BlockPart)(nil), "tendermint.proto.consensus.BlockPart") | |||
proto.RegisterType((*Vote)(nil), "tendermint.proto.consensus.Vote") | |||
proto.RegisterType((*HasVote)(nil), "tendermint.proto.consensus.HasVote") | |||
proto.RegisterType((*VoteSetMaj23)(nil), "tendermint.proto.consensus.VoteSetMaj23") | |||
proto.RegisterType((*VoteSetBits)(nil), "tendermint.proto.consensus.VoteSetBits") | |||
proto.RegisterType((*Message)(nil), "tendermint.proto.consensus.Message") | |||
} | |||
func init() { proto.RegisterFile("proto/consensus/msgs.proto", fileDescriptor_9de64017f8b3fc88) } | |||
var fileDescriptor_9de64017f8b3fc88 = []byte{ | |||
// 833 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xd4, 0x56, 0xcd, 0x6e, 0xeb, 0x44, | |||
0x14, 0x8e, 0x6f, 0x93, 0x26, 0x39, 0x4e, 0xda, 0xcb, 0x88, 0x9f, 0x28, 0x17, 0xa9, 0x91, 0xe1, | |||
0x42, 0x40, 0xc8, 0xb9, 0x4a, 0x25, 0x7e, 0x76, 0xc5, 0xfc, 0xc8, 0x15, 0x4d, 0x1b, 0x39, 0x55, | |||
0x25, 0xd8, 0x58, 0x4e, 0x3c, 0x72, 0x06, 0x62, 0x8f, 0xf1, 0x4c, 0x52, 0xf2, 0x00, 0x48, 0x3c, | |||
0x07, 0x6b, 0xb6, 0xbc, 0x01, 0x0b, 0x9e, 0xa2, 0x0b, 0x9e, 0x83, 0x05, 0x9a, 0x9f, 0xc4, 0x6e, | |||
0x2b, 0xb7, 0xcd, 0x06, 0xe9, 0x6e, 0xaa, 0x99, 0x39, 0xe7, 0xfb, 0x7c, 0xe6, 0x3b, 0x73, 0xbe, | |||
0x06, 0xba, 0x69, 0x46, 0x39, 0x1d, 0xcc, 0x68, 0xc2, 0x70, 0xc2, 0x96, 0x6c, 0x10, 0xb3, 0x88, | |||
0xd9, 0xf2, 0x10, 0x75, 0x39, 0x4e, 0x42, 0x9c, 0xc5, 0x24, 0xe1, 0xea, 0xc4, 0xde, 0xa6, 0x75, | |||
0x3f, 0xe0, 0x73, 0x92, 0x85, 0x7e, 0x1a, 0x64, 0x7c, 0x3d, 0x50, 0x1c, 0x11, 0x8d, 0x68, 0xbe, | |||
0x52, 0x88, 0xee, 0x3b, 0xea, 0x84, 0xaf, 0x53, 0xcc, 0xd4, 0x5f, 0x1d, 0x78, 0xa1, 0x02, 0x0b, | |||
0x32, 0x65, 0x83, 0x29, 0xe1, 0xb7, 0x82, 0xd6, 0x9f, 0x06, 0xb4, 0xce, 0xf1, 0xb5, 0x47, 0x97, | |||
0x49, 0x38, 0xe1, 0x38, 0x45, 0x6f, 0xc3, 0xfe, 0x1c, 0x93, 0x68, 0xce, 0x3b, 0x46, 0xcf, 0xe8, | |||
0xef, 0x79, 0x7a, 0x87, 0xde, 0x84, 0x5a, 0x26, 0x92, 0x3a, 0xcf, 0x7a, 0x46, 0xbf, 0xe6, 0xa9, | |||
0x0d, 0x42, 0x50, 0x65, 0x1c, 0xa7, 0x9d, 0xbd, 0x9e, 0xd1, 0x6f, 0x7b, 0x72, 0x8d, 0x3e, 0x83, | |||
0x0e, 0xc3, 0x33, 0x9a, 0x84, 0xcc, 0x67, 0x24, 0x99, 0x61, 0x9f, 0xf1, 0x20, 0xe3, 0x3e, 0x27, | |||
0x31, 0xee, 0x54, 0x25, 0xe7, 0x5b, 0x3a, 0x3e, 0x11, 0xe1, 0x89, 0x88, 0x5e, 0x92, 0x18, 0xa3, | |||
0x8f, 0xe1, 0x8d, 0x45, 0xc0, 0xb8, 0x3f, 0xa3, 0x71, 0x4c, 0xb8, 0xaf, 0x3e, 0x57, 0x93, 0x9f, | |||
0x3b, 0x14, 0x81, 0xaf, 0xe4, 0xb9, 0x2c, 0xd5, 0xfa, 0xd7, 0x80, 0xf6, 0x39, 0xbe, 0xbe, 0x0a, | |||
0x16, 0x24, 0x74, 0x16, 0x74, 0xf6, 0xd3, 0x8e, 0x85, 0x7f, 0x0f, 0x68, 0x2a, 0x60, 0x52, 0x57, | |||
0xe6, 0xcf, 0x71, 0x10, 0xe2, 0x4c, 0x5e, 0xc3, 0x1c, 0xbe, 0xb4, 0xef, 0xb5, 0x43, 0x49, 0x36, | |||
0x0e, 0x32, 0x3e, 0xc1, 0xdc, 0x95, 0xc9, 0x4e, 0xf5, 0xef, 0x9b, 0xa3, 0x8a, 0xf7, 0x5c, 0xd2, | |||
0x88, 0x08, 0x53, 0xe7, 0xe8, 0x1b, 0x30, 0x0b, 0xd4, 0xf2, 0xca, 0xe6, 0xf0, 0xfd, 0xfb, 0x9c, | |||
0xa2, 0x21, 0xb6, 0x68, 0x88, 0xed, 0x10, 0xfe, 0x65, 0x96, 0x05, 0x6b, 0x0f, 0x72, 0x32, 0xf4, | |||
0x02, 0x9a, 0x84, 0x69, 0x2d, 0xa4, 0x0a, 0x0d, 0xaf, 0x41, 0x98, 0xd2, 0xc0, 0x3a, 0x87, 0xc6, | |||
0x38, 0xa3, 0x29, 0x65, 0xc1, 0x02, 0x39, 0xd0, 0x48, 0xf5, 0x5a, 0x5e, 0xdd, 0x1c, 0xf6, 0x4a, | |||
0x2f, 0xa0, 0xf3, 0x74, 0xed, 0x5b, 0x9c, 0xf5, 0xbb, 0x01, 0xe6, 0x26, 0x38, 0xbe, 0x38, 0x2b, | |||
0x15, 0xf3, 0x13, 0x40, 0x1b, 0x8c, 0x9f, 0xd2, 0x85, 0x5f, 0x54, 0xf6, 0xf9, 0x26, 0x32, 0xa6, | |||
0x0b, 0xd9, 0x24, 0x34, 0x82, 0x56, 0x31, 0x5b, 0xcb, 0xfb, 0x24, 0x29, 0x74, 0x85, 0x66, 0x81, | |||
0xd3, 0xfa, 0x19, 0x9a, 0xce, 0x46, 0x9f, 0x1d, 0xdb, 0xfd, 0x29, 0x54, 0x45, 0x37, 0x74, 0x05, | |||
0xef, 0x3e, 0xd4, 0x60, 0xfd, 0x65, 0x99, 0x6f, 0x7d, 0x0e, 0xd5, 0x2b, 0xca, 0x31, 0x7a, 0x05, | |||
0xd5, 0x15, 0xe5, 0x58, 0xeb, 0x5b, 0x8a, 0x17, 0xb9, 0x9e, 0xcc, 0xb4, 0x7e, 0x33, 0xa0, 0xee, | |||
0x06, 0x4c, 0xa2, 0x77, 0xab, 0xf5, 0x0b, 0xa8, 0x0a, 0x36, 0x59, 0xeb, 0x41, 0xf9, 0x63, 0x9c, | |||
0x90, 0x28, 0xc1, 0xe1, 0x88, 0x45, 0x97, 0xeb, 0x14, 0x7b, 0x12, 0x22, 0x08, 0x49, 0x12, 0xe2, | |||
0x5f, 0xe4, 0xa3, 0x6b, 0x7b, 0x6a, 0x63, 0xfd, 0x65, 0x40, 0x4b, 0xd4, 0x31, 0xc1, 0x7c, 0x14, | |||
0xfc, 0x38, 0x3c, 0xfe, 0xff, 0xea, 0xf9, 0x0e, 0x1a, 0x6a, 0x14, 0x48, 0xa8, 0xe7, 0xe0, 0xa8, | |||
0x0c, 0x2e, 0x3b, 0x7b, 0xfa, 0xb5, 0x73, 0x28, 0xd4, 0xff, 0xe7, 0xe6, 0xa8, 0xae, 0x0f, 0xbc, | |||
0xba, 0x64, 0x38, 0x0d, 0xad, 0x5f, 0x9f, 0x81, 0xa9, 0xaf, 0xe1, 0x10, 0xce, 0x5e, 0xcf, 0x5b, | |||
0xa0, 0x13, 0xa8, 0x89, 0xf7, 0xc1, 0xe4, 0x48, 0xef, 0x36, 0x0c, 0x0a, 0x68, 0xfd, 0x51, 0x83, | |||
0xfa, 0x08, 0x33, 0x16, 0x44, 0x18, 0x8d, 0xe1, 0x20, 0xc1, 0xd7, 0x6a, 0x0c, 0x7d, 0xe9, 0xc4, | |||
0xea, 0x85, 0xf6, 0xed, 0xf2, 0xff, 0x28, 0x76, 0xd1, 0xef, 0xdd, 0x8a, 0xd7, 0x4a, 0x8a, 0xfe, | |||
0x3f, 0x81, 0x43, 0xc1, 0xb8, 0x12, 0xc6, 0xea, 0xcb, 0xa2, 0xa5, 0x8e, 0xe6, 0xf0, 0xa3, 0x47, | |||
0x28, 0x73, 0x2b, 0x76, 0x2b, 0x5e, 0x3b, 0xb9, 0xe5, 0xcd, 0x45, 0x8b, 0x2a, 0x35, 0x81, 0x9c, | |||
0x6d, 0xe3, 0x44, 0x6e, 0xc1, 0xa2, 0xd0, 0xd9, 0x1d, 0x33, 0x51, 0x9d, 0xf8, 0xf0, 0x29, 0x3c, | |||
0xe3, 0x8b, 0x33, 0xf7, 0xb6, 0x97, 0xa0, 0x6f, 0x01, 0x72, 0x93, 0xd6, 0xbd, 0x78, 0xf9, 0x10, | |||
0xd7, 0xd6, 0x79, 0xdc, 0x8a, 0xd7, 0xdc, 0xda, 0xb4, 0x30, 0x16, 0x69, 0x0c, 0xfb, 0x65, 0xc6, | |||
0x9b, 0x33, 0x88, 0xb7, 0xeb, 0x56, 0x94, 0x3d, 0xa0, 0x13, 0x68, 0xcc, 0x03, 0xe6, 0x4b, 0x6c, | |||
0x5d, 0x62, 0xdf, 0x7b, 0x08, 0xab, 0x9d, 0xc4, 0xad, 0x78, 0xf5, 0xb9, 0x36, 0x95, 0x31, 0x1c, | |||
0x08, 0xb4, 0xcf, 0x30, 0xf7, 0x63, 0x31, 0xd6, 0x9d, 0xc6, 0xe3, 0xad, 0x2f, 0xda, 0x80, 0x68, | |||
0xfd, 0xaa, 0x68, 0x0b, 0x23, 0x68, 0x6f, 0x19, 0xc5, 0xfb, 0xeb, 0x34, 0x1f, 0x97, 0xb8, 0x30, | |||
0x90, 0x42, 0xe2, 0x55, 0xbe, 0x75, 0x6a, 0xb0, 0xc7, 0x96, 0xb1, 0x33, 0xfc, 0xe1, 0x55, 0x44, | |||
0xf8, 0x7c, 0x39, 0xb5, 0x67, 0x34, 0x1e, 0xe4, 0x54, 0xc5, 0xe5, 0x9d, 0x9f, 0x46, 0xd3, 0x7d, | |||
0x79, 0x70, 0xfc, 0x5f, 0x00, 0x00, 0x00, 0xff, 0xff, 0xae, 0x4b, 0x4c, 0x2a, 0x34, 0x09, 0x00, | |||
0x00, | |||
} |
@ -0,0 +1,92 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.consensus; | |||
option go_package = "github.com/tendermint/tendermint/proto/consensus"; | |||
import "third_party/proto/gogoproto/gogo.proto"; | |||
import "proto/types/types.proto"; | |||
import "proto/libs/bits/types.proto"; | |||
// NewRoundStepMessage is sent for every step taken in the ConsensusState. | |||
// For every height/round/step transition | |||
message NewRoundStep { | |||
int64 height = 1; | |||
int32 round = 2; | |||
uint32 step = 3; | |||
int64 seconds_since_start_time = 4; | |||
int32 last_commit_round = 5; | |||
} | |||
// NewValidBlockMessage is sent when a validator observes a valid block B in some round r, | |||
//i.e., there is a Proposal for block B and 2/3+ prevotes for the block B in the round r. | |||
// In case the block is also committed, then IsCommit flag is set to true. | |||
message NewValidBlock { | |||
int64 height = 1; | |||
int32 round = 2; | |||
tendermint.proto.types.PartSetHeader block_parts_header = 3 [(gogoproto.nullable) = false]; | |||
tendermint.proto.libs.bits.BitArray block_parts = 4; | |||
bool is_commit = 5; | |||
} | |||
// ProposalMessage is sent when a new block is proposed. | |||
message Proposal { | |||
tendermint.proto.types.Proposal proposal = 1 [(gogoproto.nullable) = false]; | |||
} | |||
// ProposalPOLMessage is sent when a previous proposal is re-proposed. | |||
message ProposalPOL { | |||
int64 height = 1; | |||
int32 proposal_pol_round = 2; | |||
tendermint.proto.libs.bits.BitArray proposal_pol = 3 [(gogoproto.nullable) = false]; | |||
} | |||
// BlockPartMessage is sent when gossipping a piece of the proposed block. | |||
message BlockPart { | |||
int64 height = 1; | |||
int32 round = 2; | |||
tendermint.proto.types.Part part = 3 [(gogoproto.nullable) = false]; | |||
} | |||
// VoteMessage is sent when voting for a proposal (or lack thereof). | |||
message Vote { | |||
tendermint.proto.types.Vote vote = 1; | |||
} | |||
// HasVoteMessage is sent to indicate that a particular vote has been received. | |||
message HasVote { | |||
int64 height = 1; | |||
int32 round = 2; | |||
tendermint.proto.types.SignedMsgType type = 3; | |||
uint32 index = 4; | |||
} | |||
// VoteSetMaj23Message is sent to indicate that a given BlockID has seen +2/3 votes. | |||
message VoteSetMaj23 { | |||
int64 height = 1; | |||
int32 round = 2; | |||
tendermint.proto.types.SignedMsgType type = 3; | |||
tendermint.proto.types.BlockID block_id = 4 [(gogoproto.customname) = "BlockID", (gogoproto.nullable) = false]; | |||
} | |||
// VoteSetBitsMessage is sent to communicate the bit-array of votes seen for the BlockID. | |||
message VoteSetBits { | |||
int64 height = 1; | |||
int32 round = 2; | |||
tendermint.proto.types.SignedMsgType type = 3; | |||
tendermint.proto.types.BlockID block_id = 4 [(gogoproto.customname) = "BlockID", (gogoproto.nullable) = false]; | |||
tendermint.proto.libs.bits.BitArray votes = 5 [(gogoproto.nullable) = false]; | |||
} | |||
message Message { | |||
oneof sum { | |||
NewRoundStep new_round_step = 1; | |||
NewValidBlock new_valid_block = 2; | |||
Proposal proposal = 3; | |||
ProposalPOL proposal_pol = 4; | |||
BlockPart block_part = 5; | |||
Vote vote = 6; | |||
HasVote has_vote = 7; | |||
VoteSetMaj23 vote_set_maj23 = 8; | |||
VoteSetBits vote_set_bits = 9; | |||
} | |||
} |
@ -0,0 +1,374 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/consensus/walmsgs.proto | |||
package consensus | |||
import ( | |||
fmt "fmt" | |||
_ "github.com/gogo/protobuf/gogoproto" | |||
proto "github.com/gogo/protobuf/proto" | |||
_ "github.com/golang/protobuf/ptypes/duration" | |||
_ "github.com/golang/protobuf/ptypes/timestamp" | |||
types "github.com/tendermint/tendermint/proto/types" | |||
math "math" | |||
time "time" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
var _ = time.Kitchen | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
// MsgInfo are msgs from the reactor which may update the state | |||
type MsgInfo struct { | |||
Msg Message `protobuf:"bytes,1,opt,name=msg,proto3" json:"msg"` | |||
PeerID string `protobuf:"bytes,2,opt,name=peer_id,json=peerId,proto3" json:"peer_id,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *MsgInfo) Reset() { *m = MsgInfo{} } | |||
func (m *MsgInfo) String() string { return proto.CompactTextString(m) } | |||
func (*MsgInfo) ProtoMessage() {} | |||
func (*MsgInfo) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_60ad80fa14e37285, []int{0} | |||
} | |||
func (m *MsgInfo) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_MsgInfo.Unmarshal(m, b) | |||
} | |||
func (m *MsgInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_MsgInfo.Marshal(b, m, deterministic) | |||
} | |||
func (m *MsgInfo) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_MsgInfo.Merge(m, src) | |||
} | |||
func (m *MsgInfo) XXX_Size() int { | |||
return xxx_messageInfo_MsgInfo.Size(m) | |||
} | |||
func (m *MsgInfo) XXX_DiscardUnknown() { | |||
xxx_messageInfo_MsgInfo.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_MsgInfo proto.InternalMessageInfo | |||
func (m *MsgInfo) GetMsg() Message { | |||
if m != nil { | |||
return m.Msg | |||
} | |||
return Message{} | |||
} | |||
func (m *MsgInfo) GetPeerID() string { | |||
if m != nil { | |||
return m.PeerID | |||
} | |||
return "" | |||
} | |||
// TimeoutInfo internally generated messages which may update the state | |||
type TimeoutInfo struct { | |||
Duration time.Duration `protobuf:"bytes,1,opt,name=duration,proto3,stdduration" json:"duration"` | |||
Height int64 `protobuf:"varint,2,opt,name=height,proto3" json:"height,omitempty"` | |||
Round int32 `protobuf:"varint,3,opt,name=round,proto3" json:"round,omitempty"` | |||
Step uint32 `protobuf:"varint,4,opt,name=step,proto3" json:"step,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *TimeoutInfo) Reset() { *m = TimeoutInfo{} } | |||
func (m *TimeoutInfo) String() string { return proto.CompactTextString(m) } | |||
func (*TimeoutInfo) ProtoMessage() {} | |||
func (*TimeoutInfo) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_60ad80fa14e37285, []int{1} | |||
} | |||
func (m *TimeoutInfo) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_TimeoutInfo.Unmarshal(m, b) | |||
} | |||
func (m *TimeoutInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_TimeoutInfo.Marshal(b, m, deterministic) | |||
} | |||
func (m *TimeoutInfo) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_TimeoutInfo.Merge(m, src) | |||
} | |||
func (m *TimeoutInfo) XXX_Size() int { | |||
return xxx_messageInfo_TimeoutInfo.Size(m) | |||
} | |||
func (m *TimeoutInfo) XXX_DiscardUnknown() { | |||
xxx_messageInfo_TimeoutInfo.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_TimeoutInfo proto.InternalMessageInfo | |||
func (m *TimeoutInfo) GetDuration() time.Duration { | |||
if m != nil { | |||
return m.Duration | |||
} | |||
return 0 | |||
} | |||
func (m *TimeoutInfo) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *TimeoutInfo) GetRound() int32 { | |||
if m != nil { | |||
return m.Round | |||
} | |||
return 0 | |||
} | |||
func (m *TimeoutInfo) GetStep() uint32 { | |||
if m != nil { | |||
return m.Step | |||
} | |||
return 0 | |||
} | |||
// EndHeightMessage marks the end of the given height inside WAL. | |||
// @internal used by scripts/wal2json util. | |||
type EndHeight struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *EndHeight) Reset() { *m = EndHeight{} } | |||
func (m *EndHeight) String() string { return proto.CompactTextString(m) } | |||
func (*EndHeight) ProtoMessage() {} | |||
func (*EndHeight) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_60ad80fa14e37285, []int{2} | |||
} | |||
func (m *EndHeight) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_EndHeight.Unmarshal(m, b) | |||
} | |||
func (m *EndHeight) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_EndHeight.Marshal(b, m, deterministic) | |||
} | |||
func (m *EndHeight) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_EndHeight.Merge(m, src) | |||
} | |||
func (m *EndHeight) XXX_Size() int { | |||
return xxx_messageInfo_EndHeight.Size(m) | |||
} | |||
func (m *EndHeight) XXX_DiscardUnknown() { | |||
xxx_messageInfo_EndHeight.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_EndHeight proto.InternalMessageInfo | |||
func (m *EndHeight) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
type WALMessage struct { | |||
// Types that are valid to be assigned to Sum: | |||
// *WALMessage_EventDataRoundState | |||
// *WALMessage_MsgInfo | |||
// *WALMessage_TimeoutInfo | |||
// *WALMessage_EndHeight | |||
Sum isWALMessage_Sum `protobuf_oneof:"sum"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *WALMessage) Reset() { *m = WALMessage{} } | |||
func (m *WALMessage) String() string { return proto.CompactTextString(m) } | |||
func (*WALMessage) ProtoMessage() {} | |||
func (*WALMessage) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_60ad80fa14e37285, []int{3} | |||
} | |||
func (m *WALMessage) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_WALMessage.Unmarshal(m, b) | |||
} | |||
func (m *WALMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_WALMessage.Marshal(b, m, deterministic) | |||
} | |||
func (m *WALMessage) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_WALMessage.Merge(m, src) | |||
} | |||
func (m *WALMessage) XXX_Size() int { | |||
return xxx_messageInfo_WALMessage.Size(m) | |||
} | |||
func (m *WALMessage) XXX_DiscardUnknown() { | |||
xxx_messageInfo_WALMessage.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_WALMessage proto.InternalMessageInfo | |||
type isWALMessage_Sum interface { | |||
isWALMessage_Sum() | |||
} | |||
type WALMessage_EventDataRoundState struct { | |||
EventDataRoundState *types.EventDataRoundState `protobuf:"bytes,1,opt,name=event_data_round_state,json=eventDataRoundState,proto3,oneof" json:"event_data_round_state,omitempty"` | |||
} | |||
type WALMessage_MsgInfo struct { | |||
MsgInfo *MsgInfo `protobuf:"bytes,2,opt,name=msg_info,json=msgInfo,proto3,oneof" json:"msg_info,omitempty"` | |||
} | |||
type WALMessage_TimeoutInfo struct { | |||
TimeoutInfo *TimeoutInfo `protobuf:"bytes,3,opt,name=timeout_info,json=timeoutInfo,proto3,oneof" json:"timeout_info,omitempty"` | |||
} | |||
type WALMessage_EndHeight struct { | |||
EndHeight *EndHeight `protobuf:"bytes,4,opt,name=end_height,json=endHeight,proto3,oneof" json:"end_height,omitempty"` | |||
} | |||
func (*WALMessage_EventDataRoundState) isWALMessage_Sum() {} | |||
func (*WALMessage_MsgInfo) isWALMessage_Sum() {} | |||
func (*WALMessage_TimeoutInfo) isWALMessage_Sum() {} | |||
func (*WALMessage_EndHeight) isWALMessage_Sum() {} | |||
func (m *WALMessage) GetSum() isWALMessage_Sum { | |||
if m != nil { | |||
return m.Sum | |||
} | |||
return nil | |||
} | |||
func (m *WALMessage) GetEventDataRoundState() *types.EventDataRoundState { | |||
if x, ok := m.GetSum().(*WALMessage_EventDataRoundState); ok { | |||
return x.EventDataRoundState | |||
} | |||
return nil | |||
} | |||
func (m *WALMessage) GetMsgInfo() *MsgInfo { | |||
if x, ok := m.GetSum().(*WALMessage_MsgInfo); ok { | |||
return x.MsgInfo | |||
} | |||
return nil | |||
} | |||
func (m *WALMessage) GetTimeoutInfo() *TimeoutInfo { | |||
if x, ok := m.GetSum().(*WALMessage_TimeoutInfo); ok { | |||
return x.TimeoutInfo | |||
} | |||
return nil | |||
} | |||
func (m *WALMessage) GetEndHeight() *EndHeight { | |||
if x, ok := m.GetSum().(*WALMessage_EndHeight); ok { | |||
return x.EndHeight | |||
} | |||
return nil | |||
} | |||
// XXX_OneofWrappers is for the internal use of the proto package. | |||
func (*WALMessage) XXX_OneofWrappers() []interface{} { | |||
return []interface{}{ | |||
(*WALMessage_EventDataRoundState)(nil), | |||
(*WALMessage_MsgInfo)(nil), | |||
(*WALMessage_TimeoutInfo)(nil), | |||
(*WALMessage_EndHeight)(nil), | |||
} | |||
} | |||
// TimedWALMessage wraps WALMessage and adds Time for debugging purposes. | |||
type TimedWALMessage struct { | |||
Time time.Time `protobuf:"bytes,1,opt,name=time,proto3,stdtime" json:"time"` | |||
Msg *WALMessage `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *TimedWALMessage) Reset() { *m = TimedWALMessage{} } | |||
func (m *TimedWALMessage) String() string { return proto.CompactTextString(m) } | |||
func (*TimedWALMessage) ProtoMessage() {} | |||
func (*TimedWALMessage) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_60ad80fa14e37285, []int{4} | |||
} | |||
func (m *TimedWALMessage) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_TimedWALMessage.Unmarshal(m, b) | |||
} | |||
func (m *TimedWALMessage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_TimedWALMessage.Marshal(b, m, deterministic) | |||
} | |||
func (m *TimedWALMessage) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_TimedWALMessage.Merge(m, src) | |||
} | |||
func (m *TimedWALMessage) XXX_Size() int { | |||
return xxx_messageInfo_TimedWALMessage.Size(m) | |||
} | |||
func (m *TimedWALMessage) XXX_DiscardUnknown() { | |||
xxx_messageInfo_TimedWALMessage.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_TimedWALMessage proto.InternalMessageInfo | |||
func (m *TimedWALMessage) GetTime() time.Time { | |||
if m != nil { | |||
return m.Time | |||
} | |||
return time.Time{} | |||
} | |||
func (m *TimedWALMessage) GetMsg() *WALMessage { | |||
if m != nil { | |||
return m.Msg | |||
} | |||
return nil | |||
} | |||
func init() { | |||
proto.RegisterType((*MsgInfo)(nil), "tendermint.proto.consensus.MsgInfo") | |||
proto.RegisterType((*TimeoutInfo)(nil), "tendermint.proto.consensus.TimeoutInfo") | |||
proto.RegisterType((*EndHeight)(nil), "tendermint.proto.consensus.EndHeight") | |||
proto.RegisterType((*WALMessage)(nil), "tendermint.proto.consensus.WALMessage") | |||
proto.RegisterType((*TimedWALMessage)(nil), "tendermint.proto.consensus.TimedWALMessage") | |||
} | |||
func init() { proto.RegisterFile("proto/consensus/walmsgs.proto", fileDescriptor_60ad80fa14e37285) } | |||
var fileDescriptor_60ad80fa14e37285 = []byte{ | |||
// 528 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x53, 0xcd, 0x8a, 0x13, 0x41, | |||
0x10, 0xce, 0x6c, 0xb2, 0xf9, 0xa9, 0x28, 0xc2, 0x28, 0x4b, 0x1c, 0xd0, 0x84, 0x04, 0xd7, 0x80, | |||
0x30, 0x23, 0xeb, 0x65, 0xc1, 0x83, 0x1a, 0xb2, 0x92, 0xc0, 0x2e, 0x48, 0xbb, 0x20, 0x78, 0x19, | |||
0x26, 0x3b, 0x95, 0xce, 0xe0, 0x76, 0xf7, 0x30, 0x5d, 0xa3, 0xec, 0x03, 0x78, 0xdf, 0xa3, 0x8f, | |||
0xe4, 0xcd, 0x37, 0x58, 0xc1, 0x27, 0x91, 0xe9, 0x9e, 0xfc, 0x90, 0x60, 0xbc, 0x75, 0x57, 0xf5, | |||
0xf7, 0x7d, 0x55, 0xf5, 0x55, 0xc3, 0x93, 0x34, 0x53, 0xa4, 0x82, 0x2b, 0x25, 0x35, 0x4a, 0x9d, | |||
0xeb, 0xe0, 0x5b, 0x74, 0x2d, 0x34, 0xd7, 0xbe, 0x89, 0xbb, 0x1e, 0xa1, 0x8c, 0x31, 0x13, 0x89, | |||
0x24, 0x1b, 0xf1, 0x57, 0x2f, 0xbd, 0x63, 0x5a, 0x24, 0x59, 0x1c, 0xa6, 0x51, 0x46, 0x37, 0x81, | |||
0xa5, 0xe1, 0x8a, 0xab, 0xf5, 0xc9, 0x22, 0x3c, 0x6f, 0x5b, 0x62, 0xcd, 0xef, 0x75, 0x6c, 0x8e, | |||
0x6e, 0x52, 0xd4, 0x01, 0x7e, 0x45, 0x49, 0xcb, 0xcc, 0x53, 0xae, 0x14, 0xbf, 0x46, 0x4b, 0x3c, | |||
0xcb, 0xe7, 0x41, 0x9c, 0x67, 0x11, 0x25, 0x4a, 0x96, 0xf9, 0xee, 0x76, 0x9e, 0x12, 0x81, 0x9a, | |||
0x22, 0x91, 0xda, 0x07, 0xfd, 0x2f, 0xd0, 0xb8, 0xd0, 0x7c, 0x2a, 0xe7, 0xca, 0x7d, 0x0d, 0x55, | |||
0xa1, 0x79, 0xc7, 0xe9, 0x39, 0xc3, 0xf6, 0xc9, 0xc0, 0xff, 0x77, 0x4f, 0xfe, 0x05, 0x6a, 0x1d, | |||
0x71, 0x1c, 0xd5, 0x7e, 0xde, 0x75, 0x2b, 0xac, 0x40, 0xb9, 0x03, 0x68, 0xa4, 0x88, 0x59, 0x98, | |||
0xc4, 0x9d, 0x83, 0x9e, 0x33, 0x6c, 0x8d, 0xe0, 0xcf, 0x5d, 0xb7, 0xfe, 0x01, 0x31, 0x9b, 0x8e, | |||
0x59, 0xbd, 0x48, 0x4d, 0xe3, 0xfe, 0xad, 0x03, 0xed, 0xcb, 0x44, 0xa0, 0xca, 0xc9, 0x28, 0xbe, | |||
0x81, 0xe6, 0xb2, 0xde, 0x52, 0xf6, 0xb1, 0x6f, 0x0b, 0xf6, 0x97, 0x05, 0xfb, 0xe3, 0xf2, 0xc1, | |||
0xa8, 0x59, 0x88, 0xfd, 0xf8, 0xdd, 0x75, 0xd8, 0x0a, 0xe4, 0x1e, 0x41, 0x7d, 0x81, 0x09, 0x5f, | |||
0x90, 0x11, 0xad, 0xb2, 0xf2, 0xe6, 0x3e, 0x82, 0xc3, 0x4c, 0xe5, 0x32, 0xee, 0x54, 0x7b, 0xce, | |||
0xf0, 0x90, 0xd9, 0x8b, 0xeb, 0x42, 0x4d, 0x13, 0xa6, 0x9d, 0x5a, 0xcf, 0x19, 0xde, 0x67, 0xe6, | |||
0xdc, 0x1f, 0x40, 0xeb, 0x4c, 0xc6, 0x13, 0x0b, 0x5b, 0xd3, 0x39, 0x9b, 0x74, 0xfd, 0x5f, 0x07, | |||
0x00, 0x9f, 0xde, 0x9d, 0x97, 0x6d, 0xbb, 0x33, 0x38, 0x32, 0x26, 0x84, 0x71, 0x44, 0x51, 0x68, | |||
0xb8, 0x43, 0x4d, 0x11, 0x61, 0xd9, 0xc4, 0x8b, 0xdd, 0xd9, 0x19, 0xeb, 0xfc, 0xb3, 0x02, 0x35, | |||
0x8e, 0x28, 0x62, 0x05, 0xe6, 0x63, 0x01, 0x99, 0x54, 0xd8, 0x43, 0xdc, 0x0d, 0xbb, 0x6f, 0xa1, | |||
0x29, 0x34, 0x0f, 0x13, 0x39, 0x57, 0xa6, 0xb7, 0xff, 0x39, 0x62, 0x3d, 0x9c, 0x54, 0x58, 0x43, | |||
0x94, 0x76, 0x9e, 0xc3, 0x3d, 0xb2, 0xb3, 0xb6, 0x2c, 0x55, 0xc3, 0xf2, 0x7c, 0x1f, 0xcb, 0x86, | |||
0x37, 0x93, 0x0a, 0x6b, 0xd3, 0x86, 0x55, 0xef, 0x01, 0x50, 0xc6, 0x61, 0x39, 0x9e, 0x9a, 0xe1, | |||
0x7a, 0xb6, 0x8f, 0x6b, 0x35, 0xd5, 0x49, 0x85, 0xb5, 0x70, 0x79, 0x19, 0x1d, 0x42, 0x55, 0xe7, | |||
0xa2, 0xff, 0xdd, 0x81, 0x07, 0x85, 0x5a, 0xbc, 0x31, 0xd6, 0x53, 0xa8, 0x15, 0x8a, 0xe5, 0x10, | |||
0xbd, 0x9d, 0x4d, 0xb8, 0x5c, 0xae, 0xae, 0x5d, 0x85, 0xdb, 0x62, 0x15, 0x0c, 0xc2, 0x3d, 0xb5, | |||
0x9b, 0x6b, 0xe7, 0x74, 0xbc, 0xaf, 0xaa, 0xb5, 0x9c, 0x59, 0xdb, 0xd1, 0xc9, 0xe7, 0x97, 0x3c, | |||
0xa1, 0x45, 0x3e, 0xf3, 0xaf, 0x94, 0x08, 0xd6, 0xc0, 0xcd, 0xe3, 0xd6, 0xc7, 0x9c, 0xd5, 0x4d, | |||
0xe0, 0xd5, 0xdf, 0x00, 0x00, 0x00, 0xff, 0xff, 0x55, 0x7e, 0x02, 0x98, 0x15, 0x04, 0x00, 0x00, | |||
} |
@ -0,0 +1,46 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.consensus; | |||
option go_package = "github.com/tendermint/tendermint/proto/consensus"; | |||
import "third_party/proto/gogoproto/gogo.proto"; | |||
import "proto/consensus/msgs.proto"; | |||
import "proto/types/events.proto"; | |||
import "google/protobuf/duration.proto"; | |||
import "google/protobuf/timestamp.proto"; | |||
// MsgInfo are msgs from the reactor which may update the state | |||
message MsgInfo { | |||
Message msg = 1 [(gogoproto.nullable) = false]; | |||
string peer_id = 2 [(gogoproto.customname) = "PeerID"]; | |||
} | |||
// TimeoutInfo internally generated messages which may update the state | |||
message TimeoutInfo { | |||
google.protobuf.Duration duration = 1 | |||
[(gogoproto.nullable) = false, (gogoproto.stdduration) = true]; | |||
int64 height = 2; | |||
int32 round = 3; | |||
uint32 step = 4; | |||
} | |||
// EndHeightMessage marks the end of the given height inside WAL. | |||
// @internal used by scripts/wal2json util. | |||
message EndHeight { | |||
int64 height = 1; | |||
} | |||
message WALMessage { | |||
oneof sum { | |||
tendermint.proto.types.EventDataRoundState event_data_round_state = 1; | |||
MsgInfo msg_info = 2; | |||
TimeoutInfo timeout_info = 3; | |||
EndHeight end_height = 4; | |||
} | |||
} | |||
// TimedWALMessage wraps WALMessage and adds Time for debugging purposes. | |||
message TimedWALMessage { | |||
google.protobuf.Timestamp time = 1 [(gogoproto.nullable) = false, (gogoproto.stdtime) = true]; | |||
WALMessage msg = 2; | |||
} |
@ -0,0 +1,105 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/crypto/merkle/types.proto | |||
package merkle | |||
import ( | |||
fmt "fmt" | |||
proto "github.com/gogo/protobuf/proto" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
type SimpleProof struct { | |||
Total int64 `protobuf:"varint,1,opt,name=total,proto3" json:"total,omitempty"` | |||
Index int64 `protobuf:"varint,2,opt,name=index,proto3" json:"index,omitempty"` | |||
LeafHash []byte `protobuf:"bytes,3,opt,name=leaf_hash,json=leafHash,proto3" json:"leaf_hash,omitempty"` | |||
Aunts [][]byte `protobuf:"bytes,4,rep,name=aunts,proto3" json:"aunts,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *SimpleProof) Reset() { *m = SimpleProof{} } | |||
func (m *SimpleProof) String() string { return proto.CompactTextString(m) } | |||
func (*SimpleProof) ProtoMessage() {} | |||
func (*SimpleProof) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_57e39eefdaf7ae96, []int{0} | |||
} | |||
func (m *SimpleProof) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_SimpleProof.Unmarshal(m, b) | |||
} | |||
func (m *SimpleProof) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_SimpleProof.Marshal(b, m, deterministic) | |||
} | |||
func (m *SimpleProof) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_SimpleProof.Merge(m, src) | |||
} | |||
func (m *SimpleProof) XXX_Size() int { | |||
return xxx_messageInfo_SimpleProof.Size(m) | |||
} | |||
func (m *SimpleProof) XXX_DiscardUnknown() { | |||
xxx_messageInfo_SimpleProof.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_SimpleProof proto.InternalMessageInfo | |||
func (m *SimpleProof) GetTotal() int64 { | |||
if m != nil { | |||
return m.Total | |||
} | |||
return 0 | |||
} | |||
func (m *SimpleProof) GetIndex() int64 { | |||
if m != nil { | |||
return m.Index | |||
} | |||
return 0 | |||
} | |||
func (m *SimpleProof) GetLeafHash() []byte { | |||
if m != nil { | |||
return m.LeafHash | |||
} | |||
return nil | |||
} | |||
func (m *SimpleProof) GetAunts() [][]byte { | |||
if m != nil { | |||
return m.Aunts | |||
} | |||
return nil | |||
} | |||
func init() { | |||
proto.RegisterType((*SimpleProof)(nil), "tendermint.proto.crypto.merkle.SimpleProof") | |||
} | |||
func init() { proto.RegisterFile("proto/crypto/merkle/types.proto", fileDescriptor_57e39eefdaf7ae96) } | |||
var fileDescriptor_57e39eefdaf7ae96 = []byte{ | |||
// 188 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x2f, 0x28, 0xca, 0x2f, | |||
0xc9, 0xd7, 0x4f, 0x2e, 0xaa, 0x2c, 0x28, 0xc9, 0xd7, 0xcf, 0x4d, 0x2d, 0xca, 0xce, 0x49, 0xd5, | |||
0x2f, 0xa9, 0x2c, 0x48, 0x2d, 0xd6, 0x03, 0xcb, 0x08, 0xc9, 0x95, 0xa4, 0xe6, 0xa5, 0xa4, 0x16, | |||
0xe5, 0x66, 0xe6, 0x95, 0x40, 0x44, 0xf4, 0x20, 0x6a, 0xf5, 0x20, 0x6a, 0x95, 0x72, 0xb8, 0xb8, | |||
0x83, 0x33, 0x73, 0x0b, 0x72, 0x52, 0x03, 0x8a, 0xf2, 0xf3, 0xd3, 0x84, 0x44, 0xb8, 0x58, 0x4b, | |||
0xf2, 0x4b, 0x12, 0x73, 0x24, 0x18, 0x15, 0x18, 0x35, 0x98, 0x83, 0x20, 0x1c, 0x90, 0x68, 0x66, | |||
0x5e, 0x4a, 0x6a, 0x85, 0x04, 0x13, 0x44, 0x14, 0xcc, 0x11, 0x92, 0xe6, 0xe2, 0xcc, 0x49, 0x4d, | |||
0x4c, 0x8b, 0xcf, 0x48, 0x2c, 0xce, 0x90, 0x60, 0x56, 0x60, 0xd4, 0xe0, 0x09, 0xe2, 0x00, 0x09, | |||
0x78, 0x24, 0x16, 0x67, 0x80, 0xb4, 0x24, 0x96, 0xe6, 0x95, 0x14, 0x4b, 0xb0, 0x28, 0x30, 0x6b, | |||
0xf0, 0x04, 0x41, 0x38, 0x4e, 0x66, 0x51, 0x26, 0xe9, 0x99, 0x25, 0x19, 0xa5, 0x49, 0x7a, 0xc9, | |||
0xf9, 0xb9, 0xfa, 0x08, 0xa7, 0x21, 0x33, 0xb1, 0xf8, 0x28, 0x89, 0x0d, 0x2c, 0x68, 0x0c, 0x08, | |||
0x00, 0x00, 0xff, 0xff, 0x4f, 0x08, 0x9a, 0xf1, 0xef, 0x00, 0x00, 0x00, | |||
} |
@ -0,0 +1,11 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.crypto.merkle; | |||
option go_package = "github.com/tendermint/tendermint/proto/crypto/merkle"; | |||
message SimpleProof { | |||
int64 total = 1; | |||
int64 index = 2; | |||
bytes leaf_hash = 3; | |||
repeated bytes aunts = 4; | |||
} |
@ -0,0 +1,258 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/p2p/conn_msgs.proto | |||
package p2p | |||
import ( | |||
fmt "fmt" | |||
_ "github.com/gogo/protobuf/gogoproto" | |||
proto "github.com/gogo/protobuf/proto" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
type PacketPing struct { | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *PacketPing) Reset() { *m = PacketPing{} } | |||
func (m *PacketPing) String() string { return proto.CompactTextString(m) } | |||
func (*PacketPing) ProtoMessage() {} | |||
func (*PacketPing) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_8c680f0b24d73fe7, []int{0} | |||
} | |||
func (m *PacketPing) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_PacketPing.Unmarshal(m, b) | |||
} | |||
func (m *PacketPing) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_PacketPing.Marshal(b, m, deterministic) | |||
} | |||
func (m *PacketPing) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_PacketPing.Merge(m, src) | |||
} | |||
func (m *PacketPing) XXX_Size() int { | |||
return xxx_messageInfo_PacketPing.Size(m) | |||
} | |||
func (m *PacketPing) XXX_DiscardUnknown() { | |||
xxx_messageInfo_PacketPing.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_PacketPing proto.InternalMessageInfo | |||
type PacketPong struct { | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *PacketPong) Reset() { *m = PacketPong{} } | |||
func (m *PacketPong) String() string { return proto.CompactTextString(m) } | |||
func (*PacketPong) ProtoMessage() {} | |||
func (*PacketPong) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_8c680f0b24d73fe7, []int{1} | |||
} | |||
func (m *PacketPong) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_PacketPong.Unmarshal(m, b) | |||
} | |||
func (m *PacketPong) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_PacketPong.Marshal(b, m, deterministic) | |||
} | |||
func (m *PacketPong) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_PacketPong.Merge(m, src) | |||
} | |||
func (m *PacketPong) XXX_Size() int { | |||
return xxx_messageInfo_PacketPong.Size(m) | |||
} | |||
func (m *PacketPong) XXX_DiscardUnknown() { | |||
xxx_messageInfo_PacketPong.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_PacketPong proto.InternalMessageInfo | |||
type PacketMsg struct { | |||
ChannelID int32 `protobuf:"varint,1,opt,name=channel_id,json=channelId,proto3" json:"channel_id,omitempty"` | |||
EOF int32 `protobuf:"varint,2,opt,name=eof,proto3" json:"eof,omitempty"` | |||
Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *PacketMsg) Reset() { *m = PacketMsg{} } | |||
func (m *PacketMsg) String() string { return proto.CompactTextString(m) } | |||
func (*PacketMsg) ProtoMessage() {} | |||
func (*PacketMsg) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_8c680f0b24d73fe7, []int{2} | |||
} | |||
func (m *PacketMsg) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_PacketMsg.Unmarshal(m, b) | |||
} | |||
func (m *PacketMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_PacketMsg.Marshal(b, m, deterministic) | |||
} | |||
func (m *PacketMsg) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_PacketMsg.Merge(m, src) | |||
} | |||
func (m *PacketMsg) XXX_Size() int { | |||
return xxx_messageInfo_PacketMsg.Size(m) | |||
} | |||
func (m *PacketMsg) XXX_DiscardUnknown() { | |||
xxx_messageInfo_PacketMsg.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_PacketMsg proto.InternalMessageInfo | |||
func (m *PacketMsg) GetChannelID() int32 { | |||
if m != nil { | |||
return m.ChannelID | |||
} | |||
return 0 | |||
} | |||
func (m *PacketMsg) GetEOF() int32 { | |||
if m != nil { | |||
return m.EOF | |||
} | |||
return 0 | |||
} | |||
func (m *PacketMsg) GetData() []byte { | |||
if m != nil { | |||
return m.Data | |||
} | |||
return nil | |||
} | |||
type Packet struct { | |||
// Types that are valid to be assigned to Sum: | |||
// *Packet_PacketPing | |||
// *Packet_PacketPong | |||
// *Packet_PacketMsg | |||
Sum isPacket_Sum `protobuf_oneof:"sum"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *Packet) Reset() { *m = Packet{} } | |||
func (m *Packet) String() string { return proto.CompactTextString(m) } | |||
func (*Packet) ProtoMessage() {} | |||
func (*Packet) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_8c680f0b24d73fe7, []int{3} | |||
} | |||
func (m *Packet) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_Packet.Unmarshal(m, b) | |||
} | |||
func (m *Packet) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_Packet.Marshal(b, m, deterministic) | |||
} | |||
func (m *Packet) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_Packet.Merge(m, src) | |||
} | |||
func (m *Packet) XXX_Size() int { | |||
return xxx_messageInfo_Packet.Size(m) | |||
} | |||
func (m *Packet) XXX_DiscardUnknown() { | |||
xxx_messageInfo_Packet.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_Packet proto.InternalMessageInfo | |||
type isPacket_Sum interface { | |||
isPacket_Sum() | |||
} | |||
type Packet_PacketPing struct { | |||
PacketPing *PacketPing `protobuf:"bytes,1,opt,name=packet_ping,json=packetPing,proto3,oneof" json:"packet_ping,omitempty"` | |||
} | |||
type Packet_PacketPong struct { | |||
PacketPong *PacketPong `protobuf:"bytes,2,opt,name=packet_pong,json=packetPong,proto3,oneof" json:"packet_pong,omitempty"` | |||
} | |||
type Packet_PacketMsg struct { | |||
PacketMsg *PacketMsg `protobuf:"bytes,3,opt,name=packet_msg,json=packetMsg,proto3,oneof" json:"packet_msg,omitempty"` | |||
} | |||
func (*Packet_PacketPing) isPacket_Sum() {} | |||
func (*Packet_PacketPong) isPacket_Sum() {} | |||
func (*Packet_PacketMsg) isPacket_Sum() {} | |||
func (m *Packet) GetSum() isPacket_Sum { | |||
if m != nil { | |||
return m.Sum | |||
} | |||
return nil | |||
} | |||
func (m *Packet) GetPacketPing() *PacketPing { | |||
if x, ok := m.GetSum().(*Packet_PacketPing); ok { | |||
return x.PacketPing | |||
} | |||
return nil | |||
} | |||
func (m *Packet) GetPacketPong() *PacketPong { | |||
if x, ok := m.GetSum().(*Packet_PacketPong); ok { | |||
return x.PacketPong | |||
} | |||
return nil | |||
} | |||
func (m *Packet) GetPacketMsg() *PacketMsg { | |||
if x, ok := m.GetSum().(*Packet_PacketMsg); ok { | |||
return x.PacketMsg | |||
} | |||
return nil | |||
} | |||
// XXX_OneofWrappers is for the internal use of the proto package. | |||
func (*Packet) XXX_OneofWrappers() []interface{} { | |||
return []interface{}{ | |||
(*Packet_PacketPing)(nil), | |||
(*Packet_PacketPong)(nil), | |||
(*Packet_PacketMsg)(nil), | |||
} | |||
} | |||
func init() { | |||
proto.RegisterType((*PacketPing)(nil), "tendermint.proto.p2p.PacketPing") | |||
proto.RegisterType((*PacketPong)(nil), "tendermint.proto.p2p.PacketPong") | |||
proto.RegisterType((*PacketMsg)(nil), "tendermint.proto.p2p.PacketMsg") | |||
proto.RegisterType((*Packet)(nil), "tendermint.proto.p2p.Packet") | |||
} | |||
func init() { proto.RegisterFile("proto/p2p/conn_msgs.proto", fileDescriptor_8c680f0b24d73fe7) } | |||
var fileDescriptor_8c680f0b24d73fe7 = []byte{ | |||
// 295 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x91, 0xc1, 0x4f, 0x83, 0x30, | |||
0x14, 0xc6, 0x45, 0xdc, 0x0c, 0x8f, 0x79, 0x69, 0x3c, 0x30, 0x2f, 0x10, 0x0e, 0x66, 0x31, 0x0b, | |||
0x24, 0xf8, 0x0f, 0x18, 0xa6, 0xc6, 0x1d, 0x16, 0x17, 0x8e, 0x5e, 0x08, 0x03, 0x2c, 0x8d, 0xd2, | |||
0xd7, 0x40, 0x77, 0xf0, 0x6f, 0x35, 0xd9, 0x61, 0x7f, 0x89, 0xa1, 0x9d, 0x03, 0x13, 0xa3, 0xb7, | |||
0xef, 0xfb, 0xf2, 0xfa, 0x7b, 0x5f, 0x5b, 0x98, 0x8a, 0x06, 0x25, 0x86, 0x22, 0x12, 0x61, 0x8e, | |||
0x9c, 0xa7, 0x75, 0x4b, 0xdb, 0x40, 0x65, 0xe4, 0x52, 0x96, 0xbc, 0x28, 0x9b, 0x9a, 0x71, 0xa9, | |||
0x93, 0x40, 0x44, 0xe2, 0xea, 0x5a, 0x56, 0xac, 0x29, 0x52, 0x91, 0x35, 0xf2, 0x23, 0xd4, 0x87, | |||
0x29, 0x52, 0xec, 0x95, 0x9e, 0xf5, 0x27, 0x00, 0xeb, 0x2c, 0x7f, 0x2b, 0xe5, 0x9a, 0x71, 0x3a, | |||
0x70, 0xc8, 0xa9, 0x5f, 0x81, 0xa5, 0xdd, 0xaa, 0xa5, 0x64, 0x0e, 0x90, 0x57, 0x19, 0xe7, 0xe5, | |||
0x7b, 0xca, 0x0a, 0xc7, 0xf0, 0x8c, 0xd9, 0x28, 0xbe, 0xd8, 0xef, 0x5c, 0x6b, 0xa1, 0xd3, 0xe5, | |||
0x7d, 0x62, 0x1d, 0x06, 0x96, 0x05, 0x99, 0x82, 0x59, 0xe2, 0xab, 0x73, 0xaa, 0xc6, 0xce, 0xf7, | |||
0x3b, 0xd7, 0x7c, 0x78, 0x7e, 0x4c, 0xba, 0x8c, 0x10, 0x38, 0x2b, 0x32, 0x99, 0x39, 0xa6, 0x67, | |||
0xcc, 0x26, 0x89, 0xd2, 0xfe, 0xa7, 0x01, 0x63, 0xbd, 0x8a, 0x2c, 0xc0, 0x16, 0x4a, 0xa5, 0x82, | |||
0x71, 0xaa, 0x16, 0xd9, 0x91, 0x17, 0xfc, 0x76, 0xc9, 0xa0, 0x6f, 0xfe, 0x74, 0x92, 0x80, 0x38, | |||
0xba, 0x21, 0x04, 0x39, 0x55, 0x35, 0xfe, 0x83, 0xe0, 0x0f, 0x08, 0x72, 0x4a, 0xee, 0xe0, 0xe0, | |||
0xba, 0xd7, 0x56, 0x75, 0xed, 0xc8, 0xfd, 0x8b, 0xb1, 0x6a, 0x3b, 0x84, 0x25, 0xbe, 0x4d, 0x3c, | |||
0x02, 0xb3, 0xdd, 0xd6, 0xf1, 0xfc, 0xe5, 0x86, 0x32, 0x59, 0x6d, 0x37, 0x41, 0x8e, 0x75, 0xd8, | |||
0x03, 0x86, 0xf2, 0xf8, 0xbf, 0x9b, 0xb1, 0x92, 0xb7, 0x5f, 0x01, 0x00, 0x00, 0xff, 0xff, 0x87, | |||
0x8c, 0x0a, 0x5f, 0xf3, 0x01, 0x00, 0x00, | |||
} |
@ -0,0 +1,24 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.p2p; | |||
option go_package = "github.com/tendermint/tendermint/proto/p2p"; | |||
import "third_party/proto/gogoproto/gogo.proto"; | |||
message PacketPing {} | |||
message PacketPong {} | |||
message PacketMsg { | |||
int32 channel_id = 1 [(gogoproto.customname) = "ChannelID"]; | |||
int32 eof = 2 [(gogoproto.customname) = "EOF"]; | |||
bytes data = 3; | |||
} | |||
message Packet { | |||
oneof sum { | |||
PacketPing packet_ping = 1; | |||
PacketPong packet_pong = 2; | |||
PacketMsg packet_msg = 3; | |||
} | |||
} |
@ -0,0 +1,195 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/p2p/pex_msgs.proto | |||
package p2p | |||
import ( | |||
fmt "fmt" | |||
_ "github.com/gogo/protobuf/gogoproto" | |||
proto "github.com/gogo/protobuf/proto" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
type PexRequest struct { | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *PexRequest) Reset() { *m = PexRequest{} } | |||
func (m *PexRequest) String() string { return proto.CompactTextString(m) } | |||
func (*PexRequest) ProtoMessage() {} | |||
func (*PexRequest) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_b4d6fe6b009e47d8, []int{0} | |||
} | |||
func (m *PexRequest) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_PexRequest.Unmarshal(m, b) | |||
} | |||
func (m *PexRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_PexRequest.Marshal(b, m, deterministic) | |||
} | |||
func (m *PexRequest) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_PexRequest.Merge(m, src) | |||
} | |||
func (m *PexRequest) XXX_Size() int { | |||
return xxx_messageInfo_PexRequest.Size(m) | |||
} | |||
func (m *PexRequest) XXX_DiscardUnknown() { | |||
xxx_messageInfo_PexRequest.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_PexRequest proto.InternalMessageInfo | |||
type PexAddrs struct { | |||
Addrs []NetAddress `protobuf:"bytes,1,rep,name=addrs,proto3" json:"addrs"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *PexAddrs) Reset() { *m = PexAddrs{} } | |||
func (m *PexAddrs) String() string { return proto.CompactTextString(m) } | |||
func (*PexAddrs) ProtoMessage() {} | |||
func (*PexAddrs) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_b4d6fe6b009e47d8, []int{1} | |||
} | |||
func (m *PexAddrs) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_PexAddrs.Unmarshal(m, b) | |||
} | |||
func (m *PexAddrs) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_PexAddrs.Marshal(b, m, deterministic) | |||
} | |||
func (m *PexAddrs) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_PexAddrs.Merge(m, src) | |||
} | |||
func (m *PexAddrs) XXX_Size() int { | |||
return xxx_messageInfo_PexAddrs.Size(m) | |||
} | |||
func (m *PexAddrs) XXX_DiscardUnknown() { | |||
xxx_messageInfo_PexAddrs.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_PexAddrs proto.InternalMessageInfo | |||
func (m *PexAddrs) GetAddrs() []NetAddress { | |||
if m != nil { | |||
return m.Addrs | |||
} | |||
return nil | |||
} | |||
type Message struct { | |||
// Types that are valid to be assigned to Sum: | |||
// *Message_PexRequest | |||
// *Message_PexAddrs | |||
Sum isMessage_Sum `protobuf_oneof:"sum"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *Message) Reset() { *m = Message{} } | |||
func (m *Message) String() string { return proto.CompactTextString(m) } | |||
func (*Message) ProtoMessage() {} | |||
func (*Message) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_b4d6fe6b009e47d8, []int{2} | |||
} | |||
func (m *Message) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_Message.Unmarshal(m, b) | |||
} | |||
func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_Message.Marshal(b, m, deterministic) | |||
} | |||
func (m *Message) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_Message.Merge(m, src) | |||
} | |||
func (m *Message) XXX_Size() int { | |||
return xxx_messageInfo_Message.Size(m) | |||
} | |||
func (m *Message) XXX_DiscardUnknown() { | |||
xxx_messageInfo_Message.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_Message proto.InternalMessageInfo | |||
type isMessage_Sum interface { | |||
isMessage_Sum() | |||
} | |||
type Message_PexRequest struct { | |||
PexRequest *PexRequest `protobuf:"bytes,1,opt,name=pex_request,json=pexRequest,proto3,oneof" json:"pex_request,omitempty"` | |||
} | |||
type Message_PexAddrs struct { | |||
PexAddrs *PexAddrs `protobuf:"bytes,2,opt,name=pex_addrs,json=pexAddrs,proto3,oneof" json:"pex_addrs,omitempty"` | |||
} | |||
func (*Message_PexRequest) isMessage_Sum() {} | |||
func (*Message_PexAddrs) isMessage_Sum() {} | |||
func (m *Message) GetSum() isMessage_Sum { | |||
if m != nil { | |||
return m.Sum | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetPexRequest() *PexRequest { | |||
if x, ok := m.GetSum().(*Message_PexRequest); ok { | |||
return x.PexRequest | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetPexAddrs() *PexAddrs { | |||
if x, ok := m.GetSum().(*Message_PexAddrs); ok { | |||
return x.PexAddrs | |||
} | |||
return nil | |||
} | |||
// XXX_OneofWrappers is for the internal use of the proto package. | |||
func (*Message) XXX_OneofWrappers() []interface{} { | |||
return []interface{}{ | |||
(*Message_PexRequest)(nil), | |||
(*Message_PexAddrs)(nil), | |||
} | |||
} | |||
func init() { | |||
proto.RegisterType((*PexRequest)(nil), "tendermint.proto.p2p.PexRequest") | |||
proto.RegisterType((*PexAddrs)(nil), "tendermint.proto.p2p.PexAddrs") | |||
proto.RegisterType((*Message)(nil), "tendermint.proto.p2p.Message") | |||
} | |||
func init() { proto.RegisterFile("proto/p2p/pex_msgs.proto", fileDescriptor_b4d6fe6b009e47d8) } | |||
var fileDescriptor_b4d6fe6b009e47d8 = []byte{ | |||
// 255 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x28, 0x28, 0xca, 0x2f, | |||
0xc9, 0xd7, 0x2f, 0x30, 0x2a, 0xd0, 0x2f, 0x48, 0xad, 0x88, 0xcf, 0x2d, 0x4e, 0x2f, 0xd6, 0x03, | |||
0x0b, 0x09, 0x89, 0x94, 0xa4, 0xe6, 0xa5, 0xa4, 0x16, 0xe5, 0x66, 0xe6, 0x95, 0x40, 0x44, 0xf4, | |||
0x0a, 0x8c, 0x0a, 0xa4, 0x44, 0x11, 0xea, 0x4b, 0x2a, 0x0b, 0x52, 0xa1, 0x8a, 0xa5, 0xd4, 0x4a, | |||
0x32, 0x32, 0x8b, 0x52, 0xe2, 0x0b, 0x12, 0x8b, 0x4a, 0x2a, 0xf5, 0x21, 0x4a, 0xd2, 0xf3, 0xd3, | |||
0xf3, 0x11, 0x2c, 0x88, 0x3a, 0x25, 0x1e, 0x2e, 0xae, 0x80, 0xd4, 0x8a, 0xa0, 0xd4, 0xc2, 0xd2, | |||
0xd4, 0xe2, 0x12, 0x25, 0x0f, 0x2e, 0x8e, 0x80, 0xd4, 0x0a, 0xc7, 0x94, 0x94, 0xa2, 0x62, 0x21, | |||
0x1b, 0x2e, 0xd6, 0x44, 0x10, 0x43, 0x82, 0x51, 0x81, 0x59, 0x83, 0xdb, 0x48, 0x41, 0x0f, 0x9b, | |||
0xf5, 0x7a, 0x7e, 0xa9, 0x25, 0x20, 0xe5, 0xa9, 0xc5, 0xc5, 0x4e, 0x2c, 0x27, 0xee, 0xc9, 0x33, | |||
0x04, 0x41, 0x34, 0x29, 0x4d, 0x61, 0xe4, 0x62, 0xf7, 0x4d, 0x2d, 0x2e, 0x4e, 0x4c, 0x4f, 0x15, | |||
0x72, 0xe6, 0xe2, 0x06, 0x79, 0xa5, 0x08, 0x62, 0x89, 0x04, 0xa3, 0x02, 0x23, 0x6e, 0xf3, 0x10, | |||
0x8e, 0xf1, 0x60, 0x08, 0xe2, 0x2a, 0x80, 0xf3, 0x84, 0x6c, 0xb9, 0x38, 0x41, 0x86, 0x40, 0x9c, | |||
0xc4, 0x04, 0x36, 0x42, 0x0e, 0xa7, 0x11, 0x60, 0x1f, 0x78, 0x30, 0x04, 0x71, 0x14, 0x40, 0xd9, | |||
0x4e, 0xac, 0x5c, 0xcc, 0xc5, 0xa5, 0xb9, 0x4e, 0x3a, 0x51, 0x5a, 0xe9, 0x99, 0x25, 0x19, 0xa5, | |||
0x49, 0x7a, 0xc9, 0xf9, 0xb9, 0xfa, 0x08, 0xed, 0xc8, 0x4c, 0x78, 0x80, 0x26, 0xb1, 0x81, 0x99, | |||
0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x73, 0x54, 0xb6, 0xcc, 0x94, 0x01, 0x00, 0x00, | |||
} |
@ -0,0 +1,20 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.p2p; | |||
option go_package = "github.com/tendermint/tendermint/proto/p2p"; | |||
import "proto/p2p/types.proto"; | |||
import "third_party/proto/gogoproto/gogo.proto"; | |||
message PexRequest {} | |||
message PexAddrs { | |||
repeated NetAddress addrs = 1 [(gogoproto.nullable) = false]; | |||
} | |||
message Message { | |||
oneof sum { | |||
PexRequest pex_request = 1; | |||
PexAddrs pex_addrs = 2; | |||
} | |||
} |
@ -0,0 +1,321 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/p2p/types.proto | |||
package p2p | |||
import ( | |||
fmt "fmt" | |||
_ "github.com/gogo/protobuf/gogoproto" | |||
proto "github.com/gogo/protobuf/proto" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
type NetAddress struct { | |||
ID string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"` | |||
IP string `protobuf:"bytes,2,opt,name=ip,proto3" json:"ip,omitempty"` | |||
Port uint32 `protobuf:"varint,3,opt,name=port,proto3" json:"port,omitempty"` | |||
Str string `protobuf:"bytes,4,opt,name=str,proto3" json:"str,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *NetAddress) Reset() { *m = NetAddress{} } | |||
func (m *NetAddress) String() string { return proto.CompactTextString(m) } | |||
func (*NetAddress) ProtoMessage() {} | |||
func (*NetAddress) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_5c4320c1810ca85c, []int{0} | |||
} | |||
func (m *NetAddress) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_NetAddress.Unmarshal(m, b) | |||
} | |||
func (m *NetAddress) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_NetAddress.Marshal(b, m, deterministic) | |||
} | |||
func (m *NetAddress) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_NetAddress.Merge(m, src) | |||
} | |||
func (m *NetAddress) XXX_Size() int { | |||
return xxx_messageInfo_NetAddress.Size(m) | |||
} | |||
func (m *NetAddress) XXX_DiscardUnknown() { | |||
xxx_messageInfo_NetAddress.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_NetAddress proto.InternalMessageInfo | |||
func (m *NetAddress) GetID() string { | |||
if m != nil { | |||
return m.ID | |||
} | |||
return "" | |||
} | |||
func (m *NetAddress) GetIP() string { | |||
if m != nil { | |||
return m.IP | |||
} | |||
return "" | |||
} | |||
func (m *NetAddress) GetPort() uint32 { | |||
if m != nil { | |||
return m.Port | |||
} | |||
return 0 | |||
} | |||
func (m *NetAddress) GetStr() string { | |||
if m != nil { | |||
return m.Str | |||
} | |||
return "" | |||
} | |||
type ProtocolVersion struct { | |||
P2P uint64 `protobuf:"varint,1,opt,name=p2p,proto3" json:"p2p,omitempty"` | |||
Block uint64 `protobuf:"varint,2,opt,name=block,proto3" json:"block,omitempty"` | |||
App uint64 `protobuf:"varint,3,opt,name=app,proto3" json:"app,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *ProtocolVersion) Reset() { *m = ProtocolVersion{} } | |||
func (m *ProtocolVersion) String() string { return proto.CompactTextString(m) } | |||
func (*ProtocolVersion) ProtoMessage() {} | |||
func (*ProtocolVersion) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_5c4320c1810ca85c, []int{1} | |||
} | |||
func (m *ProtocolVersion) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_ProtocolVersion.Unmarshal(m, b) | |||
} | |||
func (m *ProtocolVersion) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_ProtocolVersion.Marshal(b, m, deterministic) | |||
} | |||
func (m *ProtocolVersion) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_ProtocolVersion.Merge(m, src) | |||
} | |||
func (m *ProtocolVersion) XXX_Size() int { | |||
return xxx_messageInfo_ProtocolVersion.Size(m) | |||
} | |||
func (m *ProtocolVersion) XXX_DiscardUnknown() { | |||
xxx_messageInfo_ProtocolVersion.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_ProtocolVersion proto.InternalMessageInfo | |||
func (m *ProtocolVersion) GetP2P() uint64 { | |||
if m != nil { | |||
return m.P2P | |||
} | |||
return 0 | |||
} | |||
func (m *ProtocolVersion) GetBlock() uint64 { | |||
if m != nil { | |||
return m.Block | |||
} | |||
return 0 | |||
} | |||
func (m *ProtocolVersion) GetApp() uint64 { | |||
if m != nil { | |||
return m.App | |||
} | |||
return 0 | |||
} | |||
type DefaultNodeInfo struct { | |||
ProtocolVersion ProtocolVersion `protobuf:"bytes,1,opt,name=protocol_version,json=protocolVersion,proto3" json:"protocol_version"` | |||
DefaultNodeID string `protobuf:"bytes,2,opt,name=default_node_id,json=defaultNodeId,proto3" json:"default_node_id,omitempty"` | |||
ListenAddr string `protobuf:"bytes,3,opt,name=listen_addr,json=listenAddr,proto3" json:"listen_addr,omitempty"` | |||
Network string `protobuf:"bytes,4,opt,name=network,proto3" json:"network,omitempty"` | |||
Version string `protobuf:"bytes,5,opt,name=version,proto3" json:"version,omitempty"` | |||
Channels []byte `protobuf:"bytes,6,opt,name=channels,proto3" json:"channels,omitempty"` | |||
Moniker string `protobuf:"bytes,7,opt,name=moniker,proto3" json:"moniker,omitempty"` | |||
Other DefaultNodeInfoOther `protobuf:"bytes,8,opt,name=other,proto3" json:"other"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *DefaultNodeInfo) Reset() { *m = DefaultNodeInfo{} } | |||
func (m *DefaultNodeInfo) String() string { return proto.CompactTextString(m) } | |||
func (*DefaultNodeInfo) ProtoMessage() {} | |||
func (*DefaultNodeInfo) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_5c4320c1810ca85c, []int{2} | |||
} | |||
func (m *DefaultNodeInfo) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_DefaultNodeInfo.Unmarshal(m, b) | |||
} | |||
func (m *DefaultNodeInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_DefaultNodeInfo.Marshal(b, m, deterministic) | |||
} | |||
func (m *DefaultNodeInfo) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_DefaultNodeInfo.Merge(m, src) | |||
} | |||
func (m *DefaultNodeInfo) XXX_Size() int { | |||
return xxx_messageInfo_DefaultNodeInfo.Size(m) | |||
} | |||
func (m *DefaultNodeInfo) XXX_DiscardUnknown() { | |||
xxx_messageInfo_DefaultNodeInfo.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_DefaultNodeInfo proto.InternalMessageInfo | |||
func (m *DefaultNodeInfo) GetProtocolVersion() ProtocolVersion { | |||
if m != nil { | |||
return m.ProtocolVersion | |||
} | |||
return ProtocolVersion{} | |||
} | |||
func (m *DefaultNodeInfo) GetDefaultNodeID() string { | |||
if m != nil { | |||
return m.DefaultNodeID | |||
} | |||
return "" | |||
} | |||
func (m *DefaultNodeInfo) GetListenAddr() string { | |||
if m != nil { | |||
return m.ListenAddr | |||
} | |||
return "" | |||
} | |||
func (m *DefaultNodeInfo) GetNetwork() string { | |||
if m != nil { | |||
return m.Network | |||
} | |||
return "" | |||
} | |||
func (m *DefaultNodeInfo) GetVersion() string { | |||
if m != nil { | |||
return m.Version | |||
} | |||
return "" | |||
} | |||
func (m *DefaultNodeInfo) GetChannels() []byte { | |||
if m != nil { | |||
return m.Channels | |||
} | |||
return nil | |||
} | |||
func (m *DefaultNodeInfo) GetMoniker() string { | |||
if m != nil { | |||
return m.Moniker | |||
} | |||
return "" | |||
} | |||
func (m *DefaultNodeInfo) GetOther() DefaultNodeInfoOther { | |||
if m != nil { | |||
return m.Other | |||
} | |||
return DefaultNodeInfoOther{} | |||
} | |||
type DefaultNodeInfoOther struct { | |||
TxIndex string `protobuf:"bytes,1,opt,name=tx_index,json=txIndex,proto3" json:"tx_index,omitempty"` | |||
RPCAdddress string `protobuf:"bytes,2,opt,name=rpc_address,json=rpcAddress,proto3" json:"rpc_address,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *DefaultNodeInfoOther) Reset() { *m = DefaultNodeInfoOther{} } | |||
func (m *DefaultNodeInfoOther) String() string { return proto.CompactTextString(m) } | |||
func (*DefaultNodeInfoOther) ProtoMessage() {} | |||
func (*DefaultNodeInfoOther) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_5c4320c1810ca85c, []int{3} | |||
} | |||
func (m *DefaultNodeInfoOther) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_DefaultNodeInfoOther.Unmarshal(m, b) | |||
} | |||
func (m *DefaultNodeInfoOther) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_DefaultNodeInfoOther.Marshal(b, m, deterministic) | |||
} | |||
func (m *DefaultNodeInfoOther) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_DefaultNodeInfoOther.Merge(m, src) | |||
} | |||
func (m *DefaultNodeInfoOther) XXX_Size() int { | |||
return xxx_messageInfo_DefaultNodeInfoOther.Size(m) | |||
} | |||
func (m *DefaultNodeInfoOther) XXX_DiscardUnknown() { | |||
xxx_messageInfo_DefaultNodeInfoOther.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_DefaultNodeInfoOther proto.InternalMessageInfo | |||
func (m *DefaultNodeInfoOther) GetTxIndex() string { | |||
if m != nil { | |||
return m.TxIndex | |||
} | |||
return "" | |||
} | |||
func (m *DefaultNodeInfoOther) GetRPCAdddress() string { | |||
if m != nil { | |||
return m.RPCAdddress | |||
} | |||
return "" | |||
} | |||
func init() { | |||
proto.RegisterType((*NetAddress)(nil), "tendermint.proto.p2p.NetAddress") | |||
proto.RegisterType((*ProtocolVersion)(nil), "tendermint.proto.p2p.ProtocolVersion") | |||
proto.RegisterType((*DefaultNodeInfo)(nil), "tendermint.proto.p2p.DefaultNodeInfo") | |||
proto.RegisterType((*DefaultNodeInfoOther)(nil), "tendermint.proto.p2p.DefaultNodeInfoOther") | |||
} | |||
func init() { proto.RegisterFile("proto/p2p/types.proto", fileDescriptor_5c4320c1810ca85c) } | |||
var fileDescriptor_5c4320c1810ca85c = []byte{ | |||
// 471 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x53, 0xcf, 0x8a, 0xdb, 0x3e, | |||
0x18, 0xfc, 0xc5, 0x71, 0xfe, 0xec, 0x97, 0x5f, 0xf0, 0x56, 0xa4, 0xc5, 0xbb, 0x17, 0x87, 0x40, | |||
0x4b, 0x58, 0x8a, 0x53, 0xdc, 0x53, 0x8f, 0x9b, 0x86, 0x42, 0x2e, 0x5b, 0x23, 0xca, 0x1e, 0x7a, | |||
0x31, 0x8e, 0xa5, 0x4d, 0x44, 0x1c, 0x49, 0xc8, 0xda, 0x36, 0xfb, 0x86, 0x7d, 0x0a, 0x1f, 0xf2, | |||
0x12, 0xbd, 0x16, 0x49, 0xde, 0xdd, 0x10, 0x72, 0x9b, 0x19, 0x7d, 0xe3, 0xf9, 0x34, 0xc8, 0xf0, | |||
0x56, 0x2a, 0xa1, 0xc5, 0x4c, 0x26, 0x72, 0xa6, 0x9f, 0x24, 0xad, 0x62, 0xcb, 0xd1, 0x48, 0x53, | |||
0x4e, 0xa8, 0xda, 0x31, 0xae, 0x9d, 0x12, 0xcb, 0x44, 0x5e, 0x7f, 0xd0, 0x1b, 0xa6, 0x48, 0x26, | |||
0x73, 0xa5, 0x9f, 0x66, 0xce, 0xb8, 0x16, 0x6b, 0xf1, 0x8a, 0xdc, 0xec, 0x64, 0x05, 0x70, 0x47, | |||
0xf5, 0x2d, 0x21, 0x8a, 0x56, 0x15, 0x7a, 0x07, 0x1e, 0x23, 0x61, 0x6b, 0xdc, 0x9a, 0x5e, 0xcc, | |||
0xbb, 0x87, 0x3a, 0xf2, 0x96, 0x0b, 0xec, 0x31, 0x62, 0x75, 0x19, 0x7a, 0x47, 0x7a, 0x8a, 0x3d, | |||
0x26, 0x11, 0x02, 0x5f, 0x0a, 0xa5, 0xc3, 0xf6, 0xb8, 0x35, 0x1d, 0x62, 0x8b, 0xd1, 0x25, 0xb4, | |||
0x2b, 0xad, 0x42, 0xdf, 0x0c, 0x63, 0x03, 0x27, 0x3f, 0x20, 0x48, 0x4d, 0x58, 0x21, 0xca, 0x7b, | |||
0xaa, 0x2a, 0x26, 0x38, 0xba, 0x82, 0xb6, 0x4c, 0xa4, 0x4d, 0xf2, 0xe7, 0xbd, 0x43, 0x1d, 0xb5, | |||
0xd3, 0x24, 0xc5, 0x46, 0x43, 0x23, 0xe8, 0xac, 0x4a, 0x51, 0x6c, 0x6d, 0x9c, 0x8f, 0x1d, 0x31, | |||
0x5f, 0xcd, 0xa5, 0xb4, 0x41, 0x3e, 0x36, 0x70, 0xf2, 0xd7, 0x83, 0x60, 0x41, 0x1f, 0xf2, 0xc7, | |||
0x52, 0xdf, 0x09, 0x42, 0x97, 0xfc, 0x41, 0xa0, 0x7b, 0xb8, 0x94, 0x4d, 0x52, 0xf6, 0xcb, 0x45, | |||
0xd9, 0x8c, 0x41, 0xf2, 0x3e, 0x3e, 0x57, 0x53, 0x7c, 0xb2, 0xd7, 0xdc, 0xff, 0x53, 0x47, 0xff, | |||
0xe1, 0x40, 0x9e, 0xac, 0xfb, 0x05, 0x02, 0xe2, 0xa2, 0x32, 0x2e, 0x08, 0xcd, 0x18, 0x69, 0xca, | |||
0x78, 0x73, 0xa8, 0xa3, 0xe1, 0xf1, 0x16, 0x0b, 0x3c, 0x24, 0x47, 0x94, 0xa0, 0x08, 0x06, 0x25, | |||
0xab, 0x34, 0xe5, 0x59, 0x4e, 0x88, 0xb2, 0x17, 0xb8, 0xc0, 0xe0, 0x24, 0x53, 0x3b, 0x0a, 0xa1, | |||
0xc7, 0xa9, 0xfe, 0x2d, 0xd4, 0xb6, 0xe9, 0xec, 0x99, 0x9a, 0x93, 0xe7, 0x4b, 0x74, 0xdc, 0x49, | |||
0x43, 0xd1, 0x35, 0xf4, 0x8b, 0x4d, 0xce, 0x39, 0x2d, 0xab, 0xb0, 0x3b, 0x6e, 0x4d, 0xff, 0xc7, | |||
0x2f, 0xdc, 0xb8, 0x76, 0x82, 0xb3, 0x2d, 0x55, 0x61, 0xcf, 0xb9, 0x1a, 0x8a, 0xbe, 0x41, 0x47, | |||
0xe8, 0x0d, 0x55, 0x61, 0xdf, 0x56, 0x72, 0x73, 0xbe, 0x92, 0x93, 0x4e, 0xbf, 0x1b, 0x47, 0xd3, | |||
0x8b, 0xb3, 0x4f, 0x0a, 0x18, 0x9d, 0x1b, 0x42, 0x57, 0xd0, 0xd7, 0xfb, 0x8c, 0x71, 0x42, 0xf7, | |||
0xee, 0x0d, 0xe1, 0x9e, 0xde, 0x2f, 0x0d, 0x45, 0x9f, 0x60, 0xa0, 0x64, 0x61, 0x2b, 0xa0, 0x55, | |||
0xd5, 0x94, 0x17, 0x1c, 0xea, 0x68, 0x80, 0xd3, 0xaf, 0xb7, 0xc4, 0xc9, 0x18, 0x94, 0x2c, 0x9a, | |||
0xa7, 0x38, 0xff, 0xf8, 0xf3, 0x66, 0xcd, 0xf4, 0xe6, 0x71, 0x15, 0x17, 0x62, 0x37, 0x7b, 0xdd, | |||
0xf4, 0x18, 0xbe, 0xfc, 0x10, 0xab, 0xae, 0x85, 0x9f, 0xff, 0x05, 0x00, 0x00, 0xff, 0xff, 0xa2, | |||
0x36, 0x05, 0x66, 0x24, 0x03, 0x00, 0x00, | |||
} |
@ -0,0 +1,35 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.p2p; | |||
option go_package = "github.com/tendermint/tendermint/proto/p2p"; | |||
import "third_party/proto/gogoproto/gogo.proto"; | |||
message NetAddress { | |||
string id = 1 [(gogoproto.customname) = "ID"]; | |||
string ip = 2 [(gogoproto.customname) = "IP"]; | |||
uint32 port = 3; | |||
string str = 4; | |||
} | |||
message ProtocolVersion { | |||
uint64 p2p = 1 [(gogoproto.customname) = "P2P"]; | |||
uint64 block = 2; | |||
uint64 app = 3; | |||
} | |||
message DefaultNodeInfo { | |||
ProtocolVersion protocol_version = 1 [(gogoproto.nullable) = false]; | |||
string default_node_id = 2 [(gogoproto.customname) = "DefaultNodeID"]; | |||
string listen_addr = 3; | |||
string network = 4; | |||
string version = 5; | |||
bytes channels = 6; | |||
string moniker = 7; | |||
DefaultNodeInfoOther other = 8 [(gogoproto.nullable) = false]; | |||
} | |||
message DefaultNodeInfoOther { | |||
string tx_index = 1; | |||
string rpc_address = 2 [(gogoproto.customname) = "RPCAdddress"]; | |||
} |
@ -0,0 +1,426 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/privval/msgs.proto | |||
package privval | |||
import ( | |||
fmt "fmt" | |||
_ "github.com/gogo/protobuf/gogoproto" | |||
proto "github.com/gogo/protobuf/proto" | |||
keys "github.com/tendermint/tendermint/proto/crypto/keys" | |||
types "github.com/tendermint/tendermint/proto/types" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
type RemoteSignerError struct { | |||
Code int32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` | |||
Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *RemoteSignerError) Reset() { *m = RemoteSignerError{} } | |||
func (m *RemoteSignerError) String() string { return proto.CompactTextString(m) } | |||
func (*RemoteSignerError) ProtoMessage() {} | |||
func (*RemoteSignerError) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9ec52cc5e378f9a4, []int{0} | |||
} | |||
func (m *RemoteSignerError) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_RemoteSignerError.Unmarshal(m, b) | |||
} | |||
func (m *RemoteSignerError) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_RemoteSignerError.Marshal(b, m, deterministic) | |||
} | |||
func (m *RemoteSignerError) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_RemoteSignerError.Merge(m, src) | |||
} | |||
func (m *RemoteSignerError) XXX_Size() int { | |||
return xxx_messageInfo_RemoteSignerError.Size(m) | |||
} | |||
func (m *RemoteSignerError) XXX_DiscardUnknown() { | |||
xxx_messageInfo_RemoteSignerError.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_RemoteSignerError proto.InternalMessageInfo | |||
func (m *RemoteSignerError) GetCode() int32 { | |||
if m != nil { | |||
return m.Code | |||
} | |||
return 0 | |||
} | |||
func (m *RemoteSignerError) GetDescription() string { | |||
if m != nil { | |||
return m.Description | |||
} | |||
return "" | |||
} | |||
// PubKeyRequest requests the consensus public key from the remote signer. | |||
type PubKeyRequest struct { | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *PubKeyRequest) Reset() { *m = PubKeyRequest{} } | |||
func (m *PubKeyRequest) String() string { return proto.CompactTextString(m) } | |||
func (*PubKeyRequest) ProtoMessage() {} | |||
func (*PubKeyRequest) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9ec52cc5e378f9a4, []int{1} | |||
} | |||
func (m *PubKeyRequest) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_PubKeyRequest.Unmarshal(m, b) | |||
} | |||
func (m *PubKeyRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_PubKeyRequest.Marshal(b, m, deterministic) | |||
} | |||
func (m *PubKeyRequest) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_PubKeyRequest.Merge(m, src) | |||
} | |||
func (m *PubKeyRequest) XXX_Size() int { | |||
return xxx_messageInfo_PubKeyRequest.Size(m) | |||
} | |||
func (m *PubKeyRequest) XXX_DiscardUnknown() { | |||
xxx_messageInfo_PubKeyRequest.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_PubKeyRequest proto.InternalMessageInfo | |||
// PubKeyResponse is a response message containing the public key. | |||
type PubKeyResponse struct { | |||
PubKey keys.PublicKey `protobuf:"bytes,1,opt,name=pub_key,json=pubKey,proto3" json:"pub_key"` | |||
Error *RemoteSignerError `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *PubKeyResponse) Reset() { *m = PubKeyResponse{} } | |||
func (m *PubKeyResponse) String() string { return proto.CompactTextString(m) } | |||
func (*PubKeyResponse) ProtoMessage() {} | |||
func (*PubKeyResponse) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9ec52cc5e378f9a4, []int{2} | |||
} | |||
func (m *PubKeyResponse) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_PubKeyResponse.Unmarshal(m, b) | |||
} | |||
func (m *PubKeyResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_PubKeyResponse.Marshal(b, m, deterministic) | |||
} | |||
func (m *PubKeyResponse) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_PubKeyResponse.Merge(m, src) | |||
} | |||
func (m *PubKeyResponse) XXX_Size() int { | |||
return xxx_messageInfo_PubKeyResponse.Size(m) | |||
} | |||
func (m *PubKeyResponse) XXX_DiscardUnknown() { | |||
xxx_messageInfo_PubKeyResponse.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_PubKeyResponse proto.InternalMessageInfo | |||
func (m *PubKeyResponse) GetPubKey() keys.PublicKey { | |||
if m != nil { | |||
return m.PubKey | |||
} | |||
return keys.PublicKey{} | |||
} | |||
func (m *PubKeyResponse) GetError() *RemoteSignerError { | |||
if m != nil { | |||
return m.Error | |||
} | |||
return nil | |||
} | |||
// SignVoteRequest is a request to sign a vote | |||
type SignVoteRequest struct { | |||
Vote types.Vote `protobuf:"bytes,1,opt,name=vote,proto3" json:"vote"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *SignVoteRequest) Reset() { *m = SignVoteRequest{} } | |||
func (m *SignVoteRequest) String() string { return proto.CompactTextString(m) } | |||
func (*SignVoteRequest) ProtoMessage() {} | |||
func (*SignVoteRequest) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9ec52cc5e378f9a4, []int{3} | |||
} | |||
func (m *SignVoteRequest) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_SignVoteRequest.Unmarshal(m, b) | |||
} | |||
func (m *SignVoteRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_SignVoteRequest.Marshal(b, m, deterministic) | |||
} | |||
func (m *SignVoteRequest) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_SignVoteRequest.Merge(m, src) | |||
} | |||
func (m *SignVoteRequest) XXX_Size() int { | |||
return xxx_messageInfo_SignVoteRequest.Size(m) | |||
} | |||
func (m *SignVoteRequest) XXX_DiscardUnknown() { | |||
xxx_messageInfo_SignVoteRequest.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_SignVoteRequest proto.InternalMessageInfo | |||
func (m *SignVoteRequest) GetVote() types.Vote { | |||
if m != nil { | |||
return m.Vote | |||
} | |||
return types.Vote{} | |||
} | |||
// SignedVoteResponse is a response containing a signed vote or an error | |||
type SignVoteResponse struct { | |||
Vote types.Vote `protobuf:"bytes,1,opt,name=vote,proto3" json:"vote"` | |||
Error *RemoteSignerError `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *SignVoteResponse) Reset() { *m = SignVoteResponse{} } | |||
func (m *SignVoteResponse) String() string { return proto.CompactTextString(m) } | |||
func (*SignVoteResponse) ProtoMessage() {} | |||
func (*SignVoteResponse) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9ec52cc5e378f9a4, []int{4} | |||
} | |||
func (m *SignVoteResponse) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_SignVoteResponse.Unmarshal(m, b) | |||
} | |||
func (m *SignVoteResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_SignVoteResponse.Marshal(b, m, deterministic) | |||
} | |||
func (m *SignVoteResponse) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_SignVoteResponse.Merge(m, src) | |||
} | |||
func (m *SignVoteResponse) XXX_Size() int { | |||
return xxx_messageInfo_SignVoteResponse.Size(m) | |||
} | |||
func (m *SignVoteResponse) XXX_DiscardUnknown() { | |||
xxx_messageInfo_SignVoteResponse.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_SignVoteResponse proto.InternalMessageInfo | |||
func (m *SignVoteResponse) GetVote() types.Vote { | |||
if m != nil { | |||
return m.Vote | |||
} | |||
return types.Vote{} | |||
} | |||
func (m *SignVoteResponse) GetError() *RemoteSignerError { | |||
if m != nil { | |||
return m.Error | |||
} | |||
return nil | |||
} | |||
// SignProposalRequest is a request to sign a proposal | |||
type SignProposalRequest struct { | |||
Proposal types.Proposal `protobuf:"bytes,1,opt,name=proposal,proto3" json:"proposal"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *SignProposalRequest) Reset() { *m = SignProposalRequest{} } | |||
func (m *SignProposalRequest) String() string { return proto.CompactTextString(m) } | |||
func (*SignProposalRequest) ProtoMessage() {} | |||
func (*SignProposalRequest) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9ec52cc5e378f9a4, []int{5} | |||
} | |||
func (m *SignProposalRequest) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_SignProposalRequest.Unmarshal(m, b) | |||
} | |||
func (m *SignProposalRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_SignProposalRequest.Marshal(b, m, deterministic) | |||
} | |||
func (m *SignProposalRequest) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_SignProposalRequest.Merge(m, src) | |||
} | |||
func (m *SignProposalRequest) XXX_Size() int { | |||
return xxx_messageInfo_SignProposalRequest.Size(m) | |||
} | |||
func (m *SignProposalRequest) XXX_DiscardUnknown() { | |||
xxx_messageInfo_SignProposalRequest.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_SignProposalRequest proto.InternalMessageInfo | |||
func (m *SignProposalRequest) GetProposal() types.Proposal { | |||
if m != nil { | |||
return m.Proposal | |||
} | |||
return types.Proposal{} | |||
} | |||
// SignedProposalResponse is response containing a signed proposal or an error | |||
type SignedProposalResponse struct { | |||
Proposal types.Proposal `protobuf:"bytes,1,opt,name=proposal,proto3" json:"proposal"` | |||
Error *RemoteSignerError `protobuf:"bytes,2,opt,name=error,proto3" json:"error,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *SignedProposalResponse) Reset() { *m = SignedProposalResponse{} } | |||
func (m *SignedProposalResponse) String() string { return proto.CompactTextString(m) } | |||
func (*SignedProposalResponse) ProtoMessage() {} | |||
func (*SignedProposalResponse) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9ec52cc5e378f9a4, []int{6} | |||
} | |||
func (m *SignedProposalResponse) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_SignedProposalResponse.Unmarshal(m, b) | |||
} | |||
func (m *SignedProposalResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_SignedProposalResponse.Marshal(b, m, deterministic) | |||
} | |||
func (m *SignedProposalResponse) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_SignedProposalResponse.Merge(m, src) | |||
} | |||
func (m *SignedProposalResponse) XXX_Size() int { | |||
return xxx_messageInfo_SignedProposalResponse.Size(m) | |||
} | |||
func (m *SignedProposalResponse) XXX_DiscardUnknown() { | |||
xxx_messageInfo_SignedProposalResponse.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_SignedProposalResponse proto.InternalMessageInfo | |||
func (m *SignedProposalResponse) GetProposal() types.Proposal { | |||
if m != nil { | |||
return m.Proposal | |||
} | |||
return types.Proposal{} | |||
} | |||
func (m *SignedProposalResponse) GetError() *RemoteSignerError { | |||
if m != nil { | |||
return m.Error | |||
} | |||
return nil | |||
} | |||
// PingRequest is a request to confirm that the connection is alive. | |||
type PingRequest struct { | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *PingRequest) Reset() { *m = PingRequest{} } | |||
func (m *PingRequest) String() string { return proto.CompactTextString(m) } | |||
func (*PingRequest) ProtoMessage() {} | |||
func (*PingRequest) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9ec52cc5e378f9a4, []int{7} | |||
} | |||
func (m *PingRequest) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_PingRequest.Unmarshal(m, b) | |||
} | |||
func (m *PingRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_PingRequest.Marshal(b, m, deterministic) | |||
} | |||
func (m *PingRequest) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_PingRequest.Merge(m, src) | |||
} | |||
func (m *PingRequest) XXX_Size() int { | |||
return xxx_messageInfo_PingRequest.Size(m) | |||
} | |||
func (m *PingRequest) XXX_DiscardUnknown() { | |||
xxx_messageInfo_PingRequest.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_PingRequest proto.InternalMessageInfo | |||
// PingResponse is a response to confirm that the connection is alive. | |||
type PingResponse struct { | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *PingResponse) Reset() { *m = PingResponse{} } | |||
func (m *PingResponse) String() string { return proto.CompactTextString(m) } | |||
func (*PingResponse) ProtoMessage() {} | |||
func (*PingResponse) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_9ec52cc5e378f9a4, []int{8} | |||
} | |||
func (m *PingResponse) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_PingResponse.Unmarshal(m, b) | |||
} | |||
func (m *PingResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_PingResponse.Marshal(b, m, deterministic) | |||
} | |||
func (m *PingResponse) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_PingResponse.Merge(m, src) | |||
} | |||
func (m *PingResponse) XXX_Size() int { | |||
return xxx_messageInfo_PingResponse.Size(m) | |||
} | |||
func (m *PingResponse) XXX_DiscardUnknown() { | |||
xxx_messageInfo_PingResponse.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_PingResponse proto.InternalMessageInfo | |||
func init() { | |||
proto.RegisterType((*RemoteSignerError)(nil), "tendermint.proto.privval.RemoteSignerError") | |||
proto.RegisterType((*PubKeyRequest)(nil), "tendermint.proto.privval.PubKeyRequest") | |||
proto.RegisterType((*PubKeyResponse)(nil), "tendermint.proto.privval.PubKeyResponse") | |||
proto.RegisterType((*SignVoteRequest)(nil), "tendermint.proto.privval.SignVoteRequest") | |||
proto.RegisterType((*SignVoteResponse)(nil), "tendermint.proto.privval.SignVoteResponse") | |||
proto.RegisterType((*SignProposalRequest)(nil), "tendermint.proto.privval.SignProposalRequest") | |||
proto.RegisterType((*SignedProposalResponse)(nil), "tendermint.proto.privval.SignedProposalResponse") | |||
proto.RegisterType((*PingRequest)(nil), "tendermint.proto.privval.PingRequest") | |||
proto.RegisterType((*PingResponse)(nil), "tendermint.proto.privval.PingResponse") | |||
} | |||
func init() { proto.RegisterFile("proto/privval/msgs.proto", fileDescriptor_9ec52cc5e378f9a4) } | |||
var fileDescriptor_9ec52cc5e378f9a4 = []byte{ | |||
// 401 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x93, 0xd1, 0xca, 0xd3, 0x30, | |||
0x1c, 0xc5, 0xad, 0x6c, 0x53, 0xff, 0x75, 0x9b, 0x56, 0xd0, 0x32, 0x14, 0x4b, 0x2f, 0x74, 0x20, | |||
0xa4, 0x32, 0xc1, 0x7b, 0x07, 0x0a, 0x63, 0x37, 0xa5, 0x82, 0xa0, 0x37, 0x63, 0x6d, 0xff, 0x74, | |||
0x61, 0x6b, 0x13, 0x93, 0x74, 0xd0, 0x87, 0xf0, 0x09, 0xbc, 0xf0, 0x75, 0x7c, 0x0a, 0x9f, 0x45, | |||
0x9a, 0xa4, 0x5f, 0xf7, 0x31, 0x76, 0xf3, 0xb1, 0xbb, 0xe4, 0xe4, 0x7f, 0x4e, 0xce, 0x2f, 0xb4, | |||
0xe0, 0x73, 0xc1, 0x14, 0x8b, 0xb8, 0xa0, 0xc7, 0xe3, 0xf6, 0x10, 0x95, 0xb2, 0x90, 0x44, 0x4b, | |||
0x9e, 0xaf, 0xb0, 0xca, 0x51, 0x94, 0xb4, 0x52, 0x46, 0x21, 0x76, 0x68, 0xf6, 0x46, 0xed, 0xa8, | |||
0xc8, 0x37, 0x7c, 0x2b, 0x54, 0x13, 0x19, 0x7f, 0xc1, 0x0a, 0xd6, 0xaf, 0xcc, 0xfc, 0xec, 0x95, | |||
0x51, 0x32, 0xd1, 0x70, 0xc5, 0xa2, 0x3d, 0x36, 0x32, 0x52, 0x0d, 0x47, 0x7b, 0xc1, 0xec, 0x85, | |||
0x39, 0xd6, 0xd2, 0xe9, 0x41, 0xb8, 0x82, 0xa7, 0x09, 0x96, 0x4c, 0xe1, 0x57, 0x5a, 0x54, 0x28, | |||
0x3e, 0x0b, 0xc1, 0x84, 0xe7, 0xc1, 0x20, 0x63, 0x39, 0xfa, 0x4e, 0xe0, 0xcc, 0x87, 0x89, 0x5e, | |||
0x7b, 0x01, 0xb8, 0x39, 0xca, 0x4c, 0x50, 0xae, 0x28, 0xab, 0xfc, 0xfb, 0x81, 0x33, 0x7f, 0x94, | |||
0x9c, 0x4a, 0xe1, 0x14, 0xc6, 0x71, 0x9d, 0xae, 0xb1, 0x49, 0xf0, 0x67, 0x8d, 0x52, 0x85, 0xbf, | |||
0x1d, 0x98, 0x74, 0x8a, 0xe4, 0xac, 0x92, 0xe8, 0x7d, 0x81, 0x07, 0xbc, 0x4e, 0x37, 0x7b, 0x6c, | |||
0x74, 0xb8, 0xbb, 0x78, 0x4b, 0xce, 0xd0, 0x0d, 0x03, 0x69, 0x19, 0x48, 0x5c, 0xa7, 0x07, 0x9a, | |||
0xad, 0xb1, 0x59, 0x0e, 0xfe, 0xfe, 0x7b, 0x7d, 0x2f, 0x19, 0x71, 0x9d, 0xe7, 0x7d, 0x82, 0x21, | |||
0xb6, 0x55, 0x75, 0x0f, 0x77, 0xf1, 0x8e, 0x5c, 0x7a, 0x40, 0x72, 0x46, 0x97, 0x18, 0x67, 0xb8, | |||
0x82, 0x69, 0xab, 0x7e, 0x63, 0x0a, 0x6d, 0x61, 0xef, 0x23, 0x0c, 0x8e, 0x4c, 0xa1, 0xad, 0xf6, | |||
0xf2, 0x3c, 0xd4, 0xbc, 0x5c, 0x6b, 0xb1, 0x7d, 0xf4, 0x7c, 0xf8, 0xcb, 0x81, 0x27, 0x7d, 0x96, | |||
0x45, 0xbd, 0x63, 0xd8, 0x35, 0xd0, 0xbe, 0xc3, 0xb3, 0x56, 0x8d, 0x05, 0xe3, 0x4c, 0x6e, 0x0f, | |||
0x1d, 0xde, 0x12, 0x1e, 0x72, 0x2b, 0xd9, 0x56, 0xc1, 0xa5, 0x56, 0x9d, 0xd5, 0x36, 0xbb, 0xf1, | |||
0x85, 0x7f, 0x1c, 0x78, 0xae, 0x6f, 0xcc, 0xfb, 0x74, 0x0b, 0x7c, 0x85, 0xf8, 0x6b, 0xc0, 0x8f, | |||
0xc1, 0x8d, 0x69, 0x55, 0x74, 0x1f, 0xe1, 0x04, 0x1e, 0x9b, 0xad, 0x69, 0xb9, 0x7c, 0xff, 0x83, | |||
0x14, 0x54, 0xed, 0xea, 0x94, 0x64, 0xac, 0x8c, 0xfa, 0xf8, 0xd3, 0xe5, 0xad, 0xff, 0x34, 0x1d, | |||
0xe9, 0xed, 0x87, 0xff, 0x01, 0x00, 0x00, 0xff, 0xff, 0xd1, 0x00, 0x13, 0x1c, 0xbf, 0x03, 0x00, | |||
0x00, | |||
} |
@ -0,0 +1,50 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.privval; | |||
option go_package = "github.com/tendermint/tendermint/proto/privval"; | |||
import "third_party/proto/gogoproto/gogo.proto"; | |||
import "proto/crypto/keys/types.proto"; | |||
import "proto/types/types.proto"; | |||
message RemoteSignerError { | |||
int32 code = 1; | |||
string description = 2; | |||
} | |||
// PubKeyRequest requests the consensus public key from the remote signer. | |||
message PubKeyRequest {} | |||
// PubKeyResponse is a response message containing the public key. | |||
message PubKeyResponse { | |||
tendermint.proto.crypto.keys.PublicKey pub_key = 1 [(gogoproto.nullable) = false]; | |||
RemoteSignerError error = 2; | |||
} | |||
// SignVoteRequest is a request to sign a vote | |||
message SignVoteRequest { | |||
tendermint.proto.types.Vote vote = 1 [(gogoproto.nullable) = false]; | |||
} | |||
// SignedVoteResponse is a response containing a signed vote or an error | |||
message SignVoteResponse { | |||
tendermint.proto.types.Vote vote = 1 [(gogoproto.nullable) = false]; | |||
RemoteSignerError error = 2; | |||
} | |||
// SignProposalRequest is a request to sign a proposal | |||
message SignProposalRequest { | |||
tendermint.proto.types.Proposal proposal = 1 [(gogoproto.nullable) = false]; | |||
} | |||
// SignedProposalResponse is response containing a signed proposal or an error | |||
message SignedProposalResponse { | |||
tendermint.proto.types.Proposal proposal = 1 [(gogoproto.nullable) = false]; | |||
RemoteSignerError error = 2; | |||
} | |||
// PingRequest is a request to confirm that the connection is alive. | |||
message PingRequest {} | |||
// PingResponse is a response to confirm that the connection is alive. | |||
message PingResponse {} |
@ -0,0 +1,199 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/privval/types.proto | |||
package privval | |||
import ( | |||
fmt "fmt" | |||
_ "github.com/gogo/protobuf/gogoproto" | |||
proto "github.com/gogo/protobuf/proto" | |||
keys "github.com/tendermint/tendermint/proto/crypto/keys" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
// FilePVKey stores the immutable part of PrivValidator. | |||
type FilePVKey struct { | |||
Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"` | |||
PubKey keys.PublicKey `protobuf:"bytes,2,opt,name=pub_key,json=pubKey,proto3" json:"pub_key"` | |||
PrivKey keys.PrivateKey `protobuf:"bytes,3,opt,name=priv_key,json=privKey,proto3" json:"priv_key"` | |||
FilePath string `protobuf:"bytes,4,opt,name=file_path,json=filePath,proto3" json:"file_path,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *FilePVKey) Reset() { *m = FilePVKey{} } | |||
func (m *FilePVKey) String() string { return proto.CompactTextString(m) } | |||
func (*FilePVKey) ProtoMessage() {} | |||
func (*FilePVKey) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_a9d74c406df3ad93, []int{0} | |||
} | |||
func (m *FilePVKey) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_FilePVKey.Unmarshal(m, b) | |||
} | |||
func (m *FilePVKey) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_FilePVKey.Marshal(b, m, deterministic) | |||
} | |||
func (m *FilePVKey) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_FilePVKey.Merge(m, src) | |||
} | |||
func (m *FilePVKey) XXX_Size() int { | |||
return xxx_messageInfo_FilePVKey.Size(m) | |||
} | |||
func (m *FilePVKey) XXX_DiscardUnknown() { | |||
xxx_messageInfo_FilePVKey.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_FilePVKey proto.InternalMessageInfo | |||
func (m *FilePVKey) GetAddress() []byte { | |||
if m != nil { | |||
return m.Address | |||
} | |||
return nil | |||
} | |||
func (m *FilePVKey) GetPubKey() keys.PublicKey { | |||
if m != nil { | |||
return m.PubKey | |||
} | |||
return keys.PublicKey{} | |||
} | |||
func (m *FilePVKey) GetPrivKey() keys.PrivateKey { | |||
if m != nil { | |||
return m.PrivKey | |||
} | |||
return keys.PrivateKey{} | |||
} | |||
func (m *FilePVKey) GetFilePath() string { | |||
if m != nil { | |||
return m.FilePath | |||
} | |||
return "" | |||
} | |||
// FilePVLastSignState stores the mutable part of PrivValidator. | |||
type FilePVLastSignState struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Round int64 `protobuf:"varint,2,opt,name=round,proto3" json:"round,omitempty"` | |||
Step int32 `protobuf:"varint,3,opt,name=step,proto3" json:"step,omitempty"` | |||
Signature []byte `protobuf:"bytes,4,opt,name=signature,proto3" json:"signature,omitempty"` | |||
SignBytes []byte `protobuf:"bytes,5,opt,name=sign_bytes,json=signBytes,proto3" json:"sign_bytes,omitempty"` | |||
FilePath string `protobuf:"bytes,6,opt,name=file_path,json=filePath,proto3" json:"file_path,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *FilePVLastSignState) Reset() { *m = FilePVLastSignState{} } | |||
func (m *FilePVLastSignState) String() string { return proto.CompactTextString(m) } | |||
func (*FilePVLastSignState) ProtoMessage() {} | |||
func (*FilePVLastSignState) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_a9d74c406df3ad93, []int{1} | |||
} | |||
func (m *FilePVLastSignState) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_FilePVLastSignState.Unmarshal(m, b) | |||
} | |||
func (m *FilePVLastSignState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_FilePVLastSignState.Marshal(b, m, deterministic) | |||
} | |||
func (m *FilePVLastSignState) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_FilePVLastSignState.Merge(m, src) | |||
} | |||
func (m *FilePVLastSignState) XXX_Size() int { | |||
return xxx_messageInfo_FilePVLastSignState.Size(m) | |||
} | |||
func (m *FilePVLastSignState) XXX_DiscardUnknown() { | |||
xxx_messageInfo_FilePVLastSignState.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_FilePVLastSignState proto.InternalMessageInfo | |||
func (m *FilePVLastSignState) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *FilePVLastSignState) GetRound() int64 { | |||
if m != nil { | |||
return m.Round | |||
} | |||
return 0 | |||
} | |||
func (m *FilePVLastSignState) GetStep() int32 { | |||
if m != nil { | |||
return m.Step | |||
} | |||
return 0 | |||
} | |||
func (m *FilePVLastSignState) GetSignature() []byte { | |||
if m != nil { | |||
return m.Signature | |||
} | |||
return nil | |||
} | |||
func (m *FilePVLastSignState) GetSignBytes() []byte { | |||
if m != nil { | |||
return m.SignBytes | |||
} | |||
return nil | |||
} | |||
func (m *FilePVLastSignState) GetFilePath() string { | |||
if m != nil { | |||
return m.FilePath | |||
} | |||
return "" | |||
} | |||
func init() { | |||
proto.RegisterType((*FilePVKey)(nil), "tendermint.proto.privval.FilePVKey") | |||
proto.RegisterType((*FilePVLastSignState)(nil), "tendermint.proto.privval.FilePVLastSignState") | |||
} | |||
func init() { proto.RegisterFile("proto/privval/types.proto", fileDescriptor_a9d74c406df3ad93) } | |||
var fileDescriptor_a9d74c406df3ad93 = []byte{ | |||
// 357 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x84, 0x52, 0x4d, 0x6e, 0xe2, 0x30, | |||
0x14, 0x9e, 0x0c, 0x10, 0x88, 0x87, 0x95, 0x67, 0x34, 0xca, 0x30, 0x45, 0x45, 0x2c, 0xda, 0xac, | |||
0x92, 0xaa, 0xbd, 0x01, 0x0b, 0xa4, 0x8a, 0x2e, 0x50, 0x90, 0xba, 0xe8, 0x26, 0x72, 0xc8, 0x6b, | |||
0x62, 0x11, 0x12, 0xcb, 0x7e, 0x41, 0xf2, 0xb1, 0x7a, 0x8b, 0x5e, 0xa0, 0xdb, 0x9e, 0xa5, 0xb2, | |||
0x43, 0x15, 0x50, 0x17, 0xdd, 0xbd, 0xef, 0xf3, 0xf3, 0xf7, 0x63, 0x99, 0xfc, 0x13, 0xb2, 0xc6, | |||
0x3a, 0x12, 0x92, 0x1f, 0x0e, 0xac, 0x8c, 0x50, 0x0b, 0x50, 0xa1, 0xe5, 0xa8, 0x8f, 0x50, 0x65, | |||
0x20, 0xf7, 0xbc, 0xc2, 0x96, 0x09, 0x8f, 0x5b, 0x93, 0x2b, 0x2c, 0xb8, 0xcc, 0x12, 0xc1, 0x24, | |||
0xea, 0xa8, 0x15, 0xc8, 0xeb, 0xbc, 0xee, 0xa6, 0x76, 0x7f, 0x32, 0x6d, 0x99, 0xad, 0xd4, 0x02, | |||
0xeb, 0x68, 0x07, 0x5a, 0x9d, 0x1a, 0xcc, 0xdf, 0x1c, 0xe2, 0x2d, 0x79, 0x09, 0xeb, 0xc7, 0x15, | |||
0x68, 0xea, 0x93, 0x21, 0xcb, 0x32, 0x09, 0x4a, 0xf9, 0xce, 0xcc, 0x09, 0xc6, 0xf1, 0x27, 0xa4, | |||
0x4b, 0x32, 0x14, 0x4d, 0x9a, 0xec, 0x40, 0xfb, 0x3f, 0x67, 0x4e, 0xf0, 0xeb, 0xf6, 0x3a, 0xfc, | |||
0x12, 0xad, 0xf5, 0x08, 0x8d, 0x47, 0xb8, 0x6e, 0xd2, 0x92, 0x6f, 0x57, 0xa0, 0x17, 0xfd, 0xd7, | |||
0xf7, 0xcb, 0x1f, 0xb1, 0x2b, 0x9a, 0xd4, 0x38, 0xdc, 0x93, 0x91, 0x69, 0x60, 0x85, 0x7a, 0x56, | |||
0x28, 0xf8, 0x46, 0x48, 0xf2, 0x03, 0x43, 0xe8, 0x94, 0x86, 0xe6, 0xbe, 0x91, 0xfa, 0x4f, 0xbc, | |||
0x67, 0x5e, 0x42, 0x22, 0x18, 0x16, 0x7e, 0x7f, 0xe6, 0x04, 0x5e, 0x3c, 0x32, 0xc4, 0x9a, 0x61, | |||
0x31, 0x7f, 0x71, 0xc8, 0xef, 0xb6, 0xd7, 0x03, 0x53, 0xb8, 0xe1, 0x79, 0xb5, 0x41, 0x86, 0x40, | |||
0xff, 0x12, 0xb7, 0x00, 0x9e, 0x17, 0x68, 0x0b, 0xf6, 0xe2, 0x23, 0xa2, 0x7f, 0xc8, 0x40, 0xd6, | |||
0x4d, 0x95, 0xd9, 0x76, 0xbd, 0xb8, 0x05, 0x94, 0x92, 0xbe, 0x42, 0x10, 0x36, 0xe9, 0x20, 0xb6, | |||
0x33, 0xbd, 0x20, 0x9e, 0xe2, 0x79, 0xc5, 0xb0, 0x91, 0x60, 0x6d, 0xc7, 0x71, 0x47, 0xd0, 0x29, | |||
0x21, 0x06, 0x24, 0xa9, 0x46, 0x50, 0xfe, 0xa0, 0x3b, 0x5e, 0x18, 0xe2, 0x3c, 0xb3, 0x7b, 0x9e, | |||
0x79, 0x71, 0xf3, 0x14, 0xe6, 0x1c, 0x8b, 0x26, 0x0d, 0xb7, 0xf5, 0x3e, 0xea, 0x5e, 0xe5, 0x74, | |||
0x3c, 0xfb, 0x2a, 0xa9, 0x6b, 0xe1, 0xdd, 0x47, 0x00, 0x00, 0x00, 0xff, 0xff, 0xf3, 0xa3, 0x78, | |||
0xe9, 0x42, 0x02, 0x00, 0x00, | |||
} |
@ -0,0 +1,27 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.privval; | |||
option go_package = "github.com/tendermint/tendermint/proto/privval"; | |||
import "third_party/proto/gogoproto/gogo.proto"; | |||
import "proto/crypto/keys/types.proto"; | |||
// FilePVKey stores the immutable part of PrivValidator. | |||
message FilePVKey { | |||
bytes address = 1; | |||
tendermint.proto.crypto.keys.PublicKey pub_key = 2 [(gogoproto.nullable) = false]; | |||
tendermint.proto.crypto.keys.PrivateKey priv_key = 3 [(gogoproto.nullable) = false]; | |||
string file_path = 4; | |||
} | |||
// FilePVLastSignState stores the mutable part of PrivValidator. | |||
message FilePVLastSignState { | |||
int64 height = 1; | |||
int64 round = 2; | |||
int32 step = 3; | |||
bytes signature = 4; | |||
bytes sign_bytes = 5; | |||
string file_path = 6; | |||
} |
@ -0,0 +1,385 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/statesync/types.proto | |||
package statesync | |||
import ( | |||
fmt "fmt" | |||
proto "github.com/gogo/protobuf/proto" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
type Message struct { | |||
// Types that are valid to be assigned to Sum: | |||
// *Message_SnapshotsRequest | |||
// *Message_SnapshotsResponse | |||
// *Message_ChunkRequest | |||
// *Message_ChunkResponse | |||
Sum isMessage_Sum `protobuf_oneof:"sum"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *Message) Reset() { *m = Message{} } | |||
func (m *Message) String() string { return proto.CompactTextString(m) } | |||
func (*Message) ProtoMessage() {} | |||
func (*Message) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_bef273312884335b, []int{0} | |||
} | |||
func (m *Message) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_Message.Unmarshal(m, b) | |||
} | |||
func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_Message.Marshal(b, m, deterministic) | |||
} | |||
func (m *Message) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_Message.Merge(m, src) | |||
} | |||
func (m *Message) XXX_Size() int { | |||
return xxx_messageInfo_Message.Size(m) | |||
} | |||
func (m *Message) XXX_DiscardUnknown() { | |||
xxx_messageInfo_Message.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_Message proto.InternalMessageInfo | |||
type isMessage_Sum interface { | |||
isMessage_Sum() | |||
} | |||
type Message_SnapshotsRequest struct { | |||
SnapshotsRequest *SnapshotsRequest `protobuf:"bytes,1,opt,name=snapshots_request,json=snapshotsRequest,proto3,oneof" json:"snapshots_request,omitempty"` | |||
} | |||
type Message_SnapshotsResponse struct { | |||
SnapshotsResponse *SnapshotsResponse `protobuf:"bytes,2,opt,name=snapshots_response,json=snapshotsResponse,proto3,oneof" json:"snapshots_response,omitempty"` | |||
} | |||
type Message_ChunkRequest struct { | |||
ChunkRequest *ChunkRequest `protobuf:"bytes,3,opt,name=chunk_request,json=chunkRequest,proto3,oneof" json:"chunk_request,omitempty"` | |||
} | |||
type Message_ChunkResponse struct { | |||
ChunkResponse *ChunkResponse `protobuf:"bytes,4,opt,name=chunk_response,json=chunkResponse,proto3,oneof" json:"chunk_response,omitempty"` | |||
} | |||
func (*Message_SnapshotsRequest) isMessage_Sum() {} | |||
func (*Message_SnapshotsResponse) isMessage_Sum() {} | |||
func (*Message_ChunkRequest) isMessage_Sum() {} | |||
func (*Message_ChunkResponse) isMessage_Sum() {} | |||
func (m *Message) GetSum() isMessage_Sum { | |||
if m != nil { | |||
return m.Sum | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetSnapshotsRequest() *SnapshotsRequest { | |||
if x, ok := m.GetSum().(*Message_SnapshotsRequest); ok { | |||
return x.SnapshotsRequest | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetSnapshotsResponse() *SnapshotsResponse { | |||
if x, ok := m.GetSum().(*Message_SnapshotsResponse); ok { | |||
return x.SnapshotsResponse | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetChunkRequest() *ChunkRequest { | |||
if x, ok := m.GetSum().(*Message_ChunkRequest); ok { | |||
return x.ChunkRequest | |||
} | |||
return nil | |||
} | |||
func (m *Message) GetChunkResponse() *ChunkResponse { | |||
if x, ok := m.GetSum().(*Message_ChunkResponse); ok { | |||
return x.ChunkResponse | |||
} | |||
return nil | |||
} | |||
// XXX_OneofWrappers is for the internal use of the proto package. | |||
func (*Message) XXX_OneofWrappers() []interface{} { | |||
return []interface{}{ | |||
(*Message_SnapshotsRequest)(nil), | |||
(*Message_SnapshotsResponse)(nil), | |||
(*Message_ChunkRequest)(nil), | |||
(*Message_ChunkResponse)(nil), | |||
} | |||
} | |||
type SnapshotsRequest struct { | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *SnapshotsRequest) Reset() { *m = SnapshotsRequest{} } | |||
func (m *SnapshotsRequest) String() string { return proto.CompactTextString(m) } | |||
func (*SnapshotsRequest) ProtoMessage() {} | |||
func (*SnapshotsRequest) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_bef273312884335b, []int{1} | |||
} | |||
func (m *SnapshotsRequest) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_SnapshotsRequest.Unmarshal(m, b) | |||
} | |||
func (m *SnapshotsRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_SnapshotsRequest.Marshal(b, m, deterministic) | |||
} | |||
func (m *SnapshotsRequest) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_SnapshotsRequest.Merge(m, src) | |||
} | |||
func (m *SnapshotsRequest) XXX_Size() int { | |||
return xxx_messageInfo_SnapshotsRequest.Size(m) | |||
} | |||
func (m *SnapshotsRequest) XXX_DiscardUnknown() { | |||
xxx_messageInfo_SnapshotsRequest.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_SnapshotsRequest proto.InternalMessageInfo | |||
type SnapshotsResponse struct { | |||
Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Format uint32 `protobuf:"varint,2,opt,name=format,proto3" json:"format,omitempty"` | |||
Chunks uint32 `protobuf:"varint,3,opt,name=chunks,proto3" json:"chunks,omitempty"` | |||
Hash []byte `protobuf:"bytes,4,opt,name=hash,proto3" json:"hash,omitempty"` | |||
Metadata []byte `protobuf:"bytes,5,opt,name=metadata,proto3" json:"metadata,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *SnapshotsResponse) Reset() { *m = SnapshotsResponse{} } | |||
func (m *SnapshotsResponse) String() string { return proto.CompactTextString(m) } | |||
func (*SnapshotsResponse) ProtoMessage() {} | |||
func (*SnapshotsResponse) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_bef273312884335b, []int{2} | |||
} | |||
func (m *SnapshotsResponse) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_SnapshotsResponse.Unmarshal(m, b) | |||
} | |||
func (m *SnapshotsResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_SnapshotsResponse.Marshal(b, m, deterministic) | |||
} | |||
func (m *SnapshotsResponse) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_SnapshotsResponse.Merge(m, src) | |||
} | |||
func (m *SnapshotsResponse) XXX_Size() int { | |||
return xxx_messageInfo_SnapshotsResponse.Size(m) | |||
} | |||
func (m *SnapshotsResponse) XXX_DiscardUnknown() { | |||
xxx_messageInfo_SnapshotsResponse.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_SnapshotsResponse proto.InternalMessageInfo | |||
func (m *SnapshotsResponse) GetHeight() uint64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *SnapshotsResponse) GetFormat() uint32 { | |||
if m != nil { | |||
return m.Format | |||
} | |||
return 0 | |||
} | |||
func (m *SnapshotsResponse) GetChunks() uint32 { | |||
if m != nil { | |||
return m.Chunks | |||
} | |||
return 0 | |||
} | |||
func (m *SnapshotsResponse) GetHash() []byte { | |||
if m != nil { | |||
return m.Hash | |||
} | |||
return nil | |||
} | |||
func (m *SnapshotsResponse) GetMetadata() []byte { | |||
if m != nil { | |||
return m.Metadata | |||
} | |||
return nil | |||
} | |||
type ChunkRequest struct { | |||
Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Format uint32 `protobuf:"varint,2,opt,name=format,proto3" json:"format,omitempty"` | |||
Index uint32 `protobuf:"varint,3,opt,name=index,proto3" json:"index,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *ChunkRequest) Reset() { *m = ChunkRequest{} } | |||
func (m *ChunkRequest) String() string { return proto.CompactTextString(m) } | |||
func (*ChunkRequest) ProtoMessage() {} | |||
func (*ChunkRequest) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_bef273312884335b, []int{3} | |||
} | |||
func (m *ChunkRequest) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_ChunkRequest.Unmarshal(m, b) | |||
} | |||
func (m *ChunkRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_ChunkRequest.Marshal(b, m, deterministic) | |||
} | |||
func (m *ChunkRequest) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_ChunkRequest.Merge(m, src) | |||
} | |||
func (m *ChunkRequest) XXX_Size() int { | |||
return xxx_messageInfo_ChunkRequest.Size(m) | |||
} | |||
func (m *ChunkRequest) XXX_DiscardUnknown() { | |||
xxx_messageInfo_ChunkRequest.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_ChunkRequest proto.InternalMessageInfo | |||
func (m *ChunkRequest) GetHeight() uint64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *ChunkRequest) GetFormat() uint32 { | |||
if m != nil { | |||
return m.Format | |||
} | |||
return 0 | |||
} | |||
func (m *ChunkRequest) GetIndex() uint32 { | |||
if m != nil { | |||
return m.Index | |||
} | |||
return 0 | |||
} | |||
type ChunkResponse struct { | |||
Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Format uint32 `protobuf:"varint,2,opt,name=format,proto3" json:"format,omitempty"` | |||
Index uint32 `protobuf:"varint,3,opt,name=index,proto3" json:"index,omitempty"` | |||
Chunk []byte `protobuf:"bytes,4,opt,name=chunk,proto3" json:"chunk,omitempty"` | |||
Missing bool `protobuf:"varint,5,opt,name=missing,proto3" json:"missing,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *ChunkResponse) Reset() { *m = ChunkResponse{} } | |||
func (m *ChunkResponse) String() string { return proto.CompactTextString(m) } | |||
func (*ChunkResponse) ProtoMessage() {} | |||
func (*ChunkResponse) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_bef273312884335b, []int{4} | |||
} | |||
func (m *ChunkResponse) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_ChunkResponse.Unmarshal(m, b) | |||
} | |||
func (m *ChunkResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_ChunkResponse.Marshal(b, m, deterministic) | |||
} | |||
func (m *ChunkResponse) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_ChunkResponse.Merge(m, src) | |||
} | |||
func (m *ChunkResponse) XXX_Size() int { | |||
return xxx_messageInfo_ChunkResponse.Size(m) | |||
} | |||
func (m *ChunkResponse) XXX_DiscardUnknown() { | |||
xxx_messageInfo_ChunkResponse.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_ChunkResponse proto.InternalMessageInfo | |||
func (m *ChunkResponse) GetHeight() uint64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *ChunkResponse) GetFormat() uint32 { | |||
if m != nil { | |||
return m.Format | |||
} | |||
return 0 | |||
} | |||
func (m *ChunkResponse) GetIndex() uint32 { | |||
if m != nil { | |||
return m.Index | |||
} | |||
return 0 | |||
} | |||
func (m *ChunkResponse) GetChunk() []byte { | |||
if m != nil { | |||
return m.Chunk | |||
} | |||
return nil | |||
} | |||
func (m *ChunkResponse) GetMissing() bool { | |||
if m != nil { | |||
return m.Missing | |||
} | |||
return false | |||
} | |||
func init() { | |||
proto.RegisterType((*Message)(nil), "tendermint.proto.statesync.Message") | |||
proto.RegisterType((*SnapshotsRequest)(nil), "tendermint.proto.statesync.SnapshotsRequest") | |||
proto.RegisterType((*SnapshotsResponse)(nil), "tendermint.proto.statesync.SnapshotsResponse") | |||
proto.RegisterType((*ChunkRequest)(nil), "tendermint.proto.statesync.ChunkRequest") | |||
proto.RegisterType((*ChunkResponse)(nil), "tendermint.proto.statesync.ChunkResponse") | |||
} | |||
func init() { proto.RegisterFile("proto/statesync/types.proto", fileDescriptor_bef273312884335b) } | |||
var fileDescriptor_bef273312884335b = []byte{ | |||
// 357 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x93, 0xcd, 0x4a, 0xc3, 0x40, | |||
0x14, 0x85, 0x9b, 0xfe, 0x73, 0x6d, 0xa4, 0x1d, 0x44, 0x42, 0xdd, 0x48, 0x56, 0x15, 0x34, 0x95, | |||
0xfa, 0x06, 0x75, 0xd3, 0x8d, 0x08, 0xa3, 0x2b, 0x05, 0x65, 0x9a, 0x8e, 0x49, 0x90, 0x4c, 0x62, | |||
0xee, 0x04, 0xec, 0x03, 0xb8, 0xf2, 0x6d, 0x7d, 0x02, 0xc9, 0x4d, 0x9a, 0xc6, 0x88, 0x52, 0xc1, | |||
0xdd, 0x9c, 0x43, 0xee, 0x97, 0x73, 0xee, 0x30, 0x70, 0x14, 0x27, 0x91, 0x8e, 0xa6, 0xa8, 0x85, | |||
0x96, 0xb8, 0x56, 0xee, 0x54, 0xaf, 0x63, 0x89, 0x0e, 0xb9, 0x6c, 0xac, 0xa5, 0x5a, 0xc9, 0x24, | |||
0x0c, 0x94, 0xce, 0x1d, 0xa7, 0xfc, 0xce, 0xfe, 0x68, 0x42, 0xef, 0x4a, 0x22, 0x0a, 0x4f, 0xb2, | |||
0x7b, 0x18, 0xa1, 0x12, 0x31, 0xfa, 0x91, 0xc6, 0xc7, 0x44, 0xbe, 0xa4, 0x12, 0xb5, 0x65, 0x1c, | |||
0x1b, 0x93, 0xbd, 0xd9, 0xa9, 0xf3, 0x33, 0xc3, 0xb9, 0xd9, 0x0c, 0xf1, 0x7c, 0x66, 0xd1, 0xe0, | |||
0x43, 0xac, 0x79, 0xec, 0x01, 0x58, 0x15, 0x8e, 0x71, 0xa4, 0x50, 0x5a, 0x4d, 0xa2, 0x9f, 0xed, | |||
0x48, 0xcf, 0x87, 0x16, 0x0d, 0x3e, 0xc2, 0xba, 0xc9, 0xae, 0xc1, 0x74, 0xfd, 0x54, 0x3d, 0x97, | |||
0xc1, 0x5b, 0x84, 0x9e, 0xfc, 0x86, 0xbe, 0xcc, 0x06, 0xb6, 0xa1, 0x07, 0x6e, 0x45, 0x33, 0x0e, | |||
0xfb, 0x1b, 0x60, 0x11, 0xb6, 0x4d, 0xc4, 0x93, 0x1d, 0x88, 0x65, 0x50, 0xd3, 0xad, 0x1a, 0xf3, | |||
0x0e, 0xb4, 0x30, 0x0d, 0x6d, 0x06, 0xc3, 0xfa, 0xce, 0xec, 0x77, 0x03, 0x46, 0xdf, 0xaa, 0xb2, | |||
0x43, 0xe8, 0xfa, 0x32, 0xf0, 0xfc, 0xfc, 0x1e, 0xda, 0xbc, 0x50, 0x99, 0xff, 0x14, 0x25, 0xa1, | |||
0xd0, 0xb4, 0x41, 0x93, 0x17, 0x2a, 0xf3, 0xe9, 0x8f, 0x48, 0xf5, 0x4d, 0x5e, 0x28, 0xc6, 0xa0, | |||
0xed, 0x0b, 0xf4, 0xa9, 0xc2, 0x80, 0xd3, 0x99, 0x8d, 0xa1, 0x1f, 0x4a, 0x2d, 0x56, 0x42, 0x0b, | |||
0xab, 0x43, 0x7e, 0xa9, 0xed, 0x5b, 0x18, 0x54, 0x97, 0xf3, 0xe7, 0x1c, 0x07, 0xd0, 0x09, 0xd4, | |||
0x4a, 0xbe, 0x16, 0x31, 0x72, 0x61, 0xbf, 0x19, 0x60, 0x7e, 0xd9, 0xd0, 0xff, 0x70, 0x33, 0x97, | |||
0x7a, 0x16, 0xf5, 0x72, 0xc1, 0x2c, 0xe8, 0x85, 0x01, 0x62, 0xa0, 0x3c, 0xaa, 0xd7, 0xe7, 0x1b, | |||
0x39, 0x9f, 0xdd, 0x9d, 0x7b, 0x81, 0xf6, 0xd3, 0xa5, 0xe3, 0x46, 0xe1, 0x74, 0x7b, 0x9d, 0xd5, | |||
0x63, 0xed, 0x41, 0x2d, 0xbb, 0x64, 0x5c, 0x7c, 0x06, 0x00, 0x00, 0xff, 0xff, 0x79, 0xd0, 0x53, | |||
0x2f, 0x6a, 0x03, 0x00, 0x00, | |||
} |
@ -0,0 +1,37 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.statesync; | |||
option go_package = "github.com/tendermint/tendermint/proto/statesync"; | |||
message Message { | |||
oneof sum { | |||
SnapshotsRequest snapshots_request = 1; | |||
SnapshotsResponse snapshots_response = 2; | |||
ChunkRequest chunk_request = 3; | |||
ChunkResponse chunk_response = 4; | |||
} | |||
} | |||
message SnapshotsRequest {} | |||
message SnapshotsResponse { | |||
uint64 height = 1; | |||
uint32 format = 2; | |||
uint32 chunks = 3; | |||
bytes hash = 4; | |||
bytes metadata = 5; | |||
} | |||
message ChunkRequest { | |||
uint64 height = 1; | |||
uint32 format = 2; | |||
uint32 index = 3; | |||
} | |||
message ChunkResponse { | |||
uint64 height = 1; | |||
uint32 format = 2; | |||
uint32 index = 3; | |||
bytes chunk = 4; | |||
bool missing = 5; | |||
} |
@ -0,0 +1,86 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/store/types.proto | |||
package store | |||
import ( | |||
fmt "fmt" | |||
proto "github.com/gogo/protobuf/proto" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
type BlockStoreState struct { | |||
Base int64 `protobuf:"varint,1,opt,name=base,proto3" json:"base,omitempty"` | |||
Height int64 `protobuf:"varint,2,opt,name=height,proto3" json:"height,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *BlockStoreState) Reset() { *m = BlockStoreState{} } | |||
func (m *BlockStoreState) String() string { return proto.CompactTextString(m) } | |||
func (*BlockStoreState) ProtoMessage() {} | |||
func (*BlockStoreState) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_45a8553e38baf31c, []int{0} | |||
} | |||
func (m *BlockStoreState) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_BlockStoreState.Unmarshal(m, b) | |||
} | |||
func (m *BlockStoreState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_BlockStoreState.Marshal(b, m, deterministic) | |||
} | |||
func (m *BlockStoreState) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_BlockStoreState.Merge(m, src) | |||
} | |||
func (m *BlockStoreState) XXX_Size() int { | |||
return xxx_messageInfo_BlockStoreState.Size(m) | |||
} | |||
func (m *BlockStoreState) XXX_DiscardUnknown() { | |||
xxx_messageInfo_BlockStoreState.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_BlockStoreState proto.InternalMessageInfo | |||
func (m *BlockStoreState) GetBase() int64 { | |||
if m != nil { | |||
return m.Base | |||
} | |||
return 0 | |||
} | |||
func (m *BlockStoreState) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func init() { | |||
proto.RegisterType((*BlockStoreState)(nil), "tendermint.proto.store.BlockStoreState") | |||
} | |||
func init() { proto.RegisterFile("proto/store/types.proto", fileDescriptor_45a8553e38baf31c) } | |||
var fileDescriptor_45a8553e38baf31c = []byte{ | |||
// 138 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x12, 0x2f, 0x28, 0xca, 0x2f, | |||
0xc9, 0xd7, 0x2f, 0x2e, 0xc9, 0x2f, 0x4a, 0xd5, 0x2f, 0xa9, 0x2c, 0x48, 0x2d, 0xd6, 0x03, 0x8b, | |||
0x08, 0x89, 0x95, 0xa4, 0xe6, 0xa5, 0xa4, 0x16, 0xe5, 0x66, 0xe6, 0x95, 0x40, 0x44, 0xf4, 0xc0, | |||
0x6a, 0x94, 0x6c, 0xb9, 0xf8, 0x9d, 0x72, 0xf2, 0x93, 0xb3, 0x83, 0x41, 0xbc, 0xe0, 0x92, 0xc4, | |||
0x92, 0x54, 0x21, 0x21, 0x2e, 0x96, 0xa4, 0xc4, 0xe2, 0x54, 0x09, 0x46, 0x05, 0x46, 0x0d, 0xe6, | |||
0x20, 0x30, 0x5b, 0x48, 0x8c, 0x8b, 0x2d, 0x23, 0x35, 0x33, 0x3d, 0xa3, 0x44, 0x82, 0x09, 0x2c, | |||
0x0a, 0xe5, 0x39, 0xe9, 0x45, 0xe9, 0xa4, 0x67, 0x96, 0x64, 0x94, 0x26, 0xe9, 0x25, 0xe7, 0xe7, | |||
0xea, 0x23, 0xec, 0x40, 0x66, 0x22, 0x39, 0x29, 0x89, 0x0d, 0xcc, 0x31, 0x06, 0x04, 0x00, 0x00, | |||
0xff, 0xff, 0xb2, 0x6b, 0x69, 0x83, 0xa8, 0x00, 0x00, 0x00, | |||
} |
@ -0,0 +1,9 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.store; | |||
option go_package = "github.com/tendermint/tendermint/proto/store"; | |||
message BlockStoreState { | |||
int64 base = 1; | |||
int64 height = 2; | |||
} |
@ -0,0 +1,96 @@ | |||
// Code generated by protoc-gen-gogo. DO NOT EDIT. | |||
// source: proto/types/events.proto | |||
package types | |||
import ( | |||
fmt "fmt" | |||
proto "github.com/gogo/protobuf/proto" | |||
math "math" | |||
) | |||
// Reference imports to suppress errors if they are not otherwise used. | |||
var _ = proto.Marshal | |||
var _ = fmt.Errorf | |||
var _ = math.Inf | |||
// This is a compile-time assertion to ensure that this generated file | |||
// is compatible with the proto package it is being compiled against. | |||
// A compilation error at this line likely means your copy of the | |||
// proto package needs to be updated. | |||
const _ = proto.GoGoProtoPackageIsVersion3 // please upgrade the proto package | |||
type EventDataRoundState struct { | |||
Height int64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` | |||
Round int32 `protobuf:"varint,2,opt,name=round,proto3" json:"round,omitempty"` | |||
Step string `protobuf:"bytes,3,opt,name=step,proto3" json:"step,omitempty"` | |||
XXX_NoUnkeyedLiteral struct{} `json:"-"` | |||
XXX_unrecognized []byte `json:"-"` | |||
XXX_sizecache int32 `json:"-"` | |||
} | |||
func (m *EventDataRoundState) Reset() { *m = EventDataRoundState{} } | |||
func (m *EventDataRoundState) String() string { return proto.CompactTextString(m) } | |||
func (*EventDataRoundState) ProtoMessage() {} | |||
func (*EventDataRoundState) Descriptor() ([]byte, []int) { | |||
return fileDescriptor_1bb9bdae76a076d6, []int{0} | |||
} | |||
func (m *EventDataRoundState) XXX_Unmarshal(b []byte) error { | |||
return xxx_messageInfo_EventDataRoundState.Unmarshal(m, b) | |||
} | |||
func (m *EventDataRoundState) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) { | |||
return xxx_messageInfo_EventDataRoundState.Marshal(b, m, deterministic) | |||
} | |||
func (m *EventDataRoundState) XXX_Merge(src proto.Message) { | |||
xxx_messageInfo_EventDataRoundState.Merge(m, src) | |||
} | |||
func (m *EventDataRoundState) XXX_Size() int { | |||
return xxx_messageInfo_EventDataRoundState.Size(m) | |||
} | |||
func (m *EventDataRoundState) XXX_DiscardUnknown() { | |||
xxx_messageInfo_EventDataRoundState.DiscardUnknown(m) | |||
} | |||
var xxx_messageInfo_EventDataRoundState proto.InternalMessageInfo | |||
func (m *EventDataRoundState) GetHeight() int64 { | |||
if m != nil { | |||
return m.Height | |||
} | |||
return 0 | |||
} | |||
func (m *EventDataRoundState) GetRound() int32 { | |||
if m != nil { | |||
return m.Round | |||
} | |||
return 0 | |||
} | |||
func (m *EventDataRoundState) GetStep() string { | |||
if m != nil { | |||
return m.Step | |||
} | |||
return "" | |||
} | |||
func init() { | |||
proto.RegisterType((*EventDataRoundState)(nil), "tendermint.proto.types.EventDataRoundState") | |||
} | |||
func init() { proto.RegisterFile("proto/types/events.proto", fileDescriptor_1bb9bdae76a076d6) } | |||
var fileDescriptor_1bb9bdae76a076d6 = []byte{ | |||
// 162 bytes of a gzipped FileDescriptorProto | |||
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0x28, 0x28, 0xca, 0x2f, | |||
0xc9, 0xd7, 0x2f, 0xa9, 0x2c, 0x48, 0x2d, 0xd6, 0x4f, 0x2d, 0x4b, 0xcd, 0x2b, 0x29, 0xd6, 0x03, | |||
0x0b, 0x09, 0x89, 0x95, 0xa4, 0xe6, 0xa5, 0xa4, 0x16, 0xe5, 0x66, 0xe6, 0x95, 0x40, 0x44, 0xf4, | |||
0xc0, 0x8a, 0x94, 0xc2, 0xb9, 0x84, 0x5d, 0x41, 0xea, 0x5c, 0x12, 0x4b, 0x12, 0x83, 0xf2, 0x4b, | |||
0xf3, 0x52, 0x82, 0x4b, 0x12, 0x4b, 0x52, 0x85, 0xc4, 0xb8, 0xd8, 0x32, 0x52, 0x33, 0xd3, 0x33, | |||
0x4a, 0x24, 0x18, 0x15, 0x18, 0x35, 0x98, 0x83, 0xa0, 0x3c, 0x21, 0x11, 0x2e, 0xd6, 0x22, 0x90, | |||
0x2a, 0x09, 0x26, 0x05, 0x46, 0x0d, 0xd6, 0x20, 0x08, 0x47, 0x48, 0x88, 0x8b, 0xa5, 0xb8, 0x24, | |||
0xb5, 0x40, 0x82, 0x59, 0x81, 0x51, 0x83, 0x33, 0x08, 0xcc, 0x76, 0xd2, 0x8b, 0xd2, 0x49, 0xcf, | |||
0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x4b, 0xce, 0xcf, 0xd5, 0x47, 0xd8, 0x8e, 0xcc, 0x44, 0x72, 0x6d, | |||
0x12, 0x1b, 0x98, 0x63, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0xbc, 0x3c, 0x7d, 0xad, 0xc3, 0x00, | |||
0x00, 0x00, | |||
} |
@ -0,0 +1,10 @@ | |||
syntax = "proto3"; | |||
package tendermint.proto.types; | |||
option go_package = "github.com/tendermint/tendermint/proto/types"; | |||
message EventDataRoundState { | |||
int64 height = 1; | |||
int32 round = 2; | |||
string step = 3; | |||
} |
@ -0,0 +1,38 @@ | |||
package types | |||
import ( | |||
"testing" | |||
"github.com/stretchr/testify/require" | |||
) | |||
func TestValidatorProtoBuf(t *testing.T) { | |||
val, _ := RandValidator(true, 100) | |||
testCases := []struct { | |||
msg string | |||
v1 *Validator | |||
expPass1 bool | |||
expPass2 bool | |||
}{ | |||
{"success validator", val, true, true}, | |||
{"failure empty", &Validator{}, false, false}, | |||
{"failure nil", nil, false, false}, | |||
} | |||
for _, tc := range testCases { | |||
protoVal, err := tc.v1.ToProto() | |||
if tc.expPass1 { | |||
require.NoError(t, err, tc.msg) | |||
} else { | |||
require.Error(t, err, tc.msg) | |||
} | |||
val, err := ValidatorFromProto(protoVal) | |||
if tc.expPass2 { | |||
require.NoError(t, err, tc.msg) | |||
require.Equal(t, tc.v1, val, tc.msg) | |||
} else { | |||
require.Error(t, err, tc.msg) | |||
} | |||
} | |||
} |