@Component public class AlarmServiceImpl extends Object implements AlarmService, org.springframework.beans.factory.InitializingBean
| Modifier and Type | Field and Description |
|---|---|
String |
successMessageTemplate |
String |
template |
| Constructor and Description |
|---|
AlarmServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
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 in interface 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 in interface 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 © 2016. All rights reserved.