dump

package
v0.27.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 23, 2019 License: Apache-2.0 Imports: 24 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidLengthDump = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowDump   = fmt.Errorf("proto: integer overflow")
)

Functions

func Load added in v0.26.1

func Load(reader Reader, st *state.State) error

Load a dump into state

func Write added in v0.26.1

func Write(stream Receiver, out io.Writer, useJSON bool, options Option) error

Types

type AccountStorage

type AccountStorage struct {
	Address              github_com_hyperledger_burrow_crypto.Address `protobuf:"bytes,1,opt,name=Address,proto3,customtype=github.com/hyperledger/burrow/crypto.Address" json:"Address"`
	Storage              []*Storage                                   `protobuf:"bytes,2,rep,name=Storage,proto3" json:"Storage,omitempty"`
	XXX_NoUnkeyedLiteral struct{}                                     `json:"-"`
	XXX_unrecognized     []byte                                       `json:"-"`
	XXX_sizecache        int32                                        `json:"-"`
}

func (*AccountStorage) Descriptor

func (*AccountStorage) Descriptor() ([]byte, []int)

func (*AccountStorage) GetStorage

func (m *AccountStorage) GetStorage() []*Storage

func (*AccountStorage) Marshal

func (m *AccountStorage) Marshal() (dAtA []byte, err error)

func (*AccountStorage) MarshalTo

func (m *AccountStorage) MarshalTo(dAtA []byte) (int, error)

func (*AccountStorage) ProtoMessage

func (*AccountStorage) ProtoMessage()

func (*AccountStorage) Reset

func (m *AccountStorage) Reset()

func (*AccountStorage) Size

func (m *AccountStorage) Size() (n int)

func (*AccountStorage) String

func (m *AccountStorage) String() string

func (*AccountStorage) Unmarshal

func (m *AccountStorage) Unmarshal(dAtA []byte) error

func (*AccountStorage) XXX_DiscardUnknown

func (m *AccountStorage) XXX_DiscardUnknown()

func (*AccountStorage) XXX_Marshal

func (m *AccountStorage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*AccountStorage) XXX_Merge

func (m *AccountStorage) XXX_Merge(src proto.Message)

func (*AccountStorage) XXX_MessageName

func (*AccountStorage) XXX_MessageName() string

func (*AccountStorage) XXX_Size

func (m *AccountStorage) XXX_Size() int

func (*AccountStorage) XXX_Unmarshal

func (m *AccountStorage) XXX_Unmarshal(b []byte) error

type Dump

type Dump struct {
	Height               uint64          `protobuf:"varint,1,opt,name=Height,proto3" json:"Height,omitempty"`
	Account              *acm.Account    `protobuf:"bytes,2,opt,name=Account,proto3" json:"Account,omitempty"`
	AccountStorage       *AccountStorage `protobuf:"bytes,3,opt,name=AccountStorage,proto3" json:"AccountStorage,omitempty"`
	EVMEvent             *EVMEvent       `protobuf:"bytes,4,opt,name=EVMEvent,proto3" json:"EVMEvent,omitempty"`
	Name                 *names.Entry    `protobuf:"bytes,5,opt,name=Name,proto3" json:"Name,omitempty"`
	XXX_NoUnkeyedLiteral struct{}        `json:"-"`
	XXX_unrecognized     []byte          `json:"-"`
	XXX_sizecache        int32           `json:"-"`
}

func (*Dump) Descriptor

func (*Dump) Descriptor() ([]byte, []int)

func (*Dump) GetAccount

func (m *Dump) GetAccount() *acm.Account

func (*Dump) GetAccountStorage

func (m *Dump) GetAccountStorage() *AccountStorage

func (*Dump) GetEVMEvent

func (m *Dump) GetEVMEvent() *EVMEvent

func (*Dump) GetHeight

func (m *Dump) GetHeight() uint64

func (*Dump) GetName

func (m *Dump) GetName() *names.Entry

func (*Dump) Marshal

func (m *Dump) Marshal() (dAtA []byte, err error)

func (*Dump) MarshalTo

func (m *Dump) MarshalTo(dAtA []byte) (int, error)

func (*Dump) ProtoMessage

func (*Dump) ProtoMessage()

func (*Dump) Reset

func (m *Dump) Reset()

func (*Dump) Size

func (m *Dump) Size() (n int)

func (*Dump) String

func (m *Dump) String() string

func (*Dump) Unmarshal

func (m *Dump) Unmarshal(dAtA []byte) error

func (*Dump) XXX_DiscardUnknown

func (m *Dump) XXX_DiscardUnknown()

func (*Dump) XXX_Marshal

func (m *Dump) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Dump) XXX_Merge

func (m *Dump) XXX_Merge(src proto.Message)

func (*Dump) XXX_MessageName

func (*Dump) XXX_MessageName() string

func (*Dump) XXX_Size

func (m *Dump) XXX_Size() int

func (*Dump) XXX_Unmarshal

func (m *Dump) XXX_Unmarshal(b []byte) error

type Dumper added in v0.26.1

type Dumper struct {
	// contains filtered or unexported fields
}

func NewDumper added in v0.26.1

func NewDumper(state *state.State, blockchain bcm.BlockchainInfo, logger *logging.Logger) *Dumper

func (*Dumper) Pipe added in v0.26.1

func (ds *Dumper) Pipe(startHeight, endHeight uint64, options Option) Pipe

func (*Dumper) Transmit added in v0.26.1

