DocsNavigatorMCP-SUSE-hackathon / src /utils /force-clear-locks.js
mackenzietechdocs's picture
Frozen Hack Week 25 snapshot from GitHub commit f2c77ec, with Space packaging
c3aa9b1 verified
Raw History Blame Contribute Delete
477 Bytes
#!/usr/bin/env node
import { CacheService } from '../services/cache-service.js';
import dotenv from 'dotenv';
dotenv.config();
const cacheService = new CacheService(process.env.PAGE_CACHE_PATH || './data/page-cache.db');
await cacheService.initialize();
console.log('🗑️ Deleting ALL locks (including active ones)...\n');
const result = cacheService.db.prepare('DELETE FROM locks').run();
console.log(`✓ Deleted ${result.changes} lock(s)`);
cacheService.close();