Skip to content

Commit 63f9b74

Browse files
committed
Improves the stress test.
1 parent 801f60a commit 63f9b74

File tree

3 files changed

+6
-5
lines changed

3 files changed

+6
-5
lines changed

CMakePresets.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@
4949
"CMAKE_BUILD_TYPE": "Debug",
5050
"CMAKE_CXX_EXTENSIONS": "OFF",
5151
"CMAKE_CXX_FLAGS": "-Wall -Wextra -fsanitize=address",
52+
"CMAKE_CXX_COMPILER": "g++-11",
5253
"CMAKE_SHARED_LINKER_FLAGS": "-fsanitize=address",
5354
"CMAKE_CXX_STANDARD_REQUIRED": "ON",
5455
"PROJECT_BINARY_DIR": "${sourceDir}/build/dev",

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ Aedis is a [Redis](https://redis.io/) client library built on top of
88
that implements the latest version of the Redis communication
99
protocol
1010
[RESP3](https://github.com/redis/redis-specifications/blob/master/protocol/RESP3.md).
11-
It makes communication with a Redis server easy by hidding most of
11+
It makes communication with a Redis server easy by hiding most of
1212
the low-level Asio-related code away from the user, which in the majority of
1313
the cases will be concerned with only three library entities
1414

@@ -155,7 +155,7 @@ For failover with sentinels see `resolve_with_sentinel.cpp`. At
155155
this point the reasons for why `async_run` was introduced in Aedis
156156
might have become apparent to the reader
157157
158-
* Provide quick reaction to disconnections and hence faster failovers.
158+
* Provide quick reaction to disconnections and hence faster failover.
159159
* Support server pushes and requests in the same connection object, concurrently.
160160
* Separate requests, handling of server pushes and reconnection operations.
161161

tests/conn_echo_stress.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ auto echo_session(std::shared_ptr<connection> conn, std::string id, int n) -> ne
5151
req.push("SUBSCRIBE", "channel");
5252
boost::system::error_code ec;
5353
co_await conn->async_exec(req, adapt(resp), redir(ec));
54-
BOOST_TEST(!ec);
54+
BOOST_CHECK_EQUAL(ec, boost::system::error_code{});
5555
BOOST_CHECK_EQUAL(msg, std::get<1>(resp));
5656
req.clear();
5757
std::get<1>(resp).clear();
@@ -63,8 +63,8 @@ auto async_echo_stress() -> net::awaitable<void>
6363
auto ex = co_await net::this_coro::executor;
6464
auto conn = std::make_shared<connection>(ex);
6565

66-
int const sessions = 1000;
67-
int const msgs = 100;
66+
int const sessions = 500;
67+
int const msgs = 1000;
6868
int total = sessions * msgs;
6969

7070
net::co_spawn(ex, push_consumer(conn, total), net::detached);

0 commit comments

Comments
 (0)