HHH-13524 Remove unused fields xref,unassociatedResultSets from JdbcCoordinatorImpl

This commit is contained in:
Sanne Grinovero 2019-07-30 11:35:30 +01:00 committed by Sanne Grinovero
parent 701bd1ff7e
commit 93e882a427
1 changed files with 0 additions and 22 deletions

View File

@ -67,13 +67,9 @@ public class JdbcCoordinatorImpl implements JdbcCoordinator {
private transient long transactionTimeOutInstant = -1;
private final HashMap<Statement,Set<ResultSet>> xref = new HashMap<>();
private final Set<ResultSet> unassociatedResultSets = new HashSet<>();
private Statement lastQuery;
private final boolean isUserSuppliedConnection;
/**
* If true, manually (and temporarily) circumvent aggressive release processing.
*/
@ -174,7 +170,6 @@ public class JdbcCoordinatorImpl implements JdbcCoordinator {
LOG.closingUnreleasedBatch();
currentBatch.release();
}
cleanup();
}
finally {
connection = logicalConnection.close();
@ -366,23 +361,6 @@ public class JdbcCoordinatorImpl implements JdbcCoordinator {
releasesEnabled = false;
}
private void cleanup() {
for ( Map.Entry<Statement,Set<ResultSet>> entry : xref.entrySet() ) {
closeAll( entry.getValue() );
close( entry.getKey() );
}
xref.clear();
closeAll( unassociatedResultSets );
}
protected void closeAll(Set<ResultSet> resultSets) {
for ( ResultSet resultSet : resultSets ) {
close( resultSet );
}
resultSets.clear();
}
@SuppressWarnings({ "unchecked" })
protected void close(Statement statement) {
LOG.tracev( "Closing prepared statement [{0}]", statement );