You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@kudu.apache.org by al...@apache.org on 2025/08/13 18:39:06 UTC
(kudu) branch master updated (3a2f29a92 -> 6307ab29b)
This is an automated email from the ASF dual-hosted git repository.
alexey pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/kudu.git
from 3a2f29a92 [util] introduce security::IsFIPSEnabled()
new 33999074d KUDU-3687 higher timeout for WAL segment count in heavy workloads
new 6307ab29b [rpc] make Messenger::ShutdownInternal() safer
The 2 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.
Summary of changes:
src/kudu/integration-tests/tablet_copy-itest.cc | 21 +++++++++++++++++----
src/kudu/rpc/messenger.cc | 6 +++---
2 files changed, 20 insertions(+), 7 deletions(-)
(kudu) 01/02: KUDU-3687 higher timeout for WAL segment count in heavy workloads
Posted by al...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
alexey pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kudu.git
commit 33999074d088e974dbfdb3501a6600fddce9a6da
Author: Alexey Serbin <al...@apache.org>
AuthorDate: Mon Aug 11 15:04:49 2025 -0700
KUDU-3687 higher timeout for WAL segment count in heavy workloads
As it turns out, even with the increased default timeout parameter for
WaitForMinFilesInTabletWalDirOnTS() in [1], a couple of new tests added
after that [2] are failing from time to time under TSAN due to heavy
workloads. This changelist addresses the issue, increasing the timeout
argument for WaitForMinFilesInTabletWalDirOnTS() in a couple of
particular call sites from 60 up to 120 seconds.
[1] http://gerrit.cloudera.org:8080/1793
[2] http://gerrit.cloudera.org:8080/16726
Change-Id: I68f30bc8b1c59843b1485bd0924ddd51d144eff1
Reviewed-on: http://gerrit.cloudera.org:8080/23286
Reviewed-by: Gabriella Lotz <lo...@gmail.com>
Tested-by: Alexey Serbin <al...@apache.org>
Reviewed-by: Abhishek Chennaka <ac...@cloudera.com>
---
src/kudu/integration-tests/tablet_copy-itest.cc | 21 +++++++++++++++++----
1 file changed, 17 insertions(+), 4 deletions(-)
diff --git a/src/kudu/integration-tests/tablet_copy-itest.cc b/src/kudu/integration-tests/tablet_copy-itest.cc
index 5ba4d9886..0703d15bf 100644
--- a/src/kudu/integration-tests/tablet_copy-itest.cc
+++ b/src/kudu/integration-tests/tablet_copy-itest.cc
@@ -2024,7 +2024,14 @@ TEST_F(TabletCopyITest, TestBeginTabletCopySessionConcurrency) {
//
// Verify wal contents by comparing the count of rows.
TEST_F(TabletCopyITest, TestDownloadWalInParallelWithHeavyInsert) {
- MonoDelta kTimeout = MonoDelta::FromSeconds(30);
+ const MonoDelta kTimeout = MonoDelta::FromSeconds(30);
+
+#ifdef THREAD_SANITIZER
+ const MonoDelta kWalSegmentCountTimeout = MonoDelta::FromSeconds(120);
+#else
+ const MonoDelta kWalSegmentCountTimeout = kTimeout;
+#endif
+
FLAGS_log_segment_size_mb = 1;
FLAGS_tablet_copy_download_wal_inject_latency = true;
@@ -2071,7 +2078,7 @@ TEST_F(TabletCopyITest, TestDownloadWalInParallelWithHeavyInsert) {
workload.Start();
ASSERT_OK(inspect_->WaitForMinFilesInTabletWalDirOnTS(
- first_leader_index, tablet_id, kNumWalSegments));
+ first_leader_index, tablet_id, kNumWalSegments, kWalSegmentCountTimeout));
workload.StopAndJoin();
ASSERT_OK(WaitForServersToAgree(kTimeout, ts_map_, tablet_id, 1));
@@ -2102,7 +2109,13 @@ TEST_F(TabletCopyITest, TestDownloadWalInParallelWithHeavyInsert) {
//
// Verify wal contents by comparing the content.
TEST_F(TabletCopyITest, TestDownloadWalInParallelWithHeavyUpdate) {
- MonoDelta kTimeout = MonoDelta::FromSeconds(30);
+ const MonoDelta kTimeout = MonoDelta::FromSeconds(30);
+#ifdef THREAD_SANITIZER
+ const MonoDelta kWalSegmentCountTimeout = MonoDelta::FromSeconds(120);
+#else
+ const MonoDelta kWalSegmentCountTimeout = kTimeout;
+#endif
+
FLAGS_log_segment_size_mb = 1;
FLAGS_tablet_copy_download_wal_inject_latency = true;
@@ -2148,7 +2161,7 @@ TEST_F(TabletCopyITest, TestDownloadWalInParallelWithHeavyUpdate) {
workload.Start();
ASSERT_OK(inspect_->WaitForMinFilesInTabletWalDirOnTS(
- first_leader_index, tablet_id, kNumWalSegments));
+ first_leader_index, tablet_id, kNumWalSegments, kWalSegmentCountTimeout));
workload.StopAndJoin();
ASSERT_OK(WaitForServersToAgree(kTimeout, ts_map_, tablet_id, 1));
(kudu) 02/02: [rpc] make Messenger::ShutdownInternal() safer
Posted by al...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
alexey pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/kudu.git
commit 6307ab29b78ebc064971e01ca1da31590298dcda
Author: Alexey Serbin <al...@apache.org>
AuthorDate: Tue Aug 12 15:50:42 2025 -0700
[rpc] make Messenger::ShutdownInternal() safer
Unless otherwise specified, all standard library objects that have been
moved from are placed in a "valid but unspecified state" [1], so only
functions without preconditions can be safely called on them.
The 'rpc_services_' and 'acceptor_pools_' member fields of the Messenger
class can be accessed after Messenger::ShutdownInternal() has been
called. In this context, it's much more straightforward to leave all
the fields in a well-defined state without digging into implementation
details of various compilers and trying to clarify on type of operations
being invoked on those fields when a Messenger object has already been
shut down, but isn't destroyed yet.
[1] https://en.cppreference.com/w/cpp/utility/move.html
Change-Id: If4950ec4ef2edb41296f0f46f2341b53068a9497
Reviewed-on: http://gerrit.cloudera.org:8080/23289
Tested-by: Alexey Serbin <al...@apache.org>
Reviewed-by: Gabriella Lotz <lo...@gmail.com>
Reviewed-by: Abhishek Chennaka <ac...@cloudera.com>
---
src/kudu/rpc/messenger.cc | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/kudu/rpc/messenger.cc b/src/kudu/rpc/messenger.cc
index 96b153761..87c2bc1be 100644
--- a/src/kudu/rpc/messenger.cc
+++ b/src/kudu/rpc/messenger.cc
@@ -226,8 +226,8 @@ void Messenger::ShutdownInternal(ShutdownMode mode) {
VLOG(1) << "shutting down messenger " << name_;
state_ = kClosing;
- services_to_release = std::move(rpc_services_);
- pools_to_shutdown = std::move(acceptor_pools_);
+ services_to_release.swap(rpc_services_);
+ pools_to_shutdown.swap(acceptor_pools_);
}
// Destroy state outside of the lock.
@@ -311,7 +311,7 @@ void Messenger::UnregisterAllServices() {
RpcServicesMap to_release;
{
std::lock_guard guard(lock_);
- to_release = std::move(rpc_services_);
+ to_release.swap(rpc_services_);
state_ = kServicesUnregistered;
}
// Release the map outside of the lock.