VAADIN应用在Tomcat下部署下的出现ClassNotFoundException问题
来源:互联网 发布:php源码学习 编辑:程序博客网 时间:2024/05/22 16:31
问题描述
在Tomcat 8下,部署VAADIN 7.3的应用,参考VAADIN的指导进行部署:
This Vaadin zip contains all the jars of the Vaadin Framework. Additionally all dependencies are provided in the lib folder.To use in a web project:1. Copy all vaadin-* files except vaadin-client and vaadin-client-compiler to WEB-INF/lib in your project2. Copy lib/*.jar to WEB-INF/lib in your project3. Copy vaadin-client and vaadin-client-compiler to a lib folder which is on your classpath but will not be deployed. These files are only needed when compiling a module (widget set) to Javascript.If you are using Eclipse and a standard WTP (Dynamic Web Project or Vaadin Project), step 3 can be:Create a /lib folder, copy the files there and right click the lib folder and select "Build Path" -> "Add to Build Path".Once this is done, the "Compile widgetset" button provided by the Vaadin Plug-in for Eclipse will work correctly.
发现在加载VAADIN生成web页面时,出现了ClassNotFoundException异常:
[Servlet execution threw an exception] with root causejava.lang.ClassNotFoundException: org.eclipse.jetty.websocket.WebSocketFactory$Acceptor at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1711) at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1556) at org.atmosphere.container.JettyServlet30AsyncSupportWithWebSocket.service(Servlet30AsyncSupportWithWebSocket.java:59) at org.atmosphere.cpr.AtmosphereFramework.doCometSupport(AtmosphereFramework.java:1124) at org.atmosphere.cpr.AtmosphereServlet.doPost(AtmosphereServlet.java:293) at org.atmosphere.cpr.AtmosphereServlet.doGet(AtmosphereServlet.java:279) at javax.servlet.http.HttpServlet.service(HttpServlet.java:621) at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)......
解决方案
经过查找资料和多方验证,最终发现Atmosphere框架发现其运行在错误的服务器上,这个问题的发生通常是由于你的应用配置了错误的依赖文件。在Tomcat的配置环境下,应用部署目录WEB-IF/lib下包含jetty-server.jar,就会抛出上述异常。解决方法就是删除该目录下Jetty相关的jar文件。
此问题困扰了2天,最终google查询到参考资料的web资料,最终得以解决。读者可以参考此资料以了解详细信息。
参考资料
1. ClassNotFoundException at startup
0 0
- VAADIN应用在Tomcat下部署下的出现ClassNotFoundException问题
- Sping+Struts+Hibernate开发的应用部署在weblogic下时出现的“ClassNotFoundException: org.hibernate.hql.ast.HqlToken”错误的解决方法
- 应用部署在Tomcat下乱码的原因之一
- 调试win系统下部署在tomcat的应用
- 在linux环境下部署tomcat应用
- Flex在tomcat部署下不能显示地图的问题
- Linux中部署tomcat下的应用
- tomcat在linux下出现乱码问题
- tomcat 下部署的应用出现ava.lang.OutOfMemoryError: unable to create new native thread ,解决方案。
- web工程在tomcat下的部署
- Birt部署在tomcat下的方法
- Birt部署在tomcat下的方法
- Solr7 在tomcat服务器下的部署
- 一个Tomcat下部署问题的解决
- eclipse下Tomcat项目的部署问题
- linux下tomcat应用部署
- Windows下部署tomcat应用
- dorado下部署应用到tomcat下的位置
- 39监听去电
- HDU 1599 find the mincost route 、 poj 1734 Sightseeing trip
- OC语法<4.3> Foundation框架中的集合类-NSDictionary
- ARM汇编的一点想法
- cocos2d-x3.2中error C2440: “类型转换”: 无法从“void (__thiscall xx::* )(void)”转换为
- VAADIN应用在Tomcat下部署下的出现ClassNotFoundException问题
- java Object的魅力(加载资源的方式的工具类)
- Hadoop 中SequenceFile的简介
- String,StringBuffer,StringBuilder之间的区别
- 西游记
- NAS的版图
- mahout从零开始
- 通过指针的指针来实现传出参数
- 局域网内不同主机之间实现数据库共享