Closed DevonMiller-tfo closed 1 year ago
Hello. A related HK2 2.x patch in Payara: https://github.com/payara/patched-src-hk2/commit/568abf93115b2d224dc24823ab2906d18b6f8b86
It looks like there is a versioning issue. By version numbers, the latest hk2 is 3.0.1.payara-p1 and this is the one included in 6.2023.1. However, the build with the corrected ASM9 parameter is 2.6.1.payara-p7 which was built 6 months later.
It looks like there is a versioning issue. By version numbers, the latest hk2 is 3.0.1.payara-p1 and this is the one included in 6.2023.1. However, the build with the corrected ASM9 parameter is 2.6.1.payara-p7 which was built 6 months later.
Those are just Payara distributions as they try to support newer JDKs also for older Payara distributions. I believe the @robelcik just wanted to show how to do it. Otherwise it would be nice if Payara would create the PR for the official Eclipse's HK2 distribution, but they don't do that much often now.
But you can create the PR on your own too, sooner than we would get to it ;-)
There are 4 classes in org.glassfish.hk2:class-model that are initializing ASM by calling
super(Opcodes.ASM7)
. To support Java 17, these need to be passingOpcodes.ASM9
.The files are all in
class-model/src/main/java/org/glassfish/hk2/classmodel/reflect/impl/
:FieldSignatureVisitorImpl.java
MethodSignatureVisitorImpl.java
ModelClassVisitor.java
SignatureVisitorImpl.java
Additionally there is a class in org.glassfish.hk2:hk2-testing that also in initializing for Java 11: