(PDB-707) Fix bonecp 57P01 handling

This patch adds retry handling for 57P01 failures, which result in an
PSQLException with a status code of 08003. The patch has been made
forward compatible by catching all SQLExceptions with this status code.

Version 0.8.0-RELEASE of Bonecp does not throw the correct sql state code
today, however a patch has been raised to make this happen so we can
upgrade to this version in the future.

Signed-off-by: Ken Barber <ken@bob.sh>
(cherry picked from commit 6d58dbfc8873166704ff60411bfa77f4dedf9f55)
Merge branch 'stable'

* stable:
  (PDB-707) Fix bonecp 57P01 handling