Issue Details (XML | Word | Printable)

Key: OPENJPA-93
Type: New Feature New Feature
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Patrick Linskey
Reporter: Patrick Linskey
Votes: 1
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
OpenJPA

Sequence generation in a JTA environment should not require non-JTA datasource

Created: 30/Dec/06 01:11 AM   Updated: 01/Mar/07 02:13 AM
Return to search
Component/s: jdbc
Affects Version/s: None
Fix Version/s: 0.9.7

Time Tracking:
Not Specified

Resolution Date: 01/Mar/07 01:18 AM


 Description  « Hide
When obtaining non-transactional sequence numbers in a JTA environment when no non-jta-data-source or JDBC connection information is supplied, OpenJPA should suspend the current transaction, perform the sequence maintenance in a new transaction, commit, and resume the suspended transaction.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Patrick Linskey added a comment - 30/Dec/06 01:23 AM
svn r491147 includes code changes that have been tested in WebLogic Server. The feature is not yet documented. The behavior is as follows: if no non-JTA datasource is available and the current environment is managed, OpenJPA will suspend the current transaction, begin a new transaction, do the sequence work, commit, and resume the original transaction. This code makes some thread-safety assumptions that should be valid in a JTA environment, since JTA transactions are inherently thread-bound.

Patrick Linskey added a comment - 31/Jan/07 05:36 PM
Has anyone tested this on non-WLS appservers?

Patrick Linskey added a comment - 01/Mar/07 01:18 AM
The feature works, but OPENJPA-149 currently prevents it from working in a WebSphere environment in a default configuration. See OPENJPA-149 for a workaround.