- 3,734,166 Users
- 2,246,899 Discussions
- 7,857,145 Comments
- 380.9K All Categories
- 2.1K Data
- 203 Big Data Appliance
- 1.9K Data Science
- 446.1K Databases
- 220.4K General Database Discussions
- 23 Multilingual Engine
- 506 MySQL Community Space
- 459 NoSQL Database
- 7.7K Oracle Database Express Edition (XE)
- 2.8K ORDS, SODA & JSON in the Database
- 438 SQLcl
- 3.9K SQL Developer Data Modeler
- 185.4K SQL & PL/SQL
- 20.8K SQL Developer
- 291.3K Development
- 6 Developer Projects
- 117 Programming Languages
- 288.1K Development Tools
- 96 DevOps
- 3K QA/Testing
- 645.2K Java
- 18 Java Learning Subscription
- 36.9K Database Connectivity
- 148 Java Community Process
- 104 Java 25
- 22.1K Java APIs
- 137.7K Java Development Tools
- 165.3K Java EE (Java Enterprise Edition)
- 12 Java Essentials
- 138 Java 8 Questions
- 85.9K Java Programming
- 79 Java Puzzle Ball
- 65.1K New To Java
- 1.7K Training / Learning / Certification
- 13.8K Java HotSpot Virtual Machine
- 94.2K Java SE
- 13.8K Java Security
- 195 Java User Groups
- 179 LiveLabs
- 34 Workshops
- 10.2K Software
- 6.7K Berkeley DB Family
- 3.5K JHeadstart
- 5.7K Other Languages
- 2.3K Chinese
- 165 Deutsche Oracle Community
- 1.2K Español
- 1.9K Japanese
- 225 Portuguese
Atomic transaction between Web Services (ws-at and ws-coor) deployed on Glassfish 188.8.131.52
We use atomic transaction between Web Services (ws-at and ws-coor) deployed on Glassfish. In the Glassfish version 2.1.1 everything works and in the version 3.1.2 it’s not working.
We use the following flow:
• A client application (Java servlet), that creates a global transaction and invokes a web service that creates a record in an Oracle database and returns the id just created for the client application.
• After that the same client application invokes a second web service in the same transactional context using the id of the record created in the first web service to make a query of that record, in the glassfish version 2.1.1 the web service finds the record, in the Oracle Glassfish application server 184.108.40.206 it doesn’t find it.
The web services were developed with:
• Java 1.7
• Session Ejb Stateless with a CMT EntityManager with hibernate 4, to make the query and to persist the record.
• The session Ejb was published like a web service using the annotations for implementing the ws-at:
• In the application server a connection pool was created for the jndi TESTEXA, with the xa driver of oracle.
Also the same application was tested on Glassfish 4, and we got the same result, the second web service doesn’t find the record created by the first web service.
We made another test, configuring the jvm option on the glassfish:
-DALLOW_MULTIPLE_ENLISTS_DELISTS=true (the default is false).
That option makes that the second web service sees the data persisted by the first web service, but it happens only because with that option the data of the first web service is persisted to the data base just after the invocation of the first web service ends, and not at the end of the global transaction, because of that when an exception is throw on the second web service the data created in the first web services doesn’t rollback.
We need help to know the configuration differences between the two versions of Glassfish( Glassfish 2.1.1 and Glassfish 3.1.2) , required for using Ws-AT e WS-Coor , and the difference that may exist in the configuration of the connection pool, i think that is impossibel that it doen't work on glassfish 3.1.2 and works on 2.1.1, anyone can help me with this plz? , we have a client that is watting for alone time for upgrade of glassfish version.