forked from luyan/epmet-cloud-lingshan
3 changed files with 78 additions and 3 deletions
@ -0,0 +1,32 @@ |
|||
/** |
|||
* Copyright (c) 2018 人人开源 All rights reserved. |
|||
* |
|||
* https://www.renren.io
|
|||
* |
|||
* 版权所有,侵权必究! |
|||
*/ |
|||
|
|||
package com.epmet.dto; |
|||
|
|||
import lombok.Data; |
|||
|
|||
import java.io.Serializable; |
|||
|
|||
/** |
|||
* 系统监控日志 |
|||
* |
|||
* @author Mark sunlightcs@gmail.com |
|||
* @since 1.0.0 |
|||
*/ |
|||
@Data |
|||
public class SysMonitorLogDTO implements Serializable { |
|||
/** |
|||
* 访问路径 |
|||
*/ |
|||
private String path; |
|||
/** |
|||
* 耗时 |
|||
*/ |
|||
private Integer costTime; |
|||
|
|||
} |
@ -0,0 +1,43 @@ |
|||
/** |
|||
* Copyright (c) 2018 人人开源 All rights reserved. |
|||
* |
|||
* https://www.renren.io
|
|||
* |
|||
* 版权所有,侵权必究! |
|||
*/ |
|||
|
|||
package com.epmet.controller; |
|||
|
|||
import com.alibaba.fastjson.JSON; |
|||
import lombok.extern.slf4j.Slf4j; |
|||
import org.springframework.web.bind.annotation.RequestBody; |
|||
import org.springframework.web.bind.annotation.RequestMapping; |
|||
import org.springframework.web.bind.annotation.RestController; |
|||
|
|||
import java.util.Map; |
|||
|
|||
|
|||
/** |
|||
* 异常日志 |
|||
* |
|||
* @author Mark sunlightcs@gmail.com |
|||
* @since 1.0.0 |
|||
*/ |
|||
@Slf4j |
|||
@RestController("monitorlog") |
|||
public class SysMonitorLogController { |
|||
|
|||
/** |
|||
* desc: 记录监控日志 |
|||
* |
|||
* @param params |
|||
* @return void |
|||
* @author LiuJanJun |
|||
* @date 2021/4/19 5:56 下午 |
|||
*/ |
|||
@RequestMapping("info") |
|||
public void infoLevel(@RequestBody Map<String,Object> params) { |
|||
log.info("monitor log info:{}", JSON.toJSONString(params)); |
|||
} |
|||
|
|||
} |
Loading…
Reference in new issue