Documentation
¶
Index ¶
- Constants
- func DecodeBlockValue(key, value []byte) (*block.BlockRef, *block.StoredBlock, error)
- type PackReplacementEvent
- func (m *PackReplacementEvent) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *PackReplacementEvent) CloneVT() *PackReplacementEvent
- func (this *PackReplacementEvent) EqualMessageVT(thatMsg any) bool
- func (this *PackReplacementEvent) EqualVT(that *PackReplacementEvent) bool
- func (x *PackReplacementEvent) GetReplacedPackIds() []string
- func (x *PackReplacementEvent) GetReplacementPackIds() []string
- func (x *PackReplacementEvent) GetSequence() uint64
- func (x *PackReplacementEvent) MarshalJSON() ([]byte, error)
- func (x *PackReplacementEvent) MarshalProtoJSON(s *json.MarshalState)
- func (x *PackReplacementEvent) MarshalProtoText() string
- func (m *PackReplacementEvent) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *PackReplacementEvent) MarshalToVT(dAtA []byte) (int, error)
- func (m *PackReplacementEvent) MarshalVT() (dAtA []byte, err error)
- func (*PackReplacementEvent) ProtoMessage()
- func (x *PackReplacementEvent) Reset()
- func (m *PackReplacementEvent) SizeVT() (n int)
- func (x *PackReplacementEvent) String() string
- func (x *PackReplacementEvent) UnmarshalJSON(b []byte) error
- func (x *PackReplacementEvent) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *PackReplacementEvent) UnmarshalVT(dAtA []byte) error
- type PackfileEntry
- func (m *PackfileEntry) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *PackfileEntry) CloneVT() *PackfileEntry
- func (this *PackfileEntry) EqualMessageVT(thatMsg any) bool
- func (this *PackfileEntry) EqualVT(that *PackfileEntry) bool
- func (x *PackfileEntry) GetBlockCount() uint64
- func (x *PackfileEntry) GetBloomFilter() []byte
- func (x *PackfileEntry) GetBloomFormatVersion() uint32
- func (x *PackfileEntry) GetCreatedAt() *timestamppb.Timestamp
- func (x *PackfileEntry) GetId() string
- func (x *PackfileEntry) GetSequence() uint64
- func (x *PackfileEntry) GetSizeBytes() uint64
- func (x *PackfileEntry) GetSupersededAt() *timestamppb.Timestamp
- func (x *PackfileEntry) GetSupersededBy() string
- func (x *PackfileEntry) MarshalJSON() ([]byte, error)
- func (x *PackfileEntry) MarshalProtoJSON(s *json.MarshalState)
- func (x *PackfileEntry) MarshalProtoText() string
- func (m *PackfileEntry) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *PackfileEntry) MarshalToVT(dAtA []byte) (int, error)
- func (m *PackfileEntry) MarshalVT() (dAtA []byte, err error)
- func (*PackfileEntry) ProtoMessage()
- func (x *PackfileEntry) Reset()
- func (m *PackfileEntry) SizeVT() (n int)
- func (x *PackfileEntry) String() string
- func (x *PackfileEntry) UnmarshalJSON(b []byte) error
- func (x *PackfileEntry) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *PackfileEntry) UnmarshalVT(dAtA []byte) error
- type PullResponse
- func (m *PullResponse) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *PullResponse) CloneVT() *PullResponse
- func (this *PullResponse) EqualMessageVT(thatMsg any) bool
- func (this *PullResponse) EqualVT(that *PullResponse) bool
- func (x *PullResponse) GetEntries() []*PackfileEntry
- func (x *PullResponse) GetLatestSequence() uint64
- func (x *PullResponse) GetReplacementEvents() []*PackReplacementEvent
- func (x *PullResponse) MarshalJSON() ([]byte, error)
- func (x *PullResponse) MarshalProtoJSON(s *json.MarshalState)
- func (x *PullResponse) MarshalProtoText() string
- func (m *PullResponse) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *PullResponse) MarshalToVT(dAtA []byte) (int, error)
- func (m *PullResponse) MarshalVT() (dAtA []byte, err error)
- func (*PullResponse) ProtoMessage()
- func (x *PullResponse) Reset()
- func (m *PullResponse) SizeVT() (n int)
- func (x *PullResponse) String() string
- func (x *PullResponse) UnmarshalJSON(b []byte) error
- func (x *PullResponse) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *PullResponse) UnmarshalVT(dAtA []byte) error
- type PushResponse
- func (m *PushResponse) CloneMessageVT() protobuf_go_lite.CloneMessage
- func (m *PushResponse) CloneVT() *PushResponse
- func (this *PushResponse) EqualMessageVT(thatMsg any) bool
- func (this *PushResponse) EqualVT(that *PushResponse) bool
- func (x *PushResponse) GetAlreadyExists() bool
- func (x *PushResponse) GetPackId() string
- func (x *PushResponse) GetSizeBytes() uint64
- func (x *PushResponse) MarshalJSON() ([]byte, error)
- func (x *PushResponse) MarshalProtoJSON(s *json.MarshalState)
- func (x *PushResponse) MarshalProtoText() string
- func (m *PushResponse) MarshalToSizedBufferVT(dAtA []byte) (int, error)
- func (m *PushResponse) MarshalToVT(dAtA []byte) (int, error)
- func (m *PushResponse) MarshalVT() (dAtA []byte, err error)
- func (*PushResponse) ProtoMessage()
- func (x *PushResponse) Reset()
- func (m *PushResponse) SizeVT() (n int)
- func (x *PushResponse) String() string
- func (x *PushResponse) UnmarshalJSON(b []byte) error
- func (x *PushResponse) UnmarshalProtoJSON(s *json.UnmarshalState)
- func (m *PushResponse) UnmarshalVT(dAtA []byte) error
Constants ¶
const BloomFormatVersionV1 uint32 = 1
BloomFormatVersionV1 identifies the current serialized Hydra BloomFilter bytes carried in PackfileEntry.bloom_filter.
Variables ¶
This section is empty.
Functions ¶
func DecodeBlockValue ¶
DecodeBlockValue decodes a pack entry: the key is the base58 block hash and the value is the encoded block.BlockObject of the block's bytes and refs. It verifies the bytes against the key.
Types ¶
type PackReplacementEvent ¶
type PackReplacementEvent struct {
// Sequence is the monotonic cursor anchor assigned to the replacement event.
Sequence uint64 `protobuf:"varint,1,opt,name=sequence,proto3" json:"sequence,omitempty"`
// ReplacedPackIds is the set of packs removed from the active manifest.
ReplacedPackIds []string `protobuf:"bytes,2,rep,name=replaced_pack_ids,json=replacedPackIds,proto3" json:"replacedPackIds,omitempty"`
// ReplacementPackIds is the set of packs added by the same replacement.
ReplacementPackIds []string `protobuf:"bytes,3,rep,name=replacement_pack_ids,json=replacementPackIds,proto3" json:"replacementPackIds,omitempty"`
// contains filtered or unexported fields
}
PackReplacementEvent describes one atomic replacement sequence.
func (*PackReplacementEvent) CloneMessageVT ¶
func (m *PackReplacementEvent) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*PackReplacementEvent) CloneVT ¶
func (m *PackReplacementEvent) CloneVT() *PackReplacementEvent
func (*PackReplacementEvent) EqualMessageVT ¶
func (this *PackReplacementEvent) EqualMessageVT(thatMsg any) bool
func (*PackReplacementEvent) EqualVT ¶
func (this *PackReplacementEvent) EqualVT(that *PackReplacementEvent) bool
func (*PackReplacementEvent) GetReplacedPackIds ¶
func (x *PackReplacementEvent) GetReplacedPackIds() []string
func (*PackReplacementEvent) GetReplacementPackIds ¶
func (x *PackReplacementEvent) GetReplacementPackIds() []string
func (*PackReplacementEvent) GetSequence ¶
func (x *PackReplacementEvent) GetSequence() uint64
func (*PackReplacementEvent) MarshalJSON ¶
func (x *PackReplacementEvent) MarshalJSON() ([]byte, error)
MarshalJSON marshals the PackReplacementEvent to JSON.
func (*PackReplacementEvent) MarshalProtoJSON ¶
func (x *PackReplacementEvent) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the PackReplacementEvent message to JSON.
func (*PackReplacementEvent) MarshalProtoText ¶
func (x *PackReplacementEvent) MarshalProtoText() string
func (*PackReplacementEvent) MarshalToSizedBufferVT ¶
func (m *PackReplacementEvent) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*PackReplacementEvent) MarshalToVT ¶
func (m *PackReplacementEvent) MarshalToVT(dAtA []byte) (int, error)
func (*PackReplacementEvent) MarshalVT ¶
func (m *PackReplacementEvent) MarshalVT() (dAtA []byte, err error)
func (*PackReplacementEvent) ProtoMessage ¶
func (*PackReplacementEvent) ProtoMessage()
func (*PackReplacementEvent) Reset ¶
func (x *PackReplacementEvent) Reset()
func (*PackReplacementEvent) SizeVT ¶
func (m *PackReplacementEvent) SizeVT() (n int)
func (*PackReplacementEvent) String ¶
func (x *PackReplacementEvent) String() string
func (*PackReplacementEvent) UnmarshalJSON ¶
func (x *PackReplacementEvent) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the PackReplacementEvent from JSON.
func (*PackReplacementEvent) UnmarshalProtoJSON ¶
func (x *PackReplacementEvent) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the PackReplacementEvent message from JSON.
func (*PackReplacementEvent) UnmarshalVT ¶
func (m *PackReplacementEvent) UnmarshalVT(dAtA []byte) error
type PackfileEntry ¶
type PackfileEntry struct {
// Id is the v1 packfile identifier.
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
// BloomFilter is the serialized bloom filter for the packfile.
BloomFilter []byte `protobuf:"bytes,2,opt,name=bloom_filter,json=bloomFilter,proto3" json:"bloomFilter,omitempty"`
// BlockCount is the number of blocks in the packfile.
BlockCount uint64 `protobuf:"varint,3,opt,name=block_count,json=blockCount,proto3" json:"blockCount,omitempty"`
// SizeBytes is the size of the packfile in bytes.
SizeBytes uint64 `protobuf:"varint,4,opt,name=size_bytes,json=sizeBytes,proto3" json:"sizeBytes,omitempty"`
// CreatedAt is the time the packfile was created.
CreatedAt *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=created_at,json=createdAt,proto3" json:"createdAt,omitempty"`
// BloomFormatVersion is the encoding version of the bloom_filter bytes.
// Version 1 means the current serialized Hydra BloomFilter bytes; future
// bloom layouts add new versions, not mutations of v1. Required on every
// entry; cloud rejects pushes whose advertised version is not in its
// accepted-versions allowlist.
BloomFormatVersion uint32 `protobuf:"varint,6,opt,name=bloom_format_version,json=bloomFormatVersion,proto3" json:"bloomFormatVersion,omitempty"`
// Sequence is the monotonic cursor anchor assigned by the cloud DO single
// writer at insert time. Pull cursors advance over sequence > since. Local
// entries not yet pushed carry 0.
Sequence uint64 `protobuf:"varint,7,opt,name=sequence,proto3" json:"sequence,omitempty"`
// SupersededBy is the replacement packfile ID; empty when the row is
// current.
SupersededBy string `protobuf:"bytes,8,opt,name=superseded_by,json=supersededBy,proto3" json:"supersededBy,omitempty"`
// SupersededAt is the time supersession was recorded; absent when the
// row is current.
SupersededAt *timestamppb.Timestamp `protobuf:"bytes,9,opt,name=superseded_at,json=supersededAt,proto3" json:"supersededAt,omitempty"`
// contains filtered or unexported fields
}
PackfileEntry describes a single packfile in the manifest.
func (*PackfileEntry) CloneMessageVT ¶
func (m *PackfileEntry) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*PackfileEntry) CloneVT ¶
func (m *PackfileEntry) CloneVT() *PackfileEntry
func (*PackfileEntry) EqualMessageVT ¶
func (this *PackfileEntry) EqualMessageVT(thatMsg any) bool
func (*PackfileEntry) EqualVT ¶
func (this *PackfileEntry) EqualVT(that *PackfileEntry) bool
func (*PackfileEntry) GetBlockCount ¶
func (x *PackfileEntry) GetBlockCount() uint64
func (*PackfileEntry) GetBloomFilter ¶
func (x *PackfileEntry) GetBloomFilter() []byte
func (*PackfileEntry) GetBloomFormatVersion ¶
func (x *PackfileEntry) GetBloomFormatVersion() uint32
func (*PackfileEntry) GetCreatedAt ¶
func (x *PackfileEntry) GetCreatedAt() *timestamppb.Timestamp
func (*PackfileEntry) GetId ¶
func (x *PackfileEntry) GetId() string
func (*PackfileEntry) GetSequence ¶
func (x *PackfileEntry) GetSequence() uint64
func (*PackfileEntry) GetSizeBytes ¶
func (x *PackfileEntry) GetSizeBytes() uint64
func (*PackfileEntry) GetSupersededAt ¶
func (x *PackfileEntry) GetSupersededAt() *timestamppb.Timestamp
func (*PackfileEntry) GetSupersededBy ¶
func (x *PackfileEntry) GetSupersededBy() string
func (*PackfileEntry) MarshalJSON ¶
func (x *PackfileEntry) MarshalJSON() ([]byte, error)
MarshalJSON marshals the PackfileEntry to JSON.
func (*PackfileEntry) MarshalProtoJSON ¶
func (x *PackfileEntry) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the PackfileEntry message to JSON.
func (*PackfileEntry) MarshalProtoText ¶
func (x *PackfileEntry) MarshalProtoText() string
func (*PackfileEntry) MarshalToSizedBufferVT ¶
func (m *PackfileEntry) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*PackfileEntry) MarshalToVT ¶
func (m *PackfileEntry) MarshalToVT(dAtA []byte) (int, error)
func (*PackfileEntry) MarshalVT ¶
func (m *PackfileEntry) MarshalVT() (dAtA []byte, err error)
func (*PackfileEntry) ProtoMessage ¶
func (*PackfileEntry) ProtoMessage()
func (*PackfileEntry) Reset ¶
func (x *PackfileEntry) Reset()
func (*PackfileEntry) SizeVT ¶
func (m *PackfileEntry) SizeVT() (n int)
func (*PackfileEntry) String ¶
func (x *PackfileEntry) String() string
func (*PackfileEntry) UnmarshalJSON ¶
func (x *PackfileEntry) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the PackfileEntry from JSON.
func (*PackfileEntry) UnmarshalProtoJSON ¶
func (x *PackfileEntry) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the PackfileEntry message from JSON.
func (*PackfileEntry) UnmarshalVT ¶
func (m *PackfileEntry) UnmarshalVT(dAtA []byte) error
type PullResponse ¶
type PullResponse struct {
// Entries is the list of packfile entries.
Entries []*PackfileEntry `protobuf:"bytes,1,rep,name=entries,proto3" json:"entries,omitempty"`
// ReplacementEvents is the list of atomic replacement events.
ReplacementEvents []*PackReplacementEvent `protobuf:"bytes,2,rep,name=replacement_events,json=replacementEvents,proto3" json:"replacementEvents,omitempty"`
// LatestSequence is the current monotonic sequence head for the block store,
// even when Entries and ReplacementEvents are empty for an up-to-date pull.
LatestSequence uint64 `protobuf:"varint,3,opt,name=latest_sequence,json=latestSequence,proto3" json:"latestSequence,omitempty"`
// contains filtered or unexported fields
}
PullResponse is the response to a pull request.
func (*PullResponse) CloneMessageVT ¶
func (m *PullResponse) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*PullResponse) CloneVT ¶
func (m *PullResponse) CloneVT() *PullResponse
func (*PullResponse) EqualMessageVT ¶
func (this *PullResponse) EqualMessageVT(thatMsg any) bool
func (*PullResponse) EqualVT ¶
func (this *PullResponse) EqualVT(that *PullResponse) bool
func (*PullResponse) GetEntries ¶
func (x *PullResponse) GetEntries() []*PackfileEntry
func (*PullResponse) GetLatestSequence ¶
func (x *PullResponse) GetLatestSequence() uint64
func (*PullResponse) GetReplacementEvents ¶
func (x *PullResponse) GetReplacementEvents() []*PackReplacementEvent
func (*PullResponse) MarshalJSON ¶
func (x *PullResponse) MarshalJSON() ([]byte, error)
MarshalJSON marshals the PullResponse to JSON.
func (*PullResponse) MarshalProtoJSON ¶
func (x *PullResponse) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the PullResponse message to JSON.
func (*PullResponse) MarshalProtoText ¶
func (x *PullResponse) MarshalProtoText() string
func (*PullResponse) MarshalToSizedBufferVT ¶
func (m *PullResponse) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*PullResponse) MarshalToVT ¶
func (m *PullResponse) MarshalToVT(dAtA []byte) (int, error)
func (*PullResponse) MarshalVT ¶
func (m *PullResponse) MarshalVT() (dAtA []byte, err error)
func (*PullResponse) ProtoMessage ¶
func (*PullResponse) ProtoMessage()
func (*PullResponse) Reset ¶
func (x *PullResponse) Reset()
func (*PullResponse) SizeVT ¶
func (m *PullResponse) SizeVT() (n int)
func (*PullResponse) String ¶
func (x *PullResponse) String() string
func (*PullResponse) UnmarshalJSON ¶
func (x *PullResponse) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the PullResponse from JSON.
func (*PullResponse) UnmarshalProtoJSON ¶
func (x *PullResponse) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the PullResponse message from JSON.
func (*PullResponse) UnmarshalVT ¶
func (m *PullResponse) UnmarshalVT(dAtA []byte) error
type PushResponse ¶
type PushResponse struct {
// PackId is the packfile identifier.
PackId string `protobuf:"bytes,1,opt,name=pack_id,json=packId,proto3" json:"packId,omitempty"`
// AlreadyExists indicates the packfile already existed.
AlreadyExists bool `protobuf:"varint,2,opt,name=already_exists,json=alreadyExists,proto3" json:"alreadyExists,omitempty"`
// SizeBytes is the size of the packfile in bytes.
SizeBytes uint64 `protobuf:"varint,3,opt,name=size_bytes,json=sizeBytes,proto3" json:"sizeBytes,omitempty"`
// contains filtered or unexported fields
}
PushResponse is the response to a push request.
func (*PushResponse) CloneMessageVT ¶
func (m *PushResponse) CloneMessageVT() protobuf_go_lite.CloneMessage
func (*PushResponse) CloneVT ¶
func (m *PushResponse) CloneVT() *PushResponse
func (*PushResponse) EqualMessageVT ¶
func (this *PushResponse) EqualMessageVT(thatMsg any) bool
func (*PushResponse) EqualVT ¶
func (this *PushResponse) EqualVT(that *PushResponse) bool
func (*PushResponse) GetAlreadyExists ¶
func (x *PushResponse) GetAlreadyExists() bool
func (*PushResponse) GetPackId ¶
func (x *PushResponse) GetPackId() string
func (*PushResponse) GetSizeBytes ¶
func (x *PushResponse) GetSizeBytes() uint64
func (*PushResponse) MarshalJSON ¶
func (x *PushResponse) MarshalJSON() ([]byte, error)
MarshalJSON marshals the PushResponse to JSON.
func (*PushResponse) MarshalProtoJSON ¶
func (x *PushResponse) MarshalProtoJSON(s *json.MarshalState)
MarshalProtoJSON marshals the PushResponse message to JSON.
func (*PushResponse) MarshalProtoText ¶
func (x *PushResponse) MarshalProtoText() string
func (*PushResponse) MarshalToSizedBufferVT ¶
func (m *PushResponse) MarshalToSizedBufferVT(dAtA []byte) (int, error)
func (*PushResponse) MarshalToVT ¶
func (m *PushResponse) MarshalToVT(dAtA []byte) (int, error)
func (*PushResponse) MarshalVT ¶
func (m *PushResponse) MarshalVT() (dAtA []byte, err error)
func (*PushResponse) ProtoMessage ¶
func (*PushResponse) ProtoMessage()
func (*PushResponse) Reset ¶
func (x *PushResponse) Reset()
func (*PushResponse) SizeVT ¶
func (m *PushResponse) SizeVT() (n int)
func (*PushResponse) String ¶
func (x *PushResponse) String() string
func (*PushResponse) UnmarshalJSON ¶
func (x *PushResponse) UnmarshalJSON(b []byte) error
UnmarshalJSON unmarshals the PushResponse from JSON.
func (*PushResponse) UnmarshalProtoJSON ¶
func (x *PushResponse) UnmarshalProtoJSON(s *json.UnmarshalState)
UnmarshalProtoJSON unmarshals the PushResponse message from JSON.
func (*PushResponse) UnmarshalVT ¶
func (m *PushResponse) UnmarshalVT(dAtA []byte) error