# springboot-prometheus **Repository Path**: fastsun666/springboot-prometheus ## Basic Information - **Project Name**: springboot-prometheus - **Description**: springboot2 web的prometheus项目,测试对应用的监控 - **Primary Language**: Unknown - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 19 - **Created**: 2025-07-24 - **Last Updated**: 2026-01-11 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # springboot-export #### 介绍 **导出功能介绍** 在使用Springboot2开发项目过程中,为了将应用快速接入prometheus,实现应用的监控。 #### 使用说明 1. 在pom.xml中加入依赖 org.springframework.boot spring-boot-starter-actuator io.micrometer micrometer-registry-prometheus 2. 修改application.yml文件,添加文件中的内容。 3. 在Prometheus.yml文件中配置采集,注意端口要和application.yml中保持一致。 - job_name: 'springboot-export' metrics_path: '/actuator/prometheus' static_configs: - targets: ['192.168.X.X:8886'] labels: application: 'springboot-demo' 4. 在telegraf中查看 #### 用到的技术 jenkins,ansible,ssh #### 说明 可能会因服务器的语言等设置,需要调整部署脚本