随笔分类 -  spring boot

介绍spring boot 的使用
摘要:项目源码url: https://github.com/zhzhair/rabbitmq-spring-boot.git。 producer项目实现登录的同时发送消息到rabbitMQ,用jmeter并发测试模拟登录; consumer消费rabbitMQ添加登录历史记录到别的数据库(消费服务的项目 阅读全文
posted @ 2019-06-10 23:28 zhzhair-codestyle 阅读(364) 评论(0) 推荐(0)
摘要:源码url: https://github.com/zhzhair/tools-spring-boot.git。 1.二维码 2.图片验证码 3.导入导出excel 4.上传文件(包含全局异常处理跳转error页面) 5.jwt 阅读全文
posted @ 2019-06-02 11:16 zhzhair-codestyle 阅读(298) 评论(0) 推荐(0)
摘要:源码url: https://github.com/zhzhair/mail-spring-boot.git 1.发送文本邮件; 2.发送html邮件; 3.发送带附件的邮件。 阅读全文
posted @ 2019-06-02 11:03 zhzhair-codestyle 阅读(877) 评论(0) 推荐(0)
摘要:源码url: https://github.com/zhzhair/stepsrank-spring-boot.git。 1.创建32个分表,用定时任务插入计步数据模拟用户上传步数; 2.项目启动初始化:将32个表的前200名记录插入mongodb的一个集合(表),清空后插入前200名记录, 并将第 阅读全文
posted @ 2019-06-02 07:47 zhzhair-codestyle 阅读(320) 评论(0) 推荐(0)
摘要:源码url: https://github.com/zhzhair/accesslimit-spring-boot.git 注解@AccessLimit 实现接口防刷功能,在方法上的注解参数优先于类上注解的参数; 限流需要在配置文件配置多长时间可以通过多少请求,当然你也可以用guava的限流方式。 阅读全文
posted @ 2019-06-01 18:53 zhzhair-codestyle 阅读(1191) 评论(0) 推荐(0)
摘要:spring-boot-data-jdbc的RowMapper配置(windows10+jdk8+idea+spring-boot2.1.5)项目url:https://github.com/zhzhair/jdbcrowmapper-spring-boot.git 启动项目初始化RowMapper 阅读全文
posted @ 2019-05-31 22:29 zhzhair-codestyle 阅读(421) 评论(0) 推荐(0)
摘要:项目源码url: https://github.com/zhzhair/logaop-spring-boot.git。 不全局写日志的原因:一般情况下,图片、语音、视频等大文件的入参或出参不适合也没必要打印日志! 阅读全文
posted @ 2019-05-31 22:19 zhzhair-codestyle 阅读(2240) 评论(0) 推荐(0)
摘要:spring-boot-starter封装(windows10+jdk8+idea+spring-boot2.1.5) 项目url:https://github.com/zhzhair/propertiesreader-spring-boot.git 1.封装启动项目读取json文件、xml文件和t 阅读全文
posted @ 2019-05-22 22:07 zhzhair-codestyle 阅读(1498) 评论(0) 推荐(0)
摘要:源码地址:https://github.com/zhzhair/mybatis-multidatasource-spring-boot.git 开发环境:windows,jdk8,spring boot2.1.4 登录异步记录日志,登录和记录日志的表在不同的数据库,读写分离对应不同的库等。 阅读全文
posted @ 2019-04-21 13:24 zhzhair-codestyle 阅读(271) 评论(0) 推荐(0)
摘要:本文参考了这位兄台的文章: https://blog.csdn.net/ffj0721/article/details/82630134 项目源码url: https://github.com/zhzhair/websocket-spring-boot.git 项目介绍: InitControlle 阅读全文
posted @ 2019-04-11 21:22 zhzhair-codestyle 阅读(996) 评论(0) 推荐(0)
摘要:一、项目介绍(本项目用的编程语言是jdk8,项目源码: https://github.com/zhzhair/mybatis-druid-spring-boot.git) 1.引入pom依赖: <dependencies> <dependency> <groupId>org.springframew 阅读全文
posted @ 2019-04-05 09:31 zhzhair-codestyle 阅读(1562) 评论(0) 推荐(0)
摘要:spring boot, elasticsearch 阅读全文
posted @ 2019-03-10 17:15 zhzhair-codestyle 阅读(1397) 评论(0) 推荐(0)
摘要:项目源码:https://github.com/zhzhair/netty-spring-boot.git 项目启动说明:服务端--spring-boot-netty-server,客户端--spring-boot-netty-client,先启动服务端的启动类,再启动客户端的启动类,从控制台能看到 阅读全文
posted @ 2018-11-18 10:32 zhzhair-codestyle 阅读(1833) 评论(0) 推荐(0)
摘要:本文介绍spring boot集成swagger,自定义注解,拦截器,xss过滤,异步调用,定时任务案例 集成swagger--对于做前后端分离的项目,后端只需要提供接口访问,swagger提供了接口调用测试和各种注释的可视化web界面。配置swagger的扫描包路径,api信息等,见配置类Swag 阅读全文
posted @ 2018-10-21 08:38 zhzhair-codestyle 阅读(3031) 评论(0) 推荐(0)
摘要:spring boot1 到 spring boot2的配置变化很大,迁移项目到spring boot2过程中发现以下变化 1.java 的 redis 配置添加了属性jedis 旧版 spring: redis: timeout: 300000 pool.max-active: 20 pool.m 阅读全文
posted @ 2018-03-29 13:11 zhzhair-codestyle 阅读(538) 评论(2) 推荐(0)