Skip to content

Cypher queries don't serve from reasoning indexes #2288

Closed

Description

@bplatz

The Cypher entry point (execute_cypher_ir, fluree-db-api/src/view/query.rs) never consults reasoning indexes. A Cypher query under ledger-wide reasoning defaults always reasons at query time, even when a matching reasoning index is current. JSON-LD and SPARQL serve from the index.

This only matters when reasoning reaches Cypher through ledger defaults; Cypher has no per-query reasoning option.

Proposed: route Cypher through the same index selection as the JSON-LD/SPARQL runners (reasoning_index_for, including the restricted-caller rules and freshness modes). Add parity tests (index-served vs query-time) and a routing check showing the index actually served.

Activity

  1. added
    enhancement
    P2
    area:query
    on Nov 9, 2026
  2. bplatz commented on Nov 20, 2026

    @bplatz
    ContributorAuthor

    Fixed on next by #2292 (merged 2026-11-13, e78a07b). execute_cypher_ir now goes through serve_from_reasoning_index, the same selection JSON-LD and SPARQL use, and it_reasoning_indexes::cypher_reads_a_matching_reasoning_generation covers it. The PR's Fixes keyword didn't close this because its base was next.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2area:queryenhancement

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions