On QueryException provide the ability to get the connection back out for reuse
commit28ea2af8d07c047795da1f632f87a3c122e8e128
authorJay Edgar <jkedgar@meta.com>
Sat, 11 May 2024 00:37:35 +0000 (10 17:37 -0700)
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>
Sat, 11 May 2024 00:37:35 +0000 (10 17:37 -0700)
treea751924c8a1738226e07b86070beccc660b35553
parentc3684f68fb6124dde0cba521f2fd64c764337bf2
On QueryException provide the ability to get the connection back out for reuse

Summary:
The existing Squangle implementation does not give a connection back to the client when an exception occurs.  This means that on a simple error like a syntax error or --read-only error the client has to generate a new connection to do more work.

We should provide the option of continuing to use the connection (provided the error wasn't a lost connection).

Differential Revision: D52610876

fbshipit-source-id: 8485b209d2d0c4b3edd784492872bca164d4be18
third-party/squangle/src/squangle/mysql_client/Connection.cpp
third-party/squangle/src/squangle/mysql_client/Connection.h
third-party/squangle/src/squangle/mysql_client/ConnectionPool.h
third-party/squangle/src/squangle/mysql_client/DbResult.cpp
third-party/squangle/src/squangle/mysql_client/DbResult.h
third-party/squangle/src/squangle/mysql_client/MysqlClientBase.h
third-party/squangle/src/squangle/mysql_client/Operation.cpp
third-party/squangle/src/squangle/mysql_client/Operation.h
third-party/squangle/src/squangle/mysql_client/SemiFutureAdapter.cpp