diff --git a/Makefile b/Makefile index e9d239003..32e8df4ee 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,8 @@ GOTOOLS = \ github.com/mitchellh/gox \ github.com/Masterminds/glide \ github.com/alecthomas/gometalinter \ - github.com/ckaznocha/protoc-gen-lint + github.com/ckaznocha/protoc-gen-lint \ + github.com/gogo/protobuf/protoc-gen-gogo all: install test @@ -17,13 +18,12 @@ install_protoc: make install && \ cd .. && \ rm -rf protobuf-3.4.1 - go get github.com/golang/protobuf/protoc-gen-go protoc: ## On "error while loading shared libraries: libprotobuf.so.14: cannot open shared object file: No such file or directory" ## ldconfig (may require sudo) ## https://stackoverflow.com/a/25518702 - protoc --go_out=plugins=grpc:. types/*.proto + protoc --gogo_out=plugins=grpc:. types/*.proto install: @ go install ./cmd/... diff --git a/types/messages.go b/types/messages.go index 77ad538ed..7b9c81f97 100644 --- a/types/messages.go +++ b/types/messages.go @@ -3,7 +3,7 @@ package types import ( "io" - "github.com/golang/protobuf/proto" + "github.com/gogo/protobuf/proto" wire "github.com/tendermint/go-wire" ) diff --git a/types/types.pb.go b/types/types.pb.go index 454f8dd77..149c060ad 100644 --- a/types/types.pb.go +++ b/types/types.pb.go @@ -1,6 +1,5 @@ -// Code generated by protoc-gen-go. +// Code generated by protoc-gen-gogo. DO NOT EDIT. // source: types/types.proto -// DO NOT EDIT! /* Package types is a generated protocol buffer package. @@ -42,14 +41,12 @@ It has these top-level messages: */ package types -import proto "github.com/golang/protobuf/proto" +import proto "github.com/gogo/protobuf/proto" import fmt "fmt" import math "math" -import ( - context "golang.org/x/net/context" - grpc "google.golang.org/grpc" -) +import context "golang.org/x/net/context" +import grpc "google.golang.org/grpc" // Reference imports to suppress errors if they are not otherwise used. var _ = proto.Marshal @@ -60,7 +57,7 @@ var _ = math.Inf // 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.ProtoPackageIsVersion2 // please upgrade the proto package +const _ = proto.GoGoProtoPackageIsVersion2 // please upgrade the proto package type KVPair_Type int32 @@ -81,7 +78,7 @@ var KVPair_Type_value = map[string]int32{ func (x KVPair_Type) String() string { return proto.EnumName(KVPair_Type_name, int32(x)) } -func (KVPair_Type) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{29, 0} } +func (KVPair_Type) EnumDescriptor() ([]byte, []int) { return fileDescriptorTypes, []int{29, 0} } type Request struct { // Types that are valid to be assigned to Value: @@ -102,7 +99,7 @@ type Request struct { func (m *Request) Reset() { *m = Request{} } func (m *Request) String() string { return proto.CompactTextString(m) } func (*Request) ProtoMessage() {} -func (*Request) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} } +func (*Request) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{0} } type isRequest_Value interface { isRequest_Value() @@ -260,57 +257,57 @@ func _Request_OneofMarshaler(msg proto.Message, b *proto.Buffer) error { // value switch x := m.Value.(type) { case *Request_Echo: - b.EncodeVarint(1<<3 | proto.WireBytes) + _ = b.EncodeVarint(1<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Echo); err != nil { return err } case *Request_Flush: - b.EncodeVarint(2<<3 | proto.WireBytes) + _ = b.EncodeVarint(2<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Flush); err != nil { return err } case *Request_Info: - b.EncodeVarint(3<<3 | proto.WireBytes) + _ = b.EncodeVarint(3<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Info); err != nil { return err } case *Request_SetOption: - b.EncodeVarint(4<<3 | proto.WireBytes) + _ = b.EncodeVarint(4<<3 | proto.WireBytes) if err := b.EncodeMessage(x.SetOption); err != nil { return err } case *Request_DeliverTx: - b.EncodeVarint(5<<3 | proto.WireBytes) + _ = b.EncodeVarint(5<<3 | proto.WireBytes) if err := b.EncodeMessage(x.DeliverTx); err != nil { return err } case *Request_CheckTx: - b.EncodeVarint(6<<3 | proto.WireBytes) + _ = b.EncodeVarint(6<<3 | proto.WireBytes) if err := b.EncodeMessage(x.CheckTx); err != nil { return err } case *Request_Commit: - b.EncodeVarint(7<<3 | proto.WireBytes) + _ = b.EncodeVarint(7<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Commit); err != nil { return err } case *Request_Query: - b.EncodeVarint(8<<3 | proto.WireBytes) + _ = b.EncodeVarint(8<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Query); err != nil { return err } case *Request_InitChain: - b.EncodeVarint(9<<3 | proto.WireBytes) + _ = b.EncodeVarint(9<<3 | proto.WireBytes) if err := b.EncodeMessage(x.InitChain); err != nil { return err } case *Request_BeginBlock: - b.EncodeVarint(10<<3 | proto.WireBytes) + _ = b.EncodeVarint(10<<3 | proto.WireBytes) if err := b.EncodeMessage(x.BeginBlock); err != nil { return err } case *Request_EndBlock: - b.EncodeVarint(11<<3 | proto.WireBytes) + _ = b.EncodeVarint(11<<3 | proto.WireBytes) if err := b.EncodeMessage(x.EndBlock); err != nil { return err } @@ -484,13 +481,13 @@ func _Request_OneofSizer(msg proto.Message) (n int) { } type RequestEcho struct { - Message string `protobuf:"bytes,1,opt,name=message" json:"message,omitempty"` + Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` } func (m *RequestEcho) Reset() { *m = RequestEcho{} } func (m *RequestEcho) String() string { return proto.CompactTextString(m) } func (*RequestEcho) ProtoMessage() {} -func (*RequestEcho) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} } +func (*RequestEcho) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{1} } func (m *RequestEcho) GetMessage() string { if m != nil { @@ -505,16 +502,16 @@ type RequestFlush struct { func (m *RequestFlush) Reset() { *m = RequestFlush{} } func (m *RequestFlush) String() string { return proto.CompactTextString(m) } func (*RequestFlush) ProtoMessage() {} -func (*RequestFlush) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} } +func (*RequestFlush) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{2} } type RequestInfo struct { - Version string `protobuf:"bytes,1,opt,name=version" json:"version,omitempty"` + Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` } func (m *RequestInfo) Reset() { *m = RequestInfo{} } func (m *RequestInfo) String() string { return proto.CompactTextString(m) } func (*RequestInfo) ProtoMessage() {} -func (*RequestInfo) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} } +func (*RequestInfo) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{3} } func (m *RequestInfo) GetVersion() string { if m != nil { @@ -524,14 +521,14 @@ func (m *RequestInfo) GetVersion() string { } type RequestSetOption struct { - Key string `protobuf:"bytes,1,opt,name=key" json:"key,omitempty"` - Value string `protobuf:"bytes,2,opt,name=value" json:"value,omitempty"` + Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` + Value string `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"` } func (m *RequestSetOption) Reset() { *m = RequestSetOption{} } func (m *RequestSetOption) String() string { return proto.CompactTextString(m) } func (*RequestSetOption) ProtoMessage() {} -func (*RequestSetOption) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} } +func (*RequestSetOption) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{4} } func (m *RequestSetOption) GetKey() string { if m != nil { @@ -554,7 +551,7 @@ type RequestDeliverTx struct { func (m *RequestDeliverTx) Reset() { *m = RequestDeliverTx{} } func (m *RequestDeliverTx) String() string { return proto.CompactTextString(m) } func (*RequestDeliverTx) ProtoMessage() {} -func (*RequestDeliverTx) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} } +func (*RequestDeliverTx) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{5} } func (m *RequestDeliverTx) GetTx() []byte { if m != nil { @@ -570,7 +567,7 @@ type RequestCheckTx struct { func (m *RequestCheckTx) Reset() { *m = RequestCheckTx{} } func (m *RequestCheckTx) String() string { return proto.CompactTextString(m) } func (*RequestCheckTx) ProtoMessage() {} -func (*RequestCheckTx) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} } +func (*RequestCheckTx) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{6} } func (m *RequestCheckTx) GetTx() []byte { if m != nil { @@ -581,15 +578,15 @@ func (m *RequestCheckTx) GetTx() []byte { type RequestQuery struct { Data []byte `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` - Path string `protobuf:"bytes,2,opt,name=path" json:"path,omitempty"` - Height uint64 `protobuf:"varint,3,opt,name=height" json:"height,omitempty"` - Prove bool `protobuf:"varint,4,opt,name=prove" json:"prove,omitempty"` + Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"` + Height uint64 `protobuf:"varint,3,opt,name=height,proto3" json:"height,omitempty"` + Prove bool `protobuf:"varint,4,opt,name=prove,proto3" json:"prove,omitempty"` } func (m *RequestQuery) Reset() { *m = RequestQuery{} } func (m *RequestQuery) String() string { return proto.CompactTextString(m) } func (*RequestQuery) ProtoMessage() {} -func (*RequestQuery) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} } +func (*RequestQuery) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{7} } func (m *RequestQuery) GetData() []byte { if m != nil { @@ -625,7 +622,7 @@ type RequestCommit struct { func (m *RequestCommit) Reset() { *m = RequestCommit{} } func (m *RequestCommit) String() string { return proto.CompactTextString(m) } func (*RequestCommit) ProtoMessage() {} -func (*RequestCommit) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{8} } +func (*RequestCommit) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{8} } type RequestInitChain struct { Validators []*Validator `protobuf:"bytes,1,rep,name=validators" json:"validators,omitempty"` @@ -634,7 +631,7 @@ type RequestInitChain struct { func (m *RequestInitChain) Reset() { *m = RequestInitChain{} } func (m *RequestInitChain) String() string { return proto.CompactTextString(m) } func (*RequestInitChain) ProtoMessage() {} -func (*RequestInitChain) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{9} } +func (*RequestInitChain) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{9} } func (m *RequestInitChain) GetValidators() []*Validator { if m != nil { @@ -651,7 +648,7 @@ type RequestBeginBlock struct { func (m *RequestBeginBlock) Reset() { *m = RequestBeginBlock{} } func (m *RequestBeginBlock) String() string { return proto.CompactTextString(m) } func (*RequestBeginBlock) ProtoMessage() {} -func (*RequestBeginBlock) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{10} } +func (*RequestBeginBlock) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{10} } func (m *RequestBeginBlock) GetHash() []byte { if m != nil { @@ -668,13 +665,13 @@ func (m *RequestBeginBlock) GetHeader() *Header { } type RequestEndBlock struct { - Height uint64 `protobuf:"varint,1,opt,name=height" json:"height,omitempty"` + Height uint64 `protobuf:"varint,1,opt,name=height,proto3" json:"height,omitempty"` } func (m *RequestEndBlock) Reset() { *m = RequestEndBlock{} } func (m *RequestEndBlock) String() string { return proto.CompactTextString(m) } func (*RequestEndBlock) ProtoMessage() {} -func (*RequestEndBlock) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{11} } +func (*RequestEndBlock) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{11} } func (m *RequestEndBlock) GetHeight() uint64 { if m != nil { @@ -703,7 +700,7 @@ type Response struct { func (m *Response) Reset() { *m = Response{} } func (m *Response) String() string { return proto.CompactTextString(m) } func (*Response) ProtoMessage() {} -func (*Response) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{12} } +func (*Response) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{12} } type isResponse_Value interface { isResponse_Value() @@ -873,62 +870,62 @@ func _Response_OneofMarshaler(msg proto.Message, b *proto.Buffer) error { // value switch x := m.Value.(type) { case *Response_Exception: - b.EncodeVarint(1<<3 | proto.WireBytes) + _ = b.EncodeVarint(1<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Exception); err != nil { return err } case *Response_Echo: - b.EncodeVarint(2<<3 | proto.WireBytes) + _ = b.EncodeVarint(2<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Echo); err != nil { return err } case *Response_Flush: - b.EncodeVarint(3<<3 | proto.WireBytes) + _ = b.EncodeVarint(3<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Flush); err != nil { return err } case *Response_Info: - b.EncodeVarint(4<<3 | proto.WireBytes) + _ = b.EncodeVarint(4<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Info); err != nil { return err } case *Response_SetOption: - b.EncodeVarint(5<<3 | proto.WireBytes) + _ = b.EncodeVarint(5<<3 | proto.WireBytes) if err := b.EncodeMessage(x.SetOption); err != nil { return err } case *Response_DeliverTx: - b.EncodeVarint(6<<3 | proto.WireBytes) + _ = b.EncodeVarint(6<<3 | proto.WireBytes) if err := b.EncodeMessage(x.DeliverTx); err != nil { return err } case *Response_CheckTx: - b.EncodeVarint(7<<3 | proto.WireBytes) + _ = b.EncodeVarint(7<<3 | proto.WireBytes) if err := b.EncodeMessage(x.CheckTx); err != nil { return err } case *Response_Commit: - b.EncodeVarint(8<<3 | proto.WireBytes) + _ = b.EncodeVarint(8<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Commit); err != nil { return err } case *Response_Query: - b.EncodeVarint(9<<3 | proto.WireBytes) + _ = b.EncodeVarint(9<<3 | proto.WireBytes) if err := b.EncodeMessage(x.Query); err != nil { return err } case *Response_InitChain: - b.EncodeVarint(10<<3 | proto.WireBytes) + _ = b.EncodeVarint(10<<3 | proto.WireBytes) if err := b.EncodeMessage(x.InitChain); err != nil { return err } case *Response_BeginBlock: - b.EncodeVarint(11<<3 | proto.WireBytes) + _ = b.EncodeVarint(11<<3 | proto.WireBytes) if err := b.EncodeMessage(x.BeginBlock); err != nil { return err } case *Response_EndBlock: - b.EncodeVarint(12<<3 | proto.WireBytes) + _ = b.EncodeVarint(12<<3 | proto.WireBytes) if err := b.EncodeMessage(x.EndBlock); err != nil { return err } @@ -1115,13 +1112,13 @@ func _Response_OneofSizer(msg proto.Message) (n int) { } type ResponseException struct { - Error string `protobuf:"bytes,1,opt,name=error" json:"error,omitempty"` + Error string `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"` } func (m *ResponseException) Reset() { *m = ResponseException{} } func (m *ResponseException) String() string { return proto.CompactTextString(m) } func (*ResponseException) ProtoMessage() {} -func (*ResponseException) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{13} } +func (*ResponseException) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{13} } func (m *ResponseException) GetError() string { if m != nil { @@ -1131,13 +1128,13 @@ func (m *ResponseException) GetError() string { } type ResponseEcho struct { - Message string `protobuf:"bytes,1,opt,name=message" json:"message,omitempty"` + Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"` } func (m *ResponseEcho) Reset() { *m = ResponseEcho{} } func (m *ResponseEcho) String() string { return proto.CompactTextString(m) } func (*ResponseEcho) ProtoMessage() {} -func (*ResponseEcho) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{14} } +func (*ResponseEcho) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{14} } func (m *ResponseEcho) GetMessage() string { if m != nil { @@ -1152,19 +1149,19 @@ type ResponseFlush struct { func (m *ResponseFlush) Reset() { *m = ResponseFlush{} } func (m *ResponseFlush) String() string { return proto.CompactTextString(m) } func (*ResponseFlush) ProtoMessage() {} -func (*ResponseFlush) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{15} } +func (*ResponseFlush) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{15} } type ResponseInfo struct { - Data string `protobuf:"bytes,1,opt,name=data" json:"data,omitempty"` - Version string `protobuf:"bytes,2,opt,name=version" json:"version,omitempty"` - LastBlockHeight uint64 `protobuf:"varint,3,opt,name=last_block_height,json=lastBlockHeight" json:"last_block_height,omitempty"` + Data string `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"` + Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"` + LastBlockHeight uint64 `protobuf:"varint,3,opt,name=last_block_height,json=lastBlockHeight,proto3" json:"last_block_height,omitempty"` LastBlockAppHash []byte `protobuf:"bytes,4,opt,name=last_block_app_hash,json=lastBlockAppHash,proto3" json:"last_block_app_hash,omitempty"` } func (m *ResponseInfo) Reset() { *m = ResponseInfo{} } func (m *ResponseInfo) String() string { return proto.CompactTextString(m) } func (*ResponseInfo) ProtoMessage() {} -func (*ResponseInfo) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{16} } +func (*ResponseInfo) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{16} } func (m *ResponseInfo) GetData() string { if m != nil { @@ -1195,13 +1192,13 @@ func (m *ResponseInfo) GetLastBlockAppHash() []byte { } type ResponseSetOption struct { - Log string `protobuf:"bytes,1,opt,name=log" json:"log,omitempty"` + Log string `protobuf:"bytes,1,opt,name=log,proto3" json:"log,omitempty"` } func (m *ResponseSetOption) Reset() { *m = ResponseSetOption{} } func (m *ResponseSetOption) String() string { return proto.CompactTextString(m) } func (*ResponseSetOption) ProtoMessage() {} -func (*ResponseSetOption) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{17} } +func (*ResponseSetOption) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{17} } func (m *ResponseSetOption) GetLog() string { if m != nil { @@ -1211,16 +1208,16 @@ func (m *ResponseSetOption) GetLog() string { } type ResponseDeliverTx struct { - Code uint32 `protobuf:"varint,1,opt,name=code" json:"code,omitempty"` + Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` - Log string `protobuf:"bytes,3,opt,name=log" json:"log,omitempty"` + Log string `protobuf:"bytes,3,opt,name=log,proto3" json:"log,omitempty"` Tags []*KVPair `protobuf:"bytes,4,rep,name=tags" json:"tags,omitempty"` } func (m *ResponseDeliverTx) Reset() { *m = ResponseDeliverTx{} } func (m *ResponseDeliverTx) String() string { return proto.CompactTextString(m) } func (*ResponseDeliverTx) ProtoMessage() {} -func (*ResponseDeliverTx) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{18} } +func (*ResponseDeliverTx) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{18} } func (m *ResponseDeliverTx) GetCode() uint32 { if m != nil { @@ -1251,17 +1248,17 @@ func (m *ResponseDeliverTx) GetTags() []*KVPair { } type ResponseCheckTx struct { - Code uint32 `protobuf:"varint,1,opt,name=code" json:"code,omitempty"` + Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` - Log string `protobuf:"bytes,3,opt,name=log" json:"log,omitempty"` - Gas uint64 `protobuf:"varint,4,opt,name=gas" json:"gas,omitempty"` - Fee uint64 `protobuf:"varint,5,opt,name=fee" json:"fee,omitempty"` + Log string `protobuf:"bytes,3,opt,name=log,proto3" json:"log,omitempty"` + Gas uint64 `protobuf:"varint,4,opt,name=gas,proto3" json:"gas,omitempty"` + Fee uint64 `protobuf:"varint,5,opt,name=fee,proto3" json:"fee,omitempty"` } func (m *ResponseCheckTx) Reset() { *m = ResponseCheckTx{} } func (m *ResponseCheckTx) String() string { return proto.CompactTextString(m) } func (*ResponseCheckTx) ProtoMessage() {} -func (*ResponseCheckTx) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{19} } +func (*ResponseCheckTx) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{19} } func (m *ResponseCheckTx) GetCode() uint32 { if m != nil { @@ -1299,19 +1296,19 @@ func (m *ResponseCheckTx) GetFee() uint64 { } type ResponseQuery struct { - Code uint32 `protobuf:"varint,1,opt,name=code" json:"code,omitempty"` - Index int64 `protobuf:"varint,2,opt,name=index" json:"index,omitempty"` + Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` + Index int64 `protobuf:"varint,2,opt,name=index,proto3" json:"index,omitempty"` Key []byte `protobuf:"bytes,3,opt,name=key,proto3" json:"key,omitempty"` Value []byte `protobuf:"bytes,4,opt,name=value,proto3" json:"value,omitempty"` Proof []byte `protobuf:"bytes,5,opt,name=proof,proto3" json:"proof,omitempty"` - Height uint64 `protobuf:"varint,6,opt,name=height" json:"height,omitempty"` - Log string `protobuf:"bytes,7,opt,name=log" json:"log,omitempty"` + Height uint64 `protobuf:"varint,6,opt,name=height,proto3" json:"height,omitempty"` + Log string `protobuf:"bytes,7,opt,name=log,proto3" json:"log,omitempty"` } func (m *ResponseQuery) Reset() { *m = ResponseQuery{} } func (m *ResponseQuery) String() string { return proto.CompactTextString(m) } func (*ResponseQuery) ProtoMessage() {} -func (*ResponseQuery) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{20} } +func (*ResponseQuery) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{20} } func (m *ResponseQuery) GetCode() uint32 { if m != nil { @@ -1363,15 +1360,15 @@ func (m *ResponseQuery) GetLog() string { } type ResponseCommit struct { - Code uint32 `protobuf:"varint,1,opt,name=code" json:"code,omitempty"` + Code uint32 `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"` Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"` - Log string `protobuf:"bytes,3,opt,name=log" json:"log,omitempty"` + Log string `protobuf:"bytes,3,opt,name=log,proto3" json:"log,omitempty"` } func (m *ResponseCommit) Reset() { *m = ResponseCommit{} } func (m *ResponseCommit) String() string { return proto.CompactTextString(m) } func (*ResponseCommit) ProtoMessage() {} -func (*ResponseCommit) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{21} } +func (*ResponseCommit) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{21} } func (m *ResponseCommit) GetCode() uint32 { if m != nil { @@ -1400,7 +1397,7 @@ type ResponseInitChain struct { func (m *ResponseInitChain) Reset() { *m = ResponseInitChain{} } func (m *ResponseInitChain) String() string { return proto.CompactTextString(m) } func (*ResponseInitChain) ProtoMessage() {} -func (*ResponseInitChain) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{22} } +func (*ResponseInitChain) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{22} } type ResponseBeginBlock struct { } @@ -1408,7 +1405,7 @@ type ResponseBeginBlock struct { func (m *ResponseBeginBlock) Reset() { *m = ResponseBeginBlock{} } func (m *ResponseBeginBlock) String() string { return proto.CompactTextString(m) } func (*ResponseBeginBlock) ProtoMessage() {} -func (*ResponseBeginBlock) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{23} } +func (*ResponseBeginBlock) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{23} } type ResponseEndBlock struct { Diffs []*Validator `protobuf:"bytes,1,rep,name=diffs" json:"diffs,omitempty"` @@ -1417,7 +1414,7 @@ type ResponseEndBlock struct { func (m *ResponseEndBlock) Reset() { *m = ResponseEndBlock{} } func (m *ResponseEndBlock) String() string { return proto.CompactTextString(m) } func (*ResponseEndBlock) ProtoMessage() {} -func (*ResponseEndBlock) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{24} } +func (*ResponseEndBlock) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{24} } func (m *ResponseEndBlock) GetDiffs() []*Validator { if m != nil { @@ -1427,10 +1424,10 @@ func (m *ResponseEndBlock) GetDiffs() []*Validator { } type Header struct { - ChainId string `protobuf:"bytes,1,opt,name=chain_id,json=chainId" json:"chain_id,omitempty"` - Height uint64 `protobuf:"varint,2,opt,name=height" json:"height,omitempty"` - Time uint64 `protobuf:"varint,3,opt,name=time" json:"time,omitempty"` - NumTxs uint64 `protobuf:"varint,4,opt,name=num_txs,json=numTxs" json:"num_txs,omitempty"` + ChainId string `protobuf:"bytes,1,opt,name=chain_id,json=chainId,proto3" json:"chain_id,omitempty"` + Height uint64 `protobuf:"varint,2,opt,name=height,proto3" json:"height,omitempty"` + Time uint64 `protobuf:"varint,3,opt,name=time,proto3" json:"time,omitempty"` + NumTxs uint64 `protobuf:"varint,4,opt,name=num_txs,json=numTxs,proto3" json:"num_txs,omitempty"` LastBlockId *BlockID `protobuf:"bytes,5,opt,name=last_block_id,json=lastBlockId" json:"last_block_id,omitempty"` LastCommitHash []byte `protobuf:"bytes,6,opt,name=last_commit_hash,json=lastCommitHash,proto3" json:"last_commit_hash,omitempty"` DataHash []byte `protobuf:"bytes,7,opt,name=data_hash,json=dataHash,proto3" json:"data_hash,omitempty"` @@ -1441,7 +1438,7 @@ type Header struct { func (m *Header) Reset() { *m = Header{} } func (m *Header) String() string { return proto.CompactTextString(m) } func (*Header) ProtoMessage() {} -func (*Header) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{25} } +func (*Header) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{25} } func (m *Header) GetChainId() string { if m != nil { @@ -1514,7 +1511,7 @@ type BlockID struct { func (m *BlockID) Reset() { *m = BlockID{} } func (m *BlockID) String() string { return proto.CompactTextString(m) } func (*BlockID) ProtoMessage() {} -func (*BlockID) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{26} } +func (*BlockID) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{26} } func (m *BlockID) GetHash() []byte { if m != nil { @@ -1531,14 +1528,14 @@ func (m *BlockID) GetParts() *PartSetHeader { } type PartSetHeader struct { - Total uint64 `protobuf:"varint,1,opt,name=total" json:"total,omitempty"` + Total uint64 `protobuf:"varint,1,opt,name=total,proto3" json:"total,omitempty"` Hash []byte `protobuf:"bytes,2,opt,name=hash,proto3" json:"hash,omitempty"` } func (m *PartSetHeader) Reset() { *m = PartSetHeader{} } func (m *PartSetHeader) String() string { return proto.CompactTextString(m) } func (*PartSetHeader) ProtoMessage() {} -func (*PartSetHeader) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{27} } +func (*PartSetHeader) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{27} } func (m *PartSetHeader) GetTotal() uint64 { if m != nil { @@ -1556,13 +1553,13 @@ func (m *PartSetHeader) GetHash() []byte { type Validator struct { PubKey []byte `protobuf:"bytes,1,opt,name=pubKey,proto3" json:"pubKey,omitempty"` - Power uint64 `protobuf:"varint,2,opt,name=power" json:"power,omitempty"` + Power uint64 `protobuf:"varint,2,opt,name=power,proto3" json:"power,omitempty"` } func (m *Validator) Reset() { *m = Validator{} } func (m *Validator) String() string { return proto.CompactTextString(m) } func (*Validator) ProtoMessage() {} -func (*Validator) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{28} } +func (*Validator) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{28} } func (m *Validator) GetPubKey() []byte { if m != nil { @@ -1579,16 +1576,16 @@ func (m *Validator) GetPower() uint64 { } type KVPair struct { - Key string `protobuf:"bytes,1,opt,name=key" json:"key,omitempty"` - ValueType KVPair_Type `protobuf:"varint,2,opt,name=value_type,json=valueType,enum=types.KVPair_Type" json:"value_type,omitempty"` - ValueString string `protobuf:"bytes,3,opt,name=value_string,json=valueString" json:"value_string,omitempty"` - ValueInt int64 `protobuf:"varint,4,opt,name=value_int,json=valueInt" json:"value_int,omitempty"` + Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"` + ValueType KVPair_Type `protobuf:"varint,2,opt,name=value_type,json=valueType,proto3,enum=types.KVPair_Type" json:"value_type,omitempty"` + ValueString string `protobuf:"bytes,3,opt,name=value_string,json=valueString,proto3" json:"value_string,omitempty"` + ValueInt int64 `protobuf:"varint,4,opt,name=value_int,json=valueInt,proto3" json:"value_int,omitempty"` } func (m *KVPair) Reset() { *m = KVPair{} } func (m *KVPair) String() string { return proto.CompactTextString(m) } func (*KVPair) ProtoMessage() {} -func (*KVPair) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{29} } +func (*KVPair) Descriptor() ([]byte, []int) { return fileDescriptorTypes, []int{29} } func (m *KVPair) GetKey() string { if m != nil { @@ -2054,9 +2051,9 @@ var _ABCIApplication_serviceDesc = grpc.ServiceDesc{ Metadata: "types/types.proto", } -func init() { proto.RegisterFile("types/types.proto", fileDescriptor0) } +func init() { proto.RegisterFile("types/types.proto", fileDescriptorTypes) } -var fileDescriptor0 = []byte{ +var fileDescriptorTypes = []byte{ // 1395 bytes of a gzipped FileDescriptorProto 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x97, 0x4b, 0x6f, 0xdb, 0x46, 0x10, 0x80, 0x2d, 0x89, 0x7a, 0x70, 0xe4, 0x87, 0xb2, 0x71, 0x13, 0x46, 0xb9, 0x24, 0x04, 0xd2,