14 Jun
2013
14 Jun
'13
7:28 a.m.
On 14/06/13 12:12, Arran Cudbard-Bell wrote:
On 14 Jun 2013, at 11:55, Phil Mayers <p.mayers@IMPERIAL.AC.UK> wrote:
In 3.0, is there a way to consider a SQL connection dead if it returns a certain class of errors, then close and re-open it?
The drivers can return SQL_DOWN, which should result in a new connection being established or an existing connection being reserved in the pool and the query being retried.
I'm actually thinking of errors where the SQL server is up, but responding incorrectly (e.g. cached query plans are invalid due to schema changes). I guess there would need to be a per-driver set of options as to which error codes count as "down"?