ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jeff Butler" <jeffgbut...@gmail.com>
Subject Re: StaleConnection handling
Date Tue, 10 Oct 2006 15:41:56 GMT
With WebSphere 6 you no longer need to deal with StaleConnectionException -
WebSphere has support for pretesting the connections.  You need to make sure
that you are not using a V4 datasource, then you can configure WebSphere to
deal with it.  iBATIS, or your code, never needs to know about stale
connections.  Basically, you set up a "ping query" in the WebSphere
configuration.

Here's the page in the WebSphere info center that describes the
configuration:

http://publib.boulder.ibm.com/infocenter/wasinfo/v6r0/index.jsp?topic=/com.ibm.websphere.base.doc/info/aes/ae/tdat_pretestconn.html

Use the search string "pretest sql string" in the info center if the link
doesn't work.

Jeff Butler


On 10/10/06, Torsten Michelmann <torsten.michelmann@gmx.de> wrote:
>
> Hi,
>
> we are running an app on WAS 6 using iBatis 2.1.7 that accesses a database
> on iSeries.
> We use the toolbox driver (
> com.ibm.as400.access.AS400JDBCConnectionPoolDataSource) to perform the
> access to the database.
> In general there is no problem, but in the morning (there is a DB backup
> during the night which causes DB2 to drop all connections) we get a
> com.ibm.websphere.ce.cm.StaleConnectionException on the first operation.
> The following operations will work.
>
> Question: Am I forced to catch the StaleConnectionException and repeat the
> action in my DAO or is there a way to handle this problem by configuration?
> --
> TorstenGMX DSL-Flatrate 0,- Euro* - Überall, wo DSL verfügbar ist!
> NEU: Jetzt bis zu 16.000 kBit/s! http://www.gmx.net/de/go/dsl
>

Mime
View raw message