SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sqlSessionFactory' defined in class path resource [app-ibatis.xml]: Invocation of init method failed; nested exception is java.lang.UnsupportedClassVersionError: com/afocus/web/core/dataDiagram/model/DataDiagram : Unsupported major.minor version 51.0
java.lang.UnsupportedClassVersionError: com/afocus/web/core/dataDiagram/model/DataDiagram : Unsupported major.minor version 51.0
因为,我们在本地使用的编译器和服务器上使用的编译器版本不同所致。
我在本地上编译使用的 JDk 版本是 jdk5.0, 而远程服务器上的 jdk 的版本是 jdk1.4, 所以我编译的程序在远程就出错。
本文探讨了因本地开发环境与服务器环境JDK版本不一致导致的应用部署失败问题。具体表现为编译后的程序在远程服务器上运行时出现UnsupportedClassVersionError错误。文章详细分析了问题的原因,并给出了相应的解决思路。

被折叠的 条评论
为什么被折叠?



