cxf-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Christian Pfeifhofer (JIRA)" <>
Subject [jira] Created: (CXF-940) adding operations to wsdls make old clients fail
Date Fri, 24 Aug 2007 14:13:30 GMT
adding operations to wsdls make old clients fail

                 Key: CXF-940
             Project: CXF
          Issue Type: Improvement
          Components: Service Model
    Affects Versions: 2.0
            Reporter: Christian Pfeifhofer

Using the old client code generated by wsdl2java to call a webservice which has been extended
to support a new operation leads to an exception at runtime: org.apache.cxf.service.factory.ServiceConstructionException:
No method was found for the WSDL operation {}rbpNewOperationWithExistingDatatypes.
	at org.apache.cxf.jaxws.ServiceImpl.getPort(
	at RbpModifyContractOperationsImplTestBase.testStandardCall(
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(
	at java.lang.reflect.Method.invoke(
	at junit.framework.TestCase.runTest(
	at junit.framework.TestCase.runBare(
	at org.springframework.test.ConditionalTestCase.runBare(
	at junit.framework.TestResult$1.protect(
	at junit.framework.TestResult.runProtected(
	at junit.framework.TestSuite.runTest(
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(
	at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(
Caused by: org.apache.cxf.service.factory.ServiceConstructionException: No method was found
for the WSDL operation {}rbpNewOperationWithExistingDatatypes.
	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeWSDLOperations(
	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.buildServiceFromWSDL(
	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.initializeServiceModel(
	at org.apache.cxf.service.factory.ReflectionServiceFactoryBean.create(
	at org.apache.cxf.frontend.AbstractEndpointFactory.createEndpoint(
	at org.apache.cxf.frontend.ClientFactoryBean.create(
	at org.apache.cxf.frontend.ClientProxyFactoryBean.create(
	at org.apache.cxf.jaxws.ServiceImpl.createPort(
	at org.apache.cxf.jaxws.ServiceImpl.getPort(
	... 23 more

I had a look into (specifically initializeWSDLOperations())
where the exception is thrown

Seems like the model build from the new wsdl is compared to the old wsdl2java-generated interface
file. If there are any operation not found in the java interface an exception is thrown. 

To support backward compatibility and loose coupling between web service providers and clients,
it would be better to ignore methods not mentioned in the java interface file instead, as
they can not be called via the interface anyway.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message