mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 22:17:45 +00:00
RequestServer+LibProtocol: Make starting requests fully async
This makes it so the clients don't have to wait for RS to become responsive, potentially allowing them to do other things while RS handles the connections. Fixes #23306.
This commit is contained in:
parent
18d26142f0
commit
5232afa13d
26 changed files with 114 additions and 87 deletions
|
@ -55,7 +55,7 @@ public:
|
|||
void did_request_certificates(Badge<RequestClient>);
|
||||
|
||||
RefPtr<Core::Notifier>& write_notifier(Badge<RequestClient>) { return m_write_notifier; }
|
||||
void set_request_fd(Badge<RequestClient>, int fd) { m_fd = fd; }
|
||||
void set_request_fd(Badge<RequestClient>, int fd);
|
||||
|
||||
private:
|
||||
explicit Request(RequestClient&, i32 request_id);
|
||||
|
@ -73,12 +73,9 @@ private:
|
|||
};
|
||||
|
||||
struct InternalStreamData {
|
||||
InternalStreamData(NonnullOwnPtr<Stream> stream)
|
||||
: read_stream(move(stream))
|
||||
{
|
||||
}
|
||||
InternalStreamData() { }
|
||||
|
||||
NonnullOwnPtr<Stream> read_stream;
|
||||
OwnPtr<Stream> read_stream;
|
||||
RefPtr<Core::Notifier> read_notifier;
|
||||
bool success;
|
||||
u32 total_size { 0 };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue