aries-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Samuel Bratton (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (ARIES-1486) can't create proxy on java 8 vm for interfaces containing lambda
Date Wed, 20 Jan 2016 09:59:39 GMT

     [ https://issues.apache.org/jira/browse/ARIES-1486?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Samuel Bratton updated ARIES-1486:
----------------------------------
    Attachment: aries-1486.patch

Java 8 adds synthetic private methods in support of default methods on interfaces. Attached
patch to ignore such methods. Added test case which will fail on Java 8 without the patch.
All test run cleanly on Java 7 and Java 8.

Absent the patch, the new test case will fail with following error:

checkInterfacesLambda(org.apache.aries.proxy.itests.BasicProxyBundlesTest)  Time elapsed:
0.198 sec  <<< ERROR!
java.lang.ClassFormatError: Absent Code attribute in method that is not native or abstract
in class file Proxyceee585d_5a1f_4c3c_af7a_91904d2b0f6f
        at java.lang.ClassLoader.defineClass1(Native Method)
        at java.lang.ClassLoader.defineClass(ClassLoader.java:760)
        at org.apache.aries.proxy.impl.interfaces.ProxyClassLoader.createProxyClass(ProxyClassLoader.java:157)



> can't create proxy on java 8 vm  for interfaces containing lambda
> -----------------------------------------------------------------
>
>                 Key: ARIES-1486
>                 URL: https://issues.apache.org/jira/browse/ARIES-1486
>             Project: Aries
>          Issue Type: Bug
>          Components: Proxy
>    Affects Versions: proxy-impl-1.0.5
>         Environment: Java 8 vm
>            Reporter: Samuel Bratton
>         Attachments: aries-1486.patch, proxyTest.patch
>
>
> Creating proxy of an interface containing a default method implemented with a lambda
will result in a invalid Proxy class file (see attached test case).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message