aries-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Bosschaert (JIRA)" <>
Subject [jira] [Commented] (ARIES-1470) java.util.ServiceConfigurationError
Date Thu, 10 Dec 2015 08:41:11 GMT


David Bosschaert commented on ARIES-1470:

Hi Setya,

So the odd one out here is this one:

bq. org.axonframework.serializer.ContentTypeConverter from file:/usr/apps/virgo-jetty-server-3.6.4.RELEASE/work/deployer/s/axonframework.plan-2.4/5/0/axon-core-2.4.jar/

all the other ones are loaded from .../repository/usr/axon-core-2.4.jar. So it would be interesting
to know why the code loads that class from that odd location. Maybe it's using the ThreadContextClassLoader
(TCCL) to load it, which would explain the 'random' behaviour as the TCCL could be set to
anything, but this is just a hunch.

*If* it's the TCCL and you have access to the code yourself, then you can set the TCCL to
the appropriate bundle classloader (just take a class loaded by the bundle and call {{clz.getClass().getClassLoader()}}
on it to get a bundle classloader). 
If you don't have access to the code and it's the TCCL then you can use SPI-Fly to weave in
TCCL setter calls...

> java.util.ServiceConfigurationError
> -----------------------------------
>                 Key: ARIES-1470
>                 URL:
>             Project: Aries
>          Issue Type: Bug
>          Components: SPI Fly
>    Affects Versions: spifly-1.0.6
>         Environment: Eclipse Virgo Jetty Server 3.6.4, Spring Framework 3.2.5
>            Reporter: Setya
> Deploying application that relies on 3rd party framework that's using ServiceLoader into
Eclipse Virgo intermittenly causes the following exception to be thrown:
> Caused by: java.util.ServiceConfigurationError: org.axonframework.serializer.ContentTypeConverter:
Provider org.axonframework.serializer.converters.ByteArrayToInputStreamConverter not a subtype
> 	at
> 	at java.util.ServiceLoader.access$300(
> 	at java.util.ServiceLoader$
> 	at java.util.ServiceLoader$
> 	at org.axonframework.serializer.ChainingConverterFactory.<init>(
> 	at org.axonframework.serializer.AbstractXStreamSerializer.<init>(
> 	at org.axonframework.serializer.AbstractXStreamSerializer.<init>(
> 	at org.axonframework.serializer.AbstractXStreamSerializer.<init>(
> 	at org.axonframework.serializer.xml.XStreamSerializer.<init>(
> 	at org.axonframework.contextsupport.spring.FileSystemEventStoreBeanDefinitionParser.doParse(
> 	at org.springframework.beans.factory.xml.AbstractSingleBeanDefinitionParser.parseInternal(
> 	at org.springframework.beans.factory.xml.AbstractBeanDefinitionParser.parse(
> 	at org.springframework.beans.factory.xml.NamespaceHandlerSupport.parse(
> 	at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(
> 	at org.springframework.beans.factory.xml.BeanDefinitionParserDelegate.parseCustomElement(
> 	at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.parseBeanDefinitions(
> 	at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.doRegisterBeanDefinitions(
> 	at org.springframework.beans.factory.xml.DefaultBeanDefinitionDocumentReader.registerBeanDefinitions(
> 	at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.registerBeanDefinitions(
> 	at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(
> 	... 21 common frames omitted
> Have tried to weave static bundle using SPI Fly, but the problem persists.

This message was sent by Atlassian JIRA

View raw message