spring-attic / spring-native

Spring Native is now superseded by Spring Boot 3 official native support

Home Page:https://docs.spring.io/spring-boot/docs/current/reference/html/native-image.html

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Installed new version of ActiveMQ 5.17.1 getting error while startup

arifulla04 opened this issue · comments

getting error while starting activemq

2022-08-31 06:05:03,228 | ERROR | Failed to load: class path resource [activemq.xml], reason: Failed to load type: io.fabric8.insight.log.log4j.Log4jLogQuery. Reason: java.lang.ClassNotFoundException: io.fabric8.insight.log.log4j.Log4jLogQuery; nested exception is java.lang.ClassNotFoundException: io.fabric8.insight.log.log4j.Log4jLogQuery | org.apache.activemq.xbean.XBeanBrokerFactory | main org.springframework.beans.factory.BeanDefinitionStoreException: Failed to load type: io.fabric8.insight.log.log4j.Log4jLogQuery. Reason: java.lang.ClassNotFoundException: io.fabric8.insight.log.log4j.Log4jLogQuery; nested exception is java.lang.ClassNotFoundException: io.fabric8.insight.log.log4j.Log4jLogQuery at org.apache.xbean.spring.context.v2c.XBeanQNameHelper.getBeanInfo(XBeanQNameHelper.java:75) at org.apache.xbean.spring.context.v2c.XBeanQNameHelper.coerceNamespaceAwarePropertyValues(XBeanQNameHelper.java:54) at org.apache.xbean.spring.context.v2c.XBeanBeanDefinitionParserDelegate.parseBeanDefinitionElement(XBeanBeanDefinitionParserDelegate.java:59) at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseBeanDefinitionElement(BeanDefinitionParserDelegate.java:437) at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseBeanDefinitionElement(BeanDefinitionParserDelegate.java:405) at org.apache.xbean.spring.context.v2.XBeanBeanDefinitionDocumentReader.processBeanDefinition(XBeanBeanDefinitionDocumentReader.java:188) at org.apache.xbean.spring.context.v2.XBeanBeanDefinitionDocumentReader.parseDefaultElement(XBeanBeanDefinitionDocumentReader.java:115) at org.apache.xbean.spring.context.v2.XBeanBeanDefinitionDocumentReader.parseBeanDefinitions(XBeanBeanDefinitionDocumentReader.java:95) at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.doRegisterBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:149) at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.registerBeanDefinitions(DefaultBeanDefinitionDocumentReader.java:96) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefinitions(XmlBeanDefinitionReader.java:511) at org.apache.xbean.spring.context.v2.XBeanXmlBeanDefinitionReader.registerBeanDefinitions(XBeanXmlBeanDefinitionReader.java:79) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:391) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:338) at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310) at org.apache.xbean.spring.context.ResourceXmlApplicationContext.loadBeanDefinitions(ResourceXmlApplicationContext.java:116) at org.apache.xbean.spring.context.ResourceXmlApplicationContext.loadBeanDefinitions(ResourceXmlApplicationContext.java:104) at org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:130) at org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:671) at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:553) at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:64) at org.apache.xbean.spring.context.ResourceXmlApplicationContext.<init>(ResourceXmlApplicationContext.java:52) at org.apache.activemq.xbean.XBeanBrokerFactory$1.<init>(XBeanBrokerFactory.java:104) at org.apache.activemq.xbean.XBeanBrokerFactory.createApplicationContext(XBeanBrokerFactory.java:104)

Please share a repro project.

can you please elaborate a little what exactly are you looking

any other alternatives to put in 5.17 xml file to use instead of "io.fabric8.insight.log.log4j.Log4jLogQuery"

can you please elaborate a little what exactly are you looking

I am looking for a way to reproduce the issue myself in order to be able to help you.

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.

Hey together,

I have the same error after upgrading from 5.16.3 to 5.17.3 and ubuntu from 20.04 to 22.02. Here is my example project to reproduce the error with docker. Just run docker-compose up in the root directory. Can you help me?

With best regards
Henni

Hi, all!

I'll try to shed some light on the issue. It would appear that version 5.16.* contained the JAR: $/optional/insight-log-core-.jar, and that's no longer included with versions 5.17.*. Classes from this JAR were referenced in the default activemq.xml file. In the newer version, the sections which contain these are missing (with no obvious replacement).

That's what's causing this issue. Obviously, there are two possibilities:

This is by design - in which case: what should we use instead of the fabric8 classes in our logging configurations? From the 5.16.2 $/conf/activemq.xml

       <!-- Allows accessing the server log -->
        <bean id="logQuery" class="io.fabric8.insight.log.log4j.Log4jLogQuery"
              lazy-init="false" scope="singleton"
              init-method="start" destroy-method="stop">
        </bean>

This section was flat out removed in 5.17.*.

This is by accident - in which case: when can we expect a fixed release (5.17.4?).

Hope this helps.