Bug 1336481 - Rebase: Upgrade ECJ to at least 4.4
Summary: Rebase: Upgrade ECJ to at least 4.4
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: ecj
Version: 6.8
Hardware: Unspecified
OS: Unspecified
Target Milestone: rc
: ---
Assignee: Elliott Baron
QA Contact: Lukáš Zachar
Depends On:
Blocks: 1269194 1361283 1223609 1337940 1379855
TreeView+ depends on / blocked
Reported: 2016-05-16 15:14 UTC by Coty Sutherland
Modified: 2020-04-15 14:29 UTC (History)
16 users (show)

Fixed In Version:
Doc Type: Rebase: Bug Fixes and Enhancements
Doc Text:
ECJ is the Java bytecode compiler of the Eclipse Platform. It is also known as the JDT Core batch compiler. Previously, ECJ was unable to compile Java code that used features introduced in Java 8, such as Lambda expressions. Compilation would also fail for Java code that referenced class files containing Java 8 features, including system classes part of the Java Runtime Environment. Users should upgrade to this updated package, which provides a newer version of ECJ that is fully compatible with Java 8 code.
Clone Of:
: 1379855 (view as bug list)
Last Closed: 2017-03-21 09:01:31 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1338903 0 unspecified CLOSED java-1.8.0-openjdk problem with tomcat6 2021-02-22 00:41:40 UTC
Red Hat Knowledge Base (Solution) 2294701 0 None None None 2016-05-16 17:48:04 UTC
Red Hat Product Errata RHBA-2017:0566 0 normal SHIPPED_LIVE ecj bug fix update 2017-03-21 12:22:50 UTC

Internal Links: 1338903

Description Coty Sutherland 2016-05-16 15:14:02 UTC
With the latest update to java-1.8.0-openjdk (java-1.8.0-openjdk-headless- all JSP compilation for tomcat6 is broken. The workaround for the problem is to revert the java update to a previously stable release.

The reason for the problem is that ECJ's JDTCompiler classes have some sort of incompatibility with the OpenJDK update's java.io.ObjectInputStream class. This compatibility issue is causing an exception and preventing JSPs from compiling on tomcat6. See attached bug (https://bugzilla.redhat.com/show_bug.cgi?id=1223609#c13) for more details on this.

Is it possible to rebase ECJ to at least 4.4 to correct this?

Comment 1 Andrew John Hughes 2016-05-16 15:28:11 UTC
Yeah, the fix for "S8144430, CVE-2016-3427: Improve JMX connections" adds:

+    static {
+        SharedSecrets.setJavaObjectInputStreamAccess(ObjectInputStream::setValidator);
+    }

to java.io.ObjectInputStream. We had to remove this for the OpenJDK 7 backport.

It's mainly luck if you've managed to use a Java 8 class library with a compiler that doesn't support Java 8 so far. This is only going to get worse on subsequent updates, as Oracle show no sign of avoiding using Java 8 features. Tomcat either needs to use the OpenJDK 7 class library or ecj needs to be upgraded.

Comment 2 Deepak Bhole 2016-05-16 17:10:35 UTC
Assigning to Elliott to study the effects of an ECJ update and then update it as appropriate.

Comment 50 errata-xmlrpc 2017-03-21 09:01:31 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.