|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jboss.mx.util.JBossNotificationBroadcasterSupport
org.jboss.system.ServiceMBeanSupport
org.jboss.mq.sm.AbstractStateManager
org.jboss.mq.sm.jdbc.JDBCStateManager
public class JDBCStateManager
A state manager that stores state in the database.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.jboss.mq.sm.AbstractStateManager |
|---|
AbstractStateManager.DurableSubscription |
| Field Summary | |
|---|---|
protected int |
connectionRetryAttempts
The connection retries |
protected DataSource |
dataSource
The data source |
protected TransactionManager |
tm
The transaction manager |
| Fields inherited from class org.jboss.system.ServiceMBeanSupport |
|---|
server, SERVICE_CONTROLLER_SIG, serviceName |
| Fields inherited from interface org.jboss.system.ServiceMBean |
|---|
CREATE_EVENT, CREATED, DESTROY_EVENT, DESTROYED, FAILED, REGISTERED, START_EVENT, STARTED, STARTING, states, STOP_EVENT, STOPPED, STOPPING, UNREGISTERED |
| Constructor Summary | |
|---|---|
JDBCStateManager()
|
|
| Method Summary | |
|---|---|
protected void |
checkLoggedOnClientId(String clientID)
Check if the clientID is allowed to logg in from the particular state managers perspective. |
javax.management.ObjectName |
getConnectionManager()
Get the connection manager name |
int |
getConnectionRetryAttempts()
Gets the ConnectionRetryAttempts. |
protected AbstractStateManager.DurableSubscription |
getDurableSubscription(DurableSubscriptionID sub)
Get a DurableSubscription. |
Collection |
getDurableSubscriptionIdsForTopic(SpyTopic topic)
Get all configured durable subscriptions for a particular topic. |
StateManager |
getInstance()
Get an instance if the StateManager (Singleton). |
protected String |
getPreconfClientId(String logon,
String passwd)
Get preconfigured clientID for login/user, and if state manager wants do authentication. |
String |
getSqlProperties()
Gets the sqlProperties. |
boolean |
hasSecurityManager()
Whether we have a security manager |
protected void |
initDB()
|
protected void |
removeDurableSubscription(AbstractStateManager.DurableSubscription ds)
Remove the subscription and save to persistent storage. |
protected void |
saveDurableSubscription(AbstractStateManager.DurableSubscription ds)
Add to durable subs and save the subsrcription to persistent storage. |
void |
setConnectionManager(javax.management.ObjectName connectionManagerName)
Set the connection manager name |
void |
setConnectionRetryAttempts(int value)
Sets the ConnectionRetryAttempts. |
void |
setHasSecurityManager(boolean hasSecurityManager)
Set whether we have a security manager |
void |
setSqlProperties(String value)
Sets the sqlProperties. |
protected void |
startService()
|
| Methods inherited from class org.jboss.mq.sm.AbstractStateManager |
|---|
addLoggedOnClientId, checkUser, getDurableTopic, removeLoggedOnClientId, setDurableSubscription |
| Methods inherited from class org.jboss.system.ServiceMBeanSupport |
|---|
create, createService, destroy, destroyService, getDeploymentInfo, getLog, getName, getNextNotificationSequenceNumber, getObjectName, getServer, getServiceName, getState, getStateString, jbossInternalCreate, jbossInternalDescription, jbossInternalDestroy, jbossInternalLifecycle, jbossInternalStart, jbossInternalStop, postDeregister, postRegister, preDeregister, preRegister, start, stop, stopService |
| Methods inherited from class org.jboss.mx.util.JBossNotificationBroadcasterSupport |
|---|
addNotificationListener, getNotificationInfo, handleNotification, nextNotificationSequenceNumber, removeNotificationListener, removeNotificationListener, sendNotification |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.jboss.system.ServiceMBean |
|---|
getName, getState, getStateString, jbossInternalLifecycle |
| Methods inherited from interface org.jboss.system.Service |
|---|
create, destroy, start, stop |
| Field Detail |
|---|
protected DataSource dataSource
protected int connectionRetryAttempts
protected TransactionManager tm
| Constructor Detail |
|---|
public JDBCStateManager()
| Method Detail |
|---|
public javax.management.ObjectName getConnectionManager()
JDBCStateManagerMBean
getConnectionManager in interface JDBCStateManagerMBeanpublic void setConnectionManager(javax.management.ObjectName connectionManagerName)
JDBCStateManagerMBean
setConnectionManager in interface JDBCStateManagerMBeanconnectionManagerName - the namepublic boolean hasSecurityManager()
JDBCStateManagerMBean
hasSecurityManager in interface JDBCStateManagerMBeanpublic void setHasSecurityManager(boolean hasSecurityManager)
JDBCStateManagerMBean
setHasSecurityManager in interface JDBCStateManagerMBeanhasSecurityManager - true when there is a security managerpublic String getSqlProperties()
JDBCStateManagerMBean
getSqlProperties in interface JDBCStateManagerMBeanpublic void setSqlProperties(String value)
JDBCStateManagerMBean
setSqlProperties in interface JDBCStateManagerMBeanpublic void setConnectionRetryAttempts(int value)
JDBCStateManagerMBean
setConnectionRetryAttempts in interface JDBCStateManagerMBeanpublic int getConnectionRetryAttempts()
JDBCStateManagerMBean
getConnectionRetryAttempts in interface JDBCStateManagerMBean
protected AbstractStateManager.DurableSubscription getDurableSubscription(DurableSubscriptionID sub)
throws javax.jms.JMSException
AbstractStateManager
getDurableSubscription in class AbstractStateManagersub - the durable subscription id
javax.jms.JMSException - for any error
protected void saveDurableSubscription(AbstractStateManager.DurableSubscription ds)
throws javax.jms.JMSException
AbstractStateManagerCalled by this class so the sublclass can save. This may be both a new subscription or a changed one. It is up to the sublcass to know how to find a changed on. (Only the topic will have changed, and it is the same DurableSubscription that is saved again that this class got through getDurableSubscription.
saveDurableSubscription in class AbstractStateManagerds - the durable subscription to save
javax.jms.JMSException - for any error
protected void removeDurableSubscription(AbstractStateManager.DurableSubscription ds)
throws javax.jms.JMSException
AbstractStateManagerCalled by this class so the sublclass can remove.
removeDurableSubscription in class AbstractStateManagerds - the durable subscription to save
javax.jms.JMSException - for any error
public Collection getDurableSubscriptionIdsForTopic(SpyTopic topic)
throws javax.jms.JMSException
StateManager
getDurableSubscriptionIdsForTopic in interface StateManagergetDurableSubscriptionIdsForTopic in class AbstractStateManagertopic - the topic.
javax.jms.JMSException - Description of Exception
protected void checkLoggedOnClientId(String clientID)
throws javax.jms.JMSException
AbstractStateManager
checkLoggedOnClientId in class AbstractStateManagerclientID - the client id to check
javax.jms.JMSException - for any error
protected String getPreconfClientId(String logon,
String passwd)
throws javax.jms.JMSException
AbstractStateManager
getPreconfClientId in class AbstractStateManagerlogon - the user namepasswd - the password
javax.jms.JMSException - for any errorpublic StateManager getInstance()
AbstractStateManagerMBean
getInstance in interface AbstractStateManagerMBean
protected void startService()
throws Exception
startService in class org.jboss.system.ServiceMBeanSupportException
protected void initDB()
throws Exception
Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||