During AMQ 7 Broker installation, we encountered "Cannot find the declaration of element 'broker'"
Issue
While installing the AMQ broker 7.10.1 via OperatorHub, the pod failed and in a CrashLoopBackOff
Pod logs:
-Xms128m -Xmx512m -XX:+UseParallelOldGC -XX:MinHeapFreeRatio=10 -XX:MaxHeapFreeRatio=20 -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -XX:MaxMetaspaceSize=100m -XX:ParallelGCThreads=1 -Djava.util.concurrent.ForkJoinPool.common.parallelism=1 -XX:CICompilerCount=2 -XX:+ExitOnOutOfMemoryError
Removing provided -XX:+UseParallelOldGC in favour of artemis.profile provided option
Enable jolokia jvm agent
Running server env: home: /home/jboss AMQ_HOME /opt/amq CONFIG_BROKER false RUN_BROKER
NO RUN_BROKER defined
Using custom configuration. Copy from /amq/init/config to /home/jboss/amq-broker
bin
etc
lib
log
tmp
Running Broker in /home/jboss/amq-broker
OpenJDK 64-Bit Server VM warning: If the number of processors is expected to increase from one, then you should configure the number of parallel GC threads appropriately using -XX:ParallelGCThreads=N
I> No access restrictor found, access to any MBean is allowed
Jolokia: Agent started with URL https://xxx.xxx.xxx.xxx:8778/jolokia/
javax.xml.bind.UnmarshalException
- with linked exception:
[org.xml.sax.SAXParseException; lineNumber: 19; columnNumber: 51; cvc-elt.1: Cannot find the declaration of element 'broker'.]
at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.handleStreamException(UnmarshallerImpl.java:483)
at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:417)
at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:386)
at org.apache.activemq.artemis.dto.XmlUtil.decode(XmlUtil.java:117)
at org.apache.activemq.artemis.cli.factory.xml.XmlBrokerFactoryHandler.createBroker(XmlBrokerFactoryHandler.java:35)
at org.apache.activemq.artemis.cli.factory.BrokerFactory.createBrokerConfiguration(BrokerFactory.java:47)
at org.apache.activemq.artemis.cli.factory.BrokerFactory.createBrokerConfiguration(BrokerFactory.java:54)
at org.apache.activemq.artemis.cli.commands.Configurable.getBrokerDTO(Configurable.java:118)
at org.apache.activemq.artemis.cli.commands.Run.execute(Run.java:75)
at org.apache.activemq.artemis.cli.Artemis.internalExecute(Artemis.java:153)
at org.apache.activemq.artemis.cli.Artemis.execute(Artemis.java:101)
at org.apache.activemq.artemis.cli.Artemis.execute(Artemis.java:128)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.activemq.artemis.boot.Artemis.execute(Artemis.java:134)
at org.apache.activemq.artemis.boot.Artemis.main(Artemis.java:50)
Caused by: org.xml.sax.SAXParseException; lineNumber: 19; columnNumber: 51; cvc-elt.1: Cannot find the declaration of element 'broker'.
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:204)
at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.java:135)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:395)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:326)
at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:283)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.handleStartElement(XMLSchemaValidator.java:1901)
at com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.startElement(XMLSchemaValidator.java:741)
at com.sun.org.apache.xerces.internal.jaxp.validation.ValidatorHandlerImpl.startElement(ValidatorHandlerImpl.java:567)
at com.sun.xml.bind.v2.runtime.unmarshaller.ValidatingUnmarshaller.startElement(ValidatingUnmarshaller.java:101)
at com.sun.xml.bind.v2.runtime.unmarshaller.InterningXmlVisitor.startElement(InterningXmlVisitor.java:75)
at com.sun.xml.bind.v2.runtime.unmarshaller.StAXStreamConnector.handleStartElement(StAXStreamConnector.java:246)
at com.sun.xml.bind.v2.runtime.unmarshaller.StAXStreamConnector.bridge(StAXStreamConnector.java:180)
at com.sun.xml.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(UnmarshallerImpl.java:415)
... 16 more
java.lang.NullPointerException
at org.apache.activemq.artemis.cli.commands.Run.execute(Run.java:137)
at org.apache.activemq.artemis.cli.Artemis.internalExecute(Artemis.java:153)
at org.apache.activemq.artemis.cli.Artemis.execute(Artemis.java:101)
at org.apache.activemq.artemis.cli.Artemis.execute(Artemis.java:128)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at org.apache.activemq.artemis.boot.Artemis.execute(Artemis.java:134)
at org.apache.activemq.artemis.boot.Artemis.main(Artemis.java:50)
Environment
AMQ Broker 7.x on Openshift 4.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.