当前仓库属于暂停状态,部分功能使用受限,详情请查阅 仓库状态说明
1 Star 0 Fork 131

zhaoliping0736 / boot-actuator
暂停

forked from 。W / boot-actuator
暂停
 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

boot-actuator

演示地址:http://www.qinxuewu.club/login

项目介绍

  • 基于SpringBoot2.0 实现的jvm远程监工图形化工具,可以同时监控多个web应用
  • 该项目是借鉴另个一开源项目 ( JavaMonitor) https://gitee.com/zyzpp/JavaMonitor 演变而来,剔除了一些功能,增加了可远程监控模块,只需要在需要监控的项目集成监控的jar包 并设置可访问的IP(默认为空 则不拦截IP访问) 就可以实现远程监控,和用户管理模块,动态定时任务

项目框架

  • SpringBoot 2.0.3.RELEASE
  • mybatis-plus 3.6
  • MySql
  • Jdk1.8

目录说明

  1. boot-actuator 需要监控的项目demo
  2. actuator-service 监控端点jar包 需要引入到需要监控的项目中(已打包好上传)
  3. boot-monitor 监监控图形化工程
  4. Sql文件 /boot-monitor/src/main/resources/db/actuator.sql

安装说明

第一步 编译actuator-service工程 打成jar包

mvn install:install-file -Dfile=actuator-service-1.0.jar -DgroupId=com.github.qinxuewu -DartifactId=actuator-service -Dversion=1.0 -Dpackaging=jar

Dfile: 要安装的JAR的本地路径 
DgroupId:要安装的JAR的Group Id  (本地仓库的下一级目录到生成好的jar包的上一级目录 之间 用.分割:redis.clients)
DartifactId: 要安装的JAR的 Artificial Id (生成好的jar包的上一级目录)
Dversion: JAR 版本 
Dpackaging: 打包类型,例如JAR

第二步 需要监控的项目中引入actuator-service-1.0.jar

<dependency>
	<groupId>com.github.qinxuewu</groupId>
	 <artifactId>actuator-service</artifactId>
	 <version>1.0</version>
</dependency

#application.properties增加如下配置
#监控应用名称 唯一
spring.application.name=web1

#限制白名单 访问监控端点 为空则不限制  建议设置
actuator.server.ip=


#springBoot启动类上增加扫描包注解 

com.pflm.**:  是需要监控的项目包名  
com.github.qinxuewu.cor   :是暴露给外部访问的监控端点包(actuator-service-1.0.jar中的controller)

@ComponentScan("com.pflm.**,com.github.qinxuewu.core")


#编译成jar或war包  ,启动需要监控的项目 (如:)
nohup java -Xms256m -Xmx256m -jar boot-actuator.jar  &

启动日志出现如下端点信息 则表示集成监控jar包成功 输入图片说明

**第三步启动boot-monitor工程(JVM远程性能监控管理工具) **

#修改application.properties配置 

#配置mysql数据源
mybatis-plus.configuration.aggressive-lazy-loading=false
spring.datasource.driver-class-name=com.mysql.jdbc.Driver
spring.datasource.url=jdbc:mysql://localhost:3306/actuator?useUnicode=true&characterEncoding=utf-8&useSSL=false
spring.datasource.username=root
spring.datasource.password=root

#编译成jar或war包启动工程
nohup java -jar boot-monitor.jar  &

访问:http://localhost:8080/login 登录默认账号 admin/admin

效果图如下

登录

输入图片说明

监控列表主页 增加应用,删除应用

输入图片说明

监控详情

输入图片说明

用户管理

输入图片说明

定时任务

输入图片说明

监控参数的含义如下:

  • S0C:s0(from)的大小(KB)
  • S1C:s1(from)的大小(KB)
  • S0U:s0(from)已使用的空间(KB)
  • S1U:s1(from)已经使用的空间(KB)
  • EC:eden区的大小(KB)
  • EU:eden区已经使用的空间(KB)
  • OC:老年代大小(KB)
  • OU:老年代已经使用的空间(KB)
  • MC:元空间的大小(Metaspace)
  • MU:元空间已使用大小(KB)
  • CCSC:压缩类空间大小(compressed class space)
  • CCSU:压缩类空间已使用大小(KB)
  • YGC:新生代gc次数
  • YGCT:新生代gc耗时(秒)
  • FGC:Full gc次数
  • FGCT:Full gc耗时(秒)
  • GCT:gc总耗时(秒)
  • Loaded:表示载入了类的数量
  • Unloaded:表示卸载类的数量
  • Compiled:表示编译任务执行的次数
  • Failed:表示编译失败的次数
  • Total:线程总数
  • Runnable:正在运行的线程数
  • Sleeping:休眠的线程数
  • Waiting:等待的线程数

QQ群交流:924715723

The MIT License (MIT) Copyright (c) 2018 。W Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

基于Spring Boot 实现的监控远程服务器多个Java应用JVM性能图形化工具 展开 收起
Java
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
Java
1
https://gitee.com/plato4ever/boot-actuator.git
git@gitee.com:plato4ever/boot-actuator.git
plato4ever
boot-actuator
boot-actuator
master

搜索帮助