2 Replies Latest reply on Oct 20, 2016 1:41 PM by eduardocl

    Webservice Call failing

    eduardocl

      Hello folks,

       

      I'm currently porting a legacy code on my company to JBoss EAP 6.1, originally built on top of Tomcat 5. I have a code calling a SOAP service using Axis 1.1, basically doing the following:

       

      QName qNameSvc  = new QName(getEndPoint(), getNameSpaceURI());         

      QName qNamePort = new QName(getEndPoint(), ClienteWS.getPortQN());                  

      ServiceFactory sf = ServiceFactory.newInstance();        

      Service svc = sf.createService(qNameSvc);         

      Call mycall = (Call)svc.createCall(qNamePort);         

      Call mycall = (Call)svc.createCall(qNamePort);         

      mycall.setTargetEndpointAddress(getEndPoint());         

      mycall.setOperationName(new QName(getNameSpaceURI(), getService()));        

      mycall.invoke(new Object[] {xmlConsulta});

       

      But, executing the code I got the following stack trace:

      javax.xml.rpc.ServiceException: Cannot find ServiceFactory implementation   at javax.xml.rpc.ServiceFactory.newInstance(ServiceFactory.java:94)   at br.gov.infoseg.soap.ClienteWS.getCallWebService(ClienteWS.java:58)   at br.gov.infoseg.soap.ClienteWS.requisitaServicoEstado(ClienteWS.java:51)   at br.gov.infoseg.servicos.individuos.service.IndividuosFacadeREST.buscaDetalhe(IndividuosFacadeREST.java:114)   at br.gov.infoseg.servicos.individuos.service.IndividuosFacadeREST$Proxy$_$$_WeldSubclass.buscaDetalhe(IndividuosFacadeREST$Proxy$_$$_WeldSubclass.java)   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)   at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)   at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)   at java.lang.reflect.Method.invoke(Method.java:497)

       

      Any ideas?

        • 1. Re: Webservice Call failing
          pjhavariotis

          Have you added a dependency on org.jboss.ws.native.jbossws-native-core through either META-INF/MANIFEST.MF or jboss-deployment-structure.xml ? If you haven't I suggest you to do so.

          1 of 1 people found this helpful
          • 2. Re: Webservice Call failing
            eduardocl

            I did, but sadly, I got the stack: Caused by: java.lang.ClassNotFoundException: javax.ejb.SessionBean from [Module "org.jboss.ws.native.jbossws-native-core:main" from local module loader @ceb1a5 (finder: local module finder @16d8735