apache / tomcat-jakartaee-migration

Apache Tomcat migration tool for Jakarta EE
https://tomcat.apache.org/
Apache License 2.0
140 stars 53 forks source link

Workaround for JDK-8303866 makes migrated jar incompatible with latest JDK releases #48

Closed DanielThomas closed 7 months ago

DanielThomas commented 1 year ago

The zip validation changes for JDK-8302483 causes failures to load jars output by the migration tool:

lombok-1.18.28.jar; Invalid CEN header (invalid zip64 extra data field size)

The problem appears to be the workaround for JDK-8303866, the field removal appears to cause the problem:

https://github.com/apache/tomcat-jakartaee-migration/blob/4b767e426dfa1cf4b565eb328d51fe1ddb043825/src/main/java/org/apache/tomcat/jakartaee/Migration.java#L317C40-L320

We're currently using in-memory transforms as a workaround, but because we're using the tool in https://github.com/nebula-plugins/gradle-jakartaee-migration-plugin/ and they run in parallel, that can lead to heap utilization issues in builds.

These Lombok jars are the only ones we've run into trouble with.

markt-asf commented 8 months ago

I can't repeat this. Please provide:

DanielThomas commented 7 months ago

Some improvements got made to this mitigation in later JDK releases, due to false positives in the detection, so I think this has been addressed upstream.