Results 1 to 9 of 9
  1. #1
    Join Date
    Mar 2007
    Posts
    86

    Unanswered: jBoss XA xact fails

    Using jBoss to manage 2-phase commit across 2 databases on same server.
    sp_transactions shows, the first thread begun and attached .. 10 threads opened on first db, 10 open on second db .. at that point jBoss hangs .. and times out after several minutes .. no errors in sybase log, and no table locks shown by sp_lock .. all dtm configs and roles are correct on server side .. when changing jBoss to local, it works fine .. when using RPC it behaves poorly. Anyone well versed in jBoss, please fire off any intelligent suggestions where I can check .. the error messages out of the class are not helpful .. it confirms a timeout .. that's all.

  2. #2
    Join Date
    Sep 2003
    Location
    Switzerland
    Posts
    443
    Your questions are not clear to be honest atleast for a DBA... Did you try the jBoss sites? Can you see the 10 connections open in Sybase? And is it the 11th connection which hangs always ?
    BTW Im assuming you meant Sybase ASE and NOT sybase IQ or ASA.

    Quote Originally Posted by stuarta
    Using jBoss to manage 2-phase commit across 2 databases on same server.
    sp_transactions shows, the first thread begun and attached .. 10 threads opened on first db, 10 open on second db .. at that point jBoss hangs .. and times out after several minutes .. no errors in sybase log, and no table locks shown by sp_lock .. all dtm configs and roles are correct on server side .. when changing jBoss to local, it works fine .. when using RPC it behaves poorly. Anyone well versed in jBoss, please fire off any intelligent suggestions where I can check .. the error messages out of the class are not helpful .. it confirms a timeout .. that's all.
    Last edited by trvishi; 06-02-09 at 17:06.

  3. #3
    Join Date
    Mar 2007
    Posts
    86

    jBoss using hibernate

    Using ASE 15.0.2 on AIX 5.3 ..
    Actually it fails even with 1 connection attached to each database. The attach is apparant after fthe first read, but the first read attempt on the second db pipe hangs, and times out. This is a functional test, to simply test the framework, and issue rollback across the two db's using 2-phase commit. The messaging from jBoss leads to no specific cause. I was wondering if anyone has done this successfully. We believe it may be a jBoss configuration. I'm guessing the seond read is being issued against the wrong database for some reason, but that's just a guess based on the type of failure .. seems like a results pending issue, but not confirmed. I'm going to set up Ribo when I get a chance and work with the developer to see what Hibernate is issuing under the covers.

  4. #4
    Join Date
    Sep 2003
    Location
    Switzerland
    Posts
    443
    I have to say Im a DBA and not a pro with any of the java issues and you will most likely see that trend in this site.

    Having said that, I did see some issues between chained and unchained with some of our users @ work recently with the latest jConnect drivers. Dont know if its even related to yours, but worth checking.

    Also, check the default db of the login. It can only have one. If you are using 2 dbs in the same instance, you need to explicitly mention the full qualifier or switch databases in code.

    Quote Originally Posted by stuarta
    Actually it fails even with 1 connection attached to each database. The attach is apparant after fthe first read, but the first read attempt on the second db pipe hangs, and times out. This is a functional test, to simply test the framework, and issue rollback across the two db's using 2-phase commit. The messaging from jBoss leads to no specific cause. I was wondering if anyone has done this successfully. We believe it may be a jBoss configuration. I'm guessing the seond read is being issued against the wrong database for some reason, but that's just a guess based on the type of failure .. seems like a results pending issue, but not confirmed. I'm going to set up Ribo when I get a chance and work with the developer to see what Hibernate is issuing under the covers.

  5. #5
    Join Date
    Sep 2003
    Location
    Switzerland
    Posts
    443
    BTW

    Ribo is a good idea.

  6. #6
    Join Date
    Mar 2007
    Posts
    86

    Chained is worth checking

    I'm a DBA as well, trying to help out the developer on this one. The db connections are supposed to be transparant, handled by jBoss - Hibernate. They work as far as opening the initial pools (10 on each db).. we tested with 1 connection on each db, then 10, but no change. I think the db currency is the issue on the read .. it seems like it, but no one knows how to debug this, except by using a TDS packet sniffer. If you''ve ever used Ribo, it's pretty primitive .. but a last resort when I free up with production deployments. Thanks again, and have a great day.

  7. #7
    Join Date
    Sep 2003
    Location
    Switzerland
    Posts
    443
    Then chained check is worth checking coz by default jConnect does a begin/end tran even for a select

    I didnt try it for this issue, but try setting this on and it will give u some idea on the ASE errorlog. P.S. Make sure to turn it off when u r done.

    dbcc traceon(11201,11202,11203,11204,11205,11206)

  8. #8
    Join Date
    Sep 2003
    Location
    Switzerland
    Posts
    443
    Also investigate on SERVER_INITIATED_TRANSACTIONS. I had an open case with Sybase about this as the behaviour seemed to have changed with the latest jConnect drivers, but the developer I tried to help just went in thin air, so couldnt follow up much. BTW, Sybase Engineering asked for a Ribo output as well...

  9. #9
    Join Date
    May 2008
    Location
    Cambridge
    Posts
    26
    It would be nice to get to the bottom of this one. We also experienced strange behaviour relating to Hibernate. Connections would come in and then just sit there mid-transaction without completing. Other spids would then queue up behind the inactive spid. In our case, sp_lock did actually show relevant output. Issue was never resolved and we were forced to kill the offending spids on a regular basis.
    Bob Holmes
    Sybase ASE/Replication Server Administrator
    Digital Data Safe - managed database services
    Email: bob.holmes@ddsafe.co.uk

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •