Documentation ¶
Overview ¶
Package batch provides batch transaction support middleware to support multiple operations in one transaction
Package batch implements batch transactions.
> Batch transaction holds a list of messages > that a given application can process. What this means > is we can wrap several "transactions" within one message. > The transaction fails if any of the messages fail to be processed. > Note that fees, sigs and other extensions that don't rely on messages > are only applied once per transaction, which means that all the "embedded" > transactions don't hit the middleware.
Index ¶
- Constants
- Variables
- func Validate(msg Msg) error
- type BatchTx
- type ByteArrayList
- func (*ByteArrayList) Descriptor() ([]byte, []int)
- func (m *ByteArrayList) GetElements() [][]byte
- func (m *ByteArrayList) Marshal() (dAtA []byte, err error)
- func (m *ByteArrayList) MarshalTo(dAtA []byte) (int, error)
- func (*ByteArrayList) ProtoMessage()
- func (m *ByteArrayList) Reset()
- func (m *ByteArrayList) Size() (n int)
- func (m *ByteArrayList) String() string
- func (m *ByteArrayList) Unmarshal(dAtA []byte) error
- func (m *ByteArrayList) XXX_DiscardUnknown()
- func (m *ByteArrayList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
- func (m *ByteArrayList) XXX_Merge(src proto.Message)
- func (m *ByteArrayList) XXX_Size() int
- func (m *ByteArrayList) XXX_Unmarshal(b []byte) error
- type Decorator
- type Msg
Constants ¶
const MaxBatchMessages = 10
const (
PathExecuteBatchMsg = "batch/execute"
)
Variables ¶
var ( ErrInvalidLengthCodec = fmt.Errorf("proto: negative length found during unmarshaling") ErrIntOverflowCodec = fmt.Errorf("proto: integer overflow") )
Functions ¶
Types ¶
type ByteArrayList ¶
type ByteArrayList struct {
Elements [][]byte `protobuf:"bytes,1,rep,name=elements,proto3" json:"elements,omitempty"`
}
func (*ByteArrayList) Descriptor ¶
func (*ByteArrayList) Descriptor() ([]byte, []int)
func (*ByteArrayList) GetElements ¶
func (m *ByteArrayList) GetElements() [][]byte
func (*ByteArrayList) Marshal ¶
func (m *ByteArrayList) Marshal() (dAtA []byte, err error)
func (*ByteArrayList) ProtoMessage ¶
func (*ByteArrayList) ProtoMessage()
func (*ByteArrayList) Reset ¶
func (m *ByteArrayList) Reset()
func (*ByteArrayList) Size ¶
func (m *ByteArrayList) Size() (n int)
func (*ByteArrayList) String ¶
func (m *ByteArrayList) String() string
func (*ByteArrayList) Unmarshal ¶
func (m *ByteArrayList) Unmarshal(dAtA []byte) error
func (*ByteArrayList) XXX_DiscardUnknown ¶ added in v0.12.0
func (m *ByteArrayList) XXX_DiscardUnknown()
func (*ByteArrayList) XXX_Marshal ¶ added in v0.12.0
func (m *ByteArrayList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)
func (*ByteArrayList) XXX_Merge ¶ added in v0.12.0
func (m *ByteArrayList) XXX_Merge(src proto.Message)
func (*ByteArrayList) XXX_Size ¶ added in v0.12.0
func (m *ByteArrayList) XXX_Size() int
func (*ByteArrayList) XXX_Unmarshal ¶ added in v0.12.0
func (m *ByteArrayList) XXX_Unmarshal(b []byte) error
type Decorator ¶
type Decorator struct { }
Decorator iterates through batch transaction messages and passes them down the stack
func NewDecorator ¶
func NewDecorator() Decorator
NewDecorator returns a batch transaction decorator