mirror of
https://github.com/boostorg/redis.git
synced 2026-02-21 15:22:14 +00:00
More refactoring.
This commit is contained in:
@@ -30,17 +30,17 @@ net::awaitable<void> ping()
|
||||
|
||||
std::queue<resp3::request> requests;
|
||||
requests.push({});
|
||||
requests.back().push(command::hello, "3");
|
||||
requests.back().push(command::hello, 3);
|
||||
requests.back().push(command::ping);
|
||||
requests.back().push(command::quit);
|
||||
|
||||
resp3::connection conn;
|
||||
resp3::stream s;
|
||||
for (;;) {
|
||||
resp3::response resp;
|
||||
co_await conn.async_consume(socket, requests, resp);
|
||||
co_await s.async_consume(socket, requests, resp);
|
||||
|
||||
std::cout
|
||||
<< requests.front().elements.front() << "\n"
|
||||
<< requests.front().commands.front() << "\n"
|
||||
<< resp << std::endl;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user