fix: Use single query instead of batch query for DQL - #84
Conversation
WalkthroughThis pull request refactors SQL statement management within the MySqlStorage module by replacing the use of prepared statements with standard statements in the Changes
Sequence Diagram(s)sequenceDiagram
participant App as Application
participant Storage as MySqlStorage
participant DB as Database
App->>Storage: Call get_ready_tasks / get_task_timeout
Storage->>DB: Create Statement & Execute consolidated query
DB-->>Storage: Return query results
Storage-->>App: Process and return results
Possibly related PRs
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
⏰ Context from checks skipped due to timeout of 90000ms (3)
🔇 Additional comments (8)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
Description
#83 introduces batch query in
get_ready_tasksandget_task_timeout. However, DQLs likeSELECTdoes not support batch query. In bulk mode, it only executes the last query. This pr fixes the problem by using a single query with subqueries.Checklist
breaking change.
Validation performed
Summary by CodeRabbit