Unsupported major.minor version 52.0 (unable to load class com.xxx.xxx)

JDK10规划中,JDK9已经推出,JDK8也出现几年了,现在越来越多的企业升级到JDK8,但是在升级过程中,稍有不周,就会遇到JDK版本不兼容的问题,这不,本人今天就遇到了,jenkins上用jdk8版本编译构建项目,部署服务器还没升级jdk,还是用jdk7(运维大哥遗漏的),导致在部署web工程师报: Unsupported major.minor version 52.0 (unable to load class com.xxx.xxx) 问题,经过把部署服务器的jdk升级到8版本之后,问题解决。

1525202:org.springframework.beans.factory.CannotLoadBeanClassException: Error loading class [com.xxx.xxx] for bean with name 'systemConstant' defined in file [/home/test/data/webapps8020/xxx/WEB-INF/classes/xxx/xxx/xxx.class]: problem with class file or dependent class; nested exception is java.lang.UnsupportedClassVersionError: xxx/xxx/xxx : Unsupported major.minor version 52.0 (unable to load class com.xxx.xxx)
1525791- at org.springframework.beans.factory.support.AbstractBeanFactory.resolveBeanClass(AbstractBeanFactory.java:1331)
1525905- at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.determineTargetType(AbstractAutowireCapableBeanFactory.java:622)
1526051- at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.predictBeanType(AbstractAutowireCapableBeanFactory.java:591)
1526193- at org.springframework.beans.factory.support.AbstractBeanFactory.isFactoryBean(AbstractBeanFactory.java:1397)
1526304- at org.springframework.beans.factory.support.DefaultListableBeanFactory.doGetBeanNamesForType(DefaultListableBeanFactory.java:434)
1526436- at org.springframework.beans.factory.support.DefaultListableBeanFactory.getBeanNamesForType(DefaultListableBeanFactory.java:404)
1526566- at org.springframework.beans.factory.BeanFactoryUtils.beanNamesForTypeIncludingAncestors(BeanFactoryUtils.java:186)
1526683- at org.springframework.aop.framework.autoproxy.BeanFactoryAdvisorRetrievalHelper.findAdvisorBeans(BeanFactoryAdvisorRetrievalHelper.java:73)
1526825- at org.springframework.aop.framework.autoproxy.AbstractAdvisorAutoProxyCreator.findCandidateAdvisors(AbstractAdvisorAutoProxyCreator.java:101)
1526969- at org.springframework.aop.aspectj.annotation.AnnotationAwareAspectJAutoProxyCreator.findCandidateAdvisors(AnnotationAwareAspectJAutoProxyCreator.java:85)
--

你可能感兴趣的:(工作记录)