解决性能监控(请求追踪、tomcat信息)菜单,打开报错的问题

This commit is contained in:
zhangdaiscott 2020-12-03 15:06:35 +08:00
parent 89ec913c9d
commit 0d299d9a98
2 changed files with 15 additions and 5 deletions

View File

@ -110,14 +110,15 @@
getAction('actuator/metrics/tomcat.sessions.active.current'),
getAction('actuator/metrics/tomcat.sessions.active.max'),
getAction('actuator/metrics/tomcat.sessions.rejected'),
getAction('actuator/metrics/tomcat.global.sent'),
getAction('actuator/metrics/tomcat.global.request.max'),
getAction('actuator/metrics/tomcat.global.request'),
// 2.3.5.RELEASE 无此API
// getAction('actuator/metrics/tomcat.global.sent'),
// getAction('actuator/metrics/tomcat.global.request.max'),
// getAction('actuator/metrics/tomcat.global.request'),
// getAction('actuator/metrics/tomcat.threads.current'),
// getAction('actuator/metrics/tomcat.threads.config.max')
// 2.1.3.RELEASE 无此API
//getAction('actuator/metrics/tomcat.servlet.request'),
// getAction('actuator/metrics/tomcat.servlet.request.max'),
getAction('actuator/metrics/tomcat.threads.current'),
getAction('actuator/metrics/tomcat.threads.config.max')
]).then((res) => {
let tomcatInfo = []
res.forEach((value, id) => {

View File

@ -1,6 +1,7 @@
package org.jeecg.config;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.boot.actuate.trace.http.InMemoryHttpTraceRepository;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Conditional;
import org.springframework.context.annotation.Configuration;
@ -63,4 +64,12 @@ public class WebMvcConfiguration implements WebMvcConfigurer {
return new CorsFilter(urlBasedCorsConfigurationSource);
}
/**
* SpringBootAdmin的Httptrace不见了
* https://blog.csdn.net/u013810234/article/details/110097201
*/
@Bean
public InMemoryHttpTraceRepository getInMemoryHttpTrace(){
return new InMemoryHttpTraceRepository();
}
}