Skip to main content

Module query

Module query 

Source
Expand description

The complete query processing pipeline.

Your query goes through several stages before results come back:

  1. Translator - Parses GQL/Cypher/SPARQL into a logical plan
  2. Binder - Validates that variables and properties exist
  3. Optimizer - Pushes filters down, reorders joins for speed
  4. Planner - Converts the logical plan to physical operators
  5. Executor - Actually runs the operators and streams results

Most users don’t interact with these directly - just call Session::execute(). But if you’re building custom query processing, QueryProcessor is the unified interface.

Re-exports§

pub use cache::CacheKey;
pub use cache::CacheStats;
pub use cache::CachingQueryProcessor;
pub use cache::QueryCache;
pub use executor::Executor;
pub use optimizer::CardinalityEstimator;
pub use optimizer::Optimizer;
pub use plan::LogicalExpression;
pub use plan::LogicalOperator;
pub use plan::LogicalPlan;
pub use planner::PhysicalPlan;
pub use planner::Planner;
pub use planner::convert_aggregate_function;
pub use planner::convert_binary_op;
pub use planner::convert_filter_expression;
pub use planner::convert_unary_op;
pub use processor::QueryLanguage;
pub use processor::QueryParams;
pub use processor::QueryProcessor;
pub use gql_translator::translate as translate_gql;

Modules§

binder
Semantic validation - catching errors before execution.
cache
Query cache for parsed and planned queries.
executor
Query executor.
gql_translator
GQL to LogicalPlan translator.
optimizer
Makes your queries faster without changing their meaning.
plan
Logical query plan representation.
planner
Converts logical plans into physical execution trees.
processor
Query processor that orchestrates the query pipeline.