6 Star 44 Fork 25

Hyperledger / fabric

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
ab.pb.go 28.86 KB
一键复制 编辑 原始数据 按行查看 历史
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: orderer/ab.proto
package orderer // import "github.com/hyperledger/fabric/protos/orderer"
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
import common "github.com/hyperledger/fabric/protos/common"
import (
context "golang.org/x/net/context"
grpc "google.golang.org/grpc"
)
// 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.ProtoPackageIsVersion2 // please upgrade the proto package
// If BLOCK_UNTIL_READY is specified, the reply will block until the requested blocks are available,
// if FAIL_IF_NOT_READY is specified, the reply will return an error indicating that the block is not
// found. To request that all blocks be returned indefinitely as they are created, behavior should be
// set to BLOCK_UNTIL_READY and the stop should be set to specified with a number of MAX_UINT64
type SeekInfo_SeekBehavior int32
const (
SeekInfo_BLOCK_UNTIL_READY SeekInfo_SeekBehavior = 0
SeekInfo_FAIL_IF_NOT_READY SeekInfo_SeekBehavior = 1
)
var SeekInfo_SeekBehavior_name = map[int32]string{
0: "BLOCK_UNTIL_READY",
1: "FAIL_IF_NOT_READY",
}
var SeekInfo_SeekBehavior_value = map[string]int32{
"BLOCK_UNTIL_READY": 0,
"FAIL_IF_NOT_READY": 1,
}
func (x SeekInfo_SeekBehavior) String() string {
return proto.EnumName(SeekInfo_SeekBehavior_name, int32(x))
}
func (SeekInfo_SeekBehavior) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_ab_237e854d47750248, []int{5, 0}
}
// SeekErrorTolerance indicates to the server how block provider errors should be tolerated. By default,
// if the deliver service detects a problem in the underlying block source (typically, in the orderer,
// a consenter error), it will begin to reject deliver requests. This is to prevent a client from waiting
// for blocks from an orderer which is stuck in an errored state. This is almost always the desired behavior
// and clients should stick with the default STRICT checking behavior. However, in some scenarios, particularly
// when attempting to recover from a crash or other corruption, it's desirable to force an orderer to respond
// with blocks on a best effort basis, even if the backing consensus implementation is in an errored state.
// In this case, set the SeekErrorResponse to BEST_EFFORT to ignore the consenter errors.
type SeekInfo_SeekErrorResponse int32
const (
SeekInfo_STRICT SeekInfo_SeekErrorResponse = 0
SeekInfo_BEST_EFFORT SeekInfo_SeekErrorResponse = 1
)
var SeekInfo_SeekErrorResponse_name = map[int32]string{
0: "STRICT",
1: "BEST_EFFORT",
}
var SeekInfo_SeekErrorResponse_value = map[string]int32{
"STRICT": 0,
"BEST_EFFORT": 1,
}
func (x SeekInfo_SeekErrorResponse) String() string {
return proto.EnumName(SeekInfo_SeekErrorResponse_name, int32(x))
}
func (SeekInfo_SeekErrorResponse) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_ab_237e854d47750248, []int{5, 1}
}
type BroadcastResponse struct {
// Status code, which may be used to programatically respond to success/failure
Status common.Status `protobuf:"varint,1,opt,name=status,proto3,enum=common.Status" json:"status,omitempty"`
// Info string which may contain additional information about the status returned
Info string `protobuf:"bytes,2,opt,name=info,proto3" json:"info,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *BroadcastResponse) Reset() { *m = BroadcastResponse{} }
func (m *BroadcastResponse) String() string { return proto.CompactTextString(m) }
func (*BroadcastResponse) ProtoMessage() {}
func (*BroadcastResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_ab_237e854d47750248, []int{0}
}
func (m *BroadcastResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_BroadcastResponse.Unmarshal(m, b)
}
func (m *BroadcastResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_BroadcastResponse.Marshal(b, m, deterministic)
}
func (dst *BroadcastResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_BroadcastResponse.Merge(dst, src)
}
func (m *BroadcastResponse) XXX_Size() int {
return xxx_messageInfo_BroadcastResponse.Size(m)
}
func (m *BroadcastResponse) XXX_DiscardUnknown() {
xxx_messageInfo_BroadcastResponse.DiscardUnknown(m)
}
var xxx_messageInfo_BroadcastResponse proto.InternalMessageInfo
func (m *BroadcastResponse) GetStatus() common.Status {
if m != nil {
return m.Status
}
return common.Status_UNKNOWN
}
func (m *BroadcastResponse) GetInfo() string {
if m != nil {
return m.Info
}
return ""
}
type SeekNewest struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *SeekNewest) Reset() { *m = SeekNewest{} }
func (m *SeekNewest) String() string { return proto.CompactTextString(m) }
func (*SeekNewest) ProtoMessage() {}
func (*SeekNewest) Descriptor() ([]byte, []int) {
return fileDescriptor_ab_237e854d47750248, []int{1}
}
func (m *SeekNewest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SeekNewest.Unmarshal(m, b)
}
func (m *SeekNewest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SeekNewest.Marshal(b, m, deterministic)
}
func (dst *SeekNewest) XXX_Merge(src proto.Message) {
xxx_messageInfo_SeekNewest.Merge(dst, src)
}
func (m *SeekNewest) XXX_Size() int {
return xxx_messageInfo_SeekNewest.Size(m)
}
func (m *SeekNewest) XXX_DiscardUnknown() {
xxx_messageInfo_SeekNewest.DiscardUnknown(m)
}
var xxx_messageInfo_SeekNewest proto.InternalMessageInfo
type SeekOldest struct {
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *SeekOldest) Reset() { *m = SeekOldest{} }
func (m *SeekOldest) String() string { return proto.CompactTextString(m) }
func (*SeekOldest) ProtoMessage() {}
func (*SeekOldest) Descriptor() ([]byte, []int) {
return fileDescriptor_ab_237e854d47750248, []int{2}
}
func (m *SeekOldest) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SeekOldest.Unmarshal(m, b)
}
func (m *SeekOldest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SeekOldest.Marshal(b, m, deterministic)
}
func (dst *SeekOldest) XXX_Merge(src proto.Message) {
xxx_messageInfo_SeekOldest.Merge(dst, src)
}
func (m *SeekOldest) XXX_Size() int {
return xxx_messageInfo_SeekOldest.Size(m)
}
func (m *SeekOldest) XXX_DiscardUnknown() {
xxx_messageInfo_SeekOldest.DiscardUnknown(m)
}
var xxx_messageInfo_SeekOldest proto.InternalMessageInfo
type SeekSpecified struct {
Number uint64 `protobuf:"varint,1,opt,name=number,proto3" json:"number,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *SeekSpecified) Reset() { *m = SeekSpecified{} }
func (m *SeekSpecified) String() string { return proto.CompactTextString(m) }
func (*SeekSpecified) ProtoMessage() {}
func (*SeekSpecified) Descriptor() ([]byte, []int) {
return fileDescriptor_ab_237e854d47750248, []int{3}
}
func (m *SeekSpecified) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SeekSpecified.Unmarshal(m, b)
}
func (m *SeekSpecified) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SeekSpecified.Marshal(b, m, deterministic)
}
func (dst *SeekSpecified) XXX_Merge(src proto.Message) {
xxx_messageInfo_SeekSpecified.Merge(dst, src)
}
func (m *SeekSpecified) XXX_Size() int {
return xxx_messageInfo_SeekSpecified.Size(m)
}
func (m *SeekSpecified) XXX_DiscardUnknown() {
xxx_messageInfo_SeekSpecified.DiscardUnknown(m)
}
var xxx_messageInfo_SeekSpecified proto.InternalMessageInfo
func (m *SeekSpecified) GetNumber() uint64 {
if m != nil {
return m.Number
}
return 0
}
type SeekPosition struct {
// Types that are valid to be assigned to Type:
// *SeekPosition_Newest
// *SeekPosition_Oldest
// *SeekPosition_Specified
Type isSeekPosition_Type `protobuf_oneof:"Type"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *SeekPosition) Reset() { *m = SeekPosition{} }
func (m *SeekPosition) String() string { return proto.CompactTextString(m) }
func (*SeekPosition) ProtoMessage() {}
func (*SeekPosition) Descriptor() ([]byte, []int) {
return fileDescriptor_ab_237e854d47750248, []int{4}
}
func (m *SeekPosition) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SeekPosition.Unmarshal(m, b)
}
func (m *SeekPosition) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SeekPosition.Marshal(b, m, deterministic)
}
func (dst *SeekPosition) XXX_Merge(src proto.Message) {
xxx_messageInfo_SeekPosition.Merge(dst, src)
}
func (m *SeekPosition) XXX_Size() int {
return xxx_messageInfo_SeekPosition.Size(m)
}
func (m *SeekPosition) XXX_DiscardUnknown() {
xxx_messageInfo_SeekPosition.DiscardUnknown(m)
}
var xxx_messageInfo_SeekPosition proto.InternalMessageInfo
type isSeekPosition_Type interface {
isSeekPosition_Type()
}
type SeekPosition_Newest struct {
Newest *SeekNewest `protobuf:"bytes,1,opt,name=newest,proto3,oneof"`
}
type SeekPosition_Oldest struct {
Oldest *SeekOldest `protobuf:"bytes,2,opt,name=oldest,proto3,oneof"`
}
type SeekPosition_Specified struct {
Specified *SeekSpecified `protobuf:"bytes,3,opt,name=specified,proto3,oneof"`
}
func (*SeekPosition_Newest) isSeekPosition_Type() {}
func (*SeekPosition_Oldest) isSeekPosition_Type() {}
func (*SeekPosition_Specified) isSeekPosition_Type() {}
func (m *SeekPosition) GetType() isSeekPosition_Type {
if m != nil {
return m.Type
}
return nil
}
func (m *SeekPosition) GetNewest() *SeekNewest {
if x, ok := m.GetType().(*SeekPosition_Newest); ok {
return x.Newest
}
return nil
}
func (m *SeekPosition) GetOldest() *SeekOldest {
if x, ok := m.GetType().(*SeekPosition_Oldest); ok {
return x.Oldest
}
return nil
}
func (m *SeekPosition) GetSpecified() *SeekSpecified {
if x, ok := m.GetType().(*SeekPosition_Specified); ok {
return x.Specified
}
return nil
}
// XXX_OneofFuncs is for the internal use of the proto package.
func (*SeekPosition) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
return _SeekPosition_OneofMarshaler, _SeekPosition_OneofUnmarshaler, _SeekPosition_OneofSizer, []interface{}{
(*SeekPosition_Newest)(nil),
(*SeekPosition_Oldest)(nil),
(*SeekPosition_Specified)(nil),
}
}
func _SeekPosition_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
m := msg.(*SeekPosition)
// Type
switch x := m.Type.(type) {
case *SeekPosition_Newest:
b.EncodeVarint(1<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Newest); err != nil {
return err
}
case *SeekPosition_Oldest:
b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Oldest); err != nil {
return err
}
case *SeekPosition_Specified:
b.EncodeVarint(3<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Specified); err != nil {
return err
}
case nil:
default:
return fmt.Errorf("SeekPosition.Type has unexpected type %T", x)
}
return nil
}
func _SeekPosition_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
m := msg.(*SeekPosition)
switch tag {
case 1: // Type.newest
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(SeekNewest)
err := b.DecodeMessage(msg)
m.Type = &SeekPosition_Newest{msg}
return true, err
case 2: // Type.oldest
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(SeekOldest)
err := b.DecodeMessage(msg)
m.Type = &SeekPosition_Oldest{msg}
return true, err
case 3: // Type.specified
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(SeekSpecified)
err := b.DecodeMessage(msg)
m.Type = &SeekPosition_Specified{msg}
return true, err
default:
return false, nil
}
}
func _SeekPosition_OneofSizer(msg proto.Message) (n int) {
m := msg.(*SeekPosition)
// Type
switch x := m.Type.(type) {
case *SeekPosition_Newest:
s := proto.Size(x.Newest)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *SeekPosition_Oldest:
s := proto.Size(x.Oldest)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case *SeekPosition_Specified:
s := proto.Size(x.Specified)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case nil:
default:
panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
}
return n
}
// SeekInfo specifies the range of requested blocks to return
// If the start position is not found, an error is immediately returned
// Otherwise, blocks are returned until a missing block is encountered, then behavior is dictated
// by the SeekBehavior specified.
type SeekInfo struct {
Start *SeekPosition `protobuf:"bytes,1,opt,name=start,proto3" json:"start,omitempty"`
Stop *SeekPosition `protobuf:"bytes,2,opt,name=stop,proto3" json:"stop,omitempty"`
Behavior SeekInfo_SeekBehavior `protobuf:"varint,3,opt,name=behavior,proto3,enum=orderer.SeekInfo_SeekBehavior" json:"behavior,omitempty"`
ErrorResponse SeekInfo_SeekErrorResponse `protobuf:"varint,4,opt,name=error_response,json=errorResponse,proto3,enum=orderer.SeekInfo_SeekErrorResponse" json:"error_response,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *SeekInfo) Reset() { *m = SeekInfo{} }
func (m *SeekInfo) String() string { return proto.CompactTextString(m) }
func (*SeekInfo) ProtoMessage() {}
func (*SeekInfo) Descriptor() ([]byte, []int) {
return fileDescriptor_ab_237e854d47750248, []int{5}
}
func (m *SeekInfo) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_SeekInfo.Unmarshal(m, b)
}
func (m *SeekInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_SeekInfo.Marshal(b, m, deterministic)
}
func (dst *SeekInfo) XXX_Merge(src proto.Message) {
xxx_messageInfo_SeekInfo.Merge(dst, src)
}
func (m *SeekInfo) XXX_Size() int {
return xxx_messageInfo_SeekInfo.Size(m)
}
func (m *SeekInfo) XXX_DiscardUnknown() {
xxx_messageInfo_SeekInfo.DiscardUnknown(m)
}
var xxx_messageInfo_SeekInfo proto.InternalMessageInfo
func (m *SeekInfo) GetStart() *SeekPosition {
if m != nil {
return m.Start
}
return nil
}
func (m *SeekInfo) GetStop() *SeekPosition {
if m != nil {
return m.Stop
}
return nil
}
func (m *SeekInfo) GetBehavior() SeekInfo_SeekBehavior {
if m != nil {
return m.Behavior
}
return SeekInfo_BLOCK_UNTIL_READY
}
func (m *SeekInfo) GetErrorResponse() SeekInfo_SeekErrorResponse {
if m != nil {
return m.ErrorResponse
}
return SeekInfo_STRICT
}
type DeliverResponse struct {
// Types that are valid to be assigned to Type:
// *DeliverResponse_Status
// *DeliverResponse_Block
Type isDeliverResponse_Type `protobuf_oneof:"Type"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *DeliverResponse) Reset() { *m = DeliverResponse{} }
func (m *DeliverResponse) String() string { return proto.CompactTextString(m) }
func (*DeliverResponse) ProtoMessage() {}
func (*DeliverResponse) Descriptor() ([]byte, []int) {
return fileDescriptor_ab_237e854d47750248, []int{6}
}
func (m *DeliverResponse) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_DeliverResponse.Unmarshal(m, b)
}
func (m *DeliverResponse) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_DeliverResponse.Marshal(b, m, deterministic)
}
func (dst *DeliverResponse) XXX_Merge(src proto.Message) {
xxx_messageInfo_DeliverResponse.Merge(dst, src)
}
func (m *DeliverResponse) XXX_Size() int {
return xxx_messageInfo_DeliverResponse.Size(m)
}
func (m *DeliverResponse) XXX_DiscardUnknown() {
xxx_messageInfo_DeliverResponse.DiscardUnknown(m)
}
var xxx_messageInfo_DeliverResponse proto.InternalMessageInfo
type isDeliverResponse_Type interface {
isDeliverResponse_Type()
}
type DeliverResponse_Status struct {
Status common.Status `protobuf:"varint,1,opt,name=status,proto3,enum=common.Status,oneof"`
}
type DeliverResponse_Block struct {
Block *common.Block `protobuf:"bytes,2,opt,name=block,proto3,oneof"`
}
func (*DeliverResponse_Status) isDeliverResponse_Type() {}
func (*DeliverResponse_Block) isDeliverResponse_Type() {}
func (m *DeliverResponse) GetType() isDeliverResponse_Type {
if m != nil {
return m.Type
}
return nil
}
func (m *DeliverResponse) GetStatus() common.Status {
if x, ok := m.GetType().(*DeliverResponse_Status); ok {
return x.Status
}
return common.Status_UNKNOWN
}
func (m *DeliverResponse) GetBlock() *common.Block {
if x, ok := m.GetType().(*DeliverResponse_Block); ok {
return x.Block
}
return nil
}
// XXX_OneofFuncs is for the internal use of the proto package.
func (*DeliverResponse) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
return _DeliverResponse_OneofMarshaler, _DeliverResponse_OneofUnmarshaler, _DeliverResponse_OneofSizer, []interface{}{
(*DeliverResponse_Status)(nil),
(*DeliverResponse_Block)(nil),
}
}
func _DeliverResponse_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
m := msg.(*DeliverResponse)
// Type
switch x := m.Type.(type) {
case *DeliverResponse_Status:
b.EncodeVarint(1<<3 | proto.WireVarint)
b.EncodeVarint(uint64(x.Status))
case *DeliverResponse_Block:
b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Block); err != nil {
return err
}
case nil:
default:
return fmt.Errorf("DeliverResponse.Type has unexpected type %T", x)
}
return nil
}
func _DeliverResponse_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
m := msg.(*DeliverResponse)
switch tag {
case 1: // Type.status
if wire != proto.WireVarint {
return true, proto.ErrInternalBadWireType
}
x, err := b.DecodeVarint()
m.Type = &DeliverResponse_Status{common.Status(x)}
return true, err
case 2: // Type.block
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(common.Block)
err := b.DecodeMessage(msg)
m.Type = &DeliverResponse_Block{msg}
return true, err
default:
return false, nil
}
}
func _DeliverResponse_OneofSizer(msg proto.Message) (n int) {
m := msg.(*DeliverResponse)
// Type
switch x := m.Type.(type) {
case *DeliverResponse_Status:
n += 1 // tag and wire
n += proto.SizeVarint(uint64(x.Status))
case *DeliverResponse_Block:
s := proto.Size(x.Block)
n += 1 // tag and wire
n += proto.SizeVarint(uint64(s))
n += s
case nil:
default:
panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
}
return n
}
func init() {
proto.RegisterType((*BroadcastResponse)(nil), "orderer.BroadcastResponse")
proto.RegisterType((*SeekNewest)(nil), "orderer.SeekNewest")
proto.RegisterType((*SeekOldest)(nil), "orderer.SeekOldest")
proto.RegisterType((*SeekSpecified)(nil), "orderer.SeekSpecified")
proto.RegisterType((*SeekPosition)(nil), "orderer.SeekPosition")
proto.RegisterType((*SeekInfo)(nil), "orderer.SeekInfo")
proto.RegisterType((*DeliverResponse)(nil), "orderer.DeliverResponse")
proto.RegisterEnum("orderer.SeekInfo_SeekBehavior", SeekInfo_SeekBehavior_name, SeekInfo_SeekBehavior_value)
proto.RegisterEnum("orderer.SeekInfo_SeekErrorResponse", SeekInfo_SeekErrorResponse_name, SeekInfo_SeekErrorResponse_value)
}
// Reference imports to suppress errors if they are not otherwise used.
var _ context.Context
var _ grpc.ClientConn
// This is a compile-time assertion to ensure that this generated file
// is compatible with the grpc package it is being compiled against.
const _ = grpc.SupportPackageIsVersion4
// AtomicBroadcastClient is the client API for AtomicBroadcast service.
//
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
type AtomicBroadcastClient interface {
// broadcast receives a reply of Acknowledgement for each common.Envelope in order, indicating success or type of failure
Broadcast(ctx context.Context, opts ...grpc.CallOption) (AtomicBroadcast_BroadcastClient, error)
// deliver first requires an Envelope of type DELIVER_SEEK_INFO with Payload data as a mashaled SeekInfo message, then a stream of block replies is received.
Deliver(ctx context.Context, opts ...grpc.CallOption) (AtomicBroadcast_DeliverClient, error)
}
type atomicBroadcastClient struct {
cc *grpc.ClientConn
}
func NewAtomicBroadcastClient(cc *grpc.ClientConn) AtomicBroadcastClient {
return &atomicBroadcastClient{cc}
}
func (c *atomicBroadcastClient) Broadcast(ctx context.Context, opts ...grpc.CallOption) (AtomicBroadcast_BroadcastClient, error) {
stream, err := c.cc.NewStream(ctx, &_AtomicBroadcast_serviceDesc.Streams[0], "/orderer.AtomicBroadcast/Broadcast", opts...)
if err != nil {
return nil, err
}
x := &atomicBroadcastBroadcastClient{stream}
return x, nil
}
type AtomicBroadcast_BroadcastClient interface {
Send(*common.Envelope) error
Recv() (*BroadcastResponse, error)
grpc.ClientStream
}
type atomicBroadcastBroadcastClient struct {
grpc.ClientStream
}
func (x *atomicBroadcastBroadcastClient) Send(m *common.Envelope) error {
return x.ClientStream.SendMsg(m)
}
func (x *atomicBroadcastBroadcastClient) Recv() (*BroadcastResponse, error) {
m := new(BroadcastResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func (c *atomicBroadcastClient) Deliver(ctx context.Context, opts ...grpc.CallOption) (AtomicBroadcast_DeliverClient, error) {
stream, err := c.cc.NewStream(ctx, &_AtomicBroadcast_serviceDesc.Streams[1], "/orderer.AtomicBroadcast/Deliver", opts...)
if err != nil {
return nil, err
}
x := &atomicBroadcastDeliverClient{stream}
return x, nil
}
type AtomicBroadcast_DeliverClient interface {
Send(*common.Envelope) error
Recv() (*DeliverResponse, error)
grpc.ClientStream
}
type atomicBroadcastDeliverClient struct {
grpc.ClientStream
}
func (x *atomicBroadcastDeliverClient) Send(m *common.Envelope) error {
return x.ClientStream.SendMsg(m)
}
func (x *atomicBroadcastDeliverClient) Recv() (*DeliverResponse, error) {
m := new(DeliverResponse)
if err := x.ClientStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
// AtomicBroadcastServer is the server API for AtomicBroadcast service.
type AtomicBroadcastServer interface {
// broadcast receives a reply of Acknowledgement for each common.Envelope in order, indicating success or type of failure
Broadcast(AtomicBroadcast_BroadcastServer) error
// deliver first requires an Envelope of type DELIVER_SEEK_INFO with Payload data as a mashaled SeekInfo message, then a stream of block replies is received.
Deliver(AtomicBroadcast_DeliverServer) error
}
func RegisterAtomicBroadcastServer(s *grpc.Server, srv AtomicBroadcastServer) {
s.RegisterService(&_AtomicBroadcast_serviceDesc, srv)
}
func _AtomicBroadcast_Broadcast_Handler(srv interface{}, stream grpc.ServerStream) error {
return srv.(AtomicBroadcastServer).Broadcast(&atomicBroadcastBroadcastServer{stream})
}
type AtomicBroadcast_BroadcastServer interface {
Send(*BroadcastResponse) error
Recv() (*common.Envelope, error)
grpc.ServerStream
}
type atomicBroadcastBroadcastServer struct {
grpc.ServerStream
}
func (x *atomicBroadcastBroadcastServer) Send(m *BroadcastResponse) error {
return x.ServerStream.SendMsg(m)
}
func (x *atomicBroadcastBroadcastServer) Recv() (*common.Envelope, error) {
m := new(common.Envelope)
if err := x.ServerStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
func _AtomicBroadcast_Deliver_Handler(srv interface{}, stream grpc.ServerStream) error {
return srv.(AtomicBroadcastServer).Deliver(&atomicBroadcastDeliverServer{stream})
}
type AtomicBroadcast_DeliverServer interface {
Send(*DeliverResponse) error
Recv() (*common.Envelope, error)
grpc.ServerStream
}
type atomicBroadcastDeliverServer struct {
grpc.ServerStream
}
func (x *atomicBroadcastDeliverServer) Send(m *DeliverResponse) error {
return x.ServerStream.SendMsg(m)
}
func (x *atomicBroadcastDeliverServer) Recv() (*common.Envelope, error) {
m := new(common.Envelope)
if err := x.ServerStream.RecvMsg(m); err != nil {
return nil, err
}
return m, nil
}
var _AtomicBroadcast_serviceDesc = grpc.ServiceDesc{
ServiceName: "orderer.AtomicBroadcast",
HandlerType: (*AtomicBroadcastServer)(nil),
Methods: []grpc.MethodDesc{},
Streams: []grpc.StreamDesc{
{
StreamName: "Broadcast",
Handler: _AtomicBroadcast_Broadcast_Handler,
ServerStreams: true,
ClientStreams: true,
},
{
StreamName: "Deliver",
Handler: _AtomicBroadcast_Deliver_Handler,
ServerStreams: true,
ClientStreams: true,
},
},
Metadata: "orderer/ab.proto",
}
func init() { proto.RegisterFile("orderer/ab.proto", fileDescriptor_ab_237e854d47750248) }
var fileDescriptor_ab_237e854d47750248 = []byte{
// 560 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x93, 0xdd, 0x6e, 0xd3, 0x30,
0x14, 0xc7, 0x93, 0xd1, 0x65, 0xdb, 0xd9, 0xfa, 0xe5, 0x69, 0x53, 0xd5, 0x0b, 0x34, 0x05, 0x0d,
0x8a, 0x80, 0x64, 0x2a, 0x12, 0x17, 0x80, 0x84, 0x9a, 0xad, 0x55, 0x0b, 0x55, 0x8b, 0xdc, 0xec,
0x02, 0x6e, 0xa2, 0x24, 0x75, 0xdb, 0xb0, 0x36, 0x8e, 0x9c, 0xb4, 0x68, 0x4f, 0xc1, 0x8b, 0xf0,
0x44, 0x3c, 0x0d, 0xf2, 0x47, 0xda, 0x75, 0x1b, 0x5c, 0x25, 0xe7, 0xf8, 0x77, 0xce, 0xff, 0x6f,
0x1f, 0x1b, 0x2a, 0x94, 0x8d, 0x09, 0x23, 0xcc, 0xf6, 0x03, 0x2b, 0x61, 0x34, 0xa3, 0x68, 0x4f,
0x65, 0xea, 0xc7, 0x21, 0x5d, 0x2c, 0x68, 0x6c, 0xcb, 0x8f, 0x5c, 0x35, 0x87, 0x50, 0x75, 0x18,
0xf5, 0xc7, 0xa1, 0x9f, 0x66, 0x98, 0xa4, 0x09, 0x8d, 0x53, 0x82, 0x9e, 0x83, 0x91, 0x66, 0x7e,
0xb6, 0x4c, 0x6b, 0xfa, 0x99, 0xde, 0x28, 0x35, 0x4b, 0x96, 0xaa, 0x19, 0x89, 0x2c, 0x56, 0xab,
0x08, 0x41, 0x21, 0x8a, 0x27, 0xb4, 0xb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1, 0x03, 0x16, 0x85, 0xf2, 0xfd, 0xa6, 0x79, 0xf9, 0xf7, 0xd7, 0xd3,
0x28, 0x9b, 0x2d, 0x03, 0x2e, 0x60, 0xdf, 0xa1, 0x6d, 0x49, 0xdb, 0x92, 0xb6, 0x15, 0x1d, 0x18,
0x22, 0x7e, 0xfb, 0x37, 0x00, 0x00, 0xff, 0xff, 0x48, 0x6c, 0xc9, 0x45, 0x2f, 0x04, 0x00, 0x00,
}
1
https://gitee.com/hyperledger/fabric.git
git@gitee.com:hyperledger/fabric.git
hyperledger
fabric
fabric
v1.4.12

搜索帮助