Author: jmesnil
Date: 2010-04-09 07:42:08 -0400 (Fri, 09 Apr 2010)
New Revision: 9082
Modified:
trunk/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java
Log:
https://jira.jboss.org/jira/browse/HORNETQ-350: Hornetq-configuration.xml elements
deployed twice
* deploy resources (queues, address settings, security settings) from Configuration object
if file deployment is disabled,
or let the deployers handle deployment else.
Modified: trunk/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java
===================================================================
--- trunk/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java 2010-04-08 19:44:31
UTC (rev 9081)
+++ trunk/src/main/org/hornetq/core/server/impl/HornetQServerImpl.java 2010-04-09 11:42:08
UTC (rev 9082)
@@ -990,14 +990,16 @@
// Address settings need to deployed initially, since they're require on paging
manager.start()
- deployAddressSettingsFromConfiguration();
-
if (configuration.isFileDeploymentEnabled())
{
addressSettingsDeployer = new AddressSettingsDeployer(deploymentManager,
addressSettingsRepository);
addressSettingsDeployer.start();
}
+ else
+ {
+ deployAddressSettingsFromConfiguration();
+ }
storageManager.start();
@@ -1014,8 +1016,6 @@
resourceManager.start();
- deploySecurityFromConfiguration();
-
// Deploy all security related config
if (configuration.isFileDeploymentEnabled())
{
@@ -1030,6 +1030,11 @@
securityDeployer.start();
}
}
+ else
+ {
+ deploySecurityFromConfiguration();
+ }
+
deployGroupingHandlerConfiguration(configuration.getGroupingHandlerConfiguration());
// Load the journal and populate queues, transactions and caches in memory
@@ -1037,18 +1042,17 @@
compareJournals(journalInfo);
- // Deploy any queues in the Configuration class - if there's no file deployment
we still need
- // to load those
- deployQueuesFromConfiguration();
-
// Deploy any predefined queues
-
if (configuration.isFileDeploymentEnabled())
{
queueDeployer = new QueueDeployer(deploymentManager, this);
queueDeployer.start();
}
+ else
+ {
+ deployQueuesFromConfiguration();
+ }
// We need to call this here, this gives any dependent server a chance to deploy
its own addresses
// this needs to be done before clustering is initialised