REM:
1. 更新数据库表结构
This commit is contained in:
HuangXin 2021-01-19 15:34:48 +08:00
parent a738c4f13e
commit 89ca62686e
2 changed files with 72 additions and 73 deletions

View File

@ -11,7 +11,7 @@
Target Server Version : 50731 Target Server Version : 50731
File Encoding : 65001 File Encoding : 65001
Date: 11/09/2020 00:46:15 Date: 19/01/2021 15:22:39
*/ */
SET NAMES utf8mb4; SET NAMES utf8mb4;
@ -23,9 +23,9 @@ SET FOREIGN_KEY_CHECKS = 0;
DROP TABLE IF EXISTS `device_task`; DROP TABLE IF EXISTS `device_task`;
CREATE TABLE `device_task` CREATE TABLE `device_task`
( (
`id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '任务信息唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '任务信息唯一标识符',
`taskId` int(11) UNSIGNED NOT NULL COMMENT '处置任务唯一标识符', `taskId` bigint(11) NOT NULL COMMENT '处置任务唯一标识符',
`deviceId` int(10) UNSIGNED NOT NULL COMMENT '处置设备唯一标识符', `deviceId` bigint(11) NOT NULL COMMENT '处置设备唯一标识符',
`beginTime` timestamp(0) NULL DEFAULT NULL COMMENT '任务开始时间', `beginTime` timestamp(0) NULL DEFAULT NULL COMMENT '任务开始时间',
`endTime` timestamp(0) NULL DEFAULT NULL COMMENT '任务结束时间', `endTime` timestamp(0) NULL DEFAULT NULL COMMENT '任务结束时间',
`taskAttackType` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '需要处置的攻击类型', `taskAttackType` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '需要处置的攻击类型',
@ -34,9 +34,9 @@ CREATE TABLE `device_task`
`execAttackTypeOut` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '已经执行处置的攻击类型(Output)', `execAttackTypeOut` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '已经执行处置的攻击类型(Output)',
`attackTypeStatusOut` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '执行的攻击类型状态(Input)', `attackTypeStatusOut` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '执行的攻击类型状态(Input)',
`externId` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '扩展任务ID', `externId` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '扩展任务ID',
`errRetry` int(10) UNSIGNED NOT NULL DEFAULT 0 COMMENT '调用失败重试次数', `errRetry` int(11) UNSIGNED NOT NULL DEFAULT 0 COMMENT '调用失败重试次数',
`status` int(10) NOT NULL DEFAULT 0 COMMENT '任务状态', `status` int(11) NOT NULL DEFAULT 0 COMMENT '任务状态',
`devStatus` int(10) NOT NULL DEFAULT 0 COMMENT '设备任务状态', `devStatus` int(11) NOT NULL DEFAULT 0 COMMENT '设备任务状态',
PRIMARY KEY (`id`) USING BTREE, PRIMARY KEY (`id`) USING BTREE,
INDEX `task_info_ibfk_1` (`taskId`) USING BTREE, INDEX `task_info_ibfk_1` (`taskId`) USING BTREE,
INDEX `task_info_ibfk_2` (`deviceId`) USING BTREE, INDEX `task_info_ibfk_2` (`deviceId`) USING BTREE,
@ -46,7 +46,7 @@ CREATE TABLE `device_task`
AUTO_INCREMENT = 1 AUTO_INCREMENT = 1
CHARACTER SET = utf8 CHARACTER SET = utf8
COLLATE = utf8_general_ci COLLATE = utf8_general_ci
ROW_FORMAT = Dynamic; ROW_FORMAT = DYNAMIC;
-- ---------------------------- -- ----------------------------
-- Table structure for dispose_capacity -- Table structure for dispose_capacity
@ -54,11 +54,11 @@ CREATE TABLE `device_task`
DROP TABLE IF EXISTS `dispose_capacity`; DROP TABLE IF EXISTS `dispose_capacity`;
CREATE TABLE `dispose_capacity` CREATE TABLE `dispose_capacity`
( (
`id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '设备处置能力唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '设备处置能力唯一标识符',
`deviceId` int(11) UNSIGNED NOT NULL COMMENT '设备ID', `deviceId` bigint(11) NOT NULL COMMENT '设备ID',
`capacityType` int(8) NOT NULL COMMENT '处置能力:\r\n0清洗\r\n1高防 \r\n2路由黑洞 \r\n3检测\r\n4WAF封堵\r\n', `capacityType` int(11) NOT NULL COMMENT '处置能力:\r\n0清洗\r\n1高防 \r\n2路由黑洞 \r\n3检测\r\n4WAF封堵\r\n',
`objectType` int(8) NOT NULL COMMENT '处置对象类型:\r\n0IP\r\n1域名 \r\n2URL', `objectType` int(11) NOT NULL COMMENT '处置对象类型:\r\n0IP\r\n1域名 \r\n2URL',
`ipType` int(8) NOT NULL DEFAULT 3 COMMENT 'IP 地址类型:\r\n1 << 0支持IPV4\r\n1 << 1支持IPV6', `ipType` int(11) NOT NULL DEFAULT 3 COMMENT 'IP 地址类型:\r\n1 << 0支持IPV4\r\n1 << 1支持IPV6',
`protectIp` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '该处置能力能够处置的IP', `protectIp` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '该处置能力能够处置的IP',
`reserveNetflow` int(11) NULL DEFAULT NULL COMMENT '清洗能力储备流量值,单位(G)', `reserveNetflow` int(11) NULL DEFAULT NULL COMMENT '清洗能力储备流量值,单位(G)',
PRIMARY KEY (`id`) USING BTREE, PRIMARY KEY (`id`) USING BTREE,
@ -68,7 +68,7 @@ CREATE TABLE `dispose_capacity`
AUTO_INCREMENT = 1 AUTO_INCREMENT = 1
CHARACTER SET = utf8 CHARACTER SET = utf8
COLLATE = utf8_general_ci COLLATE = utf8_general_ci
ROW_FORMAT = Dynamic; ROW_FORMAT = DYNAMIC;
-- ---------------------------- -- ----------------------------
-- Table structure for dispose_device -- Table structure for dispose_device
@ -76,7 +76,7 @@ CREATE TABLE `dispose_capacity`
DROP TABLE IF EXISTS `dispose_device`; DROP TABLE IF EXISTS `dispose_device`;
CREATE TABLE `dispose_device` CREATE TABLE `dispose_device`
( (
`id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '设备唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '设备唯一标识符',
`ipAddr` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '设备IP地址, IPv4/IPv6', `ipAddr` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '设备IP地址, IPv4/IPv6',
`ipPort` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '端口', `ipPort` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '端口',
`deviceType` int(11) NOT NULL DEFAULT 0 COMMENT '能力节点类型0迪普UMC平台1浩瀚设备', `deviceType` int(11) NOT NULL DEFAULT 0 COMMENT '能力节点类型0迪普UMC平台1浩瀚设备',
@ -97,7 +97,7 @@ CREATE TABLE `dispose_device`
AUTO_INCREMENT = 1 AUTO_INCREMENT = 1
CHARACTER SET = utf8 CHARACTER SET = utf8
COLLATE = utf8_general_ci COLLATE = utf8_general_ci
ROW_FORMAT = Dynamic; ROW_FORMAT = DYNAMIC;
-- ---------------------------- -- ----------------------------
-- Table structure for dispose_task -- Table structure for dispose_task
@ -105,9 +105,9 @@ CREATE TABLE `dispose_device`
DROP TABLE IF EXISTS `dispose_task`; DROP TABLE IF EXISTS `dispose_task`;
CREATE TABLE `dispose_task` CREATE TABLE `dispose_task`
( (
`id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '处置任务唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '处置任务唯一标识符',
`deviceId` int(10) NOT NULL COMMENT '处置设备唯一标识符', `deviceId` bigint(11) NOT NULL COMMENT '处置设备唯一标识符',
`accountId` int(10) UNSIGNED NOT NULL COMMENT '用户唯一标识符', `accountId` bigint(11) NOT NULL COMMENT '用户唯一标识符',
`areaCode` int(11) NOT NULL DEFAULT -1 COMMENT '设备物理位置区域码', `areaCode` int(11) NOT NULL DEFAULT -1 COMMENT '设备物理位置区域码',
`disposeCapacity` int(11) NOT NULL COMMENT '处置能力类型0清洗 1高防 2黑洞 3检测', `disposeCapacity` int(11) NOT NULL COMMENT '处置能力类型0清洗 1高防 2黑洞 3检测',
`disposeObject` varchar(4096) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '处置对象', `disposeObject` varchar(4096) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '处置对象',
@ -116,8 +116,8 @@ CREATE TABLE `dispose_task`
`planEndTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '计划结束时间', `planEndTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '计划结束时间',
`endTime` timestamp(0) NULL DEFAULT '1970-01-02 00:00:00' COMMENT '实际结束时间', `endTime` timestamp(0) NULL DEFAULT '1970-01-02 00:00:00' COMMENT '实际结束时间',
`flowDirection` int(11) NOT NULL DEFAULT 2 COMMENT '流量方向, 0流入1流出2双向', `flowDirection` int(11) NOT NULL DEFAULT 2 COMMENT '流量方向, 0流入1流出2双向',
`attackType` bigint(20) UNSIGNED NOT NULL DEFAULT 18446744073709551615 COMMENT '攻击类型默认0 全部攻击', `attackType` bigint(20) NOT NULL DEFAULT 0 COMMENT '攻击类型默认0 全部攻击',
`flowBandWidth` int(10) UNSIGNED NULL DEFAULT 1024 COMMENT '攻击流量占用带宽(MB)', `flowBandWidth` int(11) UNSIGNED NULL DEFAULT 1024 COMMENT '攻击流量占用带宽(MB)',
`currentStatus` int(11) NOT NULL DEFAULT 0 COMMENT '状态0停止。1启动', `currentStatus` int(11) NOT NULL DEFAULT 0 COMMENT '状态0停止。1启动',
PRIMARY KEY (`id`) USING BTREE, PRIMARY KEY (`id`) USING BTREE,
INDEX `dispose_task_device_capacity_id_fk` (`disposeCapacity`) USING BTREE, INDEX `dispose_task_device_capacity_id_fk` (`disposeCapacity`) USING BTREE,
@ -134,10 +134,10 @@ CREATE TABLE `dispose_task`
DROP TABLE IF EXISTS `service_group`; DROP TABLE IF EXISTS `service_group`;
CREATE TABLE `service_group` CREATE TABLE `service_group`
( (
`id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '业务ID唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '业务ID唯一标识符',
`serviceId` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务ID', `serviceId` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务ID',
`serviceType` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务类型SERVER,WEB,DNS,GAME', `serviceType` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务类型SERVER,WEB,DNS,GAME',
`serviceBandwidth` int(11) NOT NULL COMMENT '业务带宽单位M', `serviceBandwidth` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务带宽单位M',
`serviceIp` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务IP地址逗号分割', `serviceIp` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务IP地址逗号分割',
PRIMARY KEY (`id`) USING BTREE PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB ) ENGINE = InnoDB
@ -152,7 +152,7 @@ CREATE TABLE `service_group`
DROP TABLE IF EXISTS `user_account`; DROP TABLE IF EXISTS `user_account`;
CREATE TABLE `user_account` CREATE TABLE `user_account`
( (
`id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '账户唯一编号', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '账户唯一编号',
`username` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '用户名', `username` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '用户名',
`password` varchar(512) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '密码', `password` varchar(512) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '密码',
`createTime` timestamp(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间', `createTime` timestamp(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
@ -161,7 +161,7 @@ CREATE TABLE `user_account`
`token` varchar(512) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '用户token', `token` varchar(512) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '用户token',
`lastAccess` timestamp(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '最后一次访问时间戳', `lastAccess` timestamp(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '最后一次访问时间戳',
`lockTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '账户锁定时间', `lockTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '账户锁定时间',
`pwdErrTimes` int(10) NOT NULL DEFAULT 0 COMMENT '密码错误次数', `pwdErrTimes` int(11) NOT NULL DEFAULT 0 COMMENT '密码错误次数',
`status` int(11) NULL DEFAULT 0 COMMENT '账户状态', `status` int(11) NULL DEFAULT 0 COMMENT '账户状态',
PRIMARY KEY (`id`) USING BTREE, PRIMARY KEY (`id`) USING BTREE,
UNIQUE INDEX `USERNAME` (`username`) USING BTREE UNIQUE INDEX `USERNAME` (`username`) USING BTREE
@ -169,6 +169,6 @@ CREATE TABLE `user_account`
AUTO_INCREMENT = 1 AUTO_INCREMENT = 1
CHARACTER SET = utf8 CHARACTER SET = utf8
COLLATE = utf8_general_ci COLLATE = utf8_general_ci
ROW_FORMAT = Dynamic; ROW_FORMAT = DYNAMIC;
SET FOREIGN_KEY_CHECKS = 1; SET FOREIGN_KEY_CHECKS = 1;

View File

@ -23,9 +23,9 @@ SET FOREIGN_KEY_CHECKS = 0;
DROP TABLE IF EXISTS `device_task`; DROP TABLE IF EXISTS `device_task`;
CREATE TABLE `device_task` CREATE TABLE `device_task`
( (
`id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '任务信息唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '任务信息唯一标识符',
`taskId` int(11) UNSIGNED NOT NULL COMMENT '处置任务唯一标识符', `taskId` bigint(11) NOT NULL COMMENT '处置任务唯一标识符',
`deviceId` int(10) UNSIGNED NOT NULL COMMENT '处置设备唯一标识符', `deviceId` bigint(11) NOT NULL COMMENT '处置设备唯一标识符',
`beginTime` timestamp(0) NULL DEFAULT NULL COMMENT '任务开始时间', `beginTime` timestamp(0) NULL DEFAULT NULL COMMENT '任务开始时间',
`endTime` timestamp(0) NULL DEFAULT NULL COMMENT '任务结束时间', `endTime` timestamp(0) NULL DEFAULT NULL COMMENT '任务结束时间',
`taskAttackType` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '需要处置的攻击类型', `taskAttackType` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '需要处置的攻击类型',
@ -34,9 +34,9 @@ CREATE TABLE `device_task`
`execAttackTypeOut` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '已经执行处置的攻击类型(Output)', `execAttackTypeOut` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '已经执行处置的攻击类型(Output)',
`attackTypeStatusOut` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '执行的攻击类型状态(Input)', `attackTypeStatusOut` bigint(255) UNSIGNED NOT NULL DEFAULT 0 COMMENT '执行的攻击类型状态(Input)',
`externId` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '扩展任务ID', `externId` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '扩展任务ID',
`errRetry` int(10) UNSIGNED NOT NULL DEFAULT 0 COMMENT '调用失败重试次数', `errRetry` int(11) UNSIGNED NOT NULL DEFAULT 0 COMMENT '调用失败重试次数',
`status` int(10) NOT NULL DEFAULT 0 COMMENT '任务状态', `status` int(11) NOT NULL DEFAULT 0 COMMENT '任务状态',
`devStatus` int(10) NOT NULL DEFAULT 0 COMMENT '设备任务状态', `devStatus` int(11) NOT NULL DEFAULT 0 COMMENT '设备任务状态',
PRIMARY KEY (`id`) USING BTREE, PRIMARY KEY (`id`) USING BTREE,
INDEX `task_info_ibfk_1` (`taskId`) USING BTREE, INDEX `task_info_ibfk_1` (`taskId`) USING BTREE,
INDEX `task_info_ibfk_2` (`deviceId`) USING BTREE, INDEX `task_info_ibfk_2` (`deviceId`) USING BTREE,
@ -46,7 +46,7 @@ CREATE TABLE `device_task`
AUTO_INCREMENT = 1 AUTO_INCREMENT = 1
CHARACTER SET = utf8 CHARACTER SET = utf8
COLLATE = utf8_general_ci COLLATE = utf8_general_ci
ROW_FORMAT = Dynamic; ROW_FORMAT = DYNAMIC;
-- ---------------------------- -- ----------------------------
-- Records of device_task -- Records of device_task
@ -58,11 +58,11 @@ CREATE TABLE `device_task`
DROP TABLE IF EXISTS `dispose_capacity`; DROP TABLE IF EXISTS `dispose_capacity`;
CREATE TABLE `dispose_capacity` CREATE TABLE `dispose_capacity`
( (
`id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '设备处置能力唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '设备处置能力唯一标识符',
`deviceId` int(11) UNSIGNED NOT NULL COMMENT '设备ID', `deviceId` bigint(11) NOT NULL COMMENT '设备ID',
`capacityType` int(8) NOT NULL COMMENT '处置能力:\r\n0清洗\r\n1高防 \r\n2路由黑洞 \r\n3检测\r\n4WAF封堵\r\n', `capacityType` int(11) NOT NULL COMMENT '处置能力:\r\n0清洗\r\n1高防 \r\n2路由黑洞 \r\n3检测\r\n4WAF封堵\r\n',
`objectType` int(8) NOT NULL COMMENT '处置对象类型:\r\n0IP\r\n1域名 \r\n2URL', `objectType` int(11) NOT NULL COMMENT '处置对象类型:\r\n0IP\r\n1域名 \r\n2URL',
`ipType` int(8) NOT NULL DEFAULT 3 COMMENT 'IP 地址类型:\r\n1 << 0支持IPV4\r\n1 << 1支持IPV6', `ipType` int(11) NOT NULL DEFAULT 3 COMMENT 'IP 地址类型:\r\n1 << 0支持IPV4\r\n1 << 1支持IPV6',
`protectIp` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '该处置能力能够处置的IP', `protectIp` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '该处置能力能够处置的IP',
`reserveNetflow` int(11) NULL DEFAULT NULL COMMENT '清洗能力储备流量值,单位(G)', `reserveNetflow` int(11) NULL DEFAULT NULL COMMENT '清洗能力储备流量值,单位(G)',
PRIMARY KEY (`id`) USING BTREE, PRIMARY KEY (`id`) USING BTREE,
@ -72,7 +72,7 @@ CREATE TABLE `dispose_capacity`
AUTO_INCREMENT = 1 AUTO_INCREMENT = 1
CHARACTER SET = utf8 CHARACTER SET = utf8
COLLATE = utf8_general_ci COLLATE = utf8_general_ci
ROW_FORMAT = Dynamic; ROW_FORMAT = DYNAMIC;
-- ---------------------------- -- ----------------------------
-- Records of dispose_capacity -- Records of dispose_capacity
@ -99,7 +99,7 @@ VALUES (7, 4, 0, 1, 3, '0.0.0.0', 10);
DROP TABLE IF EXISTS `dispose_device`; DROP TABLE IF EXISTS `dispose_device`;
CREATE TABLE `dispose_device` CREATE TABLE `dispose_device`
( (
`id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '设备唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '设备唯一标识符',
`ipAddr` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '设备IP地址, IPv4/IPv6', `ipAddr` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '设备IP地址, IPv4/IPv6',
`ipPort` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '端口', `ipPort` varchar(64) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL DEFAULT '' COMMENT '端口',
`deviceType` int(11) NOT NULL DEFAULT 0 COMMENT '能力节点类型0迪普UMC平台1浩瀚设备', `deviceType` int(11) NOT NULL DEFAULT 0 COMMENT '能力节点类型0迪普UMC平台1浩瀚设备',
@ -120,7 +120,7 @@ CREATE TABLE `dispose_device`
AUTO_INCREMENT = 1 AUTO_INCREMENT = 1
CHARACTER SET = utf8 CHARACTER SET = utf8
COLLATE = utf8_general_ci COLLATE = utf8_general_ci
ROW_FORMAT = Dynamic; ROW_FORMAT = DYNAMIC;
-- ---------------------------- -- ----------------------------
-- Records of dispose_device -- Records of dispose_device
@ -144,9 +144,9 @@ VALUES (4, '127.0.0.1', '1002', 999, 0, '虚拟处置设备', 'Virtual Dispose D
DROP TABLE IF EXISTS `dispose_task`; DROP TABLE IF EXISTS `dispose_task`;
CREATE TABLE `dispose_task` CREATE TABLE `dispose_task`
( (
`id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '处置任务唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '处置任务唯一标识符',
`deviceId` int(10) NOT NULL COMMENT '处置设备唯一标识符', `deviceId` bigint(11) NOT NULL COMMENT '处置设备唯一标识符',
`accountId` int(10) UNSIGNED NOT NULL COMMENT '用户唯一标识符', `accountId` bigint(11) NOT NULL COMMENT '用户唯一标识符',
`areaCode` int(11) NOT NULL DEFAULT -1 COMMENT '设备物理位置区域码', `areaCode` int(11) NOT NULL DEFAULT -1 COMMENT '设备物理位置区域码',
`disposeCapacity` int(11) NOT NULL COMMENT '处置能力类型0清洗 1高防 2黑洞 3检测', `disposeCapacity` int(11) NOT NULL COMMENT '处置能力类型0清洗 1高防 2黑洞 3检测',
`disposeObject` varchar(4096) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '处置对象', `disposeObject` varchar(4096) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '处置对象',
@ -155,8 +155,8 @@ CREATE TABLE `dispose_task`
`planEndTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '计划结束时间', `planEndTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '计划结束时间',
`endTime` timestamp(0) NULL DEFAULT '1970-01-02 00:00:00' COMMENT '实际结束时间', `endTime` timestamp(0) NULL DEFAULT '1970-01-02 00:00:00' COMMENT '实际结束时间',
`flowDirection` int(11) NOT NULL DEFAULT 2 COMMENT '流量方向, 0流入1流出2双向', `flowDirection` int(11) NOT NULL DEFAULT 2 COMMENT '流量方向, 0流入1流出2双向',
`attackType` bigint(20) UNSIGNED NOT NULL DEFAULT 18446744073709551615 COMMENT '攻击类型默认0 全部攻击', `attackType` bigint(20) NOT NULL DEFAULT 0 COMMENT '攻击类型默认0 全部攻击',
`flowBandWidth` int(10) UNSIGNED NULL DEFAULT 1024 COMMENT '攻击流量占用带宽(MB)', `flowBandWidth` int(11) UNSIGNED NULL DEFAULT 1024 COMMENT '攻击流量占用带宽(MB)',
`currentStatus` int(11) NOT NULL DEFAULT 0 COMMENT '状态0停止。1启动', `currentStatus` int(11) NOT NULL DEFAULT 0 COMMENT '状态0停止。1启动',
PRIMARY KEY (`id`) USING BTREE, PRIMARY KEY (`id`) USING BTREE,
INDEX `dispose_task_device_capacity_id_fk` (`disposeCapacity`) USING BTREE, INDEX `dispose_task_device_capacity_id_fk` (`disposeCapacity`) USING BTREE,
@ -179,41 +179,16 @@ VALUES (2, -1, 1, -1, 0, '192.168.10.2', 1, CURRENT_TIMESTAMP, date_add(now(), i
8796093022207, 8796093022207,
1024, 0); 1024, 0);
-- ----------------------------
-- Table structure for user_account
-- ----------------------------
DROP TABLE IF EXISTS `user_account`;
CREATE TABLE `user_account`
(
`id` int(10) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '账户唯一编号',
`username` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '用户名',
`password` varchar(512) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '密码',
`createTime` timestamp(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
`operators` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '操作员',
`lastLoginTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '最后一次成功登录时间',
`token` varchar(512) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '用户token',
`lastAccess` timestamp(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '最后一次访问时间戳',
`lockTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '账户锁定时间',
`pwdErrTimes` int(10) NOT NULL DEFAULT 0 COMMENT '密码错误次数',
`status` int(11) NULL DEFAULT 0 COMMENT '账户状态',
PRIMARY KEY (`id`) USING BTREE,
UNIQUE INDEX `USERNAME` (`username`) USING BTREE
) ENGINE = InnoDB
AUTO_INCREMENT = 1
CHARACTER SET = utf8
COLLATE = utf8_general_ci
ROW_FORMAT = Dynamic;
-- ---------------------------- -- ----------------------------
-- Table structure for service_group -- Table structure for service_group
-- ---------------------------- -- ----------------------------
DROP TABLE IF EXISTS `service_group`; DROP TABLE IF EXISTS `service_group`;
CREATE TABLE `service_group` CREATE TABLE `service_group`
( (
`id` int(11) UNSIGNED NOT NULL AUTO_INCREMENT COMMENT '业务ID唯一标识符', `id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '业务ID唯一标识符',
`serviceId` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务ID', `serviceId` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务ID',
`serviceType` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务类型SERVER,WEB,DNS,GAME', `serviceType` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务类型SERVER,WEB,DNS,GAME',
`serviceBandwidth` int(11) NOT NULL COMMENT '业务带宽单位M', `serviceBandwidth` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务带宽单位M',
`serviceIp` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务IP地址逗号分割', `serviceIp` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '业务IP地址逗号分割',
PRIMARY KEY (`id`) USING BTREE PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB ) ENGINE = InnoDB
@ -223,6 +198,30 @@ CREATE TABLE `service_group`
ROW_FORMAT = DYNAMIC; ROW_FORMAT = DYNAMIC;
-- ---------------------------- -- ----------------------------
-- Table structure for user_account
-- ----------------------------
DROP TABLE IF EXISTS `user_account`;
CREATE TABLE `user_account`
(
`id` bigint(11) NOT NULL AUTO_INCREMENT COMMENT '账户唯一编号',
`username` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '用户名',
`password` varchar(512) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '密码',
`createTime` timestamp(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '创建时间',
`operators` varchar(128) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '操作员',
`lastLoginTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '最后一次成功登录时间',
`token` varchar(512) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT '' COMMENT '用户token',
`lastAccess` timestamp(0) NOT NULL DEFAULT CURRENT_TIMESTAMP(0) COMMENT '最后一次访问时间戳',
`lockTime` timestamp(0) NOT NULL DEFAULT '1970-01-02 00:00:00' COMMENT '账户锁定时间',
`pwdErrTimes` int(11) NOT NULL DEFAULT 0 COMMENT '密码错误次数',
`status` int(11) NULL DEFAULT 0 COMMENT '账户状态',
PRIMARY KEY (`id`) USING BTREE,
UNIQUE INDEX `USERNAME` (`username`) USING BTREE
) ENGINE = InnoDB
AUTO_INCREMENT = 1
CHARACTER SET = utf8
COLLATE = utf8_general_ci
ROW_FORMAT = DYNAMIC;
-- ----------------------------
-- Records of user_account -- Records of user_account
-- ---------------------------- -- ----------------------------
INSERT INTO `user_account` INSERT INTO `user_account`