Thanks Deepal for your quick response. Here is the message receiver part of my services.xml file,
<messageReceivers> <messageReceiver mep="http://www.w3.org/ns/wsdl/in-out" class="com.xxx.www.MyServiceMessageReceiverInOut"/> </messageReceivers> And I DO have it in the compiled class. I have searched over web, and read some where that the service needs to be compiled using the same version of jdk as the one Axis2 container is running under. I have compiled the service using jdk 1.6. Does it mean that I need to build the Axis2 war distribution from source file using jdk 1.6, or is it sufficient to just use the war distribution and standard binary distriubtion of Axis2 1.4.1 from the site http://ws.apache.org/axis2/download/1_4_1/download.cgi? Your help is much appreciated! Jessie ________________________________ From: Deepal Jayasinghe <dee...@opensource.lk> To: java-user@axis.apache.org Sent: Wed, July 21, 2010 3:58:43 PM Subject: Re: [Axis2] Error Loading Message Receiver - Please help Hi Dan, When you generate the code it generates services.xml file and it has entry for one or more Message receivers, check whether you have all of them in the compiled class before you create the aar, if you have all the classes then we can go to next step to solve the problem. Deepal On Wed, Jul 21, 2010 at 3:39 PM, Dan Wang <jessiedanw...@yahoo.com> wrote: Hi, > >I have struggled with the deploy exception for more than a week. Here is my >development environment, Axis2 1.4.1, JDK 1.6, Tomcat 6. I have generated the >skeleton, message receiver and related java files using WSDL2Java tool (adb >binding). I have tried to deploy the service in standalone Axis2 server using >aar file, also tried to deploy in Tomcat 6 using exploded service archive, >however, I am getting faulty service ( DeploymentException: >ClassNotFoundException error occurred in loading the message receiver). > >I have also tried to embed the web service in a servlet web app, and deployed >the war file into Tomcat, I am getting same error, see below for details. > >I have searched all over web, but did not find anything useful to resolve this >issue. I have made sure that the service is compiled with jdk 1.6 and the >server >is running using jdk 1.6, I have also made sure to include all Axis2 libraries >in either the service or the web app. > >Any ideas what could be wrong here, or how to debug the issue? The message >receiver class IS in the service archive or the web app, but it seems that the >class loader is having trouble finding it? Any suggestions will be greatly >appreciated. > >Jessie > >org.apache.axis2.deployment.DeploymentException: A ClassNotFoundExceptionerror >occurred in loading the message receiver >com.xxx.www.MyServiceMessageReceiverInOut > at >org.apache.axis2.deployment.ServiceGroupBuilder.populateServiceGroup(ServiceGroupBuilder.java:106) > > at >org.apache.axis2.deployment.repository.util.ArchiveReader.buildServiceGroup(ArchiveReader.java:110) > > at >org.apache.axis2.deployment.repository.util.ArchiveReader.processServiceGroup(ArchiveReader.java:179) > > at >org.apache.axis2.deployment.ServiceDeployer.deploy(ServiceDeployer.java:81) > at >org.apache.axis2.deployment.repository.util.DeploymentFileData.deploy(DeploymentFileData.java:136) > > at >org.apache.axis2.deployment.DeploymentEngine.doDeploy(DeploymentEngine.java:597) > at >org.apache.axis2.deployment.repository.util.WSInfoList.update(WSInfoList.java:144) > > at >org.apache.axis2.deployment.RepositoryListener.update(RepositoryListener.java:330) > > at >org.apache.axis2.deployment.RepositoryListener.checkServices(RepositoryListener.java:227) > > at >org.apache.axis2.deployment.DeploymentEngine.loadServices(DeploymentEngine.java:131) > > at >org.apache.axis2.deployment.WarBasedAxisConfigurator.loadServices(WarBasedAxisConfigurator.java:284) > > at >org.apache.axis2.context.ConfigurationContextFactory.createConfigurationContext(ConfigurationContextFactory.java:82) > > at >org.apache.axis2.transport.http.AxisServlet.initConfigContext(AxisServlet.java:516) > > at org.apache.axis2.transport.http.AxisServlet.init(AxisServlet.java:436) > at >org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1173) > at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:993) > at >org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4187) > > at >org.apache.catalina.core.StandardContext.start(StandardContext.java:4496) > at >org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:791) > at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:771) > at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:546) > at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:905) > at org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:740) > at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:500) > at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1277) > at >org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:321) > at >org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119) > > at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1053) > at org.apache.catalina.core.StandardHost.start(StandardHost.java:785) > at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1045) > at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443) > at >org.apache.catalina.core.StandardService.start(StandardService.java:519) > at org.apache.catalina.core.StandardServer.start(StandardServer.java:710) > at org.apache.catalina.startup.Catalina.start(Catalina.java:581) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) > at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) > at java.lang.reflect.Method.invoke(Unknown Source) > at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:289) > at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:414) >