[tx-control] Support Connection Test Queries when pooling Fixes ARIES-1692, includes patches from mit_jones with minor tidy-up applied