| IBM WebSphere Extended Deployment (XD)TM
Release 6.0.1 |
getSession()getSession(Subject)
Field Summary | |
---|---|
public String | TRANSACTION_TYPE_DEFAULT
|
public int | TRANSACTION_NO_TIMEOUT
A special value for the timeout parameter of the
#setTransactionTimeout(int) method.
|
Method Summary | |
---|---|
public
void | beginNoWriteThrough()
Changes made are just applied to the BackingMap and not given to the Loader. This method can be used.
|
public
ObjectMap | getMap(java.lang.String)
Returns the Object Map for the specific name. .
|
public
void | begin()
Begin an explicit transactional context.
|
public
void | commit()
Commits an explicit transactional context.
|
public
void | rollback()
Rolls back an explicit transactional context.
|
public
void | flush()
Forces the current changes in the Session to the Loader. It does not.
|
public
ObjectGrid | getObjectGrid()
Returns the ObjectGrid that owns this session.
|
public
TxID | getTxID()
Gets the transaction id, if a transaction is active.
|
public
boolean | isWriteThroughEnabled()
Returns whether the current session transaction is writing
through to the backend Loader (True), or if the changes are only
applying to the BackingMap (False).
|
public
void | setTransactionType(java.lang.String)
Sets the transaction type for future transactions. .
|
public
void | processLogSequence(com.ibm.websphere.objectgrid.plugins.LogSequence)
This method can be used to process a LogSequence. Each LogElement within.
|
public
boolean | isFlushing()
Returns whether the current session transaction is in a session.flush().
|
public
boolean | isCommitting()
Returns whether the current session transaction is in a session.commit().
|
public
void | markRollbackOnly(java.lang.Throwable)
Mark the current transaction as being rollback only. Marking a .
|
public
boolean | isMarkedRollbackOnly()
Returns whether or not this currently marked as being rollback only as a result of
a prior call to the #markRollbackOnly(Throwable) method on this Session.
|
public
void | setTransactionTimeout(int)
Set transaction timeout for next transaction started by this Session to a
specified number of seconds.
|
public
int | getTransactionTimeout()
Get current transaction timeout for this Session.
|
public
boolean | transactionTimedOut()
Get whether current transaction has timed out.
|
Field Detail |
public static TRANSACTION_TYPE_DEFAULT
public static TRANSACTION_NO_TIMEOUT
Method Detail |
public void beginNoWriteThrough( | ) |
com.ibm.websphere.objectgrid.TransactionAlreadyActiveExceptioncom.ibm.websphere.objectgrid.TransactionException
public ObjectMap getMap( | String cacheName )
|
The ObjectMap is used to retrieve and modify values in the BackingMap.
See Also:
ObjectMap
cacheName
-
name of desired map
com.ibm.websphere.objectgrid.UndefinedMapException
public void begin( | ) |
com.ibm.websphere.objectgrid.TransactionAlreadyActiveExceptioncom.ibm.websphere.objectgrid.TransactionException
public void commit( | ) |
com.ibm.websphere.objectgrid.NoActiveTransactionExceptioncom.ibm.websphere.objectgrid.TransactionException
public void rollback( | ) |
com.ibm.websphere.objectgrid.NoActiveTransactionExceptioncom.ibm.websphere.objectgrid.TransactionException
public void flush( | ) |
com.ibm.websphere.objectgrid.TransactionException
public ObjectGrid getObjectGrid( | ) |
public TxID getTxID( | ) |
public boolean isWriteThroughEnabled( | ) |
public void setTransactionType( | String tranType )
|
After this method is called, all future transactions will have the same type until another transaction type is set. If no transaction type is set, the default transaction type #TRANSACTION_TYPE_DEFAULT will be used.
Transaction types are used mainly for statistical data tracking purpose. Users can predefine types of transactions that will be executed in an application. The idea is to categorize transactions with the same characteristics to one category (type), so one transaction response time statistics can be used to track each transaction type. This approach is useful when your application has different types of transactions. Some types of transactions, such as update transactions, process longer than others transactions, such as read-only transactions. By using the transaction type, different transactions are tracked by different statistics, so the statistics can be more useful.
tranType
-
the transaction type for future transactions.
public void processLogSequence( | LogSequence logSequence )
|
logSequence
-
LogSequence as received by remote ObjectGrid listener
com.ibm.websphere.objectgrid.NoActiveTransactionExceptioncom.ibm.websphere.objectgrid.UndefinedMapExceptioncom.ibm.websphere.objectgrid.ObjectGridException
public boolean isFlushing( | ) |
public boolean isCommitting( | ) |
public void markRollbackOnly( | Throwable t )
|
t
-
is the Throwable that caused this method to be called.
public boolean isMarkedRollbackOnly( | ) |
public void setTransactionTimeout( | int timeout )
|
timeout
-
is the transaction timeout value in seconds. Use the special value
#TRANSACTION_NO_TIMEOUT if transaction is allowed unlimited amount
of time and no transaction timeout should occur.
public int getTransactionTimeout( | ) |
public boolean transactionTimedOut( | ) |
| IBM WebSphere Extended Deployment (XD)TM
Release 6.0.1 |