s4

package
v2.2.0-mercury-20230602 Latest Latest
Warning

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

Go to latest
Published: Jun 2, 2023 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var File_messages_proto protoreflect.FileDescriptor

Functions

func MarshalQuery

func MarshalQuery(rows []*SnapshotRow) ([]byte, error)

func MarshalRows

func MarshalRows(rows []*Row) ([]byte, error)

func NewReportingPlugin

func NewReportingPlugin(logger logger.Logger, config *PluginConfig, orm s4.ORM) (types.ReportingPlugin, error)

func UnmarshalAddress

func UnmarshalAddress(address []byte) *utils.Big

Types

type PluginConfig

type PluginConfig struct {
	ProductName             string
	NSnapshotShards         uint
	MaxObservationEntries   uint
	MaxReportEntries        uint
	MaxDeleteExpiredEntries uint
}

type Query

type Query struct {
	Rows []*SnapshotRow `protobuf:"bytes,1,rep,name=rows,proto3" json:"rows,omitempty"`
	// contains filtered or unexported fields
}

func (*Query) Descriptor deprecated

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

Deprecated: Use Query.ProtoReflect.Descriptor instead.

func (*Query) GetRows

func (x *Query) GetRows() []*SnapshotRow

func (*Query) ProtoMessage

func (*Query) ProtoMessage()

func (*Query) ProtoReflect

func (x *Query) ProtoReflect() protoreflect.Message

func (*Query) Reset

func (x *Query) Reset()

func (*Query) String

func (x *Query) String() string

type Row

type Row struct {
	Address    []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	Slotid     uint32 `protobuf:"varint,2,opt,name=slotid,proto3" json:"slotid,omitempty"`
	Payload    []byte `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"`
	Version    uint64 `protobuf:"varint,4,opt,name=version,proto3" json:"version,omitempty"`
	Expiration int64  `protobuf:"varint,5,opt,name=expiration,proto3" json:"expiration,omitempty"`
	Signature  []byte `protobuf:"bytes,6,opt,name=signature,proto3" json:"signature,omitempty"`
	// contains filtered or unexported fields
}

func UnmarshalRows

func UnmarshalRows(data []byte) ([]*Row, error)

func (*Row) Descriptor deprecated

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

Deprecated: Use Row.ProtoReflect.Descriptor instead.

func (*Row) GetAddress

func (x *Row) GetAddress() []byte

func (*Row) GetExpiration

func (x *Row) GetExpiration() int64

func (*Row) GetPayload

func (x *Row) GetPayload() []byte

func (*Row) GetSignature

func (x *Row) GetSignature() []byte

func (*Row) GetSlotid

func (x *Row) GetSlotid() uint32

func (*Row) GetVersion

func (x *Row) GetVersion() uint64

func (*Row) ProtoMessage

func (*Row) ProtoMessage()

func (*Row) ProtoReflect

func (x *Row) ProtoReflect() protoreflect.Message

func (*Row) Reset

func (x *Row) Reset()

func (*Row) String

func (x *Row) String() string

func (*Row) VerifySignature

func (row *Row) VerifySignature() error

type Rows

type Rows struct {
	Rows []*Row `protobuf:"bytes,1,rep,name=rows,proto3" json:"rows,omitempty"`
	// contains filtered or unexported fields
}

func (*Rows) Descriptor deprecated

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

Deprecated: Use Rows.ProtoReflect.Descriptor instead.

func (*Rows) GetRows

func (x *Rows) GetRows() []*Row

func (*Rows) ProtoMessage

func (*Rows) ProtoMessage()

func (*Rows) ProtoReflect

func (x *Rows) ProtoReflect() protoreflect.Message

func (*Rows) Reset

func (x *Rows) Reset()

func (*Rows) String

func (x *Rows) String() string

type SnapshotRow

type SnapshotRow struct {
	Address []byte `protobuf:"bytes,1,opt,name=address,proto3" json:"address,omitempty"`
	Slotid  uint32 `protobuf:"varint,2,opt,name=slotid,proto3" json:"slotid,omitempty"`
	Version uint64 `protobuf:"varint,3,opt,name=version,proto3" json:"version,omitempty"`
	// contains filtered or unexported fields
}

func UnmarshalQuery

func UnmarshalQuery(data []byte) ([]*SnapshotRow, error)

func (*SnapshotRow) Descriptor deprecated

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

Deprecated: Use SnapshotRow.ProtoReflect.Descriptor instead.

func (*SnapshotRow) GetAddress

func (x *SnapshotRow) GetAddress() []byte

func (*SnapshotRow) GetSlotid

func (x *SnapshotRow) GetSlotid() uint32

func (*SnapshotRow) GetVersion

func (x *SnapshotRow) GetVersion() uint64

func (*SnapshotRow) ProtoMessage

func (*SnapshotRow) ProtoMessage()

func (*SnapshotRow) ProtoReflect

func (x *SnapshotRow) ProtoReflect() protoreflect.Message

func (*SnapshotRow) Reset

func (x *SnapshotRow) Reset()

func (*SnapshotRow) String

func (x *SnapshotRow) String() string

Jump to

Keyboard shortcuts

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