![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
spring
勤读意现
我希望自己更强大
展开
-
Spring声明式事务配置管理方法
/*2011年8月28日 10:03:30 by Rush */环境配置项目使用SSH架构,现在要添加Spring事务管理功能,针对当前环境,只需要添加Spring 2.0 AOP类库即可。添加方法:点击项目右键->Build Path->Add librarys:转载 2017-03-17 09:30:48 · 174 阅读 · 0 评论 -
RestController类注解以后还需要跳页面
@RestControllerpublic class LoginController { @GetMapping("/authentication/require") public ModelAndView require() { return new ModelAndView("ftl/login"); }}原创 2018-04-02 06:26:38 · 6379 阅读 · 0 评论 -
关于springboot事务不回滚问题____________________________-gxy
最近升级到2.0.0的springboot以后发现事务有问题,不会回滚。如果引入javax的javax.transactio.Transaction的话会报错,说事务没打开: javax.persistence.TransactionRequiredException: Executing an update/delete query 而如果导入:import org.springframew...原创 2018-04-22 19:44:38 · 1053 阅读 · 0 评论 -
springboot打成jar包后无法读取resource文件夹下文件模板---------------gxy
springboot打成jar包后无法读取resource文件夹下文件模板BufferedInputStream bis = null; OutputStream os = null; ClassPathResource cpr = new ClassPathResource("/templates/excelmodual/" + fileName);os = response.get...原创 2018-09-19 11:13:07 · 5417 阅读 · 0 评论 -
springboot 2.0websocket推送指定页面------------------gxy
加一个这个就行了,其他别乱加<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-websocket</artifactId&原创 2018-11-16 16:50:06 · 250 阅读 · 0 评论 -
Unable to find a @SpringBootConfiguration, you need to use....
报错:java.lang.IllegalStateException: Unable to find a @SpringBootConfiguration, you need to use @ContextConfiguration or @SpringBootTest(classes=…) with your testat org.springframework.util.Assert.st...原创 2019-09-24 22:13:53 · 352 阅读 · 0 评论