activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "James Strachan" <james.strac...@gmail.com>
Subject Re: Embed broker with Spring
Date Tue, 19 Jun 2007 17:55:01 GMT
This issue has been fixed in 4.1.2 which will hopefully be released
soon. (Its to do with not being able to find the XSD on the internet).
You could host the XSD inside your firewall somewhere for now as a
workaround)

On 6/19/07, Aymeric Alibert <aymericnews@gmail.com> wrote:
>
> I am trying to embed a broker in my Spring application.
> Configuration: Tomcat 5.5 ActiveMQ 4.1.1 Spring 2.1 Spring-bean 2.8
>
> I tried both the XBean and Spring 2.0 examples from
> http://activemq.apache.org/how-do-i-embed-a-broker-inside-a-connection.html
> here  .
>
> It works fine if I have a network connection to the outside world. However,
> if I run the same app from behind our firewall, I am getting the following
> exception:
>
> RROR 2007-06-19 07:12:07,463 [main] (ContextLoader.java
> initWebApplicationContext:205) - Context initialization failed
> org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line
> 28 in XML document from ServletContext resource
> [/WEB-INF/activemqContext.xml] is invalid; nested exception is
> org.xml.sax.SAXParseException: cvc-complex-type.2.4.c: The matching wildcard
> is strict, but no declaration can be found for element 'amq:broker'.
> Caused by:
> org.xml.sax.SAXParseException: cvc-complex-type.2.4.c: The matching wildcard
> is strict, but no declaration can be found for element 'amq:broker'.
>         at
> com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:236)
>         at
> com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.java:172)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:382)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:316)
>         at
> com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(XMLSchemaValidator.java:429)
>         at
> com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.reportSchemaError(XMLSchemaValidator.java:3185)
>         at
> com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.handleStartElement(XMLSchemaValidator.java:1955)
>         at
> com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.startElement(XMLSchemaValidator.java:705)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:330)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1693)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:368)
>         at
> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:834)
>         at
> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)
>         at
> com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148)
>         at
> com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:250)
>         at
> com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:292)
>         at
> org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:76)
>         at
> org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:388)
>         at
> org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:340)
>         at
> org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:317)
>         at
> org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:125)
>         at
> org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:141)
>         at
> org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:123)
>         at
> org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:91)
>         at
> org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:94)
>         at
> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:292)
>         at
> org.springframework.web.context.support.AbstractRefreshableWebApplicationContext.refresh(AbstractRefreshableWebApplicationContext.java:156)
>         at
> org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:246)
>         at
> org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:184)
>         at
> org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)
>         at
> org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3763)
>         at
> org.apache.catalina.core.StandardContext.start(StandardContext.java:4211)
>         at
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
>         at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
>         at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
>         at
> org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:608)
>         at
> org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:535)
>         at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:470)
>         at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122)
>         at
> org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
>         at
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
>         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
>         at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
>         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
>         at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
>         at org.apache.catalina.core.StandardService.start(StandardService.java:450)
>         at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
>         at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>         at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>         at java.lang.reflect.Method.invoke(Method.java:585)
>         at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
>         at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)
> ERROR 2007-06-19 07:12:07,483 [main] (StandardContext.java
> listenerStart:3767) - Exception sending context initialized event to
> listener instance of class
> org.springframework.web.context.ContextLoaderListener
> org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line
> 28 in XML document from ServletContext resource
> [/WEB-INF/activemqContext.xml] is invalid; nested exception is
> org.xml.sax.SAXParseException: cvc-complex-type.2.4.c: The matching wildcard
> is strict, but no declaration can be found for element 'amq:broker'.
> Caused by:
> org.xml.sax.SAXParseException: cvc-complex-type.2.4.c: The matching wildcard
> is strict, but no declaration can be found for element 'amq:broker'.
>         at
> com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(ErrorHandlerWrapper.java:236)
>         at
> com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.error(ErrorHandlerWrapper.java:172)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:382)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(XMLErrorReporter.java:316)
>         at
> com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(XMLSchemaValidator.java:429)
>         at
> com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.reportSchemaError(XMLSchemaValidator.java:3185)
>         at
> com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.handleStartElement(XMLSchemaValidator.java:1955)
>         at
> com.sun.org.apache.xerces.internal.impl.xs.XMLSchemaValidator.startElement(XMLSchemaValidator.java:705)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:330)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1693)
>         at
> com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:368)
>         at
> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:834)
>         at
> com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:764)
>         at
> com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:148)
>         at
> com.sun.org.apache.xerces.internal.parsers.DOMParser.parse(DOMParser.java:250)
>         at
> com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse(DocumentBuilderImpl.java:292)
>         at
> org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:76)
>         at
> org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:388)
>         at
> org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:340)
>         at
> org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:317)
>         at
> org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:125)
>         at
> org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:141)
>         at
> org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:123)
>         at
> org.springframework.web.context.support.XmlWebApplicationContext.loadBeanDefinitions(XmlWebApplicationContext.java:91)
>         at
> org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:94)
>         at
> org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:292)
>         at
> org.springframework.web.context.support.AbstractRefreshableWebApplicationContext.refresh(AbstractRefreshableWebApplicationContext.java:156)
>         at
> org.springframework.web.context.ContextLoader.createWebApplicationContext(ContextLoader.java:246)
>         at
> org.springframework.web.context.ContextLoader.initWebApplicationContext(ContextLoader.java:184)
>         at
> org.springframework.web.context.ContextLoaderListener.contextInitialized(ContextLoaderListener.java:49)
>         at
> org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3763)
>         at
> org.apache.catalina.core.StandardContext.start(StandardContext.java:4211)
>         at
> org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
>         at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
>         at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
>         at
> org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:608)
>         at
> org.apache.catalina.startup.HostConfig.deployDescriptors(HostConfig.java:535)
>         at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:470)
>         at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122)
>         at
> org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
>         at
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
>         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
>         at org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
>         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
>         at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
>         at org.apache.catalina.core.StandardService.start(StandardService.java:450)
>         at org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
>         at org.apache.catalina.startup.Catalina.start(Catalina.java:551)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>         at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>         at java.lang.reflect.Method.invoke(Method.java:585)
>         at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
>         at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)
>
> Any suggestion?
> --
> View this message in context: http://www.nabble.com/Embed-broker-with-Spring-tf3945966s2354.html#a11193332
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.
>
>


-- 
James
-------
http://macstrac.blogspot.com/

Mime
View raw message