随笔分类 -  springboot

springboot
摘要:java -jar arthas_boot.jar 告警 (Can not find java process. Try to run `jps` command lists the instrumented Java Hotspot VMs on the target system. ) 阅读全文
posted @ 2024-11-05 16:12 ☆♂安♀★ 阅读(165) 评论(0) 推荐(0) 编辑
摘要:MapperScannerConfigurer中获取applicayion.yml配置,进行动态加载BasePackage 由于在MapperScannerConfigurer的bean 优先于@value,导致@value取出来的时候都是null,所以只能使用Environment 来获取值 阅读全文
posted @ 2024-08-06 11:48 ☆♂安♀★ 阅读(20) 评论(0) 推荐(0) 编辑
摘要:springboot下的纯html页面乱码带问号? html访问后端接口 返回的 Content-Type: text/html;charset=ISO-8859-1 所以大概率是springboot编码影响到了html页面 在springboot的application.yml加上以下配置 server: servlet: encoding: #enabled: true #让系统的CharacterEncdoingFilter生效 charset: UTF-8 #默认编码格式 force: true #强制request,response都使用charset属性的值 阅读全文
posted @ 2024-07-06 00:24 ☆♂安♀★ 阅读(155) 评论(0) 推荐(0) 编辑
摘要:1、修改docker.service 因为远程传输,所以需要开启Docker的2375端口的远程访问权限。 修改docker.service配置 ]# vi /usr/lib/systemd/system/docker.service 在ExecStart=/usr/bin/dockerd-curr 阅读全文
posted @ 2022-09-22 15:04 ☆♂安♀★ 阅读(431) 评论(0) 推荐(0) 编辑
摘要:Limited Setting Effect 中文描述 Java 8 -Xbootclasspath:<path> Sets the search path for bootstrap classes and resources. 设置引导类和资源的搜索路径。 不常用,否则要重新写所有Java 核心 阅读全文
posted @ 2021-12-21 17:38 ☆♂安♀★ 阅读(1547) 评论(0) 推荐(0) 编辑
摘要:Java 操作 Redis 的库有两个,Jedis 和 Lettuce,目前 SpringBoot 2.x 中已经将 Jedis 换成了 Lettuce 原因:Lettuce的连接redis太久没有操作,被强制关闭连接。 可以在spring-boot-starter-data-redis 查看是引用 阅读全文
posted @ 2021-11-24 17:46 ☆♂安♀★ 阅读(1681) 评论(0) 推荐(0) 编辑
摘要:若偶尔报错no operations allowed after connection closed com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure spring: datasource: # 数据源-1 primary: url: jdbc:mysql://127.0.0.1:3306/test1?useSSL=false&autoReconnect=true&characterEncoding=utf8 driver-class-name: com.mysql.jdbc.Driver username: root password: root 阅读全文
posted @ 2021-10-13 20:45 ☆♂安♀★ 阅读(644) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示