Abstract
Modern analytical database management systems (DBMSs) often struggle with scheduling concurrent OLAP workloads, leading to resource contention and performance degradation. This paper presents IconqSched, a non-intrusive scheduler that leverages a novel bi-directional LSTM model, Iconq, to predict query interactions and implicit system states. By modeling how concurrently executing queries impact each other's runtimes without engine modifications, IconqSched achieves significant reductions in end-to-end runtimes and tail latencies across diverse DBMS engines like PostgreSQL and AWS Redshift.
Introduction
In heavy OLAP environments, the decision of when to execute a query is as critical as how to execute it. Concurrent execution of resource-intensive queries can lead to contention for memory and I/O, resulting in "thrashing" and severe slowdowns. Traditional scheduling approaches are either deeply intrusive (requiring extensive engine-specific engineering) or overly simplistic (relying on heuristics like FIFO). IconqSched bridges this gap by acting as an external proxy layer that uses machine learning to "see" inside the black-box DBMS and predict complex query interactions.
System Architecture
IconqSched consists of two primary components: the Iconq concurrent runtime predictor and a lightweight scheduling layer.
The Iconq Predictor
The core of the system is a bi-directional Long Short-Term Memory (LSTM) network. Unlike static models, the LSTM's hidden state implicitly tracks the DBMS's internal state, such as buffer pool occupancy.
- Forward Pass: Predicts how the current system state (formed by already running queries) will affect a new query.
- Backward Pass: Predicts how the new query will impact the runtimes of queries already in execution.
The IconqSched Scheduler
The scheduler uses an event-driven, greedy approach. It evaluates waiting queries whenever a new query arrives or a running one completes. By scoring queries based on predicted benefits and a starvation penalty, it decides the optimal submission order.
Scheduling Logic and Performance
The primary advantage of IconqSched is its ability to identify when sequential execution is faster than concurrent execution due to resource bottlenecks.
As shown in the figure above, while a standard DBMS like Postgres might run $Q_0$ and $Q_1$ concurrently, IconqSched recognizes that both are memory and I/O intensive. By queuing $Q_1$ until $Q_0$ finishes, it avoids resource thrashing, ultimately reducing the total system runtime.
Evaluation and Results
The system was evaluated using realistic workloads (CAB and BRAD) based on Snowflake's "Snowset" traces.
- PostgreSQL: IconqSched reduced average end-to-end runtime by up to 28.2% and tail latency (p90) by nearly 39%.
- AWS Redshift: Against a sophisticated commercial scheduler, it still achieved a 14.1% reduction in average runtime.
- Accuracy: The Iconq model demonstrated 1.4x to 2.4x lower Q-error compared to state-of-the-art baselines like GPredictor.
Conclusion
IconqSched demonstrates that fine-grained performance prediction using LSTMs can significantly improve non-intrusive DBMS scheduling. By implicitly modeling system state and query interactions, it maximizes hardware utilization and prevents catastrophic performance drops in concurrent OLAP workloads. Future work includes addressing the "cold start" problem and adapting the model for variable serverless environments.
Summary updated