是什么导致“java.lang.IncompatibleClassChangeError:vtable stub”? [英] What causes "java.lang.IncompatibleClassChangeError: vtable stub"?

查看:2631
本文介绍了是什么导致“java.lang.IncompatibleClassChangeError:vtable stub”?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是什么导致java.lang.IncompatibleClassChangeError:vtable stub?在我们的应用程序中,我们已经看到这个错误随机出现并且很少(到目前为止只有两次,我们运行了很多)。即使重新启动应用程序,使用相同的jvm / jar而不重建也不容易重现。

What causes "java.lang.IncompatibleClassChangeError: vtable stub"? In our application, we have seen this error pop up randomly and very seldom (just twice so far, and we run it a lot). It is not readily reproducible, even when restarting the app, using the same jvm/jars without rebuilding.

至于我们的构建过程,我们清理所有类/ jar并重建它们,所以它与其他人遇到的问题不同,他们在一个类中进行了更改并且没有重新编译其他一些依赖类。

As for our build process, we clean all classes/jars and rebuild them, so it's not the same problem as others have encountered where they made a change in one class and didn't recompile some other dependent classes.

这与某些类不同与IncompatibleClassChangeError相关的其他问题 - 他们都没有提到vtable stub。事实上,在搜索IncompatibleClassChangeErrorvtable stub时,谷歌搜索结果出乎意料的很少。

This is unlike some of the other questions related to IncompatibleClassChangeError -- none of them mention "vtable stub". In fact, there are surprisingly few google results when searching for "IncompatibleClassChangeError "vtable stub"".

编辑:


  • 使用JDK 1.6.0_16。

  • 我们没有使用Java序列化。

  • 我们没有进行字节码操作。

  • 如前所述,我们正在做一个干净的构建,因此以前的构建中没有剩下的类。

  • Using JDK 1.6.0_16.
  • We are not using Java serialization.
  • We are not doing bytecode manipulation.
  • As mentioned earlier, we are doing a "clean build", so there are no classes left over from a previous build.

推荐答案

JVM字节码世界中的ABI断裂。查找Javadoc:
当某个类定义发生不兼容的类更改时抛出。当前正在执行的方法所依赖的某个类的定义已经发生了变化。

ABI breakage in the JVM byte-code world. Look up the Javadoc: "Thrown when an incompatible class change has occurred to some class definition. The definition of some class, on which the currently executing method depends, has since changed."

要查找的罪魁祸首是对静态最终文字值的更改,因为这些值会被复制在字节码中围绕优化。编辑:这可以像库升级的结果一样简单,我知道的唯一修复是干净的重建。

Culprits to look for would be changes to static final literal values because these get copied around in the byte code as "optimization". This can be as simple as the result of a library upgrade, the only fix I know of is a clean rebuild.

这篇关于是什么导致“java.lang.IncompatibleClassChangeError:vtable stub”?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