Hello, there are two possibilities.
1) Use hashes to group, let's say, 256 counters per hash. This way you
can reduce the memory usage by 10 times more or less.
2) Use 2.2 GETRANGE / SETRANGE together with MULTI/EXEC if you found a
way to avoid too much contention. So in every key you have N counters
as a single array of bytes. But this requires you to be able to index
N counters with just one key and an offset. Too little details to
understand if you can do this or not.
Cheers,
Salvatore
>
> --
> You received this message because you are subscribed to the Google Groups "Redis DB" group.
> To post to this group, send email to redi...@googlegroups.com.
> To unsubscribe from this group, send email to redis-db+u...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/redis-db?hl=en.
>
>
--
Salvatore 'antirez' Sanfilippo
open source developer - VMware
http://invece.org
"We are what we repeatedly do. Excellence, therefore, is not an act,
but a habit." -- Aristotele