func (ds *Dumper) Transmit(stream Sender, startHeight, endHeight uint64, options Option) error

type EVMEvent

type EVMEvent struct {
	// The original ChainID from for this event
	ChainID string `protobuf:"bytes,1,opt,name=ChainID,proto3" json:"ChainID,omitempty"`
	// The original block time for this transaction
	Time time.Time `protobuf:"bytes,2,opt,name=Time,proto3,stdtime" json:"Time"`
	// The event itself
	Event                *exec.LogEvent `protobuf:"bytes,3,opt,name=Event,proto3" json:"Event,omitempty"`
	XXX_NoUnkeyedLiteral struct{}       `json:"-"`
	XXX_unrecognized     []byte         `json:"-"`
	XXX_sizecache        int32          `json:"-"`
}

func (*EVMEvent) Descriptor

func (*EVMEvent) Descriptor() ([]byte, []int)

func (*EVMEvent) GetChainID

func (m *EVMEvent) GetChainID() string

func (*EVMEvent) GetEvent

func (m *EVMEvent) GetEvent() *exec.LogEvent

func (*EVMEvent) GetTime

func (m *EVMEvent) GetTime() time.Time

func (*EVMEvent) Marshal

func (m *EVMEvent) Marshal() (dAtA []byte, err error)

func (*EVMEvent) MarshalTo

func (m *EVMEvent) MarshalTo(dAtA []byte) (int, error)

func (*EVMEvent) ProtoMessage

func (*EVMEvent) ProtoMessage()

func (*EVMEvent) Reset

func (m *EVMEvent) Reset()

func (*EVMEvent) Size

func (m *EVMEvent) Size() (n int)

func (*EVMEvent) String

func (m *EVMEvent) String() string

func (*EVMEvent) Unmarshal

func (m *EVMEvent) Unmarshal(dAtA []byte) error

func (*EVMEvent) XXX_DiscardUnknown

func (m *EVMEvent) XXX_DiscardUnknown()

func (*EVMEvent) XXX_Marshal

func (m *EVMEvent) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*EVMEvent) XXX_Merge

func (m *EVMEvent) XXX_Merge(src proto.Message)

func (*EVMEvent) XXX_MessageName

func (*EVMEvent) XXX_MessageName() string

func (*EVMEvent) XXX_Size

func (m *EVMEvent) XXX_Size() int

func (*EVMEvent) XXX_Unmarshal

func (m *EVMEvent) XXX_Unmarshal(b []byte) error

type FileReader added in v0.26.1

type FileReader struct {
	// contains filtered or unexported fields
}

func (*FileReader) Next added in v0.26.1

func (f *FileReader) Next() (*Dump, error)

type Option added in v0.26.1

type Option uint64
const (
	// Whether to send/receive these classes of data
	Accounts Option = 1 << iota
	Names
	Events
)
const (
	None Option = 0
	All         = Accounts | Names | Events
)

func (Option) Enabled added in v0.26.1

func (options Option) Enabled(option Option) bool

type Pipe added in v0.26.1

type Pipe chan msg

Implements both Sender and Receiver

func (Pipe) Recv added in v0.26.1

func (p Pipe) Recv() (*Dump, error)

func (Pipe) Send added in v0.26.1

func (p Pipe) Send(dump *Dump) error

type Reader added in v0.26.1

type Reader interface {
	Next() (*Dump, error)
}

func NewFileReader added in v0.26.1

func NewFileReader(filename string) (Reader, error)

type Receiver added in v0.26.1

type Receiver interface {
	Recv() (*Dump, error)
}

type Sender added in v0.26.1

type Sender interface {
	Send(*Dump) error
}

type Storage

type Storage struct {
	Key                  github_com_hyperledger_burrow_binary.Word256  `protobuf:"bytes,1,opt,name=Key,proto3,customtype=github.com/hyperledger/burrow/binary.Word256" json:"Key"`
	Value                github_com_hyperledger_burrow_binary.HexBytes `protobuf:"bytes,2,opt,name=Value,proto3,customtype=github.com/hyperledger/burrow/binary.HexBytes" json:"Value"`
	XXX_NoUnkeyedLiteral struct{}                                      `json:"-"`
	XXX_unrecognized     []byte                                        `json:"-"`
	XXX_sizecache        int32                                         `json:"-"`
}

func (*Storage) Descriptor

func (*Storage) Descriptor() ([]byte, []int)

func (*Storage) Marshal

func (m *Storage) Marshal() (dAtA []byte, err error)

func (*Storage) MarshalTo

func (m *Storage) MarshalTo(dAtA []byte) (int, error)

func (*Storage) ProtoMessage

func (*Storage) ProtoMessage()

func (*Storage) Reset

func (m *Storage) Reset()

func (*Storage) Size

func (m *Storage) Size() (n int)

func (*Storage) String

func (m *Storage) String() string

func (*Storage) Unmarshal

func (m *Storage) Unmarshal(dAtA []byte) error

func (*Storage) XXX_DiscardUnknown

func (m *Storage) XXX_DiscardUnknown()

func (*Storage) XXX_Marshal

func (m *Storage) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Storage) XXX_Merge

func (m *Storage) XXX_Merge(src proto.Message)

func (*Storage) XXX_MessageName

func (*Storage) XXX_MessageName() string

func (*Storage) XXX_Size

func (m *Storage) XXX_Size() int

func (*Storage) XXX_Unmarshal

func (m *Storage) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL