aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorandrew-rykov <arykov@ydb.tech>2023-09-26 22:43:51 +0300
committerandrew-rykov <arykov@ydb.tech>2023-09-26 23:04:56 +0300
commitc054ff0a31f330e59b73043e4f5e692de2202386 (patch)
tree0325fe886f21cb278b44eb6e834ae6820b44e933
parentce3736f17f521ebe4e5ab910e3a3e7c8bb262482 (diff)
downloadydb-c054ff0a31f330e59b73043e4f5e692de2202386.tar.gz
KIKIMR-19348 increase system tablets time response
-rw-r--r--ydb/core/health_check/health_check.cpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/ydb/core/health_check/health_check.cpp b/ydb/core/health_check/health_check.cpp
index 3572d2df381..8545a4e8fde 100644
--- a/ydb/core/health_check/health_check.cpp
+++ b/ydb/core/health_check/health_check.cpp
@@ -516,7 +516,7 @@ public:
TTabletRequestsState TabletRequests;
- TDuration Timeout = TDuration::MilliSeconds(10000);
+ TDuration Timeout = TDuration::MilliSeconds(20000);
static constexpr TStringBuf STATIC_STORAGE_POOL_NAME = "static";
bool IsSpecificDatabaseFilter() {
@@ -1344,17 +1344,20 @@ public:
if (tablet.Database == databaseId) {
context.Location.mutable_compute()->clear_tablet();
auto& protoTablet = *context.Location.mutable_compute()->mutable_tablet();
- if (tablet.IsUnresponsive || tablet.MaxResponseTime >= TDuration::MilliSeconds(1000)) {
+ auto timeoutMs = Timeout.MilliSeconds();
+ auto orangeTimeout = timeoutMs / 2;
+ auto yellowTimeout = timeoutMs / 10;
+ if (tablet.IsUnresponsive || tablet.MaxResponseTime >= TDuration::MilliSeconds(yellowTimeout)) {
if (tablet.Type != TTabletTypes::Unknown) {
protoTablet.set_type(TTabletTypes::EType_Name(tablet.Type));
}
protoTablet.add_id(ToString(tabletId));
if (tablet.IsUnresponsive) {
context.ReportStatus(Ydb::Monitoring::StatusFlag::RED, TStringBuilder() << "System tablet is unresponsive", ETags::SystemTabletState);
- } else if (tablet.MaxResponseTime >= TDuration::MilliSeconds(5000)) {
- context.ReportStatus(Ydb::Monitoring::StatusFlag::ORANGE, "System tablet response time is over 5000ms", ETags::SystemTabletState);
- } else if (tablet.MaxResponseTime >= TDuration::MilliSeconds(1000)) {
- context.ReportStatus(Ydb::Monitoring::StatusFlag::YELLOW, "System tablet response time is over 1000ms", ETags::SystemTabletState);
+ } else if (tablet.MaxResponseTime >= TDuration::MilliSeconds(orangeTimeout)) {
+ context.ReportStatus(Ydb::Monitoring::StatusFlag::ORANGE, TStringBuilder() << "System tablet response time is over " << orangeTimeout << "ms", ETags::SystemTabletState);
+ } else if (tablet.MaxResponseTime >= TDuration::MilliSeconds(yellowTimeout)) {
+ context.ReportStatus(Ydb::Monitoring::StatusFlag::YELLOW, TStringBuilder() << "System tablet response time is over " << yellowTimeout << "ms", ETags::SystemTabletState);
}
}
}