Merge pull request #3146 from citusdata/fix/metadata_sync_on_standby

Do not try to sync metadata on standby coordinator
pull/3147/head
Hadi Moshayedi 2019-10-31 14:56:51 -07:00 committed by GitHub
commit ab4cf8525b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -366,8 +366,9 @@ CitusMaintenanceDaemonMain(Datum main_arg)
} }
#endif #endif
if (MetadataSyncTriggeredCheckAndReset(myDbData) || if (!RecoveryInProgress() &&
GetCurrentTimestamp() >= nextMetadataSyncTime) (MetadataSyncTriggeredCheckAndReset(myDbData) ||
GetCurrentTimestamp() >= nextMetadataSyncTime))
{ {
bool metadataSyncFailed = false; bool metadataSyncFailed = false;
int64 nextTimeout = 0; int64 nextTimeout = 0;