Skip to content

Commit

Permalink
remove table assertion on prefix_hint_len
Browse files Browse the repository at this point in the history
Signed-off-by: Richard Chien <[email protected]>
  • Loading branch information
stdrc committed Oct 25, 2024
1 parent bd6dfb6 commit ca48be1
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/stream/src/common/table/state_table.rs
Original file line number Diff line number Diff line change
Expand Up @@ -643,16 +643,16 @@ where
pub async fn get_encoded_row(&self, pk: impl Row) -> StreamExecutorResult<Option<Bytes>> {
assert!(pk.len() <= self.pk_indices.len());

if self.prefix_hint_len != 0 {
debug_assert_eq!(self.prefix_hint_len, pk.len());
}

let serialized_pk =
serialize_pk_with_vnode(&pk, &self.pk_serde, self.compute_vnode_by_pk(&pk));

let prefix_hint = if self.prefix_hint_len != 0 && self.prefix_hint_len == pk.len() {
Some(serialized_pk.slice(VirtualNode::SIZE..))
} else {
#[cfg(debug_assertions)]
if self.prefix_hint_len != 0 {
warn!("prefix_hint_len is not equal to pk.len(), may not be able to utilize bloom filter");
}
None
};

Expand Down

0 comments on commit ca48be1

Please sign in to comment.