Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetPartitionHashFromBytes ¶
GetPartitionHashFromBytes reads the partition hash directly from bytes
Types ¶
type Entry ¶
type Entry struct { PartitionHash uint64 UpdatedAtNs uint64 TtlSecond uint32 OpAndDataType OpAndDataType Value []byte }
Entry is the on-disk value bytes in this key-value system.
func MergeEntry ¶
MergeEntry merges two []byte into one Entry object.
func NewMergeEntry ¶
func NewMergeEntry(m *pb.MergeRequest, updatedAtNs uint64) *Entry
NewMergeEntry creates an Entry from pb.MergeRequest
func NewPutEntry ¶
func NewPutEntry(put *pb.PutRequest, updatedAtNs uint64) *Entry
NewPutEntry creates an Entry from pb.PutRequest
func (*Entry) IsExpired ¶
IsExpired checks whether the entry updated_at time plus ttl time is less than current time. If ttlSecond is 0, the entry will not expire.
Click to show internal directories.
Click to hide internal directories.