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/07/25 08:24:08 UTC

[GitHub] [shardingsphere] Bingai077 opened a new issue, #19521: How does DistSQL simplify logical table configuration

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

   Which version of ShardingSphere did you use?
   5.1.2 (helm cluster)
   
   Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?
   ShardingSphere-Proxy
   
   Expected behavior
   DistSQL has a simple logical table configuration.
   
   Actual behavior
   For the case where only the database is shard.
   Configuration is as
    `
   create database ds;
   use ds;
   
   ADD RESOURCE ds_abc (
       HOST=192.168.0.1,
       PORT=3306,
       DB=ds_abc,
       USER=root,
       PASSWORD=123456
   );
   
   ADD RESOURCE ds_bcd (
       HOST=192.168.0.1,
       PORT=3306,
       DB=ds_bcd,
       USER=root,
       PASSWORD=123456
   );
   
   CREATE SHARDING ALGORITHM database_inline (
   	TYPE(NAME=inline,PROPERTIES("algorithm-expression"="ds${tenant_code}"))
   );
   CREATE DEFAULT SHARDING DATABASE STRATEGY (
   	TYPE = standard,SHARDING_COLUMN=tenant_code,SHARDING_ALGORITHM=database_inline
   );
   
   CREATE SHARDING TABLE RULE order_test (
   	datanodes("ds_${['ds_abc','ds_bcd']}.order_test")
   )
   CREATE SHARDING TABLE RULE user_test (
   	datanodes("ds_${['ds_abc','ds_bcd']}.user_test")
   )
   `
   How do I use DistSQL if I have many databases and tables that need to be dynamically sharded?
   
   
   
   
   
   


-- 
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] Bingai077 commented on issue #19521: How does DistSQL simplify logical table configuration

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

   We need to use DistSQL to dynamically modify the database sharding rules.


-- 
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 #19521: How does DistSQL simplify logical table configuration

Posted by GitBox <gi...@apache.org>.
RaigorJiang closed issue #19521: How does DistSQL simplify logical table configuration
URL: https://github.com/apache/shardingsphere/issues/19521


-- 
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] Bingai077 commented on issue #19521: How does DistSQL simplify logical table configuration

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

   It mainly involves the configuration of logical table routes


-- 
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] terrymanu commented on issue #19521: How does DistSQL simplify logical table configuration

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

   It is better to use code dynamic DistSQL, but DistSQL should be statically.


-- 
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] terrymanu commented on issue #19521: How does DistSQL simplify logical table configuration

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

   Why need to simply DistSQL only?
   DistSQL is same with standard SQL, do you consider about use SQL to simply create table dynamically?


-- 
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 #19521: How does DistSQL simplify logical table configuration

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

   Closed due to no reply for a long time.


-- 
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] terrymanu commented on issue #19521: How does DistSQL simplify logical table configuration

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

   > It mainly involves the configuration of logical table routes
   
   So, how about `It is better to generate DistSQL from programing dynamically, but DistSQL should be statically.`


-- 
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] Bingai077 commented on issue #19521: How does DistSQL simplify logical table configuration

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

   In this case, I find the table rule configuration too tedious. The default value cannot be set null.


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