8 Replies Latest reply on Sep 18, 2007 1:37 PM by Fabio Miranda

    NoSuchMethodError in remote client WS  call

    Rick Holland Newbie

      I am getting the following error when trying to get a Service instance in a remote client to an example Web service I have deployed to JBoss 4.0.4GA:

      java.lang.NoSuchMethodError: com.ibm.wsdl.xml.WSDLReaderImpl.setEntityResolver(Lorg/xml/sax/EntityResolver;)V

      Here is my client code:
      ------------------------------------------------------------------------------
      String urlstr = "http://bldl99m4596:8090/TestJBossWS?wsdl";
      System.out.println("Contacting webservice at " + urlstr);
      URL url = new URL(urlstr);
      QName qname = new QName("http://org.jboss.ws/samples/jsr181pojo/",
      "TestService");

      ServiceFactory factory = ServiceFactory.newInstance();
      Service service = factory.createService(url, qname);

      ------------------------------------------------------------------------------

      And the stack:

      Exception in thread "main" java.lang.NoSuchMethodError: com.ibm.wsdl.xml.WSDLReaderImpl.setEntityResolver(Lorg/xml/sax/EntityResolver;)V
      at org.jboss.ws.metadata.wsdl.WSDLDefinitionsFactory.parse(WSDLDefinitionsFactory.java:142)
      at org.jboss.ws.metadata.ServiceMetaData.getWsdlDefinitions(ServiceMetaData.java:273)
      at org.jboss.ws.metadata.JSR109ClientMetaDataBuilder.buildMetaData(JSR109ClientMetaDataBuilder.java:106)
      at org.jboss.ws.metadata.JSR109ClientMetaDataBuilder.buildMetaData(JSR109ClientMetaDataBuilder.java:78)
      at org.jboss.ws.jaxrpc.ServiceImpl.(ServiceImpl.java:96)
      at org.jboss.ws.jaxrpc.ServiceFactoryImpl.createService(ServiceFactoryImpl.java:157)
      at org.jboss.ws.jaxrpc.ServiceFactoryImpl.createService(ServiceFactoryImpl.java:128)
      at testws.TestClient.getEndPoint(TestClient.java:54)
      at testws.TestClient.main(TestClient.java:37)

      I assume I have the wrong version of some jar, any help would be appreciated.

      Rick Holland