Skip to content

[Bug] RedisMemory:GetListAsync errors in Azure Redis Enterprise #1062

@AnnoDeJong

Description

@AnnoDeJong

Context / Scenario

Whenever executing GetListAsync, (for me this happened when I wanted to delete a specific memory as it first need to get a list of memories from Redis to identify the one to delete) I get the following error:

StackExchange.Redis.RedisServerException: ERR unknown command 'FT.CONFIG'

The reason for this error is that during the GetListAsync operation the following occurs:
var configurationCheckTask = this._search.ConfigGetAsync("MAXSEARCHRESULTS"); // need to query Max Search Results since Redis doesn't support unbounded queries.

However Azure Redis Enterprise does not support FT.CONFIG commands: see the note at the bottom of this MS Doc: https://learn.microsoft.com/en-us/azure/redis/redis-modules

What happened?

Is there a different way to find the MAXSEARCHRESULTS from redis, or have a default value of lets say 10000 provided if the FT.CONFIG GET command fails?

Importance

I cannot use Kernel Memory

Platform, Language, Versions

dotnet 8

Relevant log output

Microsoft.KernelMemory.Pipeline.Queue.DevTools.SimpleQueues: Warning: Message '20250508.120800.6199686.a7988a958d604e4fb370e56163d16359' processing failed with exception, putting message back in the queue. Message content: {"index":"f1d5904b-1920-4e63-b4d8-d44d43cf971f","document_id":"8aa6ea68-b124-4404-9061-0ab38bdb6815","execution_id":"c2a27fe0c13a4f2f89223307789ca581","steps":["private_delete_document"]}.

StackExchange.Redis.RedisServerException: ERR unknown command 'FT.CONFIG'
   at NRedisStack.Auxiliary.ExecuteAsync(IDatabaseAsync db, SerializedCommand command)
   at NRedisStack.SearchCommandsAsync.ConfigGetAsync(String option)
   at Microsoft.KernelMemory.MemoryDb.Redis.RedisMemory.GetListAsync(String index, ICollection`1 filters, Int32 limit, Boolean withEmbeddings, CancellationToken cancellationToken)+MoveNext()
   at Microsoft.KernelMemory.MemoryDb.Redis.RedisMemory.GetListAsync(String index, ICollection`1 filters, Int32 limit, Boolean withEmbeddings, CancellationToken cancellationToken)+System.Threading.Tasks.Sources.IValueTaskSource<System.Boolean>.GetResult()
   at Microsoft.KernelMemory.Handlers.DeleteDocumentHandler.InvokeAsync(DataPipeline pipeline, CancellationToken cancellationToken)
   at Microsoft.KernelMemory.Handlers.DeleteDocumentHandler.InvokeAsync(DataPipeline pipeline, CancellationToken cancellationToken)
   at Microsoft.KernelMemory.Pipeline.DistributedPipelineOrchestrator.RunPipelineStepAsync(DataPipeline pipeline, IPipelineStepHandler handler, CancellationToken cancellationToken)
   at Microsoft.KernelMemory.Pipeline.DistributedPipelineOrchestrator.<>c__DisplayClass5_0.<<AddHandlerAsync>b__0>d.MoveNext()
--- End of stack trace from previous location ---

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingtriage

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions