Skip to main content

reifydb_engine/
lib.rs

1// SPDX-License-Identifier: Apache-2.0
2// Copyright (c) 2026 ReifyDB
3
4//! Every public entry point that mutates catalog or storage state runs inside a transaction obtained from
5//! `reifydb-transaction`. Reading or writing a backend directly defeats MVCC, policy enforcement and CDC
6//! capture, all of which assume the engine is the single mediator of those concerns.
7
8#![cfg_attr(not(debug_assertions), deny(clippy::disallowed_methods))]
9#![cfg_attr(debug_assertions, warn(clippy::disallowed_methods))]
10#![cfg_attr(not(debug_assertions), deny(warnings))]
11#![allow(clippy::tabs_in_doc_comments)]
12
13use reifydb_core::interface::version::{ComponentType, HasVersion, SystemVersion};
14use reifydb_value::Result;
15
16pub mod bulk_insert;
17pub mod engine;
18pub mod environment;
19pub mod error;
20pub mod partition;
21pub mod policy;
22#[cfg(not(reifydb_single_threaded))]
23pub mod remote;
24pub mod run_tests;
25pub mod session;
26pub mod subscription;
27pub mod transaction;
28pub mod vm;
29pub mod watermark;
30
31pub struct EngineVersion;
32
33impl HasVersion for EngineVersion {
34	fn version(&self) -> SystemVersion {
35		SystemVersion {
36			name: env!("CARGO_PKG_NAME")
37				.strip_prefix("reifydb-")
38				.unwrap_or(env!("CARGO_PKG_NAME"))
39				.to_string(),
40			version: env!("CARGO_PKG_VERSION").to_string(),
41			description: "Query execution and processing engine module".to_string(),
42			r#type: ComponentType::Module,
43		}
44	}
45}