Hi, This ClassCastException in OSGi container usually means Calss A and B are loaded by different classloaders, that means you have multiple copy of org.apache.xerces.jaxp.SAXParserFactoryImpl or javax.xml.parsers.SAXParserFactory in your container, as in ServiceMix we already endorse the xercesImpl and xml-apis you shouldn't install those bundle yourself or you shouldn't include the classes in your axis bundle. Could you please post the result of
package:export |grep javax.xml.parsers and package:export |grep org.apache.xerces.jaxp from the console? Regards Krzysztof On 06.04.2015 17:45, anas bakhou wrote: > I made a <import-Package>*</import-Package> and the plugin that Contains the > jars has just exported package !! When i make update to my bundle , I got > another error: > Caused by: java.lang.ExceptionInInitializerError > at > org.apache.axis.configuration.FileProvider.configureEngine(FileProvider.java:179) > at > org.apache.axis.AxisEngine.init(AxisEngine.java:172)[700:Test5:1.0.0] > at > org.apache.axis.AxisEngine.<init>(AxisEngine.java:156)[700:Test5:1.0.0] > at > org.apache.axis.client.AxisClient.<init>(AxisClient.java:52)[700:Test5:1.0.0] > at > org.apache.axis.client.Service.getAxisClient(Service.java:104)[700:Test5:1.0.0] > at > org.apache.axis.client.Service.<init>(Service.java:113)[700:Test5:1.0.0] > at > com.atlassian.jira.rpc.soap.client.test.JiraSoapServiceServiceLocator.<init>(JiraSoapServiceServiceLocator.java:16)[692:JiraSoapClientCamelBlueprint.JiraSoapClientCamelBlueprint:0.0.1.SNAPSHOT] > at > com.atlassian.jira.soap.SOAPSession.<init>(SOAPSession.java:27)[692:JiraSoapClientCamelBlueprint.JiraSoapClientCamelBlueprint:0.0.1.SNAPSHOT] > at > com.atlassian.jira.soap.CreateSimpleProject.process(CreateSimpleProject.java:33)[692:JiraSoapClientCamelBlueprint.JiraSoapClientCamelBlueprint:0.0.1.SNAPSHOT] > at > org.apache.camel.processor.DelegateSyncProcessor.process(DelegateSyncProcessor.java:63) > ... 8 more > Caused by: java.lang.ClassCastException: > org.apache.xerces.jaxp.SAXParserFactoryImpl cannot be cast to > javax.xml.parsers.SAXParserFactory > at > javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:135)[700:Test5:1.0.0] > at > org.apache.axis.utils.XMLUtils.initSAXFactory(XMLUtils.java:209)[700:Test5:1.0.0] > at > org.apache.axis.utils.XMLUtils.<clinit>(XMLUtils.java:110)[700:Test5:1.0.0] > ... 18 more > I think that the error comes from that point !! Are there any solutions to > this problem :( > > > > -- > View this message in context: > http://servicemix.396122.n5.nabble.com/Caused-by-java-lang-NoClassDefFoundError-org-apache-axis-deployment-wsdd-WSDDConstants-tp5722456p5722474.html > Sent from the ServiceMix - User mailing list archive at Nabble.com. -- Krzysztof Sobkowiak JEE & OSS Architect Apache Software Foundation Member Apache ServiceMix <http://servicemix.apache.org/> Committer & PMC chair Senior Solution Architect @ Capgemini SSC <http://www.pl.capgemini-sdm.com/en/>