NutzCN Logo
问答 项目部署在本地能正常访问,部署到阿里云服务器就访问不了
发布于 2651天前 作者 qq_117e429a 3406 次浏览 复制 上一个帖子 下一个帖子
标签: jdk

另一个项目用spring框架部署到阿里服务器就可以用

9 回复

这是怎么回事

java.lang.UnsupportedClassVersionError: net/wendal/nutzbook/MainModule : Unsupported major.minor version 52.0 (unable to load class net.wendal.nutzbook.MainModule)
	at org.apache.catalina.loader.WebappClassLoader.findClassInternal(WebappClassLoader.java:2961)
	at org.apache.catalina.loader.WebappClassLoader.findClass(WebappClassLoader.java:1210)
	at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1690)
	at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1571)
	at java.lang.Class.forName0(Native Method)
	at java.lang.Class.forName(Class.java:190)
	at org.nutz.lang.Lang.loadClass(Lang.java:2063)
	at org.nutz.mvc.config.AbstractNutConfig.getMainModule(AbstractNutConfig.java:127)
	at org.nutz.mvc.config.AbstractNutConfig.createLoading(AbstractNutConfig.java:51)
	at org.nutz.mvc.ActionHandler.<init>(ActionHandler.java:18)
	at org.nutz.mvc.NutFilter._init(NutFilter.java:91)
	at org.nutz.mvc.NutFilter.init(NutFilter.java:69)
	at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:279)
	at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:260)
	at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:105)
	at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4809)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5485)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:632)
	at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1247)
	at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1898)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:745)

Aug 20, 2017 11:26:45 AM org.apache.catalina.core.ApplicationContext log
INFO: Cleaning up Shiro Environment
Aug 20, 2017 11:28:25 AM org.apache.catalina.core.ApplicationContext log
INFO: SessionListener: contextDestroyed()
Aug 20, 2017 11:28:25 AM org.apache.catalina.core.ApplicationContext log
INFO: ContextListener: contextDestroyed()

本地编译用了jdk8,但服务器上的是jdk6或者jdk7

现在我将阿里云服务器jdk换成1.8.0_144 本地的是"1.8.0_111

SEVERE: Unable to process Jar entry [org/nutz/filepool/SimpleFilePool.class] from Jar [jar:file:/alidata/server/tomcat-7.0.54/webapps/lzc/WEB-INF/lib/nutz-1.r.60.jar!/] for annotations
java.io.EOFException
	at java.io.DataInputStream.readUnsignedShort(DataInputStream.java:340)
	at org.apache.tomcat.util.bcel.classfile.Utility.swallowMethodParameters(Utility.java:796)
	at org.apache.tomcat.util.bcel.classfile.Attribute.readAttribute(Attribute.java:171)
	at org.apache.tomcat.util.bcel.classfile.FieldOrMethod.<init>(FieldOrMethod.java:57)
	at org.apache.tomcat.util.bcel.classfile.Method.<init>(Method.java:71)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readMethods(ClassParser.java:267)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:127)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2058)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:1934)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1900)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1885)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1317)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:876)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:374)
	at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5355)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:632)
	at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1247)
	at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1898)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

Aug 20, 2017 2:23:24 PM org.apache.catalina.startup.ContextConfig processAnnotationsJar
SEVERE: Unable to process Jar entry [org/nutz/filepool/SynchronizedFilePool.class] from Jar [jar:file:/alidata/server/tomcat-7.0.54/webapps/lzc/WEB-INF/lib/nutz-1.r.60.jar!/] for annotations
org.apache.tomcat.util.bcel.classfile.ClassFormatException: Constant pool at index 0 is null.
	at org.apache.tomcat.util.bcel.classfile.ConstantPool.getConstant(ConstantPool.java:204)
	at org.apache.tomcat.util.bcel.classfile.Attribute.readAttribute(Attribute.java:94)
	at org.apache.tomcat.util.bcel.classfile.FieldOrMethod.<init>(FieldOrMethod.java:57)
	at org.apache.tomcat.util.bcel.classfile.Method.<init>(Method.java:71)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readMethods(ClassParser.java:267)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:127)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2058)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:1934)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1900)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1885)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1317)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:876)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:374)
	at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5355)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:632)
	at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1247)
	at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1898)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

这是什么问题

添加回复
请先登陆
回到顶部