|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.hornetq.jms.server.impl.JMSServerManagerImpl
public class JMSServerManagerImpl
A Deployer used to create and add to JNDI queues, topics and connection factories. Typically this would only be used in an app server env.
JMS Connection Factories & Destinations can be configured either using configuration files or using a JMSConfiguration object. If configuration files are used, JMS resources are redeployed if the files content is changed. If a JMSConfiguration object is used, the JMS resources can not be redeployed.
Constructor Summary | |
---|---|
JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server)
|
|
JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server,
BindingRegistry registry)
This constructor is used by the Application Server's integration |
|
JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server,
JMSConfiguration configuration)
|
|
JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server,
String configFileName)
|
|
JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server,
String configFilename,
JMSStorageManager storageManager)
Deprecated. |
Method Summary | |
---|---|
void |
activated()
|
void |
addAddressSettings(String address,
org.hornetq.core.settings.impl.AddressSettings addressSettings)
|
boolean |
addConnectionFactoryToJNDI(String name,
String jndiBinding)
|
boolean |
addQueueToJndi(String queueName,
String jndiBinding)
|
void |
addSecurity(String addressMatch,
Set<org.hornetq.core.security.Role> roles)
|
boolean |
addTopicToJndi(String topicName,
String jndiBinding)
|
boolean |
closeConnectionsForAddress(String ipAddress)
|
void |
createConnectionFactory(boolean storeConfig,
ConnectionFactoryConfiguration cfConfig,
String... jndi)
|
void |
createConnectionFactory(String name,
boolean ha,
JMSFactoryType cfType,
List<String> connectorNames,
String... jndiBindings)
|
void |
createConnectionFactory(String name,
boolean ha,
JMSFactoryType cfType,
List<String> connectorNames,
String clientID,
long clientFailureCheckPeriod,
long connectionTTL,
long callTimeout,
long callFailoverTimeout,
boolean cacheLargeMessagesClient,
int minLargeMessageSize,
boolean compressLargeMessage,
int consumerWindowSize,
int consumerMaxRate,
int confirmationWindowSize,
int producerWindowSize,
int producerMaxRate,
boolean blockOnAcknowledge,
boolean blockOnDurableSend,
boolean blockOnNonDurableSend,
boolean autoGroup,
boolean preAcknowledge,
String loadBalancingPolicyClassName,
int transactionBatchSize,
int dupsOKBatchSize,
boolean useGlobalPools,
int scheduledThreadPoolMaxSize,
int threadPoolMaxSize,
long retryInterval,
double retryIntervalMultiplier,
long maxRetryInterval,
int reconnectAttempts,
boolean failoverOnInitialConnection,
String groupId,
String... jndiBindings)
|
void |
createConnectionFactory(String name,
boolean ha,
JMSFactoryType cfType,
String discoveryGroupName,
String... jndiBindings)
|
void |
createConnectionFactory(String name,
boolean ha,
JMSFactoryType cfType,
String discoveryGroupName,
String clientID,
long clientFailureCheckPeriod,
long connectionTTL,
long callTimeout,
long callFailoverTimeout,
boolean cacheLargeMessagesClient,
int minLargeMessageSize,
boolean compressLargeMessages,
int consumerWindowSize,
int consumerMaxRate,
int confirmationWindowSize,
int producerWindowSize,
int producerMaxRate,
boolean blockOnAcknowledge,
boolean blockOnDurableSend,
boolean blockOnNonDurableSend,
boolean autoGroup,
boolean preAcknowledge,
String loadBalancingPolicyClassName,
int transactionBatchSize,
int dupsOKBatchSize,
boolean useGlobalPools,
int scheduledThreadPoolMaxSize,
int threadPoolMaxSize,
long retryInterval,
double retryIntervalMultiplier,
long maxRetryInterval,
int reconnectAttempts,
boolean failoverOnInitialConnection,
String groupId,
String... jndiBindings)
|
boolean |
createQueue(boolean storeConfig,
String queueName,
String selectorString,
boolean durable,
String... jndi)
Creates a JMS Queue. |
boolean |
createTopic(boolean storeConfig,
String topicName,
String... jndi)
Creates a JMS Topic |
void |
deActivate()
|
boolean |
destroyConnectionFactory(String name)
destroys a connection factory. |
boolean |
destroyQueue(String name)
destroys a queue and removes it from JNDI or BindingRegistry |
boolean |
destroyTopic(String name)
destroys a topic and removes it from JNDI or BindingRegistry |
org.hornetq.core.settings.impl.AddressSettings |
getAddressSettings(String address)
|
org.hornetq.core.server.HornetQServer |
getHornetQServer()
|
JMSStorageManager |
getJMSStorageManager()
|
String[] |
getJNDIOnConnectionFactory(String factoryName)
|
String[] |
getJNDIOnQueue(String queue)
|
String[] |
getJNDIOnTopic(String topic)
|
BindingRegistry |
getRegistry()
|
Set<org.hornetq.core.security.Role> |
getSecurity(String addressMatch)
|
String |
getVersion()
|
protected HornetQConnectionFactory |
internalCreateCFPOJO(ConnectionFactoryConfiguration cfConfig)
|
boolean |
isStarted()
Has the Server been started. |
String[] |
listConnectionIDs()
|
String |
listPreparedTransactionDetailsAsHTML()
|
String |
listPreparedTransactionDetailsAsJSON()
|
String[] |
listRemoteAddresses()
|
String[] |
listRemoteAddresses(String ipAddress)
|
String[] |
listSessions(String connectionID)
|
void |
preActivate()
|
void |
recoverJndiBindings(String name,
PersistedType type)
|
HornetQConnectionFactory |
recreateCF(String name,
ConnectionFactoryConfiguration cf)
Call this method to have a CF rebound to JNDI and stored on the Journal |
boolean |
removeConnectionFactoryFromJNDI(String name)
|
boolean |
removeConnectionFactoryFromJNDI(String name,
String jndi)
|
boolean |
removeQueueFromJNDI(String name)
Remove the queue from JNDI or BindingRegistry. |
boolean |
removeQueueFromJNDI(String name,
String jndi)
Remove the queue from JNDI or BindingRegistry. |
boolean |
removeTopicFromJNDI(String name)
Remove the topic from JNDI or BindingRegistry. |
boolean |
removeTopicFromJNDI(String name,
String jndi)
Remove the topic from JNDI or BindingRegistry. |
void |
replaceStorageManager(JMSStorageManager newStorage)
|
void |
setContext(Context context)
|
void |
setRegistry(BindingRegistry registry)
Set this property if you want something other than JNDI for your registry |
protected boolean |
shutdownConnectionFactory(String name)
|
void |
start()
|
void |
stop()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server) throws Exception
Exception
public JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server, BindingRegistry registry) throws Exception
server
- registry
-
Exception
public JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server, String configFileName) throws Exception
Exception
public JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server, JMSConfiguration configuration) throws Exception
Exception
@Deprecated public JMSServerManagerImpl(org.hornetq.core.server.HornetQServer server, String configFilename, JMSStorageManager storageManager)
Method Detail |
---|
public void preActivate()
preActivate
in interface org.hornetq.core.server.ActivateCallback
public void activated()
activated
in interface org.hornetq.core.server.ActivateCallback
public void deActivate()
deActivate
in interface org.hornetq.core.server.ActivateCallback
public void recoverJndiBindings(String name, PersistedType type) throws NamingException
NamingException
public void start() throws Exception
start
in interface org.hornetq.core.server.HornetQComponent
Exception
public void stop() throws Exception
stop
in interface org.hornetq.core.server.HornetQComponent
Exception
public boolean isStarted()
JMSServerManager
isStarted
in interface org.hornetq.core.server.HornetQComponent
isStarted
in interface JMSServerManager
public BindingRegistry getRegistry()
getRegistry
in interface JMSServerManager
public void setRegistry(BindingRegistry registry)
JMSServerManager
setRegistry
in interface JMSServerManager
public org.hornetq.core.server.HornetQServer getHornetQServer()
getHornetQServer
in interface JMSServerManager
public void addAddressSettings(String address, org.hornetq.core.settings.impl.AddressSettings addressSettings)
addAddressSettings
in interface JMSServerManager
public org.hornetq.core.settings.impl.AddressSettings getAddressSettings(String address)
getAddressSettings
in interface JMSServerManager
public void addSecurity(String addressMatch, Set<org.hornetq.core.security.Role> roles)
addSecurity
in interface JMSServerManager
public Set<org.hornetq.core.security.Role> getSecurity(String addressMatch)
getSecurity
in interface JMSServerManager
public void setContext(Context context)
setContext
in interface JMSServerManager
public String getVersion()
getVersion
in interface JMSServerManager
public boolean createQueue(boolean storeConfig, String queueName, String selectorString, boolean durable, String... jndi) throws Exception
JMSServerManager
createQueue
in interface JMSServerManager
queueName
- The name of the queue to create
Exception
- if problems were encountered creating the queue.public boolean createTopic(boolean storeConfig, String topicName, String... jndi) throws Exception
JMSServerManager
createTopic
in interface JMSServerManager
topicName
- the name of the topicjndi
- the names of the binding for JNDI or BindingRegistry
Exception
- if a problem occurred creating the topicpublic boolean addTopicToJndi(String topicName, String jndiBinding) throws Exception
addTopicToJndi
in interface JMSServerManager
Exception
public String[] getJNDIOnQueue(String queue)
getJNDIOnQueue
in interface JMSServerManager
public String[] getJNDIOnTopic(String topic)
getJNDIOnTopic
in interface JMSServerManager
public String[] getJNDIOnConnectionFactory(String factoryName)
getJNDIOnConnectionFactory
in interface JMSServerManager
public boolean addQueueToJndi(String queueName, String jndiBinding) throws Exception
addQueueToJndi
in interface JMSServerManager
Exception
public boolean addConnectionFactoryToJNDI(String name, String jndiBinding) throws Exception
addConnectionFactoryToJNDI
in interface JMSServerManager
Exception
public boolean removeQueueFromJNDI(String name, String jndi) throws Exception
JMSServerManager
removeQueueFromJNDI
in interface JMSServerManager
name
- the name of the destination to remove from JNDI or BindingRegistry
Exception
- if a problem occurred removing the destinationpublic boolean removeQueueFromJNDI(String name) throws Exception
JMSServerManager
removeQueueFromJNDI
in interface JMSServerManager
name
- the name of the destination to remove from JNDI or BindingRegistry
Exception
- if a problem occurred removing the destinationpublic boolean removeTopicFromJNDI(String name, String jndi) throws Exception
JMSServerManager
removeTopicFromJNDI
in interface JMSServerManager
name
- the name of the destination to remove from JNDI or BindingRegistry
Exception
- if a problem occurred removing the destinationpublic boolean removeTopicFromJNDI(String name) throws Exception
JMSServerManager
removeTopicFromJNDI
in interface JMSServerManager
name
- the name of the destination to remove from JNDI or BindingRegistry
Exception
- if a problem occurred removing the destinationpublic boolean removeConnectionFactoryFromJNDI(String name, String jndi) throws Exception
removeConnectionFactoryFromJNDI
in interface JMSServerManager
Exception
public boolean removeConnectionFactoryFromJNDI(String name) throws Exception
removeConnectionFactoryFromJNDI
in interface JMSServerManager
Exception
public boolean destroyQueue(String name) throws Exception
JMSServerManager
destroyQueue
in interface JMSServerManager
name
- the name of the queue to destroy
Exception
- if a problem occurred destroying the queuepublic boolean destroyTopic(String name) throws Exception
JMSServerManager
destroyTopic
in interface JMSServerManager
name
- the name of the topic to destroy
Exception
- if a problem occurred destroying the topicpublic void createConnectionFactory(String name, boolean ha, JMSFactoryType cfType, List<String> connectorNames, String... jndiBindings) throws Exception
createConnectionFactory
in interface JMSServerManager
Exception
public void createConnectionFactory(String name, boolean ha, JMSFactoryType cfType, List<String> connectorNames, String clientID, long clientFailureCheckPeriod, long connectionTTL, long callTimeout, long callFailoverTimeout, boolean cacheLargeMessagesClient, int minLargeMessageSize, boolean compressLargeMessage, int consumerWindowSize, int consumerMaxRate, int confirmationWindowSize, int producerWindowSize, int producerMaxRate, boolean blockOnAcknowledge, boolean blockOnDurableSend, boolean blockOnNonDurableSend, boolean autoGroup, boolean preAcknowledge, String loadBalancingPolicyClassName, int transactionBatchSize, int dupsOKBatchSize, boolean useGlobalPools, int scheduledThreadPoolMaxSize, int threadPoolMaxSize, long retryInterval, double retryIntervalMultiplier, long maxRetryInterval, int reconnectAttempts, boolean failoverOnInitialConnection, String groupId, String... jndiBindings) throws Exception
createConnectionFactory
in interface JMSServerManager
Exception
public void createConnectionFactory(String name, boolean ha, JMSFactoryType cfType, String discoveryGroupName, String clientID, long clientFailureCheckPeriod, long connectionTTL, long callTimeout, long callFailoverTimeout, boolean cacheLargeMessagesClient, int minLargeMessageSize, boolean compressLargeMessages, int consumerWindowSize, int consumerMaxRate, int confirmationWindowSize, int producerWindowSize, int producerMaxRate, boolean blockOnAcknowledge, boolean blockOnDurableSend, boolean blockOnNonDurableSend, boolean autoGroup, boolean preAcknowledge, String loadBalancingPolicyClassName, int transactionBatchSize, int dupsOKBatchSize, boolean useGlobalPools, int scheduledThreadPoolMaxSize, int threadPoolMaxSize, long retryInterval, double retryIntervalMultiplier, long maxRetryInterval, int reconnectAttempts, boolean failoverOnInitialConnection, String groupId, String... jndiBindings) throws Exception
createConnectionFactory
in interface JMSServerManager
Exception
public void createConnectionFactory(String name, boolean ha, JMSFactoryType cfType, String discoveryGroupName, String... jndiBindings) throws Exception
createConnectionFactory
in interface JMSServerManager
Exception
public HornetQConnectionFactory recreateCF(String name, ConnectionFactoryConfiguration cf) throws Exception
JMSServerManager
recreateCF
in interface JMSServerManager
Exception
public void createConnectionFactory(boolean storeConfig, ConnectionFactoryConfiguration cfConfig, String... jndi) throws Exception
createConnectionFactory
in interface JMSServerManager
Exception
public JMSStorageManager getJMSStorageManager()
public void replaceStorageManager(JMSStorageManager newStorage)
protected HornetQConnectionFactory internalCreateCFPOJO(ConnectionFactoryConfiguration cfConfig) throws HornetQException
cfConfig
-
HornetQException
public boolean destroyConnectionFactory(String name) throws Exception
JMSServerManager
destroyConnectionFactory
in interface JMSServerManager
name
- the name of the connection factory to destroy
Exception
- if a problem occurred destroying the connection factoryprotected boolean shutdownConnectionFactory(String name) throws Exception
name
-
Exception
public String[] listRemoteAddresses() throws Exception
listRemoteAddresses
in interface JMSServerManager
Exception
public String[] listRemoteAddresses(String ipAddress) throws Exception
listRemoteAddresses
in interface JMSServerManager
Exception
public boolean closeConnectionsForAddress(String ipAddress) throws Exception
closeConnectionsForAddress
in interface JMSServerManager
Exception
public String[] listConnectionIDs() throws Exception
listConnectionIDs
in interface JMSServerManager
Exception
public String[] listSessions(String connectionID) throws Exception
listSessions
in interface JMSServerManager
Exception
public String listPreparedTransactionDetailsAsJSON() throws Exception
listPreparedTransactionDetailsAsJSON
in interface JMSServerManager
Exception
public String listPreparedTransactionDetailsAsHTML() throws Exception
listPreparedTransactionDetailsAsHTML
in interface JMSServerManager
Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |