C3P0ImplUtils.supportsMethod(...) returning true does
not guarantee that the method is supported. In
particular, when using the jconn2.jar (5.5) and Sybase
12.5, setTypeMap() is not actually supported and will
throw an UnsupportedOperationException.
I have attached my fix, which attempts to call the
getter and setter of the property. Note that it hasn't
been rigorously tested, and I'm not sure what the
performance penalties are with this kind of checking.
As a design note, the the supportsMethod information
probably shouldn't be associated with the connection
(as in NewPooledConnection) but should be associated
with the pool of connections - so you only need to
establish method support per pool, rather than per