Why set autoCommit every time? #546

@j256

Description

First off. Thanks so much for HikariCP.

I'm working on transactions and query performance. I'm curious why when someone calls setAutoCommit(...) on the proxy connection why it doesn't see if the connection is already in that mode?

All of my database calls start with SET autocommit=0 and end with SET.autocommit=1 even though I configure the pool with default autocommit set to false. Each one of these calls generates (I think) a synchronous JDBC back and forth.

This seems wasteful. Is there be a setting that was smarter than that?