自定义博客皮肤VIP专享

*博客头图:

格式为PNG、JPG,宽度*高度大于1920*100像素,不超过2MB,主视觉建议放在右侧,请参照线上博客头图

请上传大于1920*100像素的图片!

博客底图:

图片格式为PNG、JPG,不超过1MB,可上下左右平铺至整个背景

栏目图:

图片格式为PNG、JPG,图片宽度*高度为300*38像素,不超过0.5MB

主标题颜色:

RGB颜色,例如:#AFAFAF

Hover:

RGB颜色,例如:#AFAFAF

副标题颜色:

RGB颜色,例如:#AFAFAF

自定义博客皮肤

-+
  • 博客(12)
  • 资源 (5)
  • 问答 (2)
  • 收藏
  • 关注

原创 使用ObjectMapper将字符串转为json,或者json转为对象

首先加入依赖: <dependency> <groupId>com.fasterxml.jackson.core</groupId> <artifactId>jackson-databind</artifactId> &l...

2018-10-22 13:43:07 10765

原创 springboot创建新module报错- 错误: 找不到或无法加载主类

选择Edit Configurations...最下面有报错信息将Use classpath of module选择成新建的module的名字,这里我新建的midule的名字是web选完之后,报错消失,项目即可正常启动...

2018-10-16 16:48:02 3729 1

原创 JPA的findone()方法报错

jpa的2.x版本中不能在使用findone()方法,而是这样用public void decreaseStock(List<DTO> DTOList) { for(DTO dto:DTOList){ Optional<User> user=userRepository.findById(dto.getProductId()); }...

2018-10-15 11:47:38 793

原创 springcloud使用feign报错

报错Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is feign.FeignException: status 405 reading ProductClient#li...

2018-10-15 11:24:35 847

原创 使用jpa查询如果入参是List,怎么办?

在repository类下的方法后添加In即可:类似:List<User> findByIdIn(List<String> id);

2018-10-15 10:16:36 13973 2

原创 字符串转化成list

使用java.util下的ArraysArrays.asList("1","2")

2018-10-15 10:09:10 4888

原创 使用RestTemplate时报错java.lang.IllegalStateException: No instances available for 127.0.0.1

我在RestTemplate的配置类里使用了 @LoadBalanced@Componentpublic class RestTemplateConfig { @Bean @LoadBalanced public RestTemplate restTemplate(){ return new RestTemplate(); }}再调用...

2018-10-14 14:00:22 8736 3

原创 springboot集成mybatis实现crud,并简单介绍mybatis的xml配置

mybatis无法像jpa一样自动建表,表需提前建好添加依赖<dependency> <groupId>mysql</groupId> <artifactId>mysql-connector-java</artifactId></dependency><!--mybatis-->&l...

2018-10-09 21:06:53 549

原创 SpringBoot+Redis实现springsecurity

引入依赖:<!--redis--><dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-redis</artifactId></dependency>c...

2018-10-09 17:36:10 5332 2

原创 springboot+thymeleaf实现springsecurity

依赖:<!--Spring Security的依赖--><dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-security</artifactId></dependen...

2018-10-09 16:04:05 1929 1

原创 springboot集成elasticsearch

首先加入依赖<!--全文搜索--> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-data-elasticsearch</artifactId&...

2018-10-08 14:55:30 329

原创 springboot集成elasticsearch时报错NoNodeAvailableException[None of the configured nodes are available: [{#

我在集成elasticsearch在idea的控制台里出现如下报错,但是我的配置是没有问题的NoNodeAvailableException[None of the configured nodes are available: [{#transport#-1}{c86bxOiITCqF-lqJc2C-XQ}{localhost}{127.0.0.1:9300}]]    at org.e...

2018-10-08 14:44:21 2990

jenkins.war

jenkins可持续化开发集成工具,

2019-11-26

redis缓存的示例代码

使用redis缓存的代码示例,框架使用的springboot,有兴趣的可以参考

2018-12-26

几个常用的js+css

iconfont.js+jquery-1.8.0.min.js+showLoading.css+jquery.showLoading.min.js+echarts.min.js+highcharts.js需要的可下载使用

2018-09-26

TA创建的收藏夹 TA关注的收藏夹

TA关注的人

提示
确定要删除当前文章?
取消 删除