1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-28 13:15:09 +00:00
serenity/Userland/Libraries/LibSQL
Timothy Flynn 1205d39fc3 LibSQL+SQLServer: Inform SQLServer when the client has processed results
The architecture of SQLServer is currently such that it sends results
over IPC one row at a time. After the rows are exhausted, it sends a
completion IPC. However, it does not wait for the client to finish
processing a row before sending another row or the completion signal.

This can result in clients hanging if the completion comes in while a
row is being processed. At least in the case of WebView::Database, the
result is that the completion signal is dropped, and the browser then
hangs forever waiting for that signal (after it finishes processing the
row).

This patch makes SQLServer asynchronously wait for the client to tell it
that the row has been processed and the next row (or completion) may be
sent. We repurpose the `m_ongoing_executions` in SQLStatement for this
purpose (this member was oddly being written to, but otherwise unused).
2024-01-10 23:26:40 +01:00
..
AST Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
BTree.cpp LibSQL: Remove Core::EventReceiver parent from SQL::Index 2023-08-07 14:38:38 -04:00
BTree.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
BTreeIterator.cpp LibSQL: Use Block::Index everywhere; rename pointer to block_index 2023-04-23 18:08:17 -04:00
CMakeLists.txt LibSQL: Remove unused HashIndex and related classes 2023-08-07 14:38:38 -04:00
Database.cpp Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Database.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Forward.h LibSQL: Remove unused HashIndex and related classes 2023-08-07 14:38:38 -04:00
Heap.cpp Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Heap.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Index.cpp LibSQL: Use Block::Index everywhere; rename pointer to block_index 2023-04-23 18:08:17 -04:00
Index.h LibSQL: Remove Core::EventReceiver parent from SQL::Index 2023-08-07 14:38:38 -04:00
Key.cpp LibSQL: Introduce Serializer as a mediator between Heap and client code 2021-08-21 22:03:30 +02:00
Key.h LibSQL: Resolve cyclic dependency 2021-10-06 23:52:40 +01:00
Meta.cpp Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Meta.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Result.cpp Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Result.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
ResultSet.cpp LibSQL+SQLServer: Introduce and use ResultOr<ValueType> 2022-02-10 23:11:13 +01:00
ResultSet.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Row.cpp LibSQL: Use Block::Index everywhere; rename pointer to block_index 2023-04-23 18:08:17 -04:00
Row.h LibSQL: Use Block::Index everywhere; rename pointer to block_index 2023-04-23 18:08:17 -04:00
Serializer.cpp Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Serializer.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
SQLClient.cpp LibSQL+SQLServer: Inform SQLServer when the client has processed results 2024-01-10 23:26:40 +01:00
SQLClient.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
TreeNode.cpp Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Tuple.cpp Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Tuple.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
TupleDescriptor.h Everywhere: Rename {Deprecated => Byte}String 2023-12-17 18:25:10 +03:30
Type.h LibSQL: Rename Heap constants to match our code style 2023-04-23 18:08:17 -04:00
Value.cpp Everywhere: Use to_number<T> instead of to_{int,uint,float,double} 2023-12-23 20:41:07 +01:00
Value.h Everywhere: Use to_number<T> instead of to_{int,uint,float,double} 2023-12-23 20:41:07 +01:00