From 8b5d87eecd39849c7a0dde16e5e025fc9a5b3dbb Mon Sep 17 00:00:00 2001 From: zh0 Date: Tue, 27 Jul 2021 11:57:13 +0800 Subject: [PATCH] fix standalone weak read bug --- src/sql/ob_sql_trans_control.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/sql/ob_sql_trans_control.cpp b/src/sql/ob_sql_trans_control.cpp index a273e492f..6dbe3de7d 100644 --- a/src/sql/ob_sql_trans_control.cpp +++ b/src/sql/ob_sql_trans_control.cpp @@ -1857,7 +1857,8 @@ int ObSqlTransControl::start_standalone_stmt( is_local_single_partition_stmt ? in_pla.get_partitions().at(0) : ObPartitionKey())); } if (OB_FAIL(ret)) { - } else if (standalone_stmt_desc.is_bounded_staleness_read() && !ObWeakReadUtil::check_weak_read_service_available()) { + } else if (standalone_stmt_desc.is_bounded_staleness_read() && + !ObWeakReadUtil::enable_monotonic_weak_read(session_info.get_effective_tenant_id())) { if (ObSqlTransUtil::plan_can_start_trans(session_info.get_local_autocommit(), session_info.get_in_transaction())) { OZ(implicit_start_trans(exec_ctx, is_remote)); }