2 qq 38595638 qq_38595638 于 2017.09.09 12:13 提问

jsp网站发布-javaweb项目在自己电脑运行没有问题,但是部署到阿里云服务器之后运行出问题了

HTTP Status 500 - The Struts dispatcher cannot be found. This is usually caused by using Struts tags without the associated filter. Struts tags are only usable when the request has passed through its servlet filter, which initializes the Struts dispatcher needed for this tag. - [unknown location]

type Exception report

message The Struts dispatcher cannot be found. This is usually caused by using Struts tags without the associated filter. Struts tags are only usable when the request has passed through its servlet filter, which initializes the Struts dispatcher needed for this tag. - [unknown location]

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

exception

org.apache.jasper.JasperException: The Struts dispatcher cannot be found. This is usually caused by using Struts tags without the associated filter. Struts tags are only usable when the request has passed through its servlet filter, which initializes the Struts dispatcher needed for this tag. - [unknown location]
org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:565)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:481)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:385)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:329)
javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
root cause

The Struts dispatcher cannot be found. This is usually caused by using Struts tags without the associated filter. Struts tags are only usable when the request has passed through its servlet filter, which initializes the Struts dispatcher needed for this tag. - [unknown location]
org.apache.struts2.views.jsp.TagUtils.getStack(TagUtils.java:60)
org.apache.struts2.views.jsp.StrutsBodyTagSupport.getStack(StrutsBodyTagSupport.java:44)
org.apache.struts2.views.jsp.ComponentTagSupport.doStartTag(ComponentTagSupport.java:48)
org.apache.jsp.index_jsp._jspx_meth_s_005faction_005f0(index_jsp.java:516)
org.apache.jsp.index_jsp._jspService(index_jsp.java:195)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:443)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:385)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:329)
javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
note The full stack trace of the root cause is available in the Apache Tomcat/8.5.4 logs.
图片说明

部署到服务器之后进入首页报这个错误,但是我进入登陆界面(我的登录界面是静态的)却没有问题,有大神知道这怎么解决吗

2个回答

Small_Mouse0
Small_Mouse0   Ds   Rxr 2017.09.09 12:27

感觉像是缺少依赖,,,
【1】需要把jar放到工作空间中(本地的话eclipse 【build path】配置)

【2】还需要把jar拷贝到,,WIN-INF\lib下,,打包的时候会打包进去,,

题主这个错误貌似是缺少Struts依赖,,

qq_38595638
qq_38595638 你的意思是把项目的jar包复制到服务器上的WIN-INF\lib里面去是吗,但是我的包已经考进去了
2 个月之前 回复
dongfeng9ge
dongfeng9ge   Ds   Rxr 2017.09.10 19:23

你的jar没一起放上去吧?

qq_38595638
qq_38595638 jar在web-INF下的lib里面
2 个月之前 回复
Csdn user default icon
上传中...
上传图片
插入图片