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 2021/11/03 04:48:38 UTC

[GitHub] [shardingsphere] RaigorJiang opened a new issue #13426: Add FAQ for DistSQL `DROP RESOURCE`

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


   ### Background
   
   DistSQL is a new feature of version 5.0. Users may encounter some error prompts when using it, but do not understand how to deal with these situations.
   
   ### Aim
   
   Add FAQ, point out the cause of the error message, and provide solutions.
   
   ### How to
   
   1. Understand the error message in the task description, investigate and confirm the cause. (Of course you can also ask for help)
   2. Edit the [FAQ](https://github.com/apache/shardingsphere/tree/master/docs/document/content/reference/faq) files to add related questions and answers.
   3. If you are not good at Chinese, you can also submit an English FAQ independently.
   
   ### Task
   
   - DROP RESOURCE
   ```sql
   mysql> ADD RESOURCE ds_0 (
       ->     HOST=127.0.0.1,
       ->     PORT=3306,
       ->     DB=demo_ds_0,
       ->     USER=root,
       ->     PASSWORD=123456,
       ->     PROPERTIES("maximumPoolSize"=10)
       -> );
   Query OK, 0 rows affected (0.68 sec)
   
   mysql> show schema resources;
   +------+-------+-----------+------+-----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | name | type  | host      | port | db        | attribute                                                                                                                                                                                              |
   +------+-------+-----------+------+-----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   | ds_0 | MySQL | 127.0.0.1 | 3306 | demo_ds_0 | {"maxLifetimeMilliseconds":1800000,"readOnly":false,"customPoolProps":{"maximumPoolSize":"10"},"minPoolSize":1,"idleTimeoutMilliseconds":60000,"maxPoolSize":50,"connectionTimeoutMilliseconds":30000} |
   +------+-------+-----------+------+-----------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
   1 row in set (0.05 sec)
   
   mysql> drop resource ds_0;
   ERROR 1101 (C1101): Resource [ds_0] is still used by [SingleTableRule].
   ```


-- 
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] LeeGuoPing commented on issue #13426: Add FAQ for DistSQL `DROP RESOURCE`

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


   please assign it to me


-- 
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] LeeGuoPing commented on issue #13426: Add FAQ for DistSQL `DROP RESOURCE`

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


   @RaigorJiang SingleTableRule is configurated with distSQL or write in yaml, can you give me a exmaple? 


-- 
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 #13426: Add FAQ for DistSQL `DROP RESOURCE`

Posted by GitBox <gi...@apache.org>.
RaigorJiang closed issue #13426:
URL: https://github.com/apache/shardingsphere/issues/13426


   


-- 
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] LeeGuoPing commented on issue #13426: Add FAQ for DistSQL `DROP RESOURCE`

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


   please assign it to me


-- 
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] LeeGuoPing commented on issue #13426: Add FAQ for DistSQL `DROP RESOURCE`

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


   please assign it to me


-- 
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 commented on issue #13426: Add FAQ for DistSQL `DROP RESOURCE`

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


   [Single Table](https://shardingsphere.apache.org/document/current/en/features/sharding/concept/table/#single-table) does not need to be configured. A table without configuration will be recognized as a single table when it is loaded, and SharidngSphere can know which data source it is on.


-- 
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 commented on issue #13426: Add FAQ for DistSQL `DROP RESOURCE`

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


   @LeeGuoPing 
   To reproduce this scenario, you can specify a database that already has a table (the table does not have a corresponding sharding rule) when adding resource, and then drop it immediately.


-- 
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] LeeGuoPing commented on issue #13426: Add FAQ for DistSQL `DROP RESOURCE`

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


   please assign it to me


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