![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
SpringBoot
sim-uu
这个作者很懒,什么都没留下…
展开
-
Cloud-eureka集群(集群不能相互注册)
eureka 服务 pom文件版本号随parent <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-dependencies</artifactId> <version>2.2.2.RELEASE</versio.原创 2021-09-14 09:42:39 · 470 阅读 · 0 评论 -
SpringBoot数据绑定机制---自定义LocalDateTime 转换器
测试用例项目演示地址 /** * LocalDateTime 数据自定义绑定测试 * @param date * @return */ @GetMapping(value = "/bind/{date}") @ResponseBody public LocalDateTime getLocalDateTime(@PathVar...原创 2020-01-03 16:58:53 · 2081 阅读 · 0 评论 -
记录一遍java Stream API 合并2个List操作
List<RefStore> aClassList1 = new ArrayList<>(); RefStore refStore = new RefStore(); refStore.setId("1"); refStore.setName("测试1"); aClassList1.add(refStor...原创 2019-12-27 11:54:44 · 4065 阅读 · 0 评论 -
Feign调用(1)-之参数List问题
使用springboot开发项目蛮久了,依稀记得最初都是使用ArrayList才能成功的,不知道啥时候开始,官网已处理可以采用List参数传递了;新接手的项目,项目中好多地方都是采用List调用Feign,今天写了个接口,死活都是直接跑fallback了;不多逼逼重点就是加上consumes = APPLICATION_JSON_VALUE, produces = APPLIC...原创 2019-12-14 12:06:15 · 3314 阅读 · 0 评论 -
SpringBoot启动报错 Failed to read candidate component class:
** WARNING ** : Your ApplicationContext is unlikely to start due to a @ComponentScan of the default package.这个问题比较坑的解决方法就是不能在 src/java 目录下面直接创建启动类,必须先创建包, 将类放入包里面org.springframework.beans.factory...原创 2019-11-16 13:30:16 · 5024 阅读 · 6 评论 -
SpringBoot使用缓存注解 @Cacheable 基于注解显示
Spring为我们提供了几个注解来支持Spring Cache。其核心主要是@Cacheable和@CacheEvict。使用@Cacheable标记的方法在执行后Spring Cache将缓存其返回结果,而使用@CacheEvict标记的方法会在方法执行前或者执行后移除Spring Cache中的某些元素。1@Cacheable@Cacheable可以标记在一个方法上,也可以...原创 2019-09-02 14:34:46 · 1411 阅读 · 0 评论