Skip to content

desktop/src-tauri/crates/core/src/query_acceleration.rs

Comment 1, line 1

desktop/src-tauri/crates/core/src/query_acceleration.rs:1

//! Optional schema-11 query caches, maintained within transactions.

Comment 2, line 46

desktop/src-tauri/crates/core/src/query_acceleration.rs:46

// Invalidation removes cached identities too: retention and older writers

Comment 3, line 47

desktop/src-tauri/crates/core/src/query_acceleration.rs:47

// must not leave session identifiers in an unusable cache.

Comment 4, line 84

desktop/src-tauri/crates/core/src/query_acceleration.rs:84

// Include every table and retain bounded SQLite analysis so

Comment 5, line 85

desktop/src-tauri/crates/core/src/query_acceleration.rs:85

// combined filters can choose the more selective expression index.

Comment 6, line 109

desktop/src-tauri/crates/core/src/query_acceleration.rs:109

// Optional caching must not reject valid events from separate groups

Comment 7, line 110

desktop/src-tauri/crates/core/src/query_acceleration.rs:110

// when only the combined metric exceeds i64.

Comment 8, line 197

desktop/src-tauri/crates/core/src/query_acceleration.rs:197

// Outside this window, long retained histories use the original query.

Comment 9, line 248

desktop/src-tauri/crates/core/src/query_acceleration.rs:248

// Today, days before the first observation and calendar gaps need no

Comment 10, line 249

desktop/src-tauri/crates/core/src/query_acceleration.rs:249

// stored zero rows. Check absent partitions against daily_usage and usage_events

Comment 11, line 250

desktop/src-tauri/crates/core/src/query_acceleration.rs:250

// so an older event-only writer cannot make a stale cache appear valid.