Skip to content

Commit dbd3a51

Browse files
authored
fix crash inside AS when statistics is disabled (#10949) (#10953)
1 parent 0d76e37 commit dbd3a51

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

ydb/core/tx/schemeshard/schemeshard_impl.cpp

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7323,6 +7323,9 @@ void TSchemeShard::Handle(TEvPrivate::TEvSendBaseStatsToSA::TPtr&, const TActorC
73237323
}
73247324

73257325
void TSchemeShard::InitializeStatistics(const TActorContext& ctx) {
7326+
if (!EnableStatistics) {
7327+
return;
7328+
}
73267329
ResolveSA();
73277330
ctx.Schedule(TDuration::Seconds(30), new TEvPrivate::TEvSendBaseStatsToSA());
73287331
}
@@ -7379,10 +7382,6 @@ void TSchemeShard::ConnectToSA() {
73797382
}
73807383

73817384
TDuration TSchemeShard::SendBaseStatsToSA() {
7382-
if (!EnableStatistics) {
7383-
return TDuration::Max();
7384-
}
7385-
73867385
if (!SAPipeClientId) {
73877386
ResolveSA();
73887387
if (!StatisticsAggregatorId) {

0 commit comments

Comments
 (0)