From b757ec581c46069807a55ccf3b6371e1db85d2b0 Mon Sep 17 00:00:00 2001 From: Viktor Kurilko Date: Thu, 14 Dec 2023 15:19:58 +0700 Subject: [PATCH] change comment --- src/backend/gpopt/gpdbwrappers.cpp | 9 +++++---- src/include/gpopt/gpdbwrappers.h | 4 ++-- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/backend/gpopt/gpdbwrappers.cpp b/src/backend/gpopt/gpdbwrappers.cpp index 0431bb23157c..f09c652aa8a5 100644 --- a/src/backend/gpopt/gpdbwrappers.cpp +++ b/src/backend/gpopt/gpdbwrappers.cpp @@ -2510,10 +2510,11 @@ static bool mdcache_invalidation_counter_registered = false; static int64 mdcache_invalidation_counter = 0; static int64 last_mdcache_invalidation_counter = 0; -// if we have cached a relation without an index, because that index cannot -// be used in the current snapshot (for more info see src/backend/access/heap/README.HOT), -// we save TransactionXmin. If TransactionXmin changes later, the cache will -// be reset and the relation will be reloaded with that index. +// If we have cached a relation without an index, because that index cannot +// be used in the current snapshot (for more info see +// src/backend/access/heap/README.HOT), we save TransactionXmin. If +// TransactionXmin changes later, the cache will be reset and the relation will +// be reloaded with that index. static TransactionId mdcache_transaction_xmin = InvalidTransactionId; static void diff --git a/src/include/gpopt/gpdbwrappers.h b/src/include/gpopt/gpdbwrappers.h index ea8bc2d76152..4f8fa6b24635 100644 --- a/src/include/gpopt/gpdbwrappers.h +++ b/src/include/gpopt/gpdbwrappers.h @@ -687,14 +687,14 @@ gpos::ULONG CountLeafPartTables(Oid oidRelation); bool MDCacheNeedsReset(void); // Check that the index is usable in the current snapshot and if not, save the -// xmin of the current snapshot. returns true if the index is not usable and +// xmin of the current snapshot. Returns true if the index is not usable and // should be skipped. bool MDCacheSetTransientState(Relation index_rel); // reset TransactionXmin value that we saved void MDCacheResetTransientState(void); -// check if TransactionXmin value that we saved are valid +// returns true if cache is in transient state bool MDCacheInTransientState(void); // returns true if a query cancel is requested in GPDB