Skip to content

Commit

Permalink
Remove useless DispatchEvent
Browse files Browse the repository at this point in the history
  • Loading branch information
terrymanu committed Jan 1, 2025
1 parent 06c627a commit 37ac5c8
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public void handleCreatedOrAltered(final String databaseName, final String schem
"Invalid active version: %s of key: %s", event.getValue(), event.getKey());
ShardingSphereView view = contextManager.getPersistServiceFacade().getMetaDataPersistService().getDatabaseMetaDataFacade().getView().load(databaseName, schemaName, viewName);
contextManager.getMetaDataContextManager().getSchemaMetaDataManager().alterSchema(databaseName, schemaName, null, view);
new ShardingSphereStatisticsRefreshEngine(contextManager).asyncRefresh();
statisticsRefreshEngine.asyncRefresh();
}

/**
Expand All @@ -65,6 +65,6 @@ public void handleCreatedOrAltered(final String databaseName, final String schem
public void handleDropped(final String databaseName, final String schemaName, final DataChangedEvent event) {
String viewName = ViewMetaDataNode.getViewName(event.getKey()).orElseThrow(() -> new IllegalStateException("View name not found."));
contextManager.getMetaDataContextManager().getSchemaMetaDataManager().alterSchema(databaseName, schemaName, null, viewName);
new ShardingSphereStatisticsRefreshEngine(contextManager).asyncRefresh();
statisticsRefreshEngine.asyncRefresh();
}
}

0 comments on commit 37ac5c8

Please sign in to comment.