简体   繁体   中英

Java 7 to Java 11 migration blocking issue - Expecting a stackmap frame at branch target 91

I'm migrating an app from Jdk 7 to Jdk 11 , everything was going fine, the build was successful, but when i tried to run the migrated app (jdk 11) version, I faced the following error.

    Caused by: java.lang .VerifyError: Expecting a stackmap frame at branch target 91
    Exception Details:
    Location:

    Reason:
    Expected stackmap frame at this location.
    T
    Bytecode:
    0000000: 2b5a 05D2 021f 2a2a 1905 D802 253a 06b8
    0000010: 023a 06bd 0089 3a07 1907 032a 5319 0704
    0000020: 1905 5319 0705 1906 55bb 022a 5919 07D7
    0000050: 022d 1302 2eb6 0234 b202 4059 c700 1f57
    0000040: 1203 1302 4104 bd02 4359 0512 e153 b602
    0000050: 4713 023c b602 4059 b302 4000 c002 3cb6
    0000060: 0251 5761

Most solutions that i've viewed suggest to downgrade the project's jdk to jdk6 which won't work for me unfortunately, I tried to add -noverify option as VM Arguments and it resulted into some weird error I couldn't understand.

I also checked the compiled class byte code version which corresponds to 55<=>Jdk.11 .

I'm using the following jdk 11 distribution jdk-11.0.7.10-hotspot .

Thank you in advance

The option is -noverify with one - , not * --noverify with two.

If you are using any bytecode instrumentation or aspect-oriented programming libraries, anything that would use ASM, or using PowerMockito or Powermock to mock final classes, make sure you've upgraded those dependencies to newer versions, preferably the latest versions.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM