aries-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Richard Ellis <RICEL...@uk.ibm.com>
Subject Re: Latest JDK and ASM based proxies....
Date Fri, 15 Jun 2012 13:47:43 GMT
I believe that this problem is limited to the subclass proxy and not the 
newer improved WeavingHook based proxy. So for cases where people want to 
use both a very recent JVM and a class that does not have an accessible 
zero-arg constructor there is the option to move up to use proxy 0.4 and 
an OSGi 4.3 based framework.

Rich



From:   Jean-Baptiste Onofré <jb@nanthrax.net>
To:     dev@aries.apache.org, 
Date:   15/06/2012 14:23
Subject:        Re: Latest JDK and ASM based proxies....



Thanks Dan,

+1 (non binding) to pull in 0.3.x and cut off a new release.

Regards
JB

On 06/15/2012 03:20 PM, Daniel Kulp wrote:
>
> The latest JDK updates for 1.6.0_u33 and 1.7.0_u5 contain a much 
stricter
> class verifier that refuses to verify the classes we generate for our 
ASM
> based proxies.   Basically, when we generate the constructor for the 
proxy,
> we were trying to bypass all the constructors for the superclasses and
> calling the equivalent of Object.super().    That is no longer allowed.
> Per java spec, the constructor MUST call a valid constructor on the
> immediate superclass.   You cannot "skip" parent and such.  Plus, it 
must be
> VALID to call the constructor.
>
> I've updated trunk to use any non-private no-arg constructor on the
> superclass.   That works for most of the cases.   However, we do have a
> testcase that tests proxying a class with a private no-arg constructor.
> There is NO WAY we can proxy that now unless someone has a new brilliant
> idea.   We also cannot proxy classes that don't have a no-arg 
constructor
> for similar reasons.  Anyone have any thoughts?    The fix gets a 
majority
> of the use cases working again.   For the other cases, it DOES fall back 
to
> the old method which would allow them to work on the older JDK's, but 
they
> will continue to fail on the newer JDK's.
>
>
> I'd like to pull this back into a 0.3.x fix and start a release real 
soon.
> This problem breaks a TON of stuff when using the new JDK's and thus a 
lot
> of applications will likely break.   Getting a fix out quickly is likely 
a
> good idea.
>

-- 
Jean-Baptiste Onofré
jbonofre@apache.org
http://blog.nanthrax.net
Talend - http://www.talend.com








Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number 
741598. 
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU






Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message