GigaSpaces XAP 7.0 API

org.openspaces.core.transaction.manager
Class LocalJiniTransactionManager

java.lang.Object
  extended by org.springframework.transaction.support.AbstractPlatformTransactionManager
      extended by org.openspaces.core.transaction.manager.AbstractJiniTransactionManager
          extended by org.openspaces.core.transaction.manager.LocalJiniTransactionManager
All Implemented Interfaces:
Serializable, JiniPlatformTransactionManager, ServiceDetailsProvider, BeanNameAware, DisposableBean, InitializingBean, PlatformTransactionManager

public class LocalJiniTransactionManager
extends AbstractJiniTransactionManager
implements DisposableBean

Spring transaction manager (PlatformTransactionManager using GigaSpaces LocalJiniTransactionManager.

Local transaction manager is high performance single space transaction manager and should be used in most if not all space related operations.

The local transaction manager also allows for most transaction isolation levels excluding SERIALIZABLE. This is automatically applied when using this transaction manager in conjunction with GigaSpace API.

Author:
kimchy
See Also:
LocalTransactionManager, Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class org.openspaces.core.transaction.manager.AbstractJiniTransactionManager
AbstractJiniTransactionManager.JiniTransactionObject
 
Nested classes/interfaces inherited from class org.springframework.transaction.support.AbstractPlatformTransactionManager
AbstractPlatformTransactionManager.SuspendedResourcesHolder
 
Field Summary
 
Fields inherited from class org.openspaces.core.transaction.manager.AbstractJiniTransactionManager
beanName, SERVICE_TYPE
 
Fields inherited from class org.springframework.transaction.support.AbstractPlatformTransactionManager
logger, SYNCHRONIZATION_ALWAYS, SYNCHRONIZATION_NEVER, SYNCHRONIZATION_ON_ACTUAL_TRANSACTION
 
Constructor Summary
LocalJiniTransactionManager()
           
 
Method Summary
protected  void applyIsolationLevel(AbstractJiniTransactionManager.JiniTransactionObject txObject, int isolationLevel)
           
 void destroy()
           
 net.jini.core.transaction.server.TransactionManager doCreateTransactionManager()
          Returns a new LocalTransactionManager using the provided setSpace(com.j_spaces.core.IJSpace).
 ServiceDetails[] getServicesDetails()
          Retruns one or more service details that the service exposes.
 void setClustered(Boolean clustered)
          Sets if this local transaction manager will work on top of a clustered Space, or will work directly with a cluster memeber.
 void setSpace(IJSpace space)
          Sets the Space that will be used when working with the local transaction manager.
 
Methods inherited from class org.openspaces.core.transaction.manager.AbstractJiniTransactionManager
afterPropertiesSet, convertJiniException, doBegin, doCleanupAfterCompletion, doCommit, doGetTransaction, doJiniBegin, doResume, doRollback, doSetRollbackOnly, doSuspend, getBeanName, getTransactionalContext, getTransactionManager, isExistingTransaction, logMessage, setBeanName, setCommitTimeout, setLeaseRenewalConfig, setRollbackTimeout, setTransactionalContext, useSavepointForNestedTransaction
 
Methods inherited from class org.springframework.transaction.support.AbstractPlatformTransactionManager
commit, determineTimeout, getDefaultTimeout, getTransaction, getTransactionSynchronization, invokeAfterCompletion, isFailEarlyOnGlobalRollbackOnly, isGlobalRollbackOnParticipationFailure, isNestedTransactionAllowed, isRollbackOnCommitFailure, isValidateExistingTransaction, newTransactionStatus, prepareForCommit, registerAfterCompletionWithExistingTransaction, resume, rollback, setDefaultTimeout, setFailEarlyOnGlobalRollbackOnly, setGlobalRollbackOnParticipationFailure, setNestedTransactionAllowed, setRollbackOnCommitFailure, setTransactionSynchronization, setTransactionSynchronizationName, setValidateExistingTransaction, shouldCommitOnGlobalRollbackOnly, suspend, triggerBeforeCommit, triggerBeforeCompletion
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.springframework.transaction.PlatformTransactionManager
commit, getTransaction, rollback
 

Constructor Detail

LocalJiniTransactionManager

public LocalJiniTransactionManager()
Method Detail

setSpace

public void setSpace(IJSpace space)
Sets the Space that will be used when working with the local transaction manager.


setClustered

public void setClustered(Boolean clustered)
Sets if this local transaction manager will work on top of a clustered Space, or will work directly with a cluster memeber.


doCreateTransactionManager

public net.jini.core.transaction.server.TransactionManager doCreateTransactionManager()
                                                                               throws Exception
Returns a new LocalTransactionManager using the provided setSpace(com.j_spaces.core.IJSpace).

The transactional context is automatically set to be the IJSpace associated with the provided GigaSpace. This allows for zero conf when working with this local transaction manager and GigaSpace.

Specified by:
doCreateTransactionManager in class AbstractJiniTransactionManager
Throws:
Exception

getServicesDetails

public ServiceDetails[] getServicesDetails()
Description copied from interface: ServiceDetailsProvider
Retruns one or more service details that the service exposes.

Specified by:
getServicesDetails in interface ServiceDetailsProvider

destroy

public void destroy()
             throws Exception
Specified by:
destroy in interface DisposableBean
Overrides:
destroy in class AbstractJiniTransactionManager
Throws:
Exception

applyIsolationLevel

protected void applyIsolationLevel(AbstractJiniTransactionManager.JiniTransactionObject txObject,
                                   int isolationLevel)
                            throws InvalidIsolationLevelException
Overrides:
applyIsolationLevel in class AbstractJiniTransactionManager
Throws:
InvalidIsolationLevelException

GigaSpaces XAP 7.0 API

Copyright © GigaSpaces.