From 7a16877aae603e6321af281b1fcdfdab84cc474c Mon Sep 17 00:00:00 2001 From: benthompson15 Date: Thu, 30 Jan 2020 14:29:30 -0600 Subject: [PATCH] Merge pull request #1016 from dhall-MariaDB/MCOL-3744 MCOL-3744 mcssystemready to work with SKIP_OAM_INIT --- dbcon/mysql/ha_mcs_client_udfs.cpp | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) diff --git a/dbcon/mysql/ha_mcs_client_udfs.cpp b/dbcon/mysql/ha_mcs_client_udfs.cpp index 51ce2917f..8395b364b 100644 --- a/dbcon/mysql/ha_mcs_client_udfs.cpp +++ b/dbcon/mysql/ha_mcs_client_udfs.cpp @@ -294,13 +294,24 @@ extern "C" try { - oam.getSystemStatus(systemstatus); - - if (systemstatus.SystemOpState == ACTIVE - && dbrm.getSystemReady() - && dbrm.getSystemQueryReady()) + if (getenv("SKIP_OAM_INIT")) { - return 1; + if (dbrm.getSystemReady() + && dbrm.getSystemQueryReady()) + { + return 1; + } + } + else + { + oam.getSystemStatus(systemstatus); + + if (systemstatus.SystemOpState == ACTIVE + && dbrm.getSystemReady() + && dbrm.getSystemQueryReady()) + { + return 1; + } } } catch (...)