Subject Re: [IB-Java] JDBC connections again
Author David Warnock
David,

> Well, actually there is another alternative.. you could wrap the legacy
> jdbc drivers in a jca wrapper. There are at least 2: the Sun blackbox jdbc
> wrappers, which are the closest thing Sun supplied to a reference
> implementation, and the Minerva/jboss ones, available from the jboss site.
> If you need many connections I would seriously investigate this, since it
> is straightforward to add pooling to this setup.


Well yes I could but it is less work to change one driver than to change
all applications.


>>We have a good connection pool that has proved stable over many years.
>>
>
> Did you write it or is it available in some way?


It is LGPL'd as part of our GPL fundraising application for charities.
www.visres.org


>>1. The FBUnmanaged connection to work correctly with autocommit
>>
>
> There are plenty of autocommit problems even with the jca stuff, I have
> learned. The spec authors added some stuff about this in the final
> release. I need to take a look at this. It should result in autocommit
> working for unmanaged connections as well. We may be able to eliminate the
> unmanaged connection as a separate entity.


In one sense this is not too much of a worry actually as we never use
autocommit, but it could provide some nasty side effects so would be
good to fix.


>>2. A way of providing a connection so that the following will work.
>>
>> Class.forName(interbase.interclient.Driver);
>>
>> java.util.Properties connectionProperties =
>> new java.util.Properties ();
>> connectionProperties.put ("charSet", "UTF8");
>> connectionProperties.put ("user", "sysdba");
>> connectionProperties.put ("password", "masterkey");
>>
>> con = ( DriverManager.getConnection("url",
>> connectionProperties) );
>>
>
> Well, as written you are asking for interclient;-).


It was late ;-)


> I'm not sure it's possible to set the charSet in this way,


H'mm, is there another way? We use unicode everywhere.

> but I believe
> the rest works. Look in org.firebirdsql.jdbc.TestUnmanagedConnection.java
> for examples.


Thanks, I will build up from that.

Dave