scouter icon indicating copy to clipboard operation
scouter copied to clipboard

How to filter a special service in xLog and alert it in the "Alert" chart.

Open wangli777 opened this issue 5 years ago • 1 comments

Hello,Thank you for develop this useful tool,i have installed it and run it without any problem,but i wonder how to filter a special service in xLog and alert it in the "Alert" chart. Specifically,I'm trying to develop a Built-in Plugin, how to send a alert in here:

@ServerPlugin(PluginConstants.PLUGIN_SERVER_XLOG)
 public void xlog(XLogPack pack){
     if(conf.getBoolean("ext_plugin_null_xlog_enabled", true)) {
			// filter special service and alert it 
     }
 }

wangli777 avatar Jan 16 '20 10:01 wangli777

You can user plugin helper class.

https://github.com/scouter-project/scouter/blob/master/scouter.document/main/PluginHelper-API.md

https://github.com/scouter-project/scouter/blob/master/scouter.server/src/main/java/scouter/server/plugin/PluginHelper.java

gunlee01 avatar Jan 22 '20 01:01 gunlee01