gpt4 book ai didi

java.lang.LinkageError : loader constraint violation in interface itable initialization 错误

转载 作者:塔克拉玛干 更新时间:2023-11-01 22:24:01 26 4
gpt4 key购买 nike

当我执行我的代码时,出现以下错误。这是我从 JDK 1.6 升级到 1.8 后发生的

java.lang.LinkageError: loader constraint violation in interface itable initialization: when resolving method "javax.security.auth.kerberos.JavaxSecurityAuthKerberosAccessImpl.keyTabTakeSnapshot(Ljavax/security/auth/kerberos/KeyTab;)Lsun/security/krb5/internal/ktab/KeyTab;" the class loader (instance of org/powermock/core/classloader/MockClassLoader) of the current class, javax/security/auth/kerberos/JavaxSecurityAuthKerberosAccessImpl, and the class loader (instance of <bootloader>) for interface sun/security/krb5/JavaxSecurityAuthKerberosAccess have different Class objects for the type javax/security/auth/kerberos/KeyTab used in the signature
at javax.security.auth.kerberos.KeyTab.<clinit>(KeyTab.java:100)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:264)
at org.apache.hadoop.security.UserGroupInformation.<clinit>(UserGroupInformation.java:609)

最佳答案

在测试用例中使用注解@PowerMockIgnore("javax.security.*") 解决了我的测试用例失败问题。

关于java.lang.LinkageError : loader constraint violation in interface itable initialization 错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32660836/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com