History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: XFIRE-683
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Major Major
Assignee: Dan Diephouse
Reporter: Brad Sneade
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
XFire

Collection Generics resolve to xsd:ArrayOfTypeAny instead of ns1:ArrayOfGenerisizedType in the wsdl

Created: 29/Sep/06 10:53 AM   Updated: 29/Sep/06 07:51 PM
Component/s: Aegis Module, Annotations
Affects Version/s: 1.2.1
Fix Version/s: 1.2.2

Time Tracking:
Not Specified

Environment:
OSX 10.4.7
Eclipse 3.2.0
Jetty-6.0.0


 Description  « Hide
Collection generics which work in 1.2 no longer work in 1.2.1 when generating the wsdl. This can be replicated by annotating a service that has a @WebMethod that returns Collection<SomeObject> or annotating a bean (parameter or return type) that contains an attribute that is Collection<SomeObject>.

After some debugging (we are new to the xfire source) we believe we have traced the problem to changes in the org.codehaus.xfire.aegis.type.XMLTypeCreator. When entering the createCollectionTypeMethod(TypeClassInfo), the TypeClassInfo contains a genericType which is an instance of ParameterizedTypeImpl. In 1585, it is compared against Class, which is false, and moves on to the nextCreator. In our case nextCreator is a Java5TypeCreator. In the labeled version for 1.2.1 (1891), the info.getGenericType is passed into AbstractTypeCreator.createCollectionTypeFromGeneric(TypeClassInfo), which returns null since it is not aware of the ParameterizedTypeImpl. This causes the type to be returned as null and not move on to the child TypeCreator.



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Dan Diephouse - 29/Sep/06 04:27 PM
I've fixed this in SVN. Here is a patched build:

http://snapshots.repository.codehaus.org/org/codehaus/xfire/xfire-all/1.2-SNAPSHOT/xfire-all-1.2-20060929.210820-24.jar

We'll be doing 1.2.2 late this weekend. Thanks!


Brad Sneade - 29/Sep/06 05:25 PM
Works great, you rock! Looking forward to the 1.2.2 release.

Dan Diephouse - 29/Sep/06 07:51 PM
Well if I rocked, this probably wouldn't be an issue in the first place. Its kind of an embarassing bug actually and I was surprised to find there wasn't a unit test for it.