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/03/25 01:35:40 UTC
[GitHub] [shardingsphere] 814196912 opened a new issue #9811: java.lang.IndexOutOfBoundsException occurs in mysql "join" query
814196912 opened a new issue #9811:
URL: https://github.com/apache/shardingsphere/issues/9811
Hey.When I execute "select * FROM **film a join actor b** on a.unit_id=b.unit_id",sharding-sphere-proxy will generate error "java.lang.IndexOutOfBoundsException: Index: 2, Size: 2".However, when I execute "select * FROM **film a join actor b** on a.unit_id=b.unit_id",the query is OK.
![image](https://user-images.githubusercontent.com/38856046/112404826-0ec8be80-8d4c-11eb-9fdd-66f76cbade7a.png)
![image](https://user-images.githubusercontent.com/38856046/112404890-286a0600-8d4c-11eb-9520-eefba4f3589b.png)
**This is the configure Yaml file of the sharding-sphere-proxy.**
schemaName: test
dataSources:
ds_0:
url: jdbc:mysql://127.0.0.1:3306/test-master-0?serverTimezone=UTC&useSSL=false
username: root
password: root123
connectionTimeoutMilliseconds: 30000
idleTimeoutMilliseconds: 60000
maxLifetimeMilliseconds: 1800000
maxPoolSize: 50
ds_1:
url: jdbc:mysql://127.0.0.1:3306/test-master-1?serverTimezone=UTC&useSSL=false
username: root
password: root123
connectionTimeoutMilliseconds: 30000
idleTimeoutMilliseconds: 60000
maxLifetimeMilliseconds: 1800000
maxPoolSize: 50
slave_ds_1:
url: jdbc:mysql://localhost:3307/test-master-0?serverTimezone=UTC&useUnicode=true&characterEncoding=utf-8&useSSL=false&allowPublicKeyRetrieval=true
username: root
password: root123
connectionTimeoutMilliseconds: 30000
idleTimeoutMilliseconds: 60000
maxLifetimeMilliseconds: 1800000
maxPoolSize: 50
rules:
- !REPLICA_QUERY
dataSources:
ds_0:
primaryDataSourceName: ds_0
replicaDataSourceNames:
- slave_ds_1
- !SHARDING
tables:
film:
actualDataNodes: ds_${0..1}.film_${0..1}
tableStrategy:
standard:
shardingColumn: id
shardingAlgorithmName: film_inline
keyGenerateStrategy:
column: id
keyGeneratorName: snowflake
actor:
actualDataNodes: ds_${0..1}.actor
keyGenerateStrategy:
column: unit_id
keyGeneratorName: snowflake
bindingTables:
- film,actor
defaultDatabaseStrategy:
standard:
shardingColumn: unit_id
shardingAlgorithmName: database_inline
defaultTableStrategy:
none:
shardingAlgorithms:
database_inline:
type: INLINE
props:
algorithm-expression: ds_${unit_id % 2}
allow-range-query-with-inline-sharding: true
film_inline:
type: INLINE
props:
algorithm-expression: film_${id % 2}
allow-range-query-with-inline-sharding: true
keyGenerators:
snowflake:
type: SNOWFLAKE
props:
worker-id: 123
--
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
[GitHub] [shardingsphere] strongduanmu commented on issue #9811: java.lang.IndexOutOfBoundsException occurs in mysql "join" query
Posted by GitBox <gi...@apache.org>.
strongduanmu commented on issue #9811:
URL: https://github.com/apache/shardingsphere/issues/9811#issuecomment-812835568
@814196912 Can you provide the schema of the table, and complete exception stack? I need this information to reproduce the error.
--
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
[GitHub] [shardingsphere] strongduanmu closed issue #9811: java.lang.IndexOutOfBoundsException occurs in mysql "join" query
Posted by GitBox <gi...@apache.org>.
strongduanmu closed issue #9811:
URL: https://github.com/apache/shardingsphere/issues/9811
--
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
[GitHub] [shardingsphere] strongduanmu commented on issue #9811: java.lang.IndexOutOfBoundsException occurs in mysql "join" query
Posted by GitBox <gi...@apache.org>.
strongduanmu commented on issue #9811:
URL: https://github.com/apache/shardingsphere/issues/9811#issuecomment-818768481
There was no reply for a long time, so it was closed.
--
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
[GitHub] [shardingsphere] strongduanmu commented on issue #9811: java.lang.IndexOutOfBoundsException occurs in mysql "join" query
Posted by GitBox <gi...@apache.org>.
strongduanmu commented on issue #9811:
URL: https://github.com/apache/shardingsphere/issues/9811#issuecomment-806575637
@814196912 Thank you very much for your feedback, I will investigate 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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] strongduanmu commented on issue #9811: java.lang.IndexOutOfBoundsException occurs in mysql "join" query
Posted by GitBox <gi...@apache.org>.
strongduanmu commented on issue #9811:
URL: https://github.com/apache/shardingsphere/issues/9811#issuecomment-809908451
> can i handle this?
@Kelson9 Welcome!!! I will assign this issue to 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.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [shardingsphere] Kelson9 commented on issue #9811: java.lang.IndexOutOfBoundsException occurs in mysql "join" query
Posted by GitBox <gi...@apache.org>.
Kelson9 commented on issue #9811:
URL: https://github.com/apache/shardingsphere/issues/9811#issuecomment-808968020
can i handle this?
--
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