Describe the bug
I've reported a pub/sub related issue in #787. I've tested the fixed version and while the error message itself is fixed, publishing large messages (larger than 131 061 bytes) still don't work:
- Garnet now properly accepts publishes larger than the size specified before. However subscribers won't get these messages. Tested with a minimal StackExchange.Redis subscriber and redis-cli, both does not work properly.
- Furthermore after sending a large message, previous subscribers won't get any further messages regardless their size (even if they are 4 bytes, well below the supported range) and source (StackExhcange.Redis publisher and redis-cli raw command) until they reconnect to the server.
Steps to reproduce the bug
- Use the following configuration:
{
"MemorySize": "4g",
"PageSize": "128m",
"PubSubPageSize": "128m",
"IndexSize": "128m",
"DisableObjects": true,
"CompactionType" : "Lookup",
"LogLevel": "Information",
}
- Subscribe using StackExchange.Redis or redis-cli:
var redis = ConnectionMultiplexer.Connect(ConfigurationOptions.Parse($"localhost:6379"));
redis.GetSubscriber().Subscribe(RedisChannel.Literal("test")).OnMessage((msg) =>
{
byte[]? data = msg.Message;
Console.WriteLine($"Received {data?.Length ?? 0} bytes");
});
- Use the following code to publish to redis:
var db = connectionMultiplexer.GetDatabase();
db.Publish(RedisChannel.Literal("test"), RandomNumberGenerator.GetBytes(1024)); // works
db.Publish(RedisChannel.Literal("test"), RandomNumberGenerator.GetBytes(127 * 1024)); // still works
db.Publish(RedisChannel.Literal("test"), RandomNumberGenerator.GetBytes(1024 * 1024)); // does not work
db.Publish(RedisChannel.Literal("test"), RandomNumberGenerator.GetBytes(1024)); // does not work, even if it is not larger than 131 061 bytes, because it was sent after a large message
Expected behavior
All pub/sub messages arrive which fits into PubSubPageSize and received by the subscriber.
Screenshots
No response
Release version
main branch (652b49f)
IDE
Visual Studio 2022
OS version
Windows 11 Pro
Additional context
No response
Describe the bug
I've reported a pub/sub related issue in #787. I've tested the fixed version and while the error message itself is fixed, publishing large messages (larger than 131 061 bytes) still don't work:
Steps to reproduce the bug
{ "MemorySize": "4g", "PageSize": "128m", "PubSubPageSize": "128m", "IndexSize": "128m", "DisableObjects": true, "CompactionType" : "Lookup", "LogLevel": "Information", }Expected behavior
All pub/sub messages arrive which fits into PubSubPageSize and received by the subscriber.
Screenshots
No response
Release version
main branch (652b49f)
IDE
Visual Studio 2022
OS version
Windows 11 Pro
Additional context
No response