• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Help with Determining Cause of Error Messages

 
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi All,

I have started to see a new error in our application. In this application, we spawn new threads for each MQ message received, and the steps provided below is what we do on each thread. During my research, I found that this may be a thread safe issue. A brief description of what we do in the class that is generating this error:

1.Begin DB transaction
2.Insert/Update to DB
3.If Successful, Commit DB transaction
4.If Failure, Rollback DB transaction
5.Finally clause, whether an error occurs or not, we call a connection cleanup class that should close the connection. (This is the section which throws the following error regardless of previous DB transaction failure or success)

Have anyone seen this issue before, and if so, please advise what could be causing this.

Thanks,
Lulu
***********************************************************************
[4/14/05 1:12:41:325 CDT] 189856ab
MCWrapper E J2CA0081E: Method cleanup
failed while trying to execute method cleanup
on ManagedConnection
com.ibm.ws.rsadapter.spi.WSRdbManagedConnection
Impl@6fecd6a7 from resource
jdbc/TMTPDataSource. Caught exception:
com.ibm.ws.exception.WsException: DSRA0080E:
An exception was received by the Data Store
Adapter. See original exception message:
Cannot call 'cleanup' on a ManagedConnection
while it is still in a transaction..
 
Ranch Hand
Posts: 809
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you can provide the stacktrace, then it would be easy to trace the problem.

Anyway following piece of code will work.




Naseem
[ September 07, 2006: Message edited by: Naseem Khan ]
 
Elle Atechsy
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes. I am already doing what you suggested.

Here is the stack trace:

 
Naseem Khan
Ranch Hand
Posts: 809
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Here is one article on ibm, just go through it and let us know if this works.

http://www-1.ibm.com/support/docview.wss?rs=493&context=SWK90&uid=swg1IY71886

Naseem
 
Elle Atechsy
Ranch Hand
Posts: 96
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Unfortunately, I don't have access to the environment. So, I will post back as soon as I can get another group in our company to implement this update.

Thanks!
 
He was expelled for perverse baking experiments. This tiny ad is a model student:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic