[mule-user] Mule and OSGi

9 views
Skip to first unread message

paquettd

unread,
Jan 28, 2009, 10:46:15 AM1/28/09
to us...@mule.codehaus.org

I've read in some blog entries that there has been some success integrating
Mule 2.x with OSGi. Is there a tutorial or anything available showing how
this was done? I seem to be running into problems when I use
SpringXmlConfigurationBuilder to create a MuleContext; the builder cannot
parse anything because it doesn't know what a 'beans' tag or a 'mule' tag
is.
--
View this message in context: http://www.nabble.com/Mule-and-OSGi-tp21708300p21708300.html
Sent from the Mule - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe from this list, please visit:

http://xircles.codehaus.org/manage_email


Antoine Borg

unread,
Feb 2, 2009, 3:18:22 AM2/2/09
to us...@mule.codehaus.org
Hi,

Why do you think this is an OSGi issue?

It sounds like the namespaces may not be properly set but I cannot tell
unless you post some configuration here.

A


Antoine Borg, Senior Consultant | Tel: +32 28 504 696
ricston Ltd., BP 2, 1180 Uccle, Brussels, BELGIUM
email: antoin...@ricston.com | blog: blog.ricston.com | web: ricston.com

paquettd

unread,
Feb 2, 2009, 8:24:33 PM2/2/09
to us...@mule.codehaus.org

I actually don't have even get to my Mule config file; it dies trying to
parse default-mule-config.xml

I'll give you an idea what I'm seeing.

So I'm trying to startup in a bundle Activator like this

DefaultMuleContextFactory muleContextFactory = new
DefaultMuleContextFactory();
SpringXmlConfigurationBuilder configBuilder = new
SpringXmlConfigurationBuilder(configResourceArray);
muleContext = muleContextFactory.createMuleContext(configBuilder);
muleContext.start();

configResourceArray is an array of ConfigResource.

So when I do this I get...

java.io.FileNotFoundException: default-mule-config.xml

Bummer. So I saw I could call

configBuilder.setUseDefaultConfigResource(false);

which gave me

org.mule.api.MuleRuntimeException: The required object/property
"securityManager" is null

So ok, I'm thinking I need the default mule file. So I have my bundle go
find it and put it at the front of the configuration file list. I don't put
any other config files in this list at this point and I get

org.mule.api.config.ConfigurationException: Initialisation Failure:
Configuration problem: Unable to locate NamespaceHandler for namespace
[http://www.mulesource.org/schema/mule/core/2.1]
Offending resource: URL [bundleresource://90/default-mule-config.xml]
(org.mule.api.lifecycle.InitialisationException)

So that's why I came here. I'm not quite sure what I should be doing to
startup within an OSGi bundle where I'm using OSGi and Spring-DM.

Does that help shed more light?

--
View this message in context: http://www.nabble.com/Mule-and-OSGi-tp21708300p21802264.html

Antoine Borg

unread,
Feb 3, 2009, 5:25:16 AM2/3/09
to us...@mule.codehaus.org
Hi,

If it cannot find the mule configuration file then either the filename is
incorrect, or the file is not in the current directory.

What I find to be curious is that you immediately assume that you should use
"the default mule file" What are you talking about here? There is no such
thing as a default Mule configuration file since this is something that you
should provide; this MUST be the name of your configuration file. If, on
the other hand, your configuration file is named "mule-config.xml", then
Mule will find it on its own as this is the default file name to expect.

HTH

paquettd

unread,
Feb 3, 2009, 8:55:10 AM2/3/09
to us...@mule.codehaus.org

I realize that I need to use my own mule configuration file. What I'm trying
to say is that the system doesn't even get to the point of trying to load my
configuration file.

default-mule-config.xml is in mule-module-spring-config-2.1.2.jar.
SpringXmlConfigurationBuilder sure seems to be trying to read it. Line 32 of
SpringXmlConfigurationBuilder defines it as:

public static final String MULE_DEFAULTS_CONFIG = "default-mule-config.xml";

and line 62 in the doConfigure method prepends this file to the front of the
resources to be loaded array.

Needless to say I'm a little confused. This is why I thought it might be
something with OSGi changing how this works in the base case.

--
View this message in context: http://www.nabble.com/Mule-and-OSGi-tp21708300p21810349.html

Andrew Perepelytsya

unread,
Feb 3, 2009, 9:02:25 AM2/3/09
to us...@mule.codehaus.org

It appears that osgi framework replaced the parent classloader and/or url stream handler factory. I cannot explain it otherwise, the bundleresource:// qualifier clearly is the culprit here. Still, resources should be just discoverable via standard Java classloading means. Please provide as much detail as possible.

Andrew

On Feb 3, 2009 8:55 AM, "paquettd" <dan.pa...@lmco.com> wrote:


I realize that I need to use my own mule configuration file. What I'm trying
to say is that the system doesn't even get to the point of trying to load my
configuration file.

default-mule-config.xml is in mule-module-spring-config-2.1.2.jar.
SpringXmlConfigurationBuilder sure seems to be trying to read it. Line 32 of
SpringXmlConfigurationBuilder defines it as:

public static final String MULE_DEFAULTS_CONFIG = "default-mule-config.xml";

and line 62 in the doConfigure method prepends this file to the front of the
resources to be loaded array.

Needless to say I'm a little confused. This is why I thought it might be
something with OSGi changing how this works in the base case.

antoine.borg wrote: > > Hi, > > If it cannot find the mule configuration file then either the fi...

Sent from the Mule - User mailing list archive at Nabble.com. ------------------------------------...

paquettd

unread,
Feb 3, 2009, 9:50:33 AM2/3/09
to us...@mule.codehaus.org

Just for fun I opened the InputStream of the bundleresource:// and made sure
i could read the whole file.
That worked fine.

I started stepping into the SpringXmlConfigurationBuilder and have a
question about createSpringRegistry.

It checks for a parentContext before creating the registry and initializing
it. I did not supply a parent context so it goes to the base case. Is this
something i should have provided?

--
View this message in context: http://www.nabble.com/Mule-and-OSGi-tp21708300p21811413.html


Sent from the Mule - User mailing list archive at Nabble.com.

Andrew Perepelytsya

unread,
Feb 3, 2009, 9:54:33 AM2/3/09
to us...@mule.codehaus.org
No, you don't have to provide one, but this is an option if you need it (you'll know when you need one). Then, where did you execute this stream read operation? And a stacktrace is also helpful.

Andrew

paquettd

unread,
Feb 3, 2009, 10:19:49 AM2/3/09
to us...@mule.codehaus.org

Sure.

I did the stream read in the same bundle Activator that is doing the
startup.
The full stack trace follows.

To me it seems like Spring cannot figure out how to parse the file. I'm
running in Eclipse. My OSGi TargetPlatform is set to all the bundles that
came with Mule 2.1.2 (so all the org.springframework bundles are in there).
I know Spring-DM scans bundle generally looks for spring.handlers and
spring.schemas to define how to parse this stuff. How do these get set when
starting Mule?

Thanks.

Start Level Event Dispatcher] INFO
org.springframework.beans.factory.xml.XmlBeanDefinitionReader - Loading XML
bean definitions from URL [bundleresource://61/default-mule-config.xml]
[Start Level Event Dispatcher] DEBUG
org.springframework.beans.factory.xml.DefaultDocumentLoader - Using JAXP
provider
[com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl]
[Start Level Event Dispatcher] DEBUG
org.springframework.beans.factory.xml.PluggableSchemaResolver - Loading
schema mappings from [META-INF/spring.schemas]
[Start Level Event Dispatcher] DEBUG
org.springframework.beans.factory.xml.PluggableSchemaResolver - Loaded
schema mappings: {}
[Start Level Event Dispatcher] ERROR
org.mule.config.spring.SpringXmlConfigurationBuilder - Configuration with
"org.mule.config.spring.SpringXmlConfigurationBuilder" failed.
org.mule.api.lifecycle.InitialisationException: Initialisation Failure: Line
8 in XML document from URL [bundleresource://61/default-mule-config.xml] is
invalid; nested exception is org.xml.sax.SAXParseException: cvc-elt.1:
Cannot find the declaration of element 'beans'.
at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:79)
at
org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:98)
at
org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder.java:69)
at
org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:39)
at
org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)
at
org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:96)
at
org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:54)
at com.lmco.psb.mule.Activator.start(Activator.java:67)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(BundleContextImpl.java:1009)
at java.security.AccessController.doPrivileged(Native Method)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:1003)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:984)
at
org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:346)
at
org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:355)
at
org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1074)
at
org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:616)
at
org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:508)
at
org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:299)
at
org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:489)
at
org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:211)
at
org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:321)
Caused by:
org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line
8 in XML document from URL [bundleresource://61/default-mule-config.xml] is
invalid; nested exception is org.xml.sax.SAXParseException: cvc-elt.1:
Cannot find the declaration of element 'beans'.
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:404)
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:342)
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310)
at
org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
at
org.mule.config.spring.MuleApplicationContext.loadBeanDefinitions(MuleApplicationContext.java:104)
at
org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
at
org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:422)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
at
org.mule.config.spring.SpringRegistry.doInitialise(SpringRegistry.java:87)
at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:71)
... 20 more
Caused by: org.xml.sax.SAXParseException: cvc-elt.1: Cannot find the
declaration of element 'beans'.
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.handleStartElement(XMLSchemaValidator.java:1944)
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.XMLNSDocumentScannerImpl$NSContentDispatcher.scanRootElementHook(XMLNSDocumentScannerImpl.java:779)
at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1794)
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:75)
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:396)
... 29 more
[Start Level Event Dispatcher] ERROR com.lmco.psb.mule.Activator - Exception
caught starting Mule
org.mule.api.config.ConfigurationException: Initialisation Failure: Line 8
in XML document from URL [bundleresource://61/default-mule-config.xml] is
invalid; nested exception is org.xml.sax.SAXParseException: cvc-elt.1:
Cannot find the declaration of element 'beans'.
(org.mule.api.lifecycle.InitialisationException)
at
org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:46)
at
org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)
at
org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:96)
at
org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:54)
at com.lmco.psb.mule.Activator.start(Activator.java:67)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl$2.run(BundleContextImpl.java:1009)
at java.security.AccessController.doPrivileged(Native Method)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:1003)
at
org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:984)
at
org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:346)
at
org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:355)
at
org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1074)
at
org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:616)
at
org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:508)
at
org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:299)
at
org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:489)
at
org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:211)
at
org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:321)
Caused by: org.mule.api.lifecycle.InitialisationException: Initialisation
Failure: Line 8 in XML document from URL
[bundleresource://61/default-mule-config.xml] is invalid; nested exception
is org.xml.sax.SAXParseException: cvc-elt.1: Cannot find the declaration of
element 'beans'.
at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:79)
at
org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:98)
at
org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder.java:69)
at
org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:39)
... 17 more
Caused by:
org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException: Line
8 in XML document from URL [bundleresource://61/default-mule-config.xml] is
invalid; nested exception is org.xml.sax.SAXParseException: cvc-elt.1:
Cannot find the declaration of element 'beans'.
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:404)
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:342)
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310)
at
org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
at
org.mule.config.spring.MuleApplicationContext.loadBeanDefinitions(MuleApplicationContext.java:104)
at
org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
at
org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:422)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
at
org.mule.config.spring.SpringRegistry.doInitialise(SpringRegistry.java:87)
at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:71)
... 20 more
Caused by: org.xml.sax.SAXParseException: cvc-elt.1: Cannot find the
declaration of element 'beans'.
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.handleStartElement(XMLSchemaValidator.java:1944)
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.XMLNSDocumentScannerImpl$NSContentDispatcher.scanRootElementHook(XMLNSDocumentScannerImpl.java:779)
at
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1794)
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:75)
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:396)
... 29 more

--
View this message in context: http://www.nabble.com/Mule-and-OSGi-tp21708300p21811955.html

Andrew Perepelytsya

unread,
Feb 3, 2009, 10:31:08 AM2/3/09
to us...@mule.codehaus.org
It doesn't necessarily look like a problem in the default Mule config, though. Note that you're using an embedded JDK parser: com.sun.org.apache.xerces.internal.* Mule uses advanced schema elements, which aren't properly supported by stock JDKs (due to them being outdated and buggy). Typically Mule endorses up-to-date xml libs, check those $MULE_HOME/lib/endorsed. The easiest for you to try them would be to drop those in $JAVA_HOME/jre/lib/endorsed (create one if needed).

HTH,
Andrew

paquettd

unread,
Feb 3, 2009, 10:51:01 AM2/3/09
to us...@mule.codehaus.org

Well that gave me a different error; so that's exciting. I've attached the
stack trace. It seems like its trying to go get the spring schema or cannot
find the copy Spring keeps locally. I'll keep digging and I'll post if I can
find anything out. This is the current top of the stack trace.

org.xml.sax.SAXParseException: schema_reference.4: Failed to read schema
document 'http://www.springframework.org/schema/beans/spring-beans-2.5.xsd',
because 1) could not find the document; 2) the document could not be read;
3) the root element of the document is not <xsd:schema>.
at
org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown
Source)
at org.apache.xerces.util.ErrorHandlerWrapper.warning(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source)
at
org.apache.xerces.impl.xs.traversers.XSDHandler.reportSchemaWarning(Unknown
Source)
at
org.apache.xerces.impl.xs.traversers.XSDHandler.getSchemaDocument(Unknown
Source)
at org.apache.xerces.impl.xs.traversers.XSDHandler.parseSchema(Unknown
Source)
at org.apache.xerces.impl.xs.XMLSchemaLoader.loadSchema(Unknown Source)
at org.apache.xerces.impl.xs.XMLSchemaValidator.findSchemaGrammar(Unknown
Source)
at org.apache.xerces.impl.xs.XMLSchemaValidator.handleStartElement(Unknown
Source)
at org.apache.xerces.impl.xs.XMLSchemaValidator.startElement(Unknown
Source)
at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown
Source)
at
org.apache.xerces.impl.XMLNSDocumentScannerImpl$NSContentDispatcher.scanRootElementHook(Unknown
Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown
Source)
at
org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown
Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)


at
org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:75)
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:396)

at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:342)
at
org.springframework.beans.factory.xml.XmlBeanDefinitionReader.loadBeanDefinitions(XmlBeanDefinitionReader.java:310)
at
org.springframework.beans.factory.support.AbstractBeanDefinitionReader.loadBeanDefinitions(AbstractBeanDefinitionReader.java:143)
at
org.mule.config.spring.MuleApplicationContext.loadBeanDefinitions(MuleApplicationContext.java:104)
at
org.springframework.context.support.AbstractRefreshableApplicationContext.refreshBeanFactory(AbstractRefreshableApplicationContext.java:123)
at
org.springframework.context.support.AbstractApplicationContext.obtainFreshBeanFactory(AbstractApplicationContext.java:422)
at
org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:352)
at
org.mule.config.spring.SpringRegistry.doInitialise(SpringRegistry.java:87)
at org.mule.registry.AbstractRegistry.initialise(AbstractRegistry.java:71)

at
org.mule.config.spring.SpringXmlConfigurationBuilder.createSpringRegistry(SpringXmlConfigurationBuilder.java:98)
at
org.mule.config.spring.SpringXmlConfigurationBuilder.doConfigure(SpringXmlConfigurationBuilder.java:69)
at
org.mule.config.builders.AbstractConfigurationBuilder.configure(AbstractConfigurationBuilder.java:39)
at
org.mule.config.builders.AbstractResourceConfigurationBuilder.configure(AbstractResourceConfigurationBuilder.java:78)
at
org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:96)
at
org.mule.context.DefaultMuleContextFactory.createMuleContext(DefaultMuleContextFactory.java:54)

--
View this message in context: http://www.nabble.com/Mule-and-OSGi-tp21708300p21812591.html

Andrew Perepelytsya

unread,
Feb 3, 2009, 10:59:10 AM2/3/09
to us...@mule.codehaus.org
Proxy? Then, it should've resolved it from a local cache and via spring.handlers...

Andrew

paquettd

unread,
Feb 3, 2009, 12:48:17 PM2/3/09
to us...@mule.codehaus.org

Exactly. I think that might be the problem. I bet since the spring.handlers
are in the spring OSGi bundles and not just sitting on the classpath that it
can't find them.

Usually when we use Spring-DM that takes care of things.. but I bet since
I'm launching in a "mule-first" instead of "spring-first" situation the
namespace resolver isn't setup right.

I'll try some things and post if I can solve it.

--
View this message in context: http://www.nabble.com/Mule-and-OSGi-tp21708300p21815117.html

Andrew Perepelytsya

unread,
Feb 3, 2009, 12:50:49 PM2/3/09
to us...@mule.codehaus.org
Check if you can get hold of a root spring context reference in your bundle activator and do a spring-first thing by passing it as a parent to Mule.

Andrew
Reply all
Reply to author
Forward
0 new messages