[
https://issues.apache.org/jira/browse/CXF-4144?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Sergey Beryozkin resolved CXF-4144.
-----------------------------------
Resolution: Fixed
Fix Version/s: 2.7.0
2.6.2
2.5.5
Assignee: Sergey Beryozkin
This can be optionally supported if org.apache.cxf.jaxrs.model.wadl.XMLName
annotation is available
> CXF JAXRS | Complex response types are not present in the generated wadl when
> returning list of objects
> -------------------------------------------------------------------------------------------------------
>
> Key: CXF-4144
> URL: https://issues.apache.org/jira/browse/CXF-4144
> Project: CXF
> Issue Type: Bug
> Components: JAX-RS
> Affects Versions: 2.5.2
> Reporter: Gayathri.Muralidharan
> Assignee: Sergey Beryozkin
> Labels: jax-rs, wadl, wadl2java
> Fix For: 2.5.5, 2.6.2, 2.7.0
>
>
> We use cxf 2.5.2 along with spring for exposing and consuming restful
> services. For distributing the service interface classes, we started using
> wadl2java goal (which generates interface classes based on the given wadl
> file)
> The generated wadl doesnt contain the proper response type, because of which
> i guess, the generated interfaces all have 'Response' as the return type.
> Ex. if the restful get method returns 'List' , the generated wadl contains
> the following segment only:
> <response><representation mediaType="application/json"/></response>
> and the corresponding interface generated from this wadl file contains the
> return type as 'Response'
> Can someone suggest what needs to be done to prevent the actual response type
> from getting lost? Are any annotations (like ElementClass ? how to use it ?)
> or providers required?
> Current code:
> @GET
> @Path("/itemsForCategory")
> @Produces("application/json")
> @Description("getItemsForCategory")
> public List<Item> getItemsForCategory(@QueryParam("category")String category)
> {//implementation}
> Found
> http://cxf.547215.n5.nabble.com/Problem-with-WADL-generation-and-returning-a-List-of-objects-td4713351.html#a5507490
> . But the issue doesnt seem to be fixed.
> Can someone help us out here?
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira