Hi all,

When I run ActiveMQ 5.9.0 and its web console in ServiceMix (Karaf) I have a 
problem with the configuration in the org.apache.activemq.webconsole.cfg file. 
In ServiceMix the default user for jmx and jms connections to activemq is “smx” 
(instead of “karaf" in Karaf).  


The servicemix version I use is 5.0.0
The contents of my org.apache.activemq.webconsole.cfg file are:

webconsole.jms.url=${activemq.url}
webconsole.jmx.url=service:jmx:rmi:///jndi/rmi://localhost:1099/karaf-${karaf.name}
webconsole.jmx.user=smx
webconsole.jmx.password=smx
webconsole.jms.user=smx
webconsole.jms.password=smx

When i install the web console for the first time, everything works great. 
org.apache.activemq.web.config.OsgiConfiguration gets created, it gets updated 
with the new configuration and finally the web console (webconsole-osgi.xml) 
executes a getConnectionFactory on the configuration and everything gets picked 
up fine.

But after a restart the order of events is change. The creation of 
OsgiConfiguration and the getConnectionFactory call are both defined in the web 
console (webconsole-osgi.xml) and are executed right after each other, before 
the hard coded default config (user:karaf … ) gets updated with the new (user: 
smx … ) configuration. As the values of OsgiConfiguration are not passed by 
reference, the ConnectionFactory will keep using the old configuration. 
Eventually requesting queue info and sending messages trough the web console 
will fail because of authentication issues.

I bump into the same issue if I try to update the configuration while running.

At the moment i think this issue blocks the following ServiceMix issue: 
https://issues.apache.org/jira/browse/SM-2267

Is there any solution you can propose or does this has to be changed in the 
code? 


Sincerely,

Wim






Reply via email to