-
Notifications
You must be signed in to change notification settings - Fork 6.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Encryption rules do not support uppercase fields #3309
Comments
Caused by: org.apache.ibatis.exceptions.PersistenceException:
### Error updating database. Cause: java.lang.ArrayIndexOutOfBoundsException: -1
### The error may involve com.mlt.demo.mapper.SysUserMapper.saveSysUser-Inline
### The error occurred while setting parameters
### SQL: insert into SYS_USER (ID, NAME, AGE) values (?, ?, ? )
### Cause: java.lang.ArrayIndexOutOfBoundsException: -1
at org.apache.ibatis.exceptions.ExceptionFactory.wrapException(ExceptionFactory.java:30)
at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:200)
at org.apache.ibatis.session.defaults.DefaultSqlSession.insert(DefaultSqlSession.java:185)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.mybatis.spring.SqlSessionTemplate$SqlSessionInterceptor.invoke(SqlSessionTemplate.java:433)
... 46 more
Caused by: java.lang.ArrayIndexOutOfBoundsException: -1
at java.util.ArrayList.elementData(ArrayList.java:422)
at java.util.ArrayList.get(ArrayList.java:435)
at org.apache.shardingsphere.core.preprocessor.segment.insert.InsertValueContext.getValue(InsertValueContext.java:86)
at org.apache.shardingsphere.core.rewrite.feature.encrypt.parameter.impl.EncryptInsertValueParameterRewriter.encryptInsertValues(EncryptInsertValueParameterRewriter.java:75)
at org.apache.shardingsphere.core.rewrite.feature.encrypt.parameter.impl.EncryptInsertValueParameterRewriter.rewrite(EncryptInsertValueParameterRewriter.java:63)
at org.apache.shardingsphere.core.rewrite.feature.encrypt.context.EncryptSQLRewriteContextDecorator.decorate(EncryptSQLRewriteContextDecorator.java:43)
at org.apache.shardingsphere.shardingjdbc.jdbc.core.statement.EncryptPreparedStatement.getSQLUnit(EncryptPreparedStatement.java:157)
at org.apache.shardingsphere.shardingjdbc.jdbc.core.statement.EncryptPreparedStatement.execute(EncryptPreparedStatement.java:127)
at org.apache.ibatis.executor.statement.PreparedStatementHandler.update(PreparedStatementHandler.java:46)
at org.apache.ibatis.executor.statement.RoutingStatementHandler.update(RoutingStatementHandler.java:74)
at org.apache.ibatis.executor.SimpleExecutor.doUpdate(SimpleExecutor.java:50)
at org.apache.ibatis.executor.BaseExecutor.update(BaseExecutor.java:117)
at org.apache.ibatis.executor.CachingExecutor.update(CachingExecutor.java:76)
at org.apache.ibatis.session.defaults.DefaultSqlSession.update(DefaultSqlSession.java:198)
... 52 more |
Please assign me to fix this bug.(I have the same problem when i use encrypt jdbc but i had fixed it and now the code is running in product environment) @terrymanu |
@HongJinFeng |
Thanks, It may on weaekend because still need to work on weekday. |
This was referenced Dec 22, 2019
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Bug Report
Which version of ShardingSphere did you use?
4.0.0-RC3-SNAPSHOT
Which project did you use? Sharding-JDBC or Sharding-Proxy?
Sharding-JDBC
Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.
Sql:
Config:
error:
The text was updated successfully, but these errors were encountered: