Skip to main content

perl_workspace/workspace/
mod.rs

1//! Workspace-level orchestration primitives for indexing and refactoring.
2//!
3//! This module groups the concrete building blocks used by the
4//! [`WorkspaceIndex`](crate::workspace::WorkspaceIndex):
5//!
6//! - cache configuration and bounded cache implementations
7//! - in-memory document storage for open editor buffers
8//! - production coordination helpers and readiness orchestration
9//! - state-machine and SLO/runtime monitoring integration
10//! - workspace-wide symbol lookup and rename execution
11//!
12//! Use this module when wiring higher-level services that need to coordinate
13//! indexing lifecycle, telemetry, and cross-file edits.
14
15/// Cache policies and bounded cache implementations used by workspace indexing.
16pub mod cache;
17/// Open-document storage used to overlay in-editor content over on-disk files.
18pub mod document_store;
19#[cfg(feature = "memory-profiling")]
20/// Optional memory-profiling utilities for workspace index internals.
21pub mod memory;
22/// Index lifecycle instrumentation and production readiness monitoring helpers.
23pub mod monitoring;
24/// High-level coordinator that integrates state transitions, SLOs, and limits.
25pub mod production_coordinator;
26/// Service-level objective types and trackers used by workspace operations.
27pub mod slo;
28/// State machine defining valid index lifecycle transitions and degraded states.
29pub mod state_machine;
30/// Core workspace-wide symbol index and lookup/query API.
31pub mod workspace_index;
32/// Cross-file rename planning and edit-generation helpers.
33pub mod workspace_rename;
34
35// Re-export commonly used types at the workspace level for ergonomic access.
36// Note: `monitoring` types are intentionally NOT re-exported here — several names
37// (e.g. `DegradationReason`, `IndexStateKind`, `ResourceKind`) overlap with those
38// from `state_machine`, which would cause ambiguous glob import errors.  Callers
39// that need monitoring types use `workspace::monitoring::*` or the top-level
40// `crate::monitoring::*` path directly.
41pub use cache::{
42    AstCacheConfig, BoundedLruCache, CacheConfig, CombinedWorkspaceCacheConfig, EstimateSize,
43    SymbolCacheConfig, WorkspaceCacheConfig,
44};
45pub use production_coordinator::{
46    CoordinatorStatistics, ProductionCoordinatorConfig, ProductionIndexCoordinator,
47    WorkspaceCacheManager,
48};
49pub use slo::{OperationResult, OperationType, SloConfig, SloStatistics, SloTracker};
50pub use state_machine::{
51    BuildPhase, DegradationReason, IndexState, IndexStateKind, IndexStateMachine,
52    InvalidationReason, ResourceKind, TransitionResult,
53};
54pub use workspace_index::{
55    CrossFileReferenceQueryResult, IndexResourceLimits, Location, SymbolIdentity, WorkspaceIndex,
56};