/** * Close query and all associated resources * * @throws SQLException something bad happened */ public void close() throws SQLException { try { try { session.commitTransaction(); } catch (SQLException e) { session.endTransaction(); } } finally { session.close(); } }