Hello,
I created a sorted set in Redis :
Redis.As<Dummy>().SortedSets[id];
Added some items and I want to retrieve multiple items from the OrderedSet (order is important) …
I tried PopItemsFromSet (maybe it’s Set specific and does not work for SortedSet?)
Redis.PopItemsFromSet(@event.Id, 10)
but it gives me
ServiceStack.Redis.RedisResponseException: wrong number of arguments for 'spop' command\r\n at
ServiceStack.Redis.RedisNativeClient.ReadMultiData()\r\n at ServiceStack.Redis.RedisNativeClient.SendReceive[T]
(Byte[][] cmdWithBinaryArgs, Func`1 fn, Action`1 completePipelineFn, Boolean sendWithoutRead)\r\n at
ServiceStack.Redis.RedisNativeClient.SendExpectMultiData(Byte[][] cmdWithBinaryArgs)\r\n at
ServiceStack.Redis.RedisNativeClient.SPop(String setId, Int32 count)\r\n at
ServiceStack.Redis.RedisClient.PopItemsFromSet(String setId, Int32 count)\r\n
Redis.PopItemWithHighestScoreFromSortedSet(@event.Id)
works but only retrieve one item per request.
Would you have an idea on how to make this work? Should I use Redis queues instead?
Thanks,
Olivier