• 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

Performance - XA Vs Non XA

 
Bartender
Posts: 6663
5
MyEclipse IDE Firefox Browser Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is a non XA JDBC driver faster/more efficient than a XA JDBC driver ?

I am considering shifting some data sources to use XA drivers. They participate in cross database transactions. However the part of code where they participate in cross database transactions is not very large (a few scenarios only). My question is, would making this data source use a XA driver all the time bring down the performance ? If so are there any studies or recommendations to back that ?

My other option is to split the data source to XA and non XA types if performance is of concern
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There has to be some overhead to using an XA driver rather than a non XA driver. What database are you using?

I have found that changing to SQL Servers XA driver to to the had a very bad impact in performance, it caused a significant increase in database locking under load. Fortunately I was using Weblogic which allows you to emulate XA for 1 non XA datasource so there was no need to use the SQL Server XA driver, it might be worth checking your application servers documentation for a similar feature.
 
Deepak Bala
Bartender
Posts: 6663
5
MyEclipse IDE Firefox Browser Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by jimmy jones:
There has to be some overhead to using an XA driver rather than a non XA driver. What database are you using?

I have found that changing to SQL Servers XA driver to to the had a very bad impact in performance, it caused a significant increase in database locking under load. Fortunately I was using Weblogic which allows you to emulate XA for 1 non XA datasource so there was no need to use the SQL Server XA driver, it might be worth checking your application servers documentation for a similar feature.



I am using weblogic 9. However the emulate 2 phase commit option is kinda like a dummy implementation of a XA resource. In other words if your resource fails a transaction it will still say that it is prepared to commit and the other parties in the transaction will commit as well. It could lead to some inconsistencies in the application.

I cannot use the emulate option here since I am opening a transaction and allowing it to span across two databases. If I emulate the 2PC I get an error that says I am not allowed to make two non XA resource take part in a transaction involving two different databases. I initially thought that the emulate option would bypass any such errors. Oh well. I guess I ll split the datasource to XA and non XA types to avoid any performance problems.

I am using Sybase by the way
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic