This section covers the features of GemFire transactions.
- Basic transaction properties: atomicity, consistency, isolation, and durability
- Rollback and commit operations along with standard GemFire cache operations
- Ability to suspend and resume transactions
- High concurrency and high performance
- Transaction statistics gathering and archiving
- Compatibility with Java Transaction API (JTA) transactions, using either GemFire JTA or a third-party implementation.
- Ability to use GemFire as a “last resource” in JTA transactions with multiple data sources to guarantee transactional consistency
Types of Transactions
GemFire supports two kinds of transactions: GemFire cache transactions and JTA global transactions.
GemFire cache transactions are used to group the execution of cache operations and to gain control offered by transactional commit and rollback. Applications create cache transactions by using an instance of the GemFire CacheTransactionManager to start and terminate transactions. During the transaction, cache operations are performed and distributed through GemFire as usual. See GemFire Cache Transactions for details on GemFire cache transactions and how these transactions work.
JTA global transactions allow you to use the standard Java interface (JTA) to coordinate GemFire transactions with JDBC transactions. When performing JTA global transactions, you have the option of usingGemFire’s own implementation of JTA or a third party’s implementation (typically application servers like WebLogic or JBoss) of JTA. In addition, some third party JTA implementations allow you to set GemFire as a “last resource” to ensure transactional consistency across data sources in the event that GemFire or another data source becomes unavailable. For global transactions, applications use java:/UserTransaction to start and terminate transactions while GemFire cache operations are performed in the same manner as regular GemFire cache transactions. See JTA Global Transactions with GemFire for details on JTA Global transactions.