[
https://issues.apache.org/jira/browse/CXF-3268?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Daniel Kulp resolved CXF-3268.
------------------------------
Resolution: Not A Problem
Fix Version/s: Invalid
Assignee: Daniel Kulp
I'm marking this as "not a problem" as the generated code is correct per spec.
CXF 2.3.2 is a JAX-WS 2.2 compliant implementation and thus must generate code
compliant to the JAX-WS 2.2 specification which requires those constructors
like that. HOWEVER, to compile them on Java 6, you will likely need to endorse
the 2.2 jaxws-api jar (and likely the jaxb-api jar as well). See the 2.3
migration guide: http://cxf.apache.org/docs/23-migration-guide.html for some
details about the endorsed stuff.
The alternative workaround, right now, is to delete the api jars from
lib/endorsed. In that case, wsdl2java will detect that the 2.2 versions are
not available/endorsed and will switch to generating 2.1 compliant code.
I also just added a new frontend (will be there for 2.3.3) to force 2.1
behavior. With 2.3.3, you'll be able to do "wsdl2java -frontend jaxws21" to
tell it to use the JAX-WS 2.1 compliant frontend instead.
> wsdl2java generated Service class has overloaded constructors with
> WebServiceFeature ... features parameter
> -----------------------------------------------------------------------------------------------------------
>
> Key: CXF-3268
> URL: https://issues.apache.org/jira/browse/CXF-3268
> Project: CXF
> Issue Type: Bug
> Components: WS-* Components
> Affects Versions: 2.3.2
> Environment: Windows XP, Oracle jdk160_18
> Reporter: Gladwin
> Assignee: Daniel Kulp
> Priority: Blocker
> Fix For: Invalid
>
>
> wsdl2java generated Service class has overloaded constructors with
> WebServiceFeature ... features parameter which is passed on to *super*
> constructor. However {{javax.xml.ws.Service}} does not have required
> overloaded constructor causing compilation errors.
> Extract from wsdl2java output
> {{
> Loading FrontEnd jaxws ...
> Loading DataBinding jaxb ...
> wsdl2java -fe jaxws -db jaxb -wv 1.1 -verbose -client -autoNameResolution
> -mark-generated -sn MyXyzService
> -dC:\helios\my_workspace\proj-ws-gen\src\main\java -classdir
> C:\helios\my_workspace\proj-ws-gen\target\classes
> http://dev01.xyz.org:10003/Services/MyXyzService/V2?WSDL
> wsdl2java - Apache CXF 2.3.2
> }}
> Extract from generated service class showing overloaded constructors causing
> compile error
> {{
> @Generated(value = "org.apache.cxf.tools.wsdlto.WSDLToJava", date =
> "2011-01-21T15:44:35.467-05:00", comments = "Apache CXF 2.3.2")
> public class MyXyzService extends Service {
> ...
>
> @Generated(value = "org.apache.cxf.tools.wsdlto.WSDLToJava", date =
> "2011-01-21T15:44:35.467-05:00")
> public MyXyzService(WebServiceFeature ... features) {
> super(WSDL_LOCATION, SERVICE, features);
> }
> @Generated(value = "org.apache.cxf.tools.wsdlto.WSDLToJava", date =
> "2011-01-21T15:44:35.467-05:00")
> public MyXyzService(URL wsdlLocation, WebServiceFeature ... features) {
> super(wsdlLocation, SERVICE, features);
> }
> @Generated(value = "org.apache.cxf.tools.wsdlto.WSDLToJava", date =
> "2011-01-21T15:44:35.467-05:00")
> public MyXyzService(URL wsdlLocation, QName serviceName,
> WebServiceFeature ... features) {
> super(wsdlLocation, serviceName, features);
> }
> ...
> }
> }}
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.