Skip to content

PR #109374 - catalog: change hash-sharded indexes to use md5 #17852

Open
@cockroach-teamcity

Description

@cockroach-teamcity

Related PR: cockroachdb/cockroach#109374
Commit: cockroachdb/cockroach@4b2da22
Fixes: CRDB-21107


Release note (sql change): The hash function used by hash-sharded
indexes was changed to
mod(fnv32(md5(crdb_internal.datums_to_bytes(columns))), bucket_count).
(Previously, it did not use md5.) This change was made to enhance the
uniformity of bucket distribution in cases when the bucket count is a
power of 2, and the columns being sharded have numerical properties that
make the fnv32 function return values with a non-uniformly distributed
modulus.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions