@@ -747,7 +747,7 @@ class TSelfCheckRequest : public TActorBootstrapped<TSelfCheckRequest> {
747
747
748
748
TTabletRequestsState TabletRequests;
749
749
750
- TDuration Timeout = TDuration::MilliSeconds(20000 );
750
+ TDuration Timeout = TDuration::MilliSeconds(HealthCheckConfig.GetTimeout() );
751
751
static constexpr TStringBuf STATIC_STORAGE_POOL_NAME = " static" ;
752
752
753
753
bool IsSpecificDatabaseFilter () const {
@@ -1509,7 +1509,7 @@ class TSelfCheckRequest : public TActorBootstrapped<TSelfCheckRequest> {
1509
1509
for (const auto & [hiveId, hiveResponse] : HiveInfo) {
1510
1510
if (hiveResponse.IsOk ()) {
1511
1511
settings.AliveBarrier = TInstant::MilliSeconds (hiveResponse->Record .GetResponseTimestamp ()) - TDuration::Minutes (5 );
1512
- settings.MaxRestartsPerPeriod = HealthCheckConfig.GetTabletsRestartsPerPeriodOrangeThreshold ();
1512
+ settings.MaxRestartsPerPeriod = HealthCheckConfig.GetThresholds (). GetTabletsRestartsOrange ();
1513
1513
for (const NKikimrHive::TTabletInfo& hiveTablet : hiveResponse->Record .GetTablets ()) {
1514
1514
TSubDomainKey tenantId = TSubDomainKey (hiveTablet.GetObjectDomain ());
1515
1515
auto itDomain = FilterDomainKey.find (tenantId);
@@ -1735,9 +1735,9 @@ class TSelfCheckRequest : public TActorBootstrapped<TSelfCheckRequest> {
1735
1735
FillNodeInfo (nodeId, context.Location .mutable_compute ()->mutable_node ());
1736
1736
1737
1737
TSelfCheckContext rrContext (&context, " NODE_UPTIME" );
1738
- if (databaseState.NodeRestartsPerPeriod [nodeId] >= HealthCheckConfig.GetNodeRestartsPerPeriodOrangeThreshold ()) {
1738
+ if (databaseState.NodeRestartsPerPeriod [nodeId] >= HealthCheckConfig.GetThresholds (). GetNodeRestartsOrange ()) {
1739
1739
rrContext.ReportStatus (Ydb::Monitoring::StatusFlag::ORANGE, " Node is restarting too often" , ETags::Uptime);
1740
- } else if (databaseState.NodeRestartsPerPeriod [nodeId] >= HealthCheckConfig.GetNodeRestartsPerPeriodYellowThreshold ()) {
1740
+ } else if (databaseState.NodeRestartsPerPeriod [nodeId] >= HealthCheckConfig.GetThresholds (). GetNodeRestartsYellow ()) {
1741
1741
rrContext.ReportStatus (Ydb::Monitoring::StatusFlag::YELLOW, " The number of node restarts has increased" , ETags::Uptime);
1742
1742
} else {
1743
1743
rrContext.ReportStatus (Ydb::Monitoring::StatusFlag::GREEN);
@@ -1775,9 +1775,9 @@ class TSelfCheckRequest : public TActorBootstrapped<TSelfCheckRequest> {
1775
1775
long timeDifferenceUs = nodeSystemState.GetMaxClockSkewWithPeerUs ();
1776
1776
TDuration timeDifferenceDuration = TDuration::MicroSeconds (abs (timeDifferenceUs));
1777
1777
Ydb::Monitoring::StatusFlag::Status status;
1778
- if (timeDifferenceDuration > TDuration::MicroSeconds (HealthCheckConfig.GetNodesTimeDifferenceUsOrangeThreshold ())) {
1778
+ if (timeDifferenceDuration > TDuration::MicroSeconds (HealthCheckConfig.GetThresholds (). GetNodesTimeDifferenceOrange ())) {
1779
1779
status = Ydb::Monitoring::StatusFlag::ORANGE;
1780
- } else if (timeDifferenceDuration > TDuration::MicroSeconds (HealthCheckConfig.GetNodesTimeDifferenceUsYellowThreshold ())) {
1780
+ } else if (timeDifferenceDuration > TDuration::MicroSeconds (HealthCheckConfig.GetThresholds (). GetNodesTimeDifferenceYellow ())) {
1781
1781
status = Ydb::Monitoring::StatusFlag::YELLOW;
1782
1782
} else {
1783
1783
status = Ydb::Monitoring::StatusFlag::GREEN;
0 commit comments