risingwave_common

Module hash

source

Modules§

Structs§

  • A wrapper for u64 hash result. Generic over the hasher.
  • The implementation of the hash key.
  • Null bitmap on heap. We use this for the edge case where group key sizes are larger than 64. This is because group key null bits cannot fit into a u64 on the stack if they exceed 64 bits. NOTE(kwannoel): This is not really optimized as it is an edge case.
  • Key storage that uses a in-heap buffer and key, backed by a boxed slice.
  • A special hasher designed for HashKey, which stores a hash key from HashKey::hash() and outputs it on finish().
  • The buffer for building a hash key on a fixed-size byte array on the stack.
  • Null Bitmap on stack. This is specialized for the common case where group keys (<= 64).
  • Key storage that uses a on-stack buffer and key, backed by a byte array with length N.
  • VirtualNode (a.k.a. Vnode) is a minimal partition that a set of keys belong to. It is used for consistent hashing.
  • Generic mapping from virtual nodes to items.

Enums§

  • The different cases of maybe_vnode_count field in the protobuf message.

Statics§

  • This is determined by the stack based data structure we use, StackNullBitmap, which can store 64 bits at most.

Traits§

  • Associated type for KeyStorage used to build the hash key.
  • Trait for different kinds of hash keys.
  • The deserialization counterpart of HashKeySer.
  • A trait to help to dynamically dispatch HashKey template.
  • Extension of scalars to be serialized into hash keys.
  • A trait for checking whether a table/fragment is a singleton.
  • The storage where the hash key resides in memory.
  • We use a trait for NullBitmap so we can parameterize structs on it. This is because NullBitmap is used often, and we want it to occupy the minimal stack space.
  • An extension trait for Bitmap to support virtual node operations.
  • A trait for accessing the vnode count field with backward compatibility.
  • Trait for items that can be used as keys in VnodeMapping.

Functions§

  • Calculate what kind of hash key should be used given the key data types.

Type Aliases§