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

Remove retrieval of sql counts on execute in GDS layer [JDBC482] #521

Closed
firebird-issue-importer opened this issue Mar 7, 2017 · 6 comments
Closed

Comments

@firebird-issue-importer
Copy link

@firebird-issue-importer firebird-issue-importer commented Mar 7, 2017

Submitted by: @mrotteveel

We currently always retrieve SQL counts on execute in the GDS layer, instead we should only retrieve it when JDBC requires it (ie: when using executeUpdate, or with an explicit call of getUpdateCounts).

In earlier versions this made sense because we pipelined the count request immediately after the execute, but since adding cancellation support we had to split that again into separate request/response pairs. Only explicitly requesting this when needed may have a small performance benefit.

Commits: 1204a26 c56795a

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Mar 7, 2017

Commented by: @mrotteveel

Consider including for 3.0, if it requires too much restructuring, then delay to 3.1.

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Mar 7, 2017

Modified by: @mrotteveel

Fix Version: Jaybird 3.0.0 [ 10440 ]

Fix Version: Jaybird 3.1 [ 10441 ]

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Mar 11, 2017

Commented by: @mrotteveel

Current code already obtains update count if it wasn't retrieved previously, so I deleted the low-level getSqlCounts immediately after execute and after fetching all rows.

This should restore the behavior as it was in Jaybird 2.2, and result in a minor performance improvement when processing result sets, but never obtaining update counts, or when using execute() instead of executeUpdate() (eg when not interested in update counts).

As part of this I also fixed in bug with `getMoreResults()` that did not correctly handle closing of a result set (or server side cursor) if the result set had never been obtained from the statement (eg when using execute, but not calling getResultSet).

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Mar 11, 2017

Modified by: @mrotteveel

Fix Version: Jaybird 3.1 [ 10441 ] =>

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented Mar 11, 2017

Modified by: @mrotteveel

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

@firebird-issue-importer
Copy link
Author

@firebird-issue-importer firebird-issue-importer commented May 7, 2017

Modified by: @mrotteveel

status: Resolved [ 5 ] => Closed [ 6 ]

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