@Component public class AlarmServiceImpl extends Object implements AlarmService, org.springframework.beans.factory.InitializingBean
| 限定符和类型 | 字段和说明 |
|---|---|
String |
successMessageTemplate |
String |
template |
| 构造器和说明 |
|---|
AlarmServiceImpl() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
afterPropertiesSet()
Invoked by a BeanFactory after it has set all bean properties supplied
(and satisfied BeanFactoryAware and ApplicationContextAware).
|
void |
alarm()
预警核心方法,该方法会被定时任务调用
插入定时任务:
INSERT INTO task_config(task_name, project_name, project_no, task_no, task_class, task_method, initial_delay, config_value, config_type, status, remark)
VALUES ('风控系统预警', '风控系统', '00007', '00007004', 'com.xunlei.channel.riskcontrol.alarm.service.impl.AlarmServiceImpl', 'alarm', 10000, 300000, 'delay', 'Y', NULL );
|
String |
buildDetail(Map<String,Integer> detailMap) |
static void |
main(String[] args) |
@Value(value="#{alarm[\'template.messageTemplate\']}")
public String template
@Value(value="#{alarm[\'template.successMessageTemplate\']}")
public String successMessageTemplate
public void alarm()
alarm 在接口中 AlarmServicepublic void afterPropertiesSet()
throws Exception
This method allows the bean instance to perform initialization only possible when all bean properties have been set and to throw an exception in the event of misconfiguration.
afterPropertiesSet 在接口中 org.springframework.beans.factory.InitializingBeanException - in the event of misconfiguration (such
as failure to set an essential property) or if initialization fails.public static void main(String[] args)
Copyright © 2015. All rights reserved.