From 14f363c1fde9f3f5a93bdce4be65d42d7b588d72 Mon Sep 17 00:00:00 2001 From: Alexander Kotov Date: Thu, 28 Nov 2024 12:33:14 +0300 Subject: [PATCH] [*] Step value --- ydb/core/persqueue/pq_impl_app.cpp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/ydb/core/persqueue/pq_impl_app.cpp b/ydb/core/persqueue/pq_impl_app.cpp index 331c13339e45..f439a6711104 100644 --- a/ydb/core/persqueue/pq_impl_app.cpp +++ b/ydb/core/persqueue/pq_impl_app.cpp @@ -123,7 +123,7 @@ class TMonitoringProxy : public TActorBootstrapped { str << tx.TxId; } } - TABLED() {str << tx.Step;} + TABLED() {str << GetTxStep(tx);} TABLED() {str << NKikimrPQ::TTransaction_EState_Name(tx.State);} TABLED() {str << tx.MinStep;} TABLED() {str << tx.MaxStep;} @@ -147,6 +147,13 @@ class TMonitoringProxy : public TActorBootstrapped { Die(ctx); } + static TString GetTxStep(const TTransactionSnapshot& tx) { + if (tx.Step == Max()) { + return "-"; + } + return ToString(tx.Step); + } + void Wakeup(const TActorContext& ctx) { Reply(ctx); }