2008 East
DIAMOND SPONSOR:
Data Direct
Frontiers in Data Access: The Coming Wave in Data Services
PLATINUM SPONSORS:
Red Hat
The Opening of Virtualization
Intel
Virtualization – Path to Predictive Enterprise
Green Hills
IT Security in a Hostile World
JBoss / freedom oss
Practical SOA Approach
GOLD SPONSORS:
Software AG
The Art & Science of SOA: How Governance Enables Adoption
PlateSpin
Effective Planning for Virtual Infrastructure Growth
Fujitsu
Automated Business Process Discovery & Virtualization Service
Ceedo
Workspace Virtualization
Click For 2007 West
Event Webcasts

2008 East
PLATINUM SPONSORS:
Appcelerator
Think Fast: Accelerate AJAX Development with Appcelerator
GOLD SPONSORS:
DreamFace Interactive
The Ultimate Framework for Creating Personalized Web 2.0 Mashups
ICEsoft
AJAX and Social Computing for the Enterprise
Kaazing
Enterprise Comet: Real–Time, Real–Time, or Real–Time Web 2.0?
Nexaweb
Now Playing: Desktop Apps in the Browser!
Sun
jMaki as an AJAX Mashup Framework
POWER PANELS:
The Business Value
of RIAs
What Lies Beyond AJAX?
KEYNOTES:
Douglas Crockford
Can We Fix the Web?
Anthony Franco
2008: The Year of the RIA
Click For 2007 Event Webcasts
Service Oriented Architecture (SOA) has been discu...
TOP THREE LINKS YOU MUST CLICK ON


Java Developer's Journal Feature: "Deadlocks in J2EE"
Most non-trivial applications involve high degrees of concurrency and many layers of abstraction. Concurrency is associated with resource contention and an increase in deadlock conditions. The multiple layers of abstraction make it more difficult to isolate and fix the deadlock conditions.
Reader Feedback: Page 1 of 1

Thanks for this great article, Mike. I wasn't able to make it to JavaOne this year so I missed your BOF at JavaOne that looks like it was talking about this stuff (BOF-0534). Are there any slides from that that I can get ahold of?

With the power and simplicity that CMT (container managed transactions) brings, is there really no simple way to automatically handle database deadlock by retrying the transaction according to some given parameters (ie: number of retries, back off time, etc)? That would really be unfortunate.

Here are a few possible solutions, but they all seem sub-optimal for various reasons: (I would like to stay within the spec (EJB3/JEE5), but I'm not adament on this).

1) JBoss has a proprietary extension for this: (org.jboss.ejb.plugins.TxRetryExceptionHandler) However, besides being outside the spec, this implementation does not allow me to easily keep track of any state regarding the retry (ie: retry count numbers, data for back off algorithms, etc.).

2) I can use the EJB3 Interceptor spec, but this is really cumbersome because it ties in *after* the CMT stuff has already been setup.

3) I'm sure I could write a jboss-aop interceptor that would do the right thing here, but again it would be outside the spec. Has anyone done this already? I certainly don't want to reinvent the wheel on this one.

4) I could switch from CMT (container managed transactions) to BMT (bean managed transactions). This would give me more control over the the transaction endpoints but then I would have to give up all the niceties that CMT give me.

I really would like a nice solution for this...

Most non-trivial applications involve high degrees of concurrency and many layers of abstraction. Concurrency is associated with resource contention and an increase in deadlock conditions. The multiple layers of abstraction make it more difficult to isolate and fix the deadlock conditions.


FEATURED WHITE PAPERS
YOUR FEEDBACK
Mark Blafkin wrote: IBM's 'newfound principles" may be basically supported by the closed online discussion they sponsored, but they are undoubtedly "inspired" by profit and an effort to regain their stranglehold on standards bodies. If they really cared about improving standards bodies for all stakeholders, they wouldn...
Roberto Campione wrote: Good article, that helped alot. Out of interest - have you any examples of importing templates using xmlaccess?
Java Consultant wrote: Good Post.... Java Developer...
Java Web Development Company wrote: Hi, Good Post.. Thanks
Chris DiBona wrote: You meant charles dibona not chris.
SUBSCRIBE TO THE WORLD'S MOST POWERFUL NEWSLETTERS
SYS-CON FEATURED WHITEPAPERS

Since its emergence, Web Service technology has gone a long way towards perfecting itself and findin...
Join Scott Guthrie as he discusses Microsoft’s commitment to web standards development, Rich Inter...
Reminding people of how its backing was the making of Linux, IBM, to no one's surprise, has thrown i...
Service oriented architecture (SOA) could revolutionize the way we think about IT. Why is that possi...
Virtualization has become a critical part of Enterprise IT strategy. Why and how has it become one o...
Watching VMware stock and its market cap spike since it IPO'd must have had Red Hat positively pea g...
IBM announced that Vantage Deluxe World Travel has increased sales and improved business operations ...
The AJAX for IBM WebSphere Platform Early Program is an optionally installable product extension for...
Unify announced the expansion of its Composer for Lotus Notes solution through a partnership with CA...
IBM claims to have created new species of custom-built, industry-standard, Linux-based rack server f...
A standard from OASIS called Web Services for Remote Portlets (WSRP) is used so portlets can be deco...
Genuitec announced the availability of MyEclipse 6.5 Blue Edition; a next-generation ALM and open so...
ZSL announced its Enterprise 2.0 Computing Framework built on IBM WebSphere sMash and Service Orient...
SYS-CON's upcoming '3rd International Virtualization Conference & Expo' faculty includes such distin...
From Application Virtualization to Xen, a round-up of the virtualization themes & topics being discu...
Red Hat is a trusted open source provider. Red Hat offers enterprise customers a long-term plan fo...
IBM announced that businesses are taking advantage of WebSphere Virtual Enterprise to manage softwar...
IBM announced two new advances in the insurance industry - a solution for improving operational effi...
ParAccel announced it has entered into an original equipment manufacturer (OEM) agreement with IBM. ...
Micro Focus announced the availability of SOA Express 8.0. The new version adds support for direct d...
ADS BY GOOGLE