Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
perf(redis): Don't re-encode string when computing hash (#3838)
When caching values in redis, we compare the hash of the value we're about to write against the value already in the cache to avoid writing unchanged values again. The hash function we're using is expensive as it encodes the string to bytes before hashing it. Per the documentation of the putString function, it is only useful for cross-language compatibility and we should instead use putUnencodedChars for much better performance when this is not needed.
- Loading branch information