|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Bug with getJDBCType4Connection ? |
« View previous topic :: View next topic » |
Author |
Message
|
McueMart |
Posted: Thu Mar 12, 2015 7:39 am Post subject: Bug with getJDBCType4Connection ? |
|
|
 Chevalier
Joined: 29 Nov 2011 Posts: 490 Location: UK...somewhere
|
Hi all,
I am getting a JDBC connection using the getJDBCType4Connection(..) function (this is connecting to a SolidDB database...but that isn't particularly relevant to this query).
Intermittently we see an error in our DB log which shows that the JDBC connection between the broker and DB has been disconnected. I need to follow up the cause of this error with the DB vendor, but again, I don't think this is relevant to my question...
Here is a snippet of code we are using:
Code: |
private void setupDB() throws SQLException, MbException{
jdbcConnection = getJDBCType4Connection(MyDSN,JDBC_TransactionType.MB_TRANSACTION_AUTO);
if(jdbcConnection.isClosed()){
throw new MbUserException("JDBC_Test", "setupDB", "BIPXXX", "1001", "Attempt to use a closed connection returned from getJDBCType4Connection", null);
}
setupPreparedStatements();
} |
The real problem is that we are having this MbUserException thown implying that getJDBCType4Connection is returning a CLOSED connection to the broker thread.
Surely this wouldn't be the intended design. I'm surprised that within brokers connection management implementation, it isn't checking isClosed() before passing the connection to the runtime thread.
Could anyone comment on whether they think that this could possibly be intended, or whether they think it's PMR time?
Using WMB 8.0.0.4 on Linux.
Thanks. |
|
Back to top |
|
 |
fjb_saper |
Posted: Thu Mar 12, 2015 8:15 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
Isn't that the same as an MQ Connection broken (2009).
When you requested the connection, everything was AOK and you got the connection. By the time you want to use it it is broken and closed...  _________________ MQ & Broker admin |
|
Back to top |
|
 |
McueMart |
Posted: Thu Mar 12, 2015 8:20 am Post subject: |
|
|
 Chevalier
Joined: 29 Nov 2011 Posts: 490 Location: UK...somewhere
|
Hrm - I wouldnt have thought so. If we keep invoking the flow, the same broken connection keeps getting returned on the getJDBCType4Connection() call.
My gut feeling is that because the connection 'break' occurred within user code (which I think is a defect relating to the JDBC driver) , the broker isn't detecting the connection break, and so happily keeps returning it as if it's a functioning connection. |
|
Back to top |
|
 |
fjb_saper |
Posted: Thu Mar 12, 2015 8:33 am Post subject: |
|
|
 Grand High Poobah
Joined: 18 Nov 2003 Posts: 20756 Location: LI,NY
|
PMR time? _________________ MQ & Broker admin |
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|