You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shardingsphere.apache.org by GitBox <gi...@apache.org> on 2022/06/30 15:02:41 UTC

[GitHub] [shardingsphere] RaigorJiang opened a new issue, #18746: Refactor `ImportDatabaseConfigurationHandler` to only allow imports when database is empty

RaigorJiang opened a new issue, #18746:
URL: https://github.com/apache/shardingsphere/issues/18746

   Hi community,
   
   We have a pair of statements in DistSQL for export and import configuration, they are:
   - EXPORT DATABASE CONFIGURATION
   - IMPORT DATABASE CONFIGURATION
   > https://github.com/apache/shardingsphere/pull/15069
   https://github.com/apache/shardingsphere/pull/16162
   
   Among them, there may be some problems in the processing of `IMPORT`:
   1. When the data sources already exist in the metadata, the current practice is to merge the imported ones, but the removed resources are not well closed, which may lead to connection leakage;
   2. When a configuration already exists, it is difficult to tell whether the user wants to merge or replace completely;
   3. Refer to some other databases, hope the target is clean when importing, such API is easier to understand.
   
   Therefore, I recommend adjusting the implementation of `ImportDatabaseConfigurationHandler` to only allow imports if the current database's configuration is empty.
   
   If anyone wants to try it, please leave a comment on this issue.


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shardingsphere] RaigorJiang commented on issue #18746: Refactor `ImportDatabaseConfigurationHandler` to only allow imports when database is empty

Posted by GitBox <gi...@apache.org>.
RaigorJiang commented on issue #18746:
URL: https://github.com/apache/shardingsphere/issues/18746#issuecomment-1171864577

   @yx9o Thank you!


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shardingsphere] yx9o commented on issue #18746: Refactor `ImportDatabaseConfigurationHandler` to only allow imports when database is empty

Posted by GitBox <gi...@apache.org>.
yx9o commented on issue #18746:
URL: https://github.com/apache/shardingsphere/issues/18746#issuecomment-1171860891

   Let me try.


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


[GitHub] [shardingsphere] RaigorJiang closed issue #18746: Refactor `ImportDatabaseConfigurationHandler` to only allow imports when database is empty

Posted by GitBox <gi...@apache.org>.
RaigorJiang closed issue #18746: Refactor `ImportDatabaseConfigurationHandler` to only allow imports when database is empty
URL: https://github.com/apache/shardingsphere/issues/18746


-- 
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.

To unsubscribe, e-mail: notifications-unsubscribe@shardingsphere.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org