cache keys/values are sorted (with configurable sorting)