Uploaded image for project: 'ServiceMix 4'
  1. ServiceMix 4
  2. SMX4-910

install activemq-web-console feature should work out of the box

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.4.0
    • Component/s: None
    • Labels:
      None

      Description

      when features:install activemq-web-console it will try to start an instance of activemq broker with default configuration(like listening port 61616), however by default when start smx we already start an activemq broker, so will encounter exception like
      13:48:52,751 | ERROR | l Console Thread | RegisterWebAppVisitorWC | 162 - org.ops4j.pax.web.pax-web-extender-war - 1.0.3 | Registration exception. Skipping.
      org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionPool' defined in ServletContext resource [/WEB-INF/webconsole-embedded.xml]: Cannot resolve reference to bean 'connectionFactory' while setting bean property 'connectionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'connectionFactory' defined in ServletContext resource [/WEB-INF/webconsole-embedded.xml]: Cannot resolve reference to bean 'brokerURL' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'brokerService' defined in ServletContext resource [/WEB-INF/webconsole-embedded.xml]: Invocation of init method failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'org.apache.activemq.xbean.XBeanBrokerService#0' defined in ServletContext resource [/WEB-INF/activemq.xml]: Invocation of init method failed; nested exception is java.io.IOException: Transport Connector could not be registered in JMX: Failed to bind to server socket: tcp://localhost:61616 due to: java.net.BindException: Address already in use
      at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveReference(BeanDefinitionValueResolver.java:328)[215:org.apache.activemq.activemq-web-console:5.5.0.fuse-00-43]
      at org.springframework.beans.factory.support.BeanDefinitionValueResolver.resolveValueIfNecessary(BeanDefinitionValueResolver.java:106)[215:org.apache.activemq.activemq-web-console:5.5.0.fuse-00-43]
      at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.applyPropertyValues(AbstractAutowireCapableBeanFactory.java:1317)[215:org.apache.activemq.activemq-web-console:5.5.0.fuse-00-43]

      Marcelo Jabali have a great blog[1] to demonstrate how to workaround it by adding some properties to make the activemq-web-console connect to the default embedded broker but not create another one, I think we need have this out-of-box

      [1]http://marcelojabali.blogspot.com/2011/08/how-to-enable-activemq-web-console-on.html

        Activity

        Show
        ffang Freeman Fang added a comment - commit fix http://svn.apache.org/viewvc?rev=1166010&view=rev

          People

          • Assignee:
            ffang Freeman Fang
            Reporter:
            ffang Freeman Fang
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development