You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@logging.apache.org by sw...@apache.org on 2024/10/16 11:49:13 UTC
(logging-log4cxx) branch fix_flaky_asyncappender_test created (now 820ffa28)
This is an automated email from the ASF dual-hosted git repository.
swebb2066 pushed a change to branch fix_flaky_asyncappender_test
in repository https://gitbox.apache.org/repos/asf/logging-log4cxx.git
at 820ffa28 Prevent asyncappender test timeout
This branch includes the following new commits:
new 820ffa28 Prevent asyncappender test timeout
The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
(logging-log4cxx) 01/01: Prevent asyncappender test timeout
Posted by sw...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
swebb2066 pushed a commit to branch fix_flaky_asyncappender_test
in repository https://gitbox.apache.org/repos/asf/logging-log4cxx.git
commit 820ffa282bfd61e98a28c4ad1b4a97c62d14f910
Author: Stephen Webb <sw...@gmail.com>
AuthorDate: Wed Oct 16 22:48:52 2024 +1100
Prevent asyncappender test timeout
---
src/test/cpp/asyncappendertestcase.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/test/cpp/asyncappendertestcase.cpp b/src/test/cpp/asyncappendertestcase.cpp
index bffa5e73..87b7d913 100644
--- a/src/test/cpp/asyncappendertestcase.cpp
+++ b/src/test/cpp/asyncappendertestcase.cpp
@@ -235,7 +235,7 @@ class AsyncAppenderTestCase : public AppenderSkeletonTestCase
void testMultiThread()
{
int LEN = 2000; // Larger than default buffer size (128)
- int threadCount = 6;
+ int threadCount = max(std::thread::hardware_concurrency(), 2);
auto root = Logger::getRootLogger();
auto vectorAppender = std::make_shared<VectorAppender>();
auto asyncAppender = std::make_shared<AsyncAppender>();