1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-02-28 00:17:12 +01:00

docs: add note about Unleash using MurmurHash for stickiness.

This commit is contained in:
Thomas Heartman 2021-11-24 13:41:25 +01:00
parent d58ed5f84b
commit 42b1f44d84

View File

@ -7,7 +7,7 @@ _Stickiness_ is how Unleash guarantees that the same user gets the same features
## Calculation
By default, Unleash calculates stickiness based on the user id and the group id. If the user id is unavailable, it falls back to using the session id instead. It hashes these values to a number between 0 and 100. This number is what determines whether a user will see a specific feature or variant. Because the process is deterministic, the same user will always get the same number.
By default, Unleash calculates stickiness based on the user id and the group id. If the user id is unavailable, it falls back to using the session id instead. It hashes these values to a number between 0 and 100 using the [MurmurHash hash function](https://en.wikipedia.org/wiki/MurmurHash). This number is what determines whether a user will see a specific feature or variant. Because the process is deterministic, the same user will always get the same number.
If both the user id and the session id is unavailable, the calculation returns a random value and stickiness is not guaranteed.