handle.getConnection().setAutoCommit(stuff.getInitialAutocommit());
stuff.getCheckpoints().clear();
}
}
catch (SQLException e) {
throw new TransactionException("Failed to rollback transaction", e);
}
finally {
// prevent memory leak if rollback throws an exception
if (localStuff.containsKey(handle)) {
localStuff.remove(handle);