Skip to content

Implement FT.CURSOR command (FT.SEARCH, FT.AGGREGATE) #5961

@vyavdoshenko

Description

@vyavdoshenko

Currently, Dragonfly does not support the FT.CURSOR command for incremental retrieval of large result sets.
This feature is essential for handling large aggregation or search results efficiently without loading the entire dataset into memory at once.

Expected behavior:
Implement the following subcommands:

  • FT.CURSOR READ <cursor_id> [COUNT ]
    Returns the next batch of results for an existing cursor.
  • FT.CURSOR DEL <cursor_id>
    Explicitly deletes a cursor and frees server-side resources.

Support for creating cursors should be added to:

  • FT.AGGREGATE with WITHCURSOR [COUNT ]
  • FT.SEARCH with WITHCURSOR [COUNT ].

Why it matters:

  • Enables incremental result fetching for large queries.
  • Improves client performance and memory usage.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions