Merge branch 'develop' of git.mesalab.cn:galaxy/galaxy-service into develop
This commit is contained in:
@@ -876,14 +876,16 @@
|
||||
<insert id="insertNtcIpRangeBatch"
|
||||
parameterType="com.nis.domain.restful.NtcIpRangeReport">
|
||||
INSERT INTO traffic_ip_identify
|
||||
(ip_start,ip_end,ip_start_num,ip_end_num,ip_sub,area_type,country)
|
||||
(ip_start,ip_end,ip_start_num,ip_end_num,ip_sub,area_type,country,desc_detail)
|
||||
VALUES
|
||||
<foreach collection="list" item="ipRange" separator=",">
|
||||
(#{ipRange.ipStart}, #{ipRange.ipEnd},
|
||||
#{ipRange.ipStartNum},
|
||||
#{ipRange.ipEndNum},
|
||||
#{ipRange.ipSub}, #{ipRange.areaType},
|
||||
#{ipRange.country})
|
||||
#{ipRange.country},
|
||||
#{ipRange.desc}
|
||||
)
|
||||
</foreach>
|
||||
</insert>
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
<resultMap id="NtcRadiusReportMap"
|
||||
type="com.nis.domain.restful.NtcRadiusReport">
|
||||
<result column="account" jdbcType="VARCHAR" property="account" />
|
||||
<result column="nas_ip" jdbcType="VARCHAR" property="nasIp" />
|
||||
<result column="frame_ip" jdbcType="VARCHAR" property="nasIp" />
|
||||
<result column="sum" jdbcType="BIGINT" property="sum" />
|
||||
<result column="report_time" jdbcType="TIMESTAMP"
|
||||
property="reportTime" />
|
||||
@@ -786,7 +786,7 @@
|
||||
<select id="findNasIpList"
|
||||
parameterType="com.nis.domain.restful.NtcRadiusReport"
|
||||
resultMap="NtcRadiusReportMap">
|
||||
select nas_ip,sum(num) num from ntc_radius_report
|
||||
select frame_ip,sum(num) num from ntc_radius_report
|
||||
<where>
|
||||
<choose>
|
||||
<when
|
||||
@@ -800,7 +800,7 @@
|
||||
</choose>
|
||||
|
||||
</where>
|
||||
group by nas_ip order by num desc
|
||||
group by frame_ip order by num desc
|
||||
</select>
|
||||
<select id="findAccounList"
|
||||
parameterType="com.nis.domain.restful.NtcRadiusReport"
|
||||
@@ -826,7 +826,7 @@
|
||||
parameterType="com.nis.domain.restful.NtcRadiusReport"
|
||||
resultMap="NtcRadiusReportMap">
|
||||
SELECT
|
||||
*
|
||||
frame_ip,num,account,report_time
|
||||
FROM ntc_radius_report
|
||||
<where>
|
||||
<if
|
||||
@@ -835,20 +835,17 @@
|
||||
</if>
|
||||
<if
|
||||
test="searchBusinessType !=null and searchBusinessType != '' and searchBusinessType == 3 and searchNasIp != null and searchNasIp !=''">
|
||||
<![CDATA[AND nas_ip =#{searchNasIp}]]>
|
||||
<![CDATA[AND frame_ip =#{searchNasIp}]]>
|
||||
</if>
|
||||
<choose>
|
||||
<when
|
||||
test="searchReportStartTime != null and searchReportStartTime !=''">
|
||||
<![CDATA[AND REPORT_TIME >= STR_TO_DATE(#{searchReportStartTime},'%Y-%m-%d %H:%i:%s') AND REPORT_TIME < STR_TO_DATE(#{searchReportEndTime},'%Y-%m-%d %H:%i:%s')]]>
|
||||
<![CDATA[AND report_time >= #{searchReportStartTime} AND report_time < #{searchReportEndTime}]]>
|
||||
</when>
|
||||
<otherwise>
|
||||
<![CDATA[AND REPORT_TIME>DATE_SUB(now(), INTERVAL 1 HOUR) ]]>
|
||||
</otherwise>
|
||||
</choose>
|
||||
</where>
|
||||
ORDER BY
|
||||
REPORT_TIME ASC
|
||||
report_time ASC
|
||||
</select>
|
||||
|
||||
<select id="findNtcIpRangeReport"
|
||||
@@ -934,7 +931,7 @@
|
||||
|
||||
<!-- 根据最近的时间获取阻断,监测等流量信息 -->
|
||||
<select id="getTotalReportList" resultType="java.util.HashMap">
|
||||
SELECT SUM(reject_num) rejectNum,SUM(monitor_num) monitorNum,SUM(c2s_pkt_num) c2sPktNum,SUM(s2c_pkt_num) s2cPktNum,SUM(c2s_byte_len) c2sByteLen,SUM(s2c_byte_len) s2cByteLen,SUM(new_uni_conn_num) newUniConnNum,SUM(live_conn_num) liveConnNum,
|
||||
SELECT SUM(reject_num) rejectNum,SUM(monitor_num) monitorNum,SUM(c2s_pkt_num) c2sPktNum,SUM(s2c_pkt_num) s2cPktNum,SUM(c2s_byte_len) c2sByteLen,SUM(s2c_byte_len) s2cByteLen,SUM(new_uni_conn_num) newUniConnNum,SUM(close_conn_num) closeConnNum,
|
||||
SUM(drop_conn_num) dropConnNum,SUM(loop_conn_num) loopConnNum FROM ntc_total_report
|
||||
where report_time > DATE_SUB(#{reportTime},INTERVAL 1 hour)
|
||||
</select>
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
|
||||
<!-- 根据最近的时间获取阻断,监测等流量信息 -->
|
||||
<select id="getTotalReportList" resultType="java.util.HashMap">
|
||||
SELECT SUM(reject_num) rejectNum,SUM(monitor_num) monitorNum,SUM(c2s_pkt_num) c2sPktNum,SUM(s2c_pkt_num) s2cPktNum,SUM(c2s_byte_len) c2sByteLen,SUM(s2c_byte_len) s2cByteLen,SUM(new_uni_conn_num) newUniConnNum,SUM(live_conn_num) liveConnNum,
|
||||
SELECT SUM(reject_num) rejectNum,SUM(monitor_num) monitorNum,SUM(c2s_pkt_num) c2sPktNum,SUM(s2c_pkt_num) s2cPktNum,SUM(c2s_byte_len) c2sByteLen,SUM(s2c_byte_len) s2cByteLen,SUM(new_uni_conn_num) newUniConnNum,SUM(close_conn_num) closeConnNum,
|
||||
SUM(drop_conn_num) dropConnNum,SUM(loop_conn_num) loopConnNum FROM ntc_total_report
|
||||
where report_time > DATE_SUB(#{reportTime},INTERVAL 1 hour)
|
||||
</select>
|
||||
@@ -145,7 +145,7 @@
|
||||
new_uni_conn_num
|
||||
</when>
|
||||
<when test="searchBusinessType !=null and searchBusinessType != '' and searchBusinessType == 4 ">
|
||||
live_conn_num
|
||||
close_conn_num
|
||||
</when>
|
||||
<when test="searchBusinessType !=null and searchBusinessType != '' and searchBusinessType == 5 ">
|
||||
(new_uni_conn_num-reject_num)
|
||||
|
||||
Reference in New Issue
Block a user