已解决:An error occurred at line: 1 in the generated java file The type java.io.ObjectInputStream canno

简介: 已解决:An error occurred at line: 1 in the generated java file The type java.io.ObjectInputStream canno

tomcat报错

An error occurred at line: 1 in the generated java file
The type java.io.ObjectInputStream cannot be resolved. It is indirectly referenced from required .class files
HTTP Status 500 - org.apache.jasper.JasperException: Unable to load class for JSP
type Exception report

message org.apache.jasper.JasperException: Unable to load class for JSP

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

exception

org.apache.jasper.JasperException: org.apache.jasper.JasperException: Unable to load class for JSP
  org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:161)
  org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:340)
  org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
  org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
  org.apache.struts2.dispatcher.ServletDispatcherResult.doExecute(ServletDispatcherResult.java:164)
  org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:191)
  com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:372)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:276)
  org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:54)
  org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:575)
  org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:81)
  org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:99)
  org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
  org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
root cause

org.apache.jasper.JasperException: Unable to load class for JSP
  org.apache.jasper.JspCompilationContext.load(JspCompilationContext.java:630)
  org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:149)
  org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:340)
  org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
  org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
  org.apache.struts2.dispatcher.ServletDispatcherResult.doExecute(ServletDispatcherResult.java:164)
  org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:191)
  com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:372)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:276)
  org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:54)
  org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:575)
  org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:81)
  org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:99)
  org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
  org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
root cause

java.lang.ClassNotFoundException: org.apache.jsp.WEB_002dINF.jsp.frame.error_jsp
  java.net.URLClassLoader.findClass(URLClassLoader.java:382)
  org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:134)
  org.apache.jasper.servlet.JasperLoader.loadClass(JasperLoader.java:66)
  org.apache.jasper.JspCompilationContext.load(JspCompilationContext.java:628)
  org.apache.jasper.servlet.JspServletWrapper.getServlet(JspServletWrapper.java:149)
  org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:340)
  org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:313)
  org.apache.jasper.servlet.JspServlet.service(JspServlet.java:260)
  javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
  org.apache.struts2.dispatcher.ServletDispatcherResult.doExecute(ServletDispatcherResult.java:164)
  org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:191)
  com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:372)
  com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:276)
  org.apache.struts2.impl.StrutsActionProxy.execute(StrutsActionProxy.java:54)
  org.apache.struts2.dispatcher.Dispatcher.serviceAction(Dispatcher.java:575)
  org.apache.struts2.dispatcher.ng.ExecuteOperations.executeAction(ExecuteOperations.java:81)
  org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.doFilter(StrutsPrepareAndExecuteFilter.java:99)
  org.springframework.orm.hibernate3.support.OpenSessionInViewFilter.doFilterInternal(OpenSessionInViewFilter.java:198)
  org.springframework.web.filter.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:76)
note The full stack trace of the root cause is available in the Apache Tomcat/6.0.36 logs.

原因是tomcat和jdk的版本不兼容 更换jdk或者tomcat即可

目录
相关文章
|
1月前
|
Java 开发工具
【Azure Storage Account】Java Code访问Storage Account File Share的上传和下载代码示例
本文介绍如何使用Java通过azure-storage-file-share SDK实现Azure文件共享的上传下载。包含依赖引入、客户端创建及完整示例代码,助你快速集成Azure File Share功能。
341 4
|
4月前
|
监控 Java API
现代 Java IO 高性能实践从原理到落地的高效实现路径与实战指南
本文深入解析现代Java高性能IO实践,涵盖异步非阻塞IO、操作系统优化、大文件处理、响应式网络编程与数据库访问,结合Netty、Reactor等技术落地高并发应用,助力构建高效可扩展的IO系统。
150 0
|
1月前
|
JSON Java 数据格式
java调用服务报错415 Content type ‘application/octet-stream‘ not supported
java调用服务报错415 Content type ‘application/octet-stream‘ not supported
175 6
|
1月前
|
Java Unix Go
【Java】(8)Stream流、文件File相关操作,IO的含义与运用
Java 为 I/O 提供了强大的而灵活的支持,使其更广泛地应用到文件传输和网络编程中。!但本节讲述最基本的和流与 I/O 相关的功能。我们将通过一个个例子来学习这些功能。
176 1
|
3月前
|
Java 测试技术 API
Java IO流(二):文件操作与NIO入门
本文详解Java NIO与传统IO的区别与优势,涵盖Path、Files类、Channel、Buffer、Selector等核心概念,深入讲解文件操作、目录遍历、NIO实战及性能优化技巧,适合处理大文件与高并发场景,助力高效IO编程与面试准备。
|
3月前
|
SQL Java 数据库连接
Java IO流(一):字节流与字符流基础
本文全面解析Java IO流,涵盖字节流、字符流及其使用场景,帮助开发者理解IO流分类与用途,掌握文件读写、编码转换、异常处理等核心技术,通过实战案例提升IO编程能力。
|
4月前
|
存储 Java Linux
操作系统层面视角下 Java IO 的演进路径及核心技术变革解析
本文从操作系统层面深入解析Java IO的演进历程,涵盖BIO、NIO、多路复用器及Netty等核心技术。分析各阶段IO模型的原理、优缺点及系统调用机制,探讨Java如何通过底层优化提升并发性能与数据处理效率,全面呈现IO技术的变革路径与发展趋势。
112 2
|
8月前
|
存储 网络协议 安全
Java网络编程,多线程,IO流综合小项目一一ChatBoxes
**项目介绍**:本项目实现了一个基于TCP协议的C/S架构控制台聊天室,支持局域网内多客户端同时聊天。用户需注册并登录,用户名唯一,密码格式为字母开头加纯数字。登录后可实时聊天,服务端负责验证用户信息并转发消息。 **项目亮点**: - **C/S架构**:客户端与服务端通过TCP连接通信。 - **多线程**:采用多线程处理多个客户端的并发请求,确保实时交互。 - **IO流**:使用BufferedReader和BufferedWriter进行数据传输,确保高效稳定的通信。 - **线程安全**:通过同步代码块和锁机制保证共享数据的安全性。
351 23
|
10月前
|
关系型数据库 MySQL Docker
docker pull mysql:8.0.26提示Error response from daemon: Get “https://registry-1.docker.io/v2/“: EOF错误
docker pull mysql:8.0.26提示Error response from daemon: Get “https://registry-1.docker.io/v2/“: EOF错误
3647 9