ShannonDB provides a comprehensive, intelligent workload management system that automatically optimizes query execution across primary and secondary engines. By leveraging two complementary mechanisms—Dynamic Query Offloading and Self-Load Management—ShannonDB ensures high performance, efficient resource utilization, and operational simplicity for hybrid transactional/analytical workloads.
Dynamic Query Offloading enables ShannonDB to intelligently route queries to the most appropriate engine in real-time, based on system state, query characteristics, and historical performance.
ShannonDB dynamically determines query execution paths through a multi-stage decision process: Initial Qualification verifies table availability, data synchronization status, and feature compatibility; Intelligent Classification applies one of three strategies depending on the system state and query features.
Standard Cost Threshold Classifier: Routes queries to RAPID when execution cost exceeds secondary_engine_cost_threshold; keeps fast queries on InnoDB for optimal responsiveness.
Machine Learning Decision Tree: Uses ONNX-based model (shannon_rapid_classifier.onnx) to analyze multiple query features; learns from historical performance patterns; adapts to specific workload characteristics.
Dynamic State-Aware Routing: Monitors data population queue length and size during active synchronization; progressively shifts heavier queries to InnoDB under high load; ensures system stability during propagation.
Self-Load Management automates table lifecycle operations, dynamically loading and unloading tables based on usage patterns and system resources.
Table Information Collection: Schema discovery, statistics analysis, and configuration parsing to detect RAPID tables.
Intelligent Importance Scoring: Tables receive dynamic importance scores based on size, query time, and weight factors.
Automatic Loading/Unloading: Applies exponential decay to importance, memory-aware loading, and priority-based queue management.
System State Awareness: Quiet system detection, resource monitoring, and user vs self-loaded table prioritization.
Performance Optimization: Intelligent routing, automatic loading of hot tables into RAPID, efficient memory usage by unloading cold tables.
Operational Simplicity: Zero manual management, self-learning based on query patterns, detailed telemetry and monitoring.
System Resilience: Load-aware decisions prevent overloading, graceful degradation under memory pressure, ensures data consistency before offloading queries.
Unified Intelligence: Combines real-time query analysis, long-term table pattern recognition, and resource-aware scheduling.
Adaptive Learning: Continuously updates table importance based on actual usage and query performance feedback.
Enterprise-Grade Reliability: Thread-safe operations, comprehensive error handling, and detailed telemetry ensure robust operation.