|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.sandesha2.storage.StorageManager
org.apache.sandesha2.storage.jdbc.PersistentStorageManager
public class PersistentStorageManager
A Storage Manager implementation for managing Sandesha2 beans.
Needs this parameter in module.xml or axis2.xml : db.driver JDBC Driver class name db.connectionstring JDBC connection string db.user Data Base user name db.password Data Base user password Transactions are supposed to be attached to a thread (see inMemoryStorageManager) hence the ThreadLocal threadTransaction variable (instead of the transactions HashMap used by inMemoryStorageManager). MessageContexts are stored in a HashMap, as in inMemoryStorageManager, AND in DataBase as backup in case of failure.
Constructor Summary | |
---|---|
PersistentStorageManager(org.apache.axis2.context.ConfigurationContext context)
|
Method Summary | |
---|---|
void |
acquireTransactionLock()
|
java.sql.Connection |
dbConnect()
|
java.sql.Connection |
getDbConnection()
Returns the connection attached to the current transaction if exists or the "common" connection. |
SandeshaThread |
getInvoker()
Get the invoker that hands inbound messages over to the application. |
InvokerBeanMgr |
getInvokerBeanMgr()
|
PollingManager |
getPollingManager()
Get the thread that generates polling requests to send to remote endpoints. |
RMDBeanMgr |
getRMDBeanMgr()
|
RMSBeanMgr |
getRMSBeanMgr()
|
SandeshaThread |
getSender()
|
SenderBeanMgr |
getSenderBeanMgr()
|
Transaction |
getTransaction()
|
boolean |
hasUserTransaction(org.apache.axis2.context.MessageContext msg)
If there is no user transaction in scope then we can optimize the sending / invoking of a message. |
void |
initStorage(org.apache.axis2.description.AxisModule moduleDesc)
|
void |
releaseTransactionLock()
|
void |
removeMessageContext(java.lang.String key)
|
void |
removeTransaction()
|
boolean |
requiresMessageSerialization()
|
org.apache.axis2.context.MessageContext |
retrieveMessageContext(java.lang.String key,
org.apache.axis2.context.ConfigurationContext configContext)
|
void |
shutdown()
|
void |
storeMessageContext(java.lang.String key,
org.apache.axis2.context.MessageContext msgContext)
|
void |
updateMessageContext(java.lang.String key,
org.apache.axis2.context.MessageContext msgContext)
|
Methods inherited from class org.apache.sandesha2.storage.StorageManager |
---|
getContext, setContext |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PersistentStorageManager(org.apache.axis2.context.ConfigurationContext context) throws SandeshaException
SandeshaException
Method Detail |
---|
public SandeshaThread getInvoker()
StorageManager
getInvoker
in class StorageManager
public PollingManager getPollingManager()
StorageManager
getPollingManager
in class StorageManager
public SandeshaThread getSender()
getSender
in class StorageManager
public void shutdown()
shutdown
in class StorageManager
public InvokerBeanMgr getInvokerBeanMgr()
getInvokerBeanMgr
in class StorageManager
public RMDBeanMgr getRMDBeanMgr()
getRMDBeanMgr
in class StorageManager
public RMSBeanMgr getRMSBeanMgr()
getRMSBeanMgr
in class StorageManager
public SenderBeanMgr getSenderBeanMgr()
getSenderBeanMgr
in class StorageManager
public boolean requiresMessageSerialization()
requiresMessageSerialization
in class StorageManager
public boolean hasUserTransaction(org.apache.axis2.context.MessageContext msg)
StorageManager
hasUserTransaction
in class StorageManager
public Transaction getTransaction()
getTransaction
in class StorageManager
public void removeTransaction()
public java.sql.Connection getDbConnection()
public void initStorage(org.apache.axis2.description.AxisModule moduleDesc) throws SandeshaStorageException
initStorage
in class StorageManager
SandeshaStorageException
public java.sql.Connection dbConnect() throws SandeshaStorageException
SandeshaStorageException
public org.apache.axis2.context.MessageContext retrieveMessageContext(java.lang.String key, org.apache.axis2.context.ConfigurationContext configContext) throws SandeshaStorageException
retrieveMessageContext
in class StorageManager
SandeshaStorageException
public void storeMessageContext(java.lang.String key, org.apache.axis2.context.MessageContext msgContext) throws SandeshaStorageException
storeMessageContext
in class StorageManager
SandeshaStorageException
public void updateMessageContext(java.lang.String key, org.apache.axis2.context.MessageContext msgContext) throws SandeshaStorageException
updateMessageContext
in class StorageManager
SandeshaStorageException
public void removeMessageContext(java.lang.String key) throws SandeshaStorageException
removeMessageContext
in class StorageManager
SandeshaStorageException
public void acquireTransactionLock()
public void releaseTransactionLock()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |