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 2020/03/20 09:06:20 UTC
[GitHub] [incubator-shardingsphere] nevereverever opened a new issue #4862:
using "" will route to all datanode
nevereverever opened a new issue #4862: using "" will route to all datanode
URL: https://github.com/apache/incubator-shardingsphere/issues/4862
## Bug Report
**For English only**, other languages will not accept.
Before report a bug, make sure you have:
- Searched open and closed [GitHub issues](https://github.com/apache/incubator-shardingsphere/issues).
- Read documentation: [ShardingSphere Doc](https://shardingsphere.apache.org/document/current/en/overview).
Please pay attention on issues you submitted, because we maybe need more details.
If no response **more than 7 days** and we cannot reproduce it on current information, we will **close it**.
Please answer these questions before submitting your issue. Thanks!
### Which version of ShardingSphere did you use?
4.0.1
### Which project did you use? Sharding-JDBC or Sharding-Proxy?
sharding-proxy
### description
insert into table use "" will route to all datanode.
such as ,I have a table named tborder,sharding by order_id using hash.
actual datasource: ds_${0..1}
actual tables: tborder_${0..4}
I execute this sql:
```sql
insert into tborder(order_id,order_account) values("ef0f34fd5b9296f102ffdbd47",10000);
```
it will route to all datanode:
```sql
INSERT INTO `tborder`(order_id,order_account) VALUES ("ef0f34fd5b9296f102ffdbd47", 10000)
> Affected rows: 10
> 时间: 0.055s
```
Is it a bug?
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] terrymanu commented on issue #4862:
using "" will route to all datanode
Posted by GitBox <gi...@apache.org>.
terrymanu commented on issue #4862: using "" will route to all datanode
URL: https://github.com/apache/incubator-shardingsphere/issues/4862#issuecomment-603712234
What is content in the class `org.apache.shardingsphere.sharding.rules.standard.SimpleHashShardingAlgorithm`?
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] terrymanu edited a comment on issue
#4862: using "" will route to all datanode
Posted by GitBox <gi...@apache.org>.
terrymanu edited a comment on issue #4862: using "" will route to all datanode
URL: https://github.com/apache/incubator-shardingsphere/issues/4862#issuecomment-603712234
What is content in the class `org.apache.shardingsphere.sharding.rules.standard.SimpleHashShardingAlgorithm`?
@nevereverever
By the way, I find two minor things to reminder you.
1. Your class path `org.apache..shardingsphere.sharding.rules.standard.SimpleHashShardingAlgorithm` is wrong which has tow `..` together.
2. Please do not use `org.apache.shardingsphere` to name your own package, that is Infringing the copyright.
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] nevereverever commented on issue #4862:
using "" will route to all datanode
Posted by GitBox <gi...@apache.org>.
nevereverever commented on issue #4862: using "" will route to all datanode
URL: https://github.com/apache/incubator-shardingsphere/issues/4862#issuecomment-602143391
I'm sure there's no problem with ''.So my split rule is fine.
@kimmking
```yaml
schemaName: sharding_db
dataSources:
ds_0:
url: jdbc:mysql://172.18.30.14:3310/db01?serverTimezone=UTC&useSSL=false&useServerPrepStmts=true&cachePrepStmts=true
username: hotdb_root
password: hotdb_root
connectionTimeoutMilliseconds: 300000
idleTimeoutMilliseconds: 600000
maxLifetimeMilliseconds: 1800000
maxPoolSize: 200
ds_1:
url: jdbc:mysql://172.18.30.15:3310/db01?serverTimezone=UTC&useSSL=false&useServerPrepStmts=true&cachePrepStmts=true
username: hotdb_root
password: hotdb_root
connectionTimeoutMilliseconds: 300000
idleTimeoutMilliseconds: 600000
maxLifetimeMilliseconds: 1800000
maxPoolSize: 200
shardingRule:
tables:
tbperson:
actualDataNodes: ds_${0..1}.tborder${0..4}
databaseStrategy:
standard:
shardingColumn: order_id
preciseAlgorithmClassName: org.apache..shardingsphere.sharding.rules.standard.SimpleHashShardingAlgorithm
defaultDatabaseStrategy:
none:
defaultTableStrategy:
none:
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] terrymanu edited a comment on issue
#4862: using "" will route to all datanode
Posted by GitBox <gi...@apache.org>.
terrymanu edited a comment on issue #4862: using "" will route to all datanode
URL: https://github.com/apache/incubator-shardingsphere/issues/4862#issuecomment-603712234
What is content in the class `org.apache.shardingsphere.sharding.rules.standard.SimpleHashShardingAlgorithm`?
@nevereverever
By the way, I find 2 things to reminder you.
1. Your class path `org.apache..shardingsphere.sharding.rules.standard.SimpleHashShardingAlgorithm` is wrong which has tow `..` together.
2. Please do not use `org.apache.shardingsphere` to name your own package, that is Infringing the copyright.
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] terrymanu commented on issue #4862:
using "" will route to all datanode
Posted by GitBox <gi...@apache.org>.
terrymanu commented on issue #4862: using "" will route to all datanode
URL: https://github.com/apache/incubator-shardingsphere/issues/4862#issuecomment-605824759
Will close soon if no update anymore
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] kimmking commented on issue #4862: using
"" will route to all datanode
Posted by GitBox <gi...@apache.org>.
kimmking commented on issue #4862: using "" will route to all datanode
URL: https://github.com/apache/incubator-shardingsphere/issues/4862#issuecomment-601614667
show the sharding config rule.
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services
[GitHub] [incubator-shardingsphere] terrymanu closed issue #4862: using ""
will route to all datanode
Posted by GitBox <gi...@apache.org>.
terrymanu closed issue #4862: using "" will route to all datanode
URL: https://github.com/apache/incubator-shardingsphere/issues/4862
----------------------------------------------------------------
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:
users@infra.apache.org
With regards,
Apache Git Services