On Tuesday 19 April 2011, Daniel Kulp wrote:
> On Tuesday 19 April 2011 8:38:31 AM Vassilis Virvilis wrote:
> > Hi
> > 
> > I am using the cxf 2.3.6 (we haven't upgraded yet to 2.4.0) and we have the
> > following exception on deploy (not in runtime)
> 
> There isn't a 2.3.6.   I assume 2.3.3?

Yes I meant 2.3.3. Sorry.

> In either case, if it worked with 2.2.x, I'm actually quite surprised and 
> would have been completely by accident.   For both JAXB and Aegis, the 
> interpretation of the generics is really just done for two cases (well, one 
> case for JAXB): 
> 
> 1) List<..>  - both JAXB and Aegis will handle this to determine the "type" 
> of 
> the list.    For the most part, it's treated the same as an []  of the type.
> 
> 2) Map<.. , ..> - Aegis will also look at this and create a pseudo map type 
> for it with key/value entries.   

So lists and maps are special.

> 
> That's  pretty much it at this point.   It MAY have worked with 2.2.x as I 
> think 2.2.x really didn't look at any of the generics much at all.   For the 
> most part, it would have seen the "getFirst"/"setFirst" methods on the Pair 
> and just treated them as the "Object" version and mapped them to xsd:any, 
> which is kind of a crappy schema, but it may have worked for you.   Again, 
> purely by accident and not by design. 

In 2.2.6 we had some heavy generic servlets that were working for java2java but 
they were failing
for java to js. I have filed a JIRA 
https://issues.apache.org/jira/browse/CXF-1758 for this but since we were just 
experimenting with js it was a toy problem. I think this confirms the works by 
accident theory.

> That all said, an NPE is definitely not what should occur.   A better 
> exception should be generated.    If you could create a small test case and 
> attach to a JIRA, that would be great. 
> 
> Dan
> 

Ok I will file a jira in wednesday after easter holdays :-)

Thanks for the detailed and helpful answer. It is much appreciated.


   Vassilis

Reply via email to