j2ee 应用中 jar 编码导致的错误 HTTP Status 500 - Internal Server Error

24 篇文章 0 订阅

  今天遇到一个 500 错误(java.lang.UnsupportedClassVersionError),属于来自服务器内部的错误。该 j2ee 程序在我的电脑上没问题,但在客户的服务器上却出现问题,而最近只升级过一个 jar 文件,而错误提示也与该文件有关,于是问题范围就缩小了。

  分析发现客户服务器上的 jdk 是 jdk 1.7,而我的电脑上是 jdk 1.8,而新发布的 jar 是以 jdk 1.8 为编码,那么问题就在于此,于是重新以 jdk 1.7 为编码进行编译并部署。至此,问题解决。

  当然,也可以升级客户的 jdk 版本至 1.8,也可以解决这个问题。


HTTP Status 500 - Internal Server Error


type Exception report

messageInternal Server Error

descriptionThe server encountered an internal error that prevented it from fulfilling this request.

exception

java.lang.UnsupportedClassVersionError: Class com.google.zxing.WriterException has unsupported major or minor version numbers, which are greater than those found in the Java Runtime Environment version 1.7.0_67

noteThe full stack traces of the exception and its root causes are available in the GlassFish Server Open Source Edition 4.1 logs.


GlassFish Server Open Source Edition 4.1




Q群讨论:236201801


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值