MCPcopy Create free account
hub / github.com/erans/pgsqlite / execute_memory_action

Method execute_memory_action

src/cache/memory_aware_manager.rs:262–277  ·  view source on GitHub ↗
(&self, action: MemoryAction, current_memory_mb: f64)

Source from the content-addressed store, hash-verified

260 }
261
262 fn execute_memory_action(&self, action: MemoryAction, current_memory_mb: f64) {
263 match action {
264 MemoryAction::None => return,
265 MemoryAction::AdaptiveTtl => {
266 if self.config.enable_adaptive_ttl {
267 self.adjust_adaptive_ttl();
268 }
269 }
270 MemoryAction::PressureEviction => {
271 self.handle_pressure_eviction(current_memory_mb);
272 }
273 MemoryAction::CriticalEviction => {
274 self.handle_critical_eviction(current_memory_mb);
275 }
276 }
277 }
278
279 fn adjust_adaptive_ttl(&self) {
280 let mut stats = self.stats.write();

Callers 1

check_memory_pressureMethod · 0.80

Calls 3

adjust_adaptive_ttlMethod · 0.80

Tested by

no test coverage detected