Compaction & Memtable Flush Management Page
Create an Angular admin page for managing LSM-Tree compaction and memtable flushing.
Backend Endpoints (already exist)
POST /admin/flush — Force memtable flush
POST /admin/compact — Force compaction
GET /stats — Engine stats (includes compaction metrics)
UI Requirements
Compaction Panel
- Current Status: Display if compaction is running (from stats)
- Last Compaction Stats: files merged, bytes read/written, duration
- Trigger Button: Manual compaction trigger with confirmation
- Strategy Display: Show current compaction strategy (SizeTiered/Leveled)
- Threshold Config: Display current thresholds
Memtable Panel
- Current Usage: Gauge showing memtable bytes / max
- Record Count: Number of records in active memtable
- Flush Button: Manual flush trigger with confirmation
- Auto-flush Indicator: Show if memtable is near capacity
Statistics Integration
- SSTable count per level
- WAL size
- Disk usage
- Operation rates (gets/sets per second)
Component Structure
app/
pages/
compaction/
compaction.component.ts
compaction.component.html
compaction.component.scss
Data Flow
- On init: fetch
GET /stats and display compaction metrics
- Poll every 5s to refresh compaction status
- On flush click:
POST /admin/flush → refresh stats
- On compact click:
POST /admin/compact → show progress indicator → refresh stats
Acceptance Criteria
Parent Epic
#290
Compaction & Memtable Flush Management Page
Create an Angular admin page for managing LSM-Tree compaction and memtable flushing.
Backend Endpoints (already exist)
UI Requirements
Compaction Panel
Memtable Panel
Statistics Integration
Component Structure
Data Flow
GET /statsand display compaction metricsPOST /admin/flush→ refresh statsPOST /admin/compact→ show progress indicator → refresh statsAcceptance Criteria
Parent Epic
#290