细化日志查询接口的异常处理:数据验证未通过等客户端原因引起的异常归为RestServiceException(status=400);在服务程序运行过程中发生的内容异常归为ServiceRuntimeException(status=500)
This commit is contained in:
@@ -5,14 +5,13 @@ import java.util.Map;
|
|||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import org.apache.log4j.Logger;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
import com.nis.domain.restful.ConfigPzIdSource;
|
import com.nis.domain.restful.ConfigPzIdSource;
|
||||||
import com.nis.restful.RestServiceException;
|
import com.nis.restful.ServiceRuntimeException;
|
||||||
import com.nis.util.Constants;
|
import com.nis.util.Constants;
|
||||||
import com.nis.util.ExceptionUtil;
|
import com.nis.util.ExceptionUtil;
|
||||||
import com.nis.web.controller.BaseRestController;
|
import com.nis.web.controller.BaseRestController;
|
||||||
@@ -47,7 +46,7 @@ public class ConfigPzIdController extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
thread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
thread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
throw new RestServiceException(thread, System.currentTimeMillis() - start, "配置ID获取失败");
|
throw new ServiceRuntimeException(thread, System.currentTimeMillis() - start, "配置ID获取失败");
|
||||||
}
|
}
|
||||||
return serviceResponse(thread, System.currentTimeMillis() - start, request, response, "配置ID获取成功",
|
return serviceResponse(thread, System.currentTimeMillis() - start, request, response, "配置ID获取成功",
|
||||||
configPzIdSource);
|
configPzIdSource);
|
||||||
|
|||||||
@@ -6,21 +6,22 @@ import java.util.LinkedHashMap;
|
|||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
|
|
||||||
import com.nis.domain.restful.dashboard.TrafficPortActiveStatistic;
|
|
||||||
import com.nis.restful.RestServiceException;
|
|
||||||
import com.nis.util.Constants;
|
|
||||||
import javax.servlet.http.HttpServletRequest;
|
import javax.servlet.http.HttpServletRequest;
|
||||||
import javax.servlet.http.HttpServletResponse;
|
import javax.servlet.http.HttpServletResponse;
|
||||||
|
|
||||||
import com.nis.web.service.AuditLogThread;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.ui.Model;
|
import org.springframework.ui.Model;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMethod;
|
import org.springframework.web.bind.annotation.RequestMethod;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import com.nis.restful.RestBusinessCode;
|
||||||
|
import com.nis.restful.ServiceRuntimeException;
|
||||||
|
import com.nis.util.Constants;
|
||||||
|
import com.nis.util.ExceptionUtil;
|
||||||
import com.nis.util.JsonMapper;
|
import com.nis.util.JsonMapper;
|
||||||
import com.nis.web.controller.BaseRestController;
|
import com.nis.web.controller.BaseRestController;
|
||||||
|
import com.nis.web.service.AuditLogThread;
|
||||||
import com.nis.web.service.ServicesRequestLogService;
|
import com.nis.web.service.ServicesRequestLogService;
|
||||||
import com.nis.web.service.restful.DashboardService;
|
import com.nis.web.service.restful.DashboardService;
|
||||||
import com.wordnik.swagger.annotations.Api;
|
import com.wordnik.swagger.annotations.Api;
|
||||||
@@ -54,11 +55,9 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("业务总量汇聚实时统计数据检索失败"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "业务总量汇聚实时统计数据检索失败");
|
"业务总量汇聚实时统计数据检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "业务总量汇聚实时统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "业务总量汇聚实时统计数据检索成功",list, 0);
|
||||||
}
|
}
|
||||||
@@ -81,11 +80,9 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("活跃端口实时统计数据检索失败:"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "活跃端口实时统计数据检索失败");
|
"活跃端口实时统计数据检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "活跃端口实时统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "活跃端口实时统计数据检索成功",list, 0);
|
||||||
}
|
}
|
||||||
@@ -109,13 +106,11 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("协议统计图表数据检索失败:"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "协议统计图表数据检索失败");
|
"协议统计图表数据检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "IP地址日志检索成功",
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "协议统计图表数据检索成功",
|
||||||
list, 0);
|
list, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -138,11 +133,9 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("活跃IP实时统计数据检索失败:"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "活跃IP实时统计数据检索失败");
|
"活跃IP实时统计数据检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "活跃IP实时统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "活跃IP实时统计数据检索成功",list, 0);
|
||||||
}
|
}
|
||||||
@@ -164,19 +157,17 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("活跃IP统计一个小时的活跃IP"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "活跃IP实时统计数据检索失败");
|
"活跃IP统计一个小时的活跃IP检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "活跃IP实时统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "活跃IP统计一个小时的活跃IP检索成功",list, 0);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* 活跃IP TOP10 一小时数据
|
* 活跃IP TOP10 一小时数据
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "trafficIpActiveFiveMinute", method = RequestMethod.GET)
|
@RequestMapping(value = "trafficIpActiveFiveMinute", method = RequestMethod.GET)
|
||||||
@ApiOperation(value = "活跃IP统计最近五分钟TOP10在近一个小时间隔五分钟的活跃IP数据", httpMethod = "GET", notes = "对应活跃IP实时统计查询服务。")
|
@ApiOperation(value = "活跃IP最近一个小时的变化趋势统计", httpMethod = "GET", notes = "对最新TOP10的活跃IP,在近一个小时的变化情况进行统计")
|
||||||
public Map<String,?> trafficIpActiveFiveMinute(Model model, HttpServletRequest request, HttpServletResponse response) {
|
public Map<String,?> trafficIpActiveFiveMinute(Model model, HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
|
||||||
long start = System.currentTimeMillis();
|
long start = System.currentTimeMillis();
|
||||||
@@ -190,19 +181,17 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("活跃IP最近一个小时的变化趋势统计"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "活跃IP实时统计数据检索失败");
|
"活跃IP最近一个小时的变化趋势统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "活跃IP实时统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "活跃IP最近一个小时的变化趋势统计成功",list, 0);
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
* app应用流量分析 TOP10
|
* app应用流量分析 TOP10
|
||||||
*/
|
*/
|
||||||
@RequestMapping(value = "trafficApp", method = RequestMethod.GET)
|
@RequestMapping(value = "trafficApp", method = RequestMethod.GET)
|
||||||
@ApiOperation(value = "app流量分析统计", httpMethod = "GET", notes = "对应app流量分析实时统计查询服务。")
|
@ApiOperation(value = "App流量分析统计", httpMethod = "GET", notes = "对应app流量分析实时统计查询服务。")
|
||||||
public Map<String, ?> trafficApp(Model model, HttpServletRequest request, HttpServletResponse response) {
|
public Map<String, ?> trafficApp(Model model, HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
|
||||||
long start = System.currentTimeMillis();
|
long start = System.currentTimeMillis();
|
||||||
@@ -216,11 +205,9 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("App流量分析统计:"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "App流量统计数据检索失败");
|
"App流量分析统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "App流量统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "App流量统计数据检索成功",list, 0);
|
||||||
}
|
}
|
||||||
@@ -238,11 +225,9 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("操作系统流量分析统计失败:"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "操作系统流量分析统计检索失败");
|
"操作系统流量分析统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "操作系统流量分析统计检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "操作系统流量分析统计检索成功",list, 0);
|
||||||
}
|
}
|
||||||
@@ -261,11 +246,9 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("操作系统下浏览器流量分析统计失败:"+e);
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "操作系统下浏览器分类统计数据检索失败");
|
"操作系统下浏览器流量分析统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "操作系统下浏览器分类统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "操作系统下浏览器分类统计数据检索成功",list, 0);
|
||||||
}
|
}
|
||||||
@@ -283,11 +266,9 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("浏览器流量分析统计失败:"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "浏览器流量分析统计数据检索失败");
|
"浏览器流量分析统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "浏览器流量分析统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "浏览器流量分析统计数据检索成功",list, 0);
|
||||||
}
|
}
|
||||||
@@ -306,11 +287,9 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("浏览器下操作系统流量分析统计失败:"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "浏览器下操作系统流量统计数据检索失败");
|
"浏览器下操作系统流量分析统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "浏览器下操作系统流量统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "浏览器下操作系统流量统计数据检索成功",list, 0);
|
||||||
}
|
}
|
||||||
@@ -330,16 +309,14 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("网站流量分析统计失败:"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "网站流量分析统计数据检索失败");
|
"网站流量分析统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "网站流量分析统计数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "网站流量分析统计数据检索成功",list, 0);
|
||||||
}
|
}
|
||||||
@RequestMapping(value = "trafficWebTypeChart", method = RequestMethod.GET)
|
@RequestMapping(value = "trafficWebTypeChart", method = RequestMethod.GET)
|
||||||
@ApiOperation(value = "http网站分类分析统计", httpMethod = "GET", notes = "对应某个网站类型分类统计图")
|
@ApiOperation(value = "HTTP网站分类分析统计", httpMethod = "GET", notes = "对应某个网站类型分类统计图")
|
||||||
public Map<String, ?> trafficWebTypeChart(Integer websiteServiceId,Model model, HttpServletRequest request, HttpServletResponse response) {
|
public Map<String, ?> trafficWebTypeChart(Integer websiteServiceId,Model model, HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
|
||||||
long start = System.currentTimeMillis();
|
long start = System.currentTimeMillis();
|
||||||
@@ -353,16 +330,14 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("HTTP网站分类分析统计失败:"+e);
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "http网站分类分析数据检索失败");
|
"HTTP网站分类分析统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "http网站分类分析数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "HTTP网站分类分析统计成功",list, 0);
|
||||||
}
|
}
|
||||||
@RequestMapping(value = "trafficTopicAndDomainChart", method = RequestMethod.GET)
|
@RequestMapping(value = "trafficTopicAndDomainChart", method = RequestMethod.GET)
|
||||||
@ApiOperation(value = "http网站主题分类分析统计", httpMethod = "GET", notes = "对应某个网站主题类型分类统计图")
|
@ApiOperation(value = "HTTP网站主题分类分析统计", httpMethod = "GET", notes = "对应某个网站主题类型分类统计图")
|
||||||
public Map<String, ?> trafficTopicAndDomainChart(Integer websiteServiceId,Model model, HttpServletRequest request, HttpServletResponse response) {
|
public Map<String, ?> trafficTopicAndDomainChart(Integer websiteServiceId,Model model, HttpServletRequest request, HttpServletResponse response) {
|
||||||
|
|
||||||
long start = System.currentTimeMillis();
|
long start = System.currentTimeMillis();
|
||||||
@@ -376,12 +351,10 @@ public class DashboardServiceController extends BaseRestController {
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error("流量统计接口服务错误"+e);
|
logger.error("HTTP网站主题分类分析统计失败:"+ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "http网站主题分类分析数据检索失败");
|
"HTTP网站分类分析统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "http网站主题分类分析数据检索成功",list, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "HTTP网站主题分类分析数据检索成功",list, 0);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -14,7 +14,9 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
import com.nis.domain.Page;
|
import com.nis.domain.Page;
|
||||||
import com.nis.domain.restful.DkBehaviorLog;
|
import com.nis.domain.restful.DkBehaviorLog;
|
||||||
import com.nis.domain.restful.PxyHttpLog;
|
import com.nis.domain.restful.PxyHttpLog;
|
||||||
|
import com.nis.restful.RestBusinessCode;
|
||||||
import com.nis.restful.RestServiceException;
|
import com.nis.restful.RestServiceException;
|
||||||
|
import com.nis.restful.ServiceRuntimeException;
|
||||||
import com.nis.util.Constants;
|
import com.nis.util.Constants;
|
||||||
import com.nis.util.ExceptionUtil;
|
import com.nis.util.ExceptionUtil;
|
||||||
import com.nis.web.controller.BaseRestController;
|
import com.nis.web.controller.BaseRestController;
|
||||||
@@ -69,9 +71,11 @@ public class LogController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "行为识别日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"行为识别日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "行为识别日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "行为识别日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -93,9 +97,11 @@ public class LogController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "PXY HTTP日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"PXY HTTP日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "PXY HTTP日志检索成功", page,
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "PXY HTTP日志检索成功", page,
|
||||||
0);
|
0);
|
||||||
|
|||||||
@@ -28,7 +28,9 @@ import com.nis.domain.restful.MmSampleVoipLog;
|
|||||||
import com.nis.domain.restful.MmSpeakerRecognizationLog;
|
import com.nis.domain.restful.MmSpeakerRecognizationLog;
|
||||||
import com.nis.domain.restful.MmVoipAccountLog;
|
import com.nis.domain.restful.MmVoipAccountLog;
|
||||||
import com.nis.domain.restful.MmVoipIpLog;
|
import com.nis.domain.restful.MmVoipIpLog;
|
||||||
|
import com.nis.restful.RestBusinessCode;
|
||||||
import com.nis.restful.RestServiceException;
|
import com.nis.restful.RestServiceException;
|
||||||
|
import com.nis.restful.ServiceRuntimeException;
|
||||||
import com.nis.util.Constants;
|
import com.nis.util.Constants;
|
||||||
import com.nis.util.ExceptionUtil;
|
import com.nis.util.ExceptionUtil;
|
||||||
import com.nis.web.controller.BaseRestController;
|
import com.nis.web.controller.BaseRestController;
|
||||||
@@ -76,9 +78,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "音视频IP日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"音视频IP日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "音视频IP日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "音视频IP日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -100,9 +104,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "音视频URL日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"音视频URL日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "音视频URL日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "音视频URL日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -124,9 +130,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "图片IP日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"图片IP日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "图片IP日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "图片IP日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -148,9 +156,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "图片URL日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"图片URL日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "图片URL日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "图片URL日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -174,9 +184,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "VoIP IP日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"VoIP IP日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "VoIP IP日志检索成功", page,
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "VoIP IP日志检索成功", page,
|
||||||
0);
|
0);
|
||||||
@@ -200,9 +212,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "VoIP Account日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"VoIP Account日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "VoIP Account日志检索成功",
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "VoIP Account日志检索成功",
|
||||||
page, 0);
|
page, 0);
|
||||||
@@ -225,9 +239,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "音频样例日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"音频样例日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "音频样例日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "音频样例日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -249,9 +265,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "视频样例日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"视频样例日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "视频样例日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "视频样例日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -274,9 +292,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "音频色情日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"音频色情日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "音频色情日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "音频色情日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -299,9 +319,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "视频色情日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"视频色情日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "视频色情日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "视频色情日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -323,9 +345,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "图片样例日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"图片样例日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "图片样例日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "图片样例日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -347,9 +371,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "VOIP样例日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"VOIP样例日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "VOIP样例日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "VOIP样例日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -372,9 +398,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "说话人识别日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"说话人识别日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "说话人识别日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "说话人识别日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -397,9 +425,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "台标识别日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"台标识别日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "台标识别日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "台标识别日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -422,9 +452,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "人脸识别日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"人脸识别日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "人脸识别日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "人脸识别日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -446,9 +478,11 @@ public class MmLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "文件摘要日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"文件摘要日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "文件摘要日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "文件摘要日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,7 +16,9 @@ import com.nis.domain.restful.TrafficNetflowPortInfoList;
|
|||||||
import com.nis.domain.restful.TrafficNmsServerStatisticList;
|
import com.nis.domain.restful.TrafficNmsServerStatisticList;
|
||||||
import com.nis.restful.RestBusinessCode;
|
import com.nis.restful.RestBusinessCode;
|
||||||
import com.nis.restful.RestServiceException;
|
import com.nis.restful.RestServiceException;
|
||||||
|
import com.nis.restful.ServiceRuntimeException;
|
||||||
import com.nis.util.Constants;
|
import com.nis.util.Constants;
|
||||||
|
import com.nis.util.ExceptionUtil;
|
||||||
import com.nis.web.controller.BaseRestController;
|
import com.nis.web.controller.BaseRestController;
|
||||||
import com.nis.web.service.AuditLogThread;
|
import com.nis.web.service.AuditLogThread;
|
||||||
import com.nis.web.service.ServicesRequestLogService;
|
import com.nis.web.service.ServicesRequestLogService;
|
||||||
@@ -60,8 +62,14 @@ public class NmsInfoController extends BaseRestController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RestServiceException(thread, System.currentTimeMillis() - start, "上报服务器状态信息异常:" + e.getMessage(),
|
logger.error("上报服务器状态信息异常:" + ExceptionUtil.getExceptionMsg(e));
|
||||||
RestBusinessCode.unknow_error.getValue());
|
if (e instanceof RestServiceException) {
|
||||||
|
throw (RestServiceException) e;
|
||||||
|
} else {
|
||||||
|
throw new ServiceRuntimeException(thread, System.currentTimeMillis() - start, "上报服务器状态信息异常:" + e.getMessage(),
|
||||||
|
RestBusinessCode.unknow_error.getValue());
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
return compileServiceResponse(thread, System.currentTimeMillis() - start, request, response, "上报服务器状态信息成功",
|
return compileServiceResponse(thread, System.currentTimeMillis() - start, request, response, "上报服务器状态信息成功",
|
||||||
Constants.IS_DEBUG ? trafficNmsServerStatisticList : null);
|
Constants.IS_DEBUG ? trafficNmsServerStatisticList : null);
|
||||||
@@ -84,8 +92,13 @@ public class NmsInfoController extends BaseRestController {
|
|||||||
RestBusinessCode.missing_args.getValue());
|
RestBusinessCode.missing_args.getValue());
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RestServiceException(thread, System.currentTimeMillis() - start,
|
logger.error("上报NmsDiRule信息异常:" + ExceptionUtil.getExceptionMsg(e));
|
||||||
|
if (e instanceof RestServiceException) {
|
||||||
|
throw (RestServiceException) e;
|
||||||
|
} else {
|
||||||
|
throw new ServiceRuntimeException(thread, System.currentTimeMillis() - start,
|
||||||
"上报NmsDiRule信息异常:" + e.getMessage(), RestBusinessCode.unknow_error.getValue());
|
"上报NmsDiRule信息异常:" + e.getMessage(), RestBusinessCode.unknow_error.getValue());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return compileServiceResponse(thread, System.currentTimeMillis() - start, request, response, "上报NmsDiRule信息成功",
|
return compileServiceResponse(thread, System.currentTimeMillis() - start, request, response, "上报NmsDiRule信息成功",
|
||||||
Constants.IS_DEBUG ? nmsDiRuleList : null);
|
Constants.IS_DEBUG ? nmsDiRuleList : null);
|
||||||
@@ -111,8 +124,12 @@ public class NmsInfoController extends BaseRestController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RestServiceException(thread, System.currentTimeMillis() - start,
|
if (e instanceof RestServiceException) {
|
||||||
|
throw (RestServiceException) e;
|
||||||
|
} else {
|
||||||
|
throw new ServiceRuntimeException(thread, System.currentTimeMillis() - start,
|
||||||
"上报trafficNetflowPort信息异常:" + e.getMessage(), RestBusinessCode.unknow_error.getValue());
|
"上报trafficNetflowPort信息异常:" + e.getMessage(), RestBusinessCode.unknow_error.getValue());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
return compileServiceResponse(thread, System.currentTimeMillis() - start, request, response,
|
return compileServiceResponse(thread, System.currentTimeMillis() - start, request, response,
|
||||||
"上报trafficNetflowPort信息成功", Constants.IS_DEBUG ? trafficNetflowPortInfoList : null);
|
"上报trafficNetflowPort信息成功", Constants.IS_DEBUG ? trafficNetflowPortInfoList : null);
|
||||||
|
|||||||
@@ -31,7 +31,9 @@ import com.nis.domain.restful.NtcSshLog;
|
|||||||
import com.nis.domain.restful.NtcSslLog;
|
import com.nis.domain.restful.NtcSslLog;
|
||||||
import com.nis.domain.restful.NtcStreamingMediaLog;
|
import com.nis.domain.restful.NtcStreamingMediaLog;
|
||||||
import com.nis.domain.restful.NtcVoipLog;
|
import com.nis.domain.restful.NtcVoipLog;
|
||||||
|
import com.nis.restful.RestBusinessCode;
|
||||||
import com.nis.restful.RestServiceException;
|
import com.nis.restful.RestServiceException;
|
||||||
|
import com.nis.restful.ServiceRuntimeException;
|
||||||
import com.nis.util.Constants;
|
import com.nis.util.Constants;
|
||||||
import com.nis.util.DateUtils;
|
import com.nis.util.DateUtils;
|
||||||
import com.nis.util.ExceptionUtil;
|
import com.nis.util.ExceptionUtil;
|
||||||
@@ -79,9 +81,12 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "IP地址日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"IP地址日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "IP地址日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "IP地址日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -102,10 +107,15 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
|
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "Http日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"Http日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "Http日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "Http日志检索成功", page, 0);
|
||||||
@@ -128,9 +138,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "Dns日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"Dns日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "Dns日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "Dns日志检索成功", page, 0);
|
||||||
@@ -152,12 +164,14 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "Mail日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"Mail日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "Mail日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@RequestMapping(value = "/ntcSslLogs", method = RequestMethod.GET)
|
@RequestMapping(value = "/ntcSslLogs", method = RequestMethod.GET)
|
||||||
@@ -177,9 +191,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "SSL日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"SSL日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "SSL日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "SSL日志检索成功", page, 0);
|
||||||
@@ -202,9 +218,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "PPTP日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"PPTP日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "PPTP日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "PPTP日志检索成功", page, 0);
|
||||||
@@ -227,9 +245,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "L2TP日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"L2TP日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "L2TP日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "L2TP日志检索成功", page, 0);
|
||||||
@@ -252,9 +272,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "Openvpn日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"Openvpn日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "Openvpn日志检索成功", page,
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "Openvpn日志检索成功", page,
|
||||||
@@ -278,9 +300,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "IPSEC日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"IPSEC日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "IPSEC日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "IPSEC日志检索成功", page, 0);
|
||||||
@@ -303,9 +327,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "SSH日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"SSH日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "SSH日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "SSH日志检索成功", page, 0);
|
||||||
@@ -330,9 +356,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "FTP日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"FTP日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "FTP日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "FTP日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -353,9 +381,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "App日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"App日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "App日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "App日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -377,9 +407,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "DDos日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"DDos日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "DDos日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "DDos日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -402,9 +434,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "P2P日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"P2P日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "P2P日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "P2P日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -427,9 +461,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "BGP日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"BGP日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "BGP日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "BGP日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -451,9 +487,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "NTC VoIP日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"NTC VoIP日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "NTC VoIP日志检索成功", page,
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "NTC VoIP日志检索成功", page,
|
||||||
0);
|
0);
|
||||||
@@ -477,9 +515,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "流媒体协议日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"流媒体协议日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "流媒体协议日志检索成功", page, 0);
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "流媒体协议日志检索成功", page, 0);
|
||||||
}
|
}
|
||||||
@@ -501,9 +541,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "NTC关键字转URL日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"NTC关键字转URL日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "NTC关键字转URL日志检索成功", page,
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "NTC关键字转URL日志检索成功", page,
|
||||||
0);
|
0);
|
||||||
@@ -533,9 +575,11 @@ public class NtcLogSearchController extends BaseRestController {
|
|||||||
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
auditLogThread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(auditLogThread, System.currentTimeMillis() - start, "VoIp泛收日志检索失败");
|
throw new ServiceRuntimeException(auditLogThread, System.currentTimeMillis() - start,
|
||||||
|
"VoIp泛收日志检索失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "VoIp泛收日志检索成功", page,
|
return serviceLogResponse(auditLogThread, System.currentTimeMillis() - start, request, "VoIp泛收日志检索成功", page,
|
||||||
0);
|
0);
|
||||||
|
|||||||
@@ -12,7 +12,8 @@ import org.springframework.web.bind.annotation.RestController;
|
|||||||
|
|
||||||
import com.nis.domain.Page;
|
import com.nis.domain.Page;
|
||||||
import com.nis.domain.restful.ServicesRequestLogBean;
|
import com.nis.domain.restful.ServicesRequestLogBean;
|
||||||
import com.nis.restful.RestServiceException;
|
import com.nis.restful.RestBusinessCode;
|
||||||
|
import com.nis.restful.ServiceRuntimeException;
|
||||||
import com.nis.util.Constants;
|
import com.nis.util.Constants;
|
||||||
import com.nis.util.ExceptionUtil;
|
import com.nis.util.ExceptionUtil;
|
||||||
import com.nis.web.controller.BaseRestController;
|
import com.nis.web.controller.BaseRestController;
|
||||||
@@ -40,10 +41,8 @@ public class ServicesRequestLogController extends BaseRestController {
|
|||||||
thread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
thread.setExceptionInfo(e.getMessage() + " " + e.getCause());
|
||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(ExceptionUtil.getExceptionMsg(e));
|
logger.error(ExceptionUtil.getExceptionMsg(e));
|
||||||
if (!(e instanceof RestServiceException)) {
|
throw new ServiceRuntimeException(thread, System.currentTimeMillis() - start,
|
||||||
e = new RestServiceException(thread, System.currentTimeMillis() - start, "获取系统操作日志失败");
|
"获取系统操作日志失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
}
|
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return testServiceResponse( System.currentTimeMillis() - start, request, response, "获取系统操作日志成功",
|
return testServiceResponse( System.currentTimeMillis() - start, request, response, "获取系统操作日志成功",
|
||||||
|
|||||||
@@ -23,7 +23,9 @@ import com.nis.domain.restful.NtcReportEntity;
|
|||||||
import com.nis.domain.restful.NtcServiceReport;
|
import com.nis.domain.restful.NtcServiceReport;
|
||||||
import com.nis.domain.restful.NtcSrcipDomesticReport;
|
import com.nis.domain.restful.NtcSrcipDomesticReport;
|
||||||
import com.nis.domain.restful.NtcTagReport;
|
import com.nis.domain.restful.NtcTagReport;
|
||||||
|
import com.nis.restful.RestBusinessCode;
|
||||||
import com.nis.restful.RestServiceException;
|
import com.nis.restful.RestServiceException;
|
||||||
|
import com.nis.restful.ServiceRuntimeException;
|
||||||
import com.nis.util.Constants;
|
import com.nis.util.Constants;
|
||||||
import com.nis.util.DateUtils;
|
import com.nis.util.DateUtils;
|
||||||
import com.nis.web.controller.BaseRestController;
|
import com.nis.web.controller.BaseRestController;
|
||||||
@@ -32,7 +34,6 @@ import com.nis.web.service.ServicesRequestLogService;
|
|||||||
import com.nis.web.service.restful.NtcReportService;
|
import com.nis.web.service.restful.NtcReportService;
|
||||||
import com.wordnik.swagger.annotations.Api;
|
import com.wordnik.swagger.annotations.Api;
|
||||||
import com.wordnik.swagger.annotations.ApiOperation;
|
import com.wordnik.swagger.annotations.ApiOperation;
|
||||||
import com.zdjizhi.utils.DateUtil;
|
|
||||||
import com.zdjizhi.utils.StringUtil;
|
import com.zdjizhi.utils.StringUtil;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -84,9 +85,11 @@ public class SingleDimensionReport extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(e.getMessage());
|
logger.error(e.getMessage());
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(saveLogThread, System.currentTimeMillis() - start, "配置日志总量统计失败");
|
throw new ServiceRuntimeException(saveLogThread, System.currentTimeMillis() - start,
|
||||||
|
"配置日志总量统计失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "配置日志总量统计成功",
|
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "配置日志总量统计成功",
|
||||||
@@ -119,9 +122,11 @@ public class SingleDimensionReport extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(e.getMessage());
|
logger.error(e.getMessage());
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(saveLogThread, System.currentTimeMillis() - start, "业务类型统计查询失败");
|
throw new ServiceRuntimeException(saveLogThread, System.currentTimeMillis() - start,
|
||||||
|
"业务类型统计查询失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "业务类型统计查询成功",
|
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "业务类型统计查询成功",
|
||||||
@@ -158,9 +163,11 @@ public class SingleDimensionReport extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(e.getMessage());
|
logger.error(e.getMessage());
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(saveLogThread, System.currentTimeMillis() - start, "标签统计查询失败");
|
throw new ServiceRuntimeException(saveLogThread, System.currentTimeMillis() - start,
|
||||||
|
"标签统计查询失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "标签统计查询成功",
|
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "标签统计查询成功",
|
||||||
@@ -194,9 +201,11 @@ public class SingleDimensionReport extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(e.getMessage());
|
logger.error(e.getMessage());
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(saveLogThread, System.currentTimeMillis() - start, "性质统计查询失败");
|
throw new ServiceRuntimeException(saveLogThread, System.currentTimeMillis() - start,
|
||||||
|
"性质统计查询失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "性质统计查询成功",
|
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "性质统计查询成功",
|
||||||
@@ -232,9 +241,11 @@ public class SingleDimensionReport extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(e.getMessage());
|
logger.error(e.getMessage());
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(saveLogThread, System.currentTimeMillis() - start, "来文函号统计查询失败");
|
throw new ServiceRuntimeException(saveLogThread, System.currentTimeMillis() - start,
|
||||||
|
"来文函号统计查询失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "来文函号统计查询成功",
|
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "来文函号统计查询成功",
|
||||||
@@ -268,18 +279,17 @@ public class SingleDimensionReport extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(e.getMessage());
|
logger.error(e.getMessage());
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(saveLogThread, System.currentTimeMillis() - start, "境内源IP统计查询失败");
|
throw new ServiceRuntimeException(saveLogThread, System.currentTimeMillis() - start,
|
||||||
|
"境内源IP统计查询失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "境内源IP统计查询成功",
|
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "境内源IP统计查询成功",
|
||||||
reportPage, 0);
|
reportPage, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@RequestMapping(value = "/ntcDestipCountryReport", method = RequestMethod.GET)
|
@RequestMapping(value = "/ntcDestipCountryReport", method = RequestMethod.GET)
|
||||||
@ApiOperation(value = "各国家目的IP统计查询服务", httpMethod = "GET", notes = "各国家目的IP统计查询服务,基于目的IP所属国家与业务类型(service)维度聚合")
|
@ApiOperation(value = "各国家目的IP统计查询服务", httpMethod = "GET", notes = "各国家目的IP统计查询服务,基于目的IP所属国家与业务类型(service)维度聚合")
|
||||||
public Map<String, ?> ntcDestipCountryReport(Page page, NtcDestipCountryReport ntcDestipCountryReport, Model model,
|
public Map<String, ?> ntcDestipCountryReport(Page page, NtcDestipCountryReport ntcDestipCountryReport, Model model,
|
||||||
@@ -309,9 +319,11 @@ public class SingleDimensionReport extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(e.getMessage());
|
logger.error(e.getMessage());
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(saveLogThread, System.currentTimeMillis() - start, "各国家目的IP统计查询失败");
|
throw new ServiceRuntimeException(saveLogThread, System.currentTimeMillis() - start,
|
||||||
|
"各国家目的IP统计查询失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "各国家目的IP统计查询成功",
|
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "各国家目的IP统计查询成功",
|
||||||
@@ -348,9 +360,11 @@ public class SingleDimensionReport extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(e.getMessage());
|
logger.error(e.getMessage());
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(saveLogThread, System.currentTimeMillis() - start, "运营商局点统计查询失败");
|
throw new ServiceRuntimeException(saveLogThread, System.currentTimeMillis() - start,
|
||||||
|
"运营商局点统计查询失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "运营商局点统计查询成功", reportPage,
|
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "运营商局点统计查询成功", reportPage,
|
||||||
@@ -375,9 +389,11 @@ public class SingleDimensionReport extends BaseRestController {
|
|||||||
e.printStackTrace();
|
e.printStackTrace();
|
||||||
logger.error(e.getMessage());
|
logger.error(e.getMessage());
|
||||||
if (!(e instanceof RestServiceException)) {
|
if (!(e instanceof RestServiceException)) {
|
||||||
e = new RestServiceException(saveLogThread, System.currentTimeMillis() - start, "用户行为统计查询失败");
|
throw new ServiceRuntimeException(saveLogThread, System.currentTimeMillis() - start,
|
||||||
|
"用户行为统计查询失败:" + e.getMessage(), RestBusinessCode.service_runtime_error.getValue());
|
||||||
|
}else{
|
||||||
|
throw ((RestServiceException) e);
|
||||||
}
|
}
|
||||||
throw ((RestServiceException) e);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "用户行为统计查询成功", dataList,
|
return serviceLogResponse(saveLogThread, System.currentTimeMillis() - start, request, "用户行为统计查询成功", dataList,
|
||||||
|
|||||||
Reference in New Issue
Block a user