zoukankan      html  css  js  c++  java
  • jdk版本和spring版本不匹配引起的500

    jdk版本和spring版本不匹配引起的500

    01) jdk如果是1.8以上的,那么springframwork版本建议使用4.0以上的版本

    HTTP Status 500 – Internal Server Error
    Type Exception Report
    
    Message An exception occurred processing JSP page [/dafei/header.jsp] at line [23]
    
    Description The server encountered an unexpected condition that prevented it from fulfilling the request.
    
    Exception
    
    org.apache.jasper.JasperException: An exception occurred processing JSP page [/dafei/header.jsp] at line [23]
    
    20: <html xmlns="http://www.w3.org/1999/xhtml">
    21: <head>
    22: <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    23: <title><%=newJcpeizhi.getJcpeizhiName()%></title>
    24: <link rel="stylesheet" type="text/css" href="<%=basePath %>jquery-easyui-1.3.3/themes/default/easyui.css">
    25: <link rel="stylesheet" type="text/css" href="<%=basePath %>jquery-easyui-1.3.3/themes/icon.css">
    26: <script type="text/javascript" src="<%=basePath %>jquery-easyui-1.3.3/jquery.min.js"></script>
    
    
    Stacktrace:
        org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:617)
        org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:514)
        org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:386)
        org.apache.jasper.servlet.JspServlet.service(JspServlet.java:330)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:742)
        org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
        org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
    Root Cause
    
    java.lang.NullPointerException
        org.apache.jsp.dafei.index_jsp._jspService(index_jsp.java:384)
        org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:742)
        org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:476)
        org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:386)
        org.apache.jasper.servlet.JspServlet.service(JspServlet.java:330)
        javax.servlet.http.HttpServlet.service(HttpServlet.java:742)
        org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
        org.springframework.web.filter.CharacterEncodingFilter.doFilterInternal(CharacterEncodingFilter.java:88)
        org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:107)
    Note The full stack trace of the root cause is available in the server logs.
    
    Apache Tomcat/8.5.39
    View Code

    02) 然后去spring官网下载对应点jar包 

    spring jar包下载地址

    03)  下载完成后手动升级项目中的spring包[  没有使用maven,需要手动升级 ]

    把项目lib下面和spring有关的包都替换成spring4.0以上的版本,然后重启项目即可[ 项目中的配置一般不需要修改,除非遇到废除的方法 ]

     04) 另一种报错 

    HTTP Status 500-Servlet.init() for servlet [springmvc] threw exception解决办法

    这种报错也是因为spring 版本和jdk版本不匹配造成的 

    HTTP Status 500-Servlet.init 报错参考地址

    其他: 

    spring jar包下载地址

  • 相关阅读:
    使用Logstash把MySQL数据导入到Elasticsearch中
    通过Metricbeat实现外部对Elastic Stack的监控
    使用Elasticsearch的processors来对csv格式数据进行解析
    redis学习网址
    部署文件:filebeat->kafka集群(zk集群)->logstash->es集群->kibana
    ios实例开发精品文章推荐(8.13)
    ios实例开发精品文章推荐(8.12)11个处理触摸事件和多点触摸的JS库
    Android开发环境——模拟器AVD相关内容汇总
    Android开发环境——Eclipse ADT相关内容汇总
    Android开发环境——SDK相关内容汇总
  • 原文地址:https://www.cnblogs.com/dafei4/p/13070660.html
Copyright © 2011-2022 走看看