branch-2.1: [fix](external catalog) Fixed non-master FE log replay during refresh (#46373)
cherry-pick #46369
This commit is contained in:
@ -718,7 +718,7 @@ public abstract class ExternalCatalog
|
||||
|
||||
public void replayInitCatalog(InitCatalogLog log) {
|
||||
// If the remote name is missing during upgrade, all databases in the Map will be reinitialized.
|
||||
if (log.getRemoteDbNames() == null || log.getRemoteDbNames().isEmpty()) {
|
||||
if (log.getCreateCount() > 0 && (log.getRemoteDbNames() == null || log.getRemoteDbNames().isEmpty())) {
|
||||
dbNameToId = Maps.newConcurrentMap();
|
||||
idToDb = Maps.newConcurrentMap();
|
||||
lastUpdateTime = log.getLastUpdateTime();
|
||||
|
||||
@ -191,7 +191,7 @@ public abstract class ExternalDatabase<T extends ExternalTable>
|
||||
|
||||
public void replayInitDb(InitDatabaseLog log, ExternalCatalog catalog) {
|
||||
// If the remote name is missing during upgrade, all tables in the Map will be reinitialized.
|
||||
if (log.getRemoteTableNames() == null || log.getRemoteTableNames().isEmpty()) {
|
||||
if (log.getCreateCount() > 0 && (log.getRemoteTableNames() == null || log.getRemoteTableNames().isEmpty())) {
|
||||
tableNameToId = Maps.newConcurrentMap();
|
||||
idToTbl = Maps.newConcurrentMap();
|
||||
lastUpdateTime = log.getLastUpdateTime();
|
||||
|
||||
Reference in New Issue
Block a user