Beyondeclipse commented on issue #10678:
URL: 
https://github.com/apache/shardingsphere/issues/10678#issuecomment-865714539


   @tristaZero I found the root cause of slowing down my system is loading all 
'TableMetaData' twice:
   1. ShardingSphereDataSource -> MetaDataContextsBuilder.build -> 
MetaDataContextsBuilder.buildMetaData -> SchemaBuilder.build
   2. ShardingSphereDataSource -> MetaDataContextsBuilder.build -> 
StandardMetaDataContexts -> OptimizeContextFactory -> FederateSchemaMetadatas 
-> FederateSchemaMetadata.initTables
   The first way is faster than the second one by using multi-thread and 
DialectTableMetaDataLoader. It seams that the simple way is to make the loading 
once and I create a pull request for it.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to