提交 e36e8f1f 编写于 作者: J jialinsun

clean some code

上级 36e98f05
......@@ -96,6 +96,7 @@ public class Handler implements PageHandler<Context> {
Metric metric = Cat.getProducer().newMetric(group, key);
DefaultMetric defaultMetric = (DefaultMetric) metric;
if (defaultMetric != null) {
defaultMetric.setTimestamp(time);
}
......
......@@ -123,9 +123,6 @@ public class Payload extends AbstractReportPayload<Action> {
if (m_action == null) {
m_action = Action.COUNT_API;
}
if(m_type == null) {
m_type = "network";
}
}
}
......@@ -66,6 +66,7 @@ public class ExceptionAlert implements Task, LogEnabled {
private TopMetric buildTopMetric(Date date) {
TopReport topReport = queryTopReport(date);
TopMetric topMetric = new TopMetric(ALERT_PERIOD, Integer.MAX_VALUE, m_configManager);
topMetric.setStart(date).setEnd(new Date(date.getTime() + TimeUtil.ONE_MINUTE));
topMetric.visitTopReport(topReport);
return topMetric;
......@@ -149,7 +150,6 @@ public class ExceptionAlert implements Task, LogEnabled {
for (List<Item> item : items) {
for (Item i : item) {
String domain = i.getDomain();
ExceptionLimit totalExceptionLimit = m_configManager.queryDomainTotalLimit(domain);
int totalWarnLimit = -1;
int totalErrorLimit = -1;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册