My Oracle Support Banner

Proxy Creation - Enable Root Package For Generated Types Field- Causes "Two declarations cause a collision in the ObjectFactory class" Error (Doc ID 2530921.1)

Last updated on APRIL 22, 2019

Applies to:

Oracle JDeveloper - Version 11.1.1.5.0 to 11.1.1.9.0 [Release Oracle11g]
Information in this document applies to any platform.

Symptoms

When trying to create a Web service proxy based on a WSDL from a WSDL URL (http://<HOSTNAME>/WebServices/Service.asmx?WSDL), at step 3, after entering the WSDL URL, the following error is generated in JDeveloper 11.1.1.9:

 

oracle.jdeveloper.webservices.model.WebServiceException: 

Error creating model from wsdl "file:/C:/Servicesv3.wsdl":
A class/interface with the same name "com.AddItemResponse" is already in use.
Use a class customization to resolve this conflict.
(Relevant to above error) another "CloseoutResponse" is generated from here. A class/interface with the same name "com.AddPackageResponse" is already in use.
Use a class customization to resolve this conflict.
(Relevant to above error) another "UpdateOrderResponse" is generated from here.
(Relevant to above error) another "AddItemResponse" is generated from here.
Two declarations cause a collision in the ObjectFactory class.A class/interface with the same name "com.CloseoutResponse" is already in use.
Use a class customization to resolve this conflict. A class/interface with the same name "com.UpdateOrderResponse" is already in use. Use a class customization to resolve this conflict.
(Related to above error) This is the other declaration.
(Relevant to above error) This confusing error happened most likely because the schema uses a technique called "chameleon schema",
which causes a single definition to be loaded multiple times into different namespaces.

(Relevant to above error) another "AddPackageResponse" is generated from here.
at oracle.jdeveloper.webservices.model.java.JavaWebService.createPortTypes(JavaWebService.java:1635)
at oracle.jdeveloper.webservices.model.WebService.createServiceFromWSDL(WebService.java:2853)
at oracle.jdeveloper.webservices.model.WebService.createServiceFromWSDL(WebService.java:2618)
at oracle.jdeveloper.webservices.model.java.JavaWebService.(JavaWebService.java:509)
at oracle.jdeveloper.webservices.model.java.JavaWebService.(JavaWebService.java:461)
at oracle.jdeveloper.webservices.model.proxy.WebServiceProxy$ProxyJavaWebService.(WebServiceProxy.java:2278)
at oracle.jdeveloper.webservices.model.proxy.WebServiceProxy.updateServiceModel(WebServiceProxy.java:1701)
at oracle.jdeveloper.webservices.model.proxy.WebServiceProxy.setDescription(WebServiceProxy.java:525)
at oracle.jdevimpl.webservices.wizard.jaxrpc.proxy.ProxyJaxWsSpecifyWSDLPanel.setDescription(ProxyJaxWsSpecifyWSDLPanel.java:238)
at oracle.jdevimpl.webservices.wizard.jaxrpc.common.SpecifyWsdlPanel.buildModel(SpecifyWsdlPanel.java:1109)
at oracle.jdevimpl.webservices.wizard.jaxrpc.common.SpecifyWsdlPanel$5.run(SpecifyWsdlPanel.java:661)
at oracle.ide.dialogs.ProgressBar.run(ProgressBar.java:655)
at java.lang.Thread.run(Thread.java:662)
Caused by: oracle.jdeveloper.webservices.tools.WsdlValidationException:
Error creating model from wsdl "file:/C:/Servicesv3.wsdl":
Caused by: oracle.j2ee.ws.common.tools.api.ValidationException:
Error creating model from wsdl "file:/C:/Servicesv3.wsdl":
A class/interface with the same name "com.AddItemResponse" is already in use.
Use a class customization to resolve this conflict.(Relevant to above error) another "CloseoutResponse" is generated from here.
A class/interface with the same name "com.AddPackageResponse" is already in use.
Use a class customization to resolve this conflict.(Relevant to above error) another "UpdateOrderResponse" is generated from here.
(Relevant to above error) another "AddItemResponse" is generated from here.
Two declarations cause a collision in the ObjectFactory class.
A class/interface with the same name "com.CloseoutResponse" is already in use.
Use a class customization to resolve this conflict. A class/interface with the same name "com.UpdateOrderResponse" is already in use. Use a class customization to resolve this conflict.
(Related to above error) This is the other declaration.
(Relevant to above error) This confusing error happened most likely because the schema uses a technique called "chameleon schema",
which causes a single definition to be loaded multiple times into different namespaces.

 



Changes

 

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Changes
Cause
Solution


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.