Skip to main content

Module plan_cache

Module plan_cache 

Source
Expand description

Query Plan Cache Module

Provides Prepared Statement style query plan caching with support for parameterized queries.

§Design objectives

  1. Cache query plan parsing, validation and planning results
  2. Support for parameterized queries (Prepared Statement)
  3. Limit memory usage to prevent unlimited growth
  4. Thread-safe, supporting highly concurrent access

§Scenarios of use

  • Repeated execution of the same query template
  • Batch insert/update operations
  • Applications use Prepared Statements

Re-exports§

pub use entry::CachedPlan;
pub use key::ParamPosition;
pub use key::PlanCacheContext;
pub use key::PlanCacheKey;
pub use key::PlanCachePutContext;
pub use params::ParameterizedQueryHandler;

Modules§

entry
key
params

Structs§

QueryPlanCache