Skip to content
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

Fixes #2923. #2985

Closed
wants to merge 6 commits into from
Closed

Fixes #2923. #2985

wants to merge 6 commits into from

Conversation

xiyelife
Copy link
Contributor

@xiyelife xiyelife commented Sep 5, 2019

Fixes #2923.

Changes proposed in this pull request:
First, if preparedStatemnt == null in getRoutedStatements(), emptyList will be returned. This step will stop NPE, but set queryTime() actually is not executed, for there is no preparedStatement.
Second, we may cache the value of queryTime() in AbstractStatementAdapter.java. When executeUpdate() or execute() is called, at this time, we relay the action, i.e, setQueryTime().

add the protected  queryTimeout properties
if null == preparedStatement, return the empty statement List
re add the queryTimeout,set it zero when clear paramaters
@coveralls
Copy link

coveralls commented Sep 5, 2019

Pull Request Test Coverage Report for Build 307

  • 5 of 6 (83.33%) changed or added relevant lines in 3 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.01%) to 65.07%

Changes Missing Coverage Covered Lines Changed/Added Lines %
sharding-jdbc/sharding-jdbc-core/src/main/java/org/apache/shardingsphere/shardingjdbc/jdbc/core/statement/EncryptPreparedStatement.java 1 2 50.0%
Totals Coverage Status
Change from base Build 335: 0.01%
Covered Lines: 9208
Relevant Lines: 14151

💛 - Coveralls

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

when using EncryptPreparedStatement to savebatch occours error
3 participants