随笔分类 -  程序报错/BUG

摘要:org.springframework.orm.jpa.JpaSystemException: Null value was assigned to a property of primitive type setter of com.eshore.ismp.order.entity.HandSiO 阅读全文
posted @ 2017-05-22 15:31 Lost blog 阅读(2688) 评论(0) 推荐(0)
摘要:java.lang.ClassCastException: org.springframework.web.filter.CharacterEncodingFilter cannot be cast to javax.servlet.Filter at org.apache.catalina.cor 阅读全文
posted @ 2017-05-22 15:27 Lost blog 阅读(928) 评论(0) 推荐(0)
摘要:No identifier specified for entity 原因:hibernate实体类缺少主键。。。。 阅读全文
posted @ 2017-05-22 15:26 Lost blog 阅读(274) 评论(0) 推荐(0)
摘要:1.Java开发环境时 如果在使用Eclipse开发Java项目时,在使用 @Override 出现以下错误: The method *** of type *** must override a superclass method 主要是因为你的Compiler是jdk5,(5不支持@Overri 阅读全文
posted @ 2017-05-22 15:25 Lost blog 阅读(236) 评论(0) 推荐(0)
摘要:由于CacheFilter实现了javax.servlet.Filter接口,Filter是在servlet-api.jar里,因此pom中有 <dependency> <groupId>javax.servlet</groupId> <artifactId>servlet-api</artifac 阅读全文
posted @ 2017-05-22 15:25 Lost blog 阅读(139) 评论(0) 推荐(0)
摘要:严重: Error configuring application listener of class org.springframework.web.context.ContextLoaderListener java.lang.ClassNotFoundException: org.spring 阅读全文
posted @ 2017-05-22 15:22 Lost blog 阅读(318) 评论(0) 推荐(0)
摘要:症状: tomcat在eclipse里面能正常启动,而在浏览器中访问http://localhost:8080/不能访问,且报404错误。同时其他项目页面也不能访问。 关闭eclipse里面的tomcat,在tomcat安装目录下双击startup.bat手动启动tomcat服务器。访问htt:// 阅读全文
posted @ 2017-05-22 15:20 Lost blog 阅读(297) 评论(0) 推荐(0)
摘要:在tomcat bin目录下执行startup.bat可以正常启动,但在eclipse下安装了tomcat插件并且配置tomcat路径后启动且报错:A Java Exception has occurred 解决方法,在eclipse中[window][Preferences]找到[tomcat][ 阅读全文
posted @ 2017-05-22 15:18 Lost blog 阅读(852) 评论(0) 推荐(0)
摘要:在进行Eclipse开发的时候,经常会遇到一些小问题,现在开始每天积累一些小问题的解决方法。出现:JRE not compatible with workspace .class file compatibility: 1.7这个错误的原因是,JRE库配置与Java Compiler设置不一样,如图 阅读全文
posted @ 2017-05-22 15:17 Lost blog 阅读(777) 评论(0) 推荐(0)
摘要:原因追踪及解决办法: 1.查阅资料发现说在jdk1.5下要使用@Override这个annotation必须保证被标注的方法来源于class而不是interface. 2.即使自己的jdk是1.6,还需要修改myeclipse里面的编译jdk版本,从1.5(5.0)改成1.6(6.0),否则还会出现 阅读全文
posted @ 2017-05-22 15:17 Lost blog 阅读(209) 评论(0) 推荐(0)
摘要:配置如下 问题就 出在这 由Hibernate从数据库中取出主键的最大值(每个session只取1次),以该值为基础,每次增量为1,在内存中生成主键,不依赖于底层的数据库,因此可以跨数据库。 <id name="id" column="id"> <generator class="increment 阅读全文
posted @ 2017-03-17 17:41 Lost blog 阅读(1037) 评论(0) 推荐(0)
摘要:Configures whether to enable default transactions for Spring Data JPA repositories. Defaults to true. If disabled, repositories must be used behind a 阅读全文
posted @ 2017-01-13 10:47 Lost blog 阅读(1065) 评论(0) 推荐(0)
摘要:更新的时候报 Caused by: java.sql.BatchUpdateException: Transaction error, need to rollback. errno:1205 Lock wait timeout exceeded; try restarting transactio 阅读全文
posted @ 2016-12-27 17:16 Lost blog 阅读(1368) 评论(0) 推荐(0)
摘要:1.摘要 前一阵遇到了一个使用Collections.sort()时报异常的问题,跟小伙伴@zhuidawugui 一起排查了一下,发现问题的原因是JDK7的排序实现改为了TimSort,之后我们又进一步研究了一下这个神奇的算法。 2.背景 先说一下为什么要研究这个异常,前几天线上服务器发现日志里有 阅读全文
posted @ 2016-12-13 16:19 Lost blog 阅读(4696) 评论(0) 推荐(0)
摘要:用Maven build("clean tomcat7:run" ) Maven聚合工程时,出现了一下问题: 注意查看这句: Could not find artifact com.easybuy:easybuy-parent:pom:0.0.1-SNAPSHOT and 'parent.relat 阅读全文
posted @ 2016-09-19 16:59 Lost blog 阅读(1395) 评论(0) 推荐(0)
摘要:今天将老的项目放在Myeclipse2015中运行时,报错了。错误原因:在spring的配置文件applicationContext.xml中, 配置包扫描器时, 使用了*, 想扫描所有的包; 而这种方式有可能扫描到spring自带的包, 造成错误(自我理解, 不对的话求教育)改动前: 改动后... 阅读全文
posted @ 2015-12-24 00:03 Lost blog 阅读(1009) 评论(0) 推荐(0)
摘要:今天碰到个问题。FATAL [btir.server.ServerStartup:54] - <java.lang.IllegalArgumentException: Malformed \uxxxx encoding.只要把\改成/就可以了。。 阅读全文
posted @ 2015-04-27 10:25 Lost blog 阅读(1043) 评论(0) 推荐(0)