Questions tagged [servicestack.redis]

ServiceStack.Redis is a simple, high-performance and feature-rich C# Client for Redis with native support and high-level abstractions for serializing POCOs and Complex Types.

225 questions
1
vote
1 answer

ServiceStack.Redis WaitBeforeForcingMasterFailover

Context: I'm trying to understand the motivation behind existence of WaitBeforeForcingMasterFailover property (and the code associated with it) inside of ServiceStack.Redis.RedisSentinel. If I interpreted the code right - the meaning behind this…
Dmitry Kotov
  • 375
  • 3
  • 9
1
vote
1 answer

ServiceStack.Redis relationship between RedisSentinelWorker and RedisPubSubServer

Description: I'm curious what is the relationship between RedisSentinelWorker and RedisPubSubServer. From what I've observed the library holds at most 1 active sentinel connection even if there are more sentinel hosts available. That sentinel…
Dmitry Kotov
  • 375
  • 3
  • 9
1
vote
1 answer

ServiceStack.Redis authentication Redis Sentinel + Redis

The problem: It is not obvious how to correctly authenticate with: sentinels redis instances themselves when using the ServiceStack.Redis solution. According to the docs a proper way to provide a password for redis/sentinel is to set it via URLs…
Dmitry Kotov
  • 375
  • 3
  • 9
1
vote
1 answer

ServiceStack.Redis RedisTypedClient TTL

I'm using ServiceStack.Redis v5.10.4 and trying to set the TTL using the following code: Note: mClientsManager = IRedisClientsManager ttl = TimeSpan? await using var client = await mClientsManager.GetClientAsync(token).ConfigureAwait(false); var…
1
vote
1 answer

ServiceStack Messaging API: Can it make a broadcast?

As I have previously mentioned, I am using ServiceStack Messaging API (IMessageQueueClient.Publish) as well as the more low-level IRedisClient.PublishMessage. I use the Messaging API when I need a specific message/request to be processed by only one…
Ted
  • 19,727
  • 35
  • 96
  • 154
1
vote
1 answer

ServiceStack Redis (AWS ElastiCache implementation) using .Net core causing error No master found in: redis-cluster-xxxxxxxx:637

I have implemented the following version of ServiceStack .net Core Redis library: ServiceStack.Redis.Core 5.9.2 I am using the library to access a Redis cache I have created to persist values for my AWS Serverless Application using .NET Core 3.1. I…
JamesMatson
  • 2,522
  • 2
  • 37
  • 86
1
vote
2 answers

ServiceStack Redis Get an struct always return default

I'm using ServiceStack Redis. I have an struct and I want to storage it in Redis. But when I try to get it, it always return the default value. But if I change the struct for class it works ok. Any ideas? public struct PersonStruct { public…
satellite satellite
  • 893
  • 2
  • 10
  • 27
1
vote
1 answer

How to represent this structure in Redis

Let's say I'm building a cards game (I'm using an analogy as I can't disclose the original project details). Consider the following structure: Dealer1 91 // Card 9 of spades (Second digit represents card type, check the legend below) …
Nour
  • 5,252
  • 3
  • 41
  • 66
1
vote
1 answer

Redis keyspace notifications with StackExchange.Redis For Delete operation

I've been searching to find out how to perform a subscription to key space notifications on Redis using ServiceStack.Redis library for removal of Key. Checking available tests on the git-hub and other websites I've found IRedisSubscription can be…
Siraj ur Rahman
  • 213
  • 3
  • 13
1
vote
0 answers

How to unpack msgpack record

I am using Redis and C#. I saved my user data in Redis with msgPack format. How can I deserialize msgPack data? I guess, some records are different from the current user model in Redis. I usually get the serialize exceptions when I try to…
1
vote
1 answer

ServiceStack RedisPubSubServer will enter in OnStop, OnInit, and OnStart frequently

Here is my situation: I instantiate a RedisPubSubServer and configure it with OnInit, OnStart, and OnStop callbacks. I keep this reference as long as the application lives and, in the end, I dispose it. Somehow, during the application life cycle,…
ioan
  • 722
  • 4
  • 12
1
vote
2 answers

How to read values from the Redis Stream using ServiceStack.Redis Library?

How to read values from the Redis Stream using ServiceStack.Redis Library? For example, you can read all values from Redis List using RedisClient.GetAllItemsFromList method.
user306080
  • 1,409
  • 3
  • 16
  • 37
1
vote
1 answer

ServiceStack's RedisTypedClient - Can you use strings to define the type?

I'm trying to figure out if there is any way to create a RedisClient that has the functionality of a RedisTypedClient but able to define the URN key with a simple string instead of passing in a type. For example, at the moment we're creating the…
1
vote
1 answer

Removing element from SortedSet in C#

I'm trying to remove an element from a Redis Sorted list without success public bool Delete(int id) { try { var redisManager = new RedisManagerPool(Global.RedisConnector); using (var…
user_1856538_
  • 149
  • 11
1
vote
1 answer

Unknown command error when using multithread to set redis

I am using the ServiceStack.Redis C# client to talk to Redis. With few request everything is ok, but when I get LoadRunner to request it or use multi-threading to make requests, I get some errors that say I am using the wrong command. I check the…
Mike Li
  • 3,336
  • 2
  • 22
  • 27