Springboot3.5.x版本actuator新属性

前言

Springboot3.5.x版本发布之后,下载heapdump文件需要配置,使其更加安全

示例

1、创建一个Springboot3.5.x版本

2、加入actuator相关包

xml 复制代码
<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-actuator</artifactId>
</dependency>

3、开启配置

ini 复制代码
server.port=8011
spring.profiles.active=dev
spring.application.name=demo-actuator

management.endpoints.web.exposure.include=*
management.endpoint.health.show-details=always

4、访问

bash 复制代码
http://localhost:8011/actuator/info

输出

5、这个时候访问

bash 复制代码
http://localhost:8011/actuator/heapdump

输出 6、开启heapdump配置 在application-dev.yml开启配置

yaml 复制代码
management:
    endpoint:
      heapdump:
        access: unrestricted

访问

bash 复制代码
http://localhost:8011/actuator/heapdump

会下载

总结

Spring Boot3.5.x这个版本的变化还挺大的,增加了不少实用功能,如果能升级,可以用用新属性

相关推荐
用户298698530143 分钟前
Python 一键导出 Excel 中的图表和形状为图片
后端·python·excel
用户8130077816375 分钟前
PageHelper分页查询步骤
后端
是小李呀7 分钟前
MyBatis、MyBatis-Plus 与全自动 ORM 的本质区别
后端
小堂子这厢有礼了20 分钟前
Chet.Admin 权限模型:菜单级 + 按钮级 + 行级三层防护
前端·后端·信息可视化·前端框架·.net
SimonKing21 分钟前
Spring Boot 4.0 + gRPC 极简集成:4步搞定,比REST还丝滑
java·后端·程序员
IT_陈寒1 小时前
Vue的这个响应式陷阱,让我加班到凌晨三点
前端·人工智能·后端
Wang's Blog1 小时前
Go-Zero基础入门5: 探究go-zero如何基于gRPC扩展客户端
开发语言·后端·golang·go-zero
小堂子这厢有礼了1 小时前
Chet.QuartzNet.UI v2.3.0 大更新!表格重构 + 系统配置 + 分析页全面升级!
前端·后端·ui·重构·c#·vue
cfm_29142 小时前
SpringBoot自定义Starter
java·spring boot·后端
触底反弹2 小时前
⚡ Promise.all 性能优化:让 Agent 的工具调用飞起来
javascript·人工智能·后端