SET NAMES utf8mb4;
SET FOREIGN_KEY_CHECKS = 0;
-- ----------------------------
-- 创建表
-- ----------------------------
CREATE TABLE IF NOT EXISTS `nms_cxy_nrm_log` (
  `msg_id` bigint NOT NULL AUTO_INCREMENT COMMENT '消息序号，9位长度，递增',
  `ruid` varchar(255) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '网络资源对象Ruid',
  `user_label` varchar(32) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '用户标签-网元名称',
  `change_time` varchar(32) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '资源变化时间，格式为"2022-12-15 08:34:24"',
  `change_type` varchar(16) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '变化类型 add：新增 mod：修改 del：删除',
  `change_oper` varchar(3000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '资源的具体属性',
  `create_by` varchar(50) COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '创建者',
  `create_time` bigint DEFAULT NULL COMMENT '创建时间',
  PRIMARY KEY (`msg_id`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='星网-资源数据操作日志';

-- ----------------------------
-- 新增记录
-- ----------------------------
-- 性能数据文件的上报
INSERT IGNORE INTO `sys_job` VALUES  (null,'job.nms_cxy.performance_upload_oss', 'SYSTEM', 'performance_upload_oss', '{\"interval\":15,\"neTypes\":[\"AMF\",\"UPF\",\"UDM\",\"SMF\",\"NSSF\"]}', '0 0/15 * * * ?', '3', '0', '1', '1', 'supervisor', 1698478134839, 'supervisor', 1710819124454, 'job.nms_cxy.performance_upload_oss_remark');
INSERT IGNORE INTO `sys_dict_data` VALUES (210, 210, 'job.nms_cxy.performance_upload_oss', '性能数据文件的上报', 'i18n_zh', '', '', '1', 'supervisor', 1705550000000, '', 0, '');
INSERT IGNORE INTO `sys_dict_data` VALUES (211, 211, 'job.nms_cxy.performance_upload_oss_remark', 'interval周期为15分钟。neTypes为数组对应上报数据的网元类型。', 'i18n_zh', '', '', '1', 'supervisor', 1705550000000, '', 0, '');
INSERT IGNORE INTO `sys_dict_data` VALUES (212, 212, 'job.nms_cxy.performance_upload_oss', 'Reporting of performance data files', 'i18n_en', '', '', '1', 'supervisor', 1705550000000, '', 0, '');
INSERT IGNORE INTO `sys_dict_data` VALUES (213, 213, 'job.nms_cxy.performance_upload_oss_remark', 'The interval period is 15 minutes. neTypes is an array corresponding to the type of network element for which the data was reported.', 'i18n_en', '', '', '1', 'supervisor', 1705550000000, '', 0, '');

-- 资源数据上报接口
INSERT IGNORE INTO `sys_job` VALUES  (null,'job.nms_cxy.resource_upload_oss', 'SYSTEM', 'resource_upload_oss', '{\"neTypes\":[\"AMF\",\"UPF\"]}', '0 0 0,12 * * ?', '3', '0', '1', '1', 'supervisor', 1698478134839, 'supervisor', 1710819133986, 'job.nms_cxy.resource_upload_oss_remark');
INSERT IGNORE INTO `sys_dict_data` VALUES (215, 215, 'job.nms_cxy.resource_upload_oss', '资源数据上报接口', 'i18n_zh', '', '', '1', 'supervisor', 1705550000000, '', 0, '');
INSERT IGNORE INTO `sys_dict_data` VALUES (216, 216, 'job.nms_cxy.resource_upload_oss_remark', '每天的 0 时及 12 时上报网元的全量资源数据文件至 OSS。', 'i18n_zh', '', '', '1', 'supervisor', 1705550000000, '', 0, '');
INSERT IGNORE INTO `sys_dict_data` VALUES (217, 217, 'job.nms_cxy.resource_upload_oss', 'Resource data reporting interface', 'i18n_en', '', '', '1', 'supervisor', 1705550000000, '', 0, '');
INSERT IGNORE INTO `sys_dict_data` VALUES (218, 218, 'job.nms_cxy.resource_upload_oss_remark', 'Full resource data files for network elements are reported to the OSS at 0000 and 1200 hours each day.', 'i18n_en', '', '', '1', 'supervisor', 1705550000000, '', 0, '');

-- 配置数据上报接口
INSERT IGNORE INTO `sys_job` VALUES  (null,'job.nms_cxy.config_upload_oss', 'SYSTEM', 'config_upload_oss', '{\"neTypes\":[\"AMF\",\"UPF\",\"UDM\",\"SMF\"]}', '0 0 0,12 * * ?', '3', '0', '1', '1', 'supervisor', 1698478134839, 'supervisor', 1710818082110, 'job.nms_cxy.config_upload_oss_remark');
INSERT IGNORE INTO `sys_dict_data` VALUES (220, 220, 'job.nms_cxy.config_upload_oss', '配置数据上报接口', 'i18n_zh', '', '', '1', 'supervisor', 1705550000000, '', 0, '');
INSERT IGNORE INTO `sys_dict_data` VALUES (221, 221, 'job.nms_cxy.config_upload_oss_remark', '配置数据上报时间为每日的0时及12时。', 'i18n_zh', '', '', '1', 'supervisor', 1705550000000, '', 0, '');
INSERT IGNORE INTO `sys_dict_data` VALUES (222, 222, 'job.nms_cxy.config_upload_oss', 'Configure data reporting interface', 'i18n_en', '', '', '1', 'supervisor', 1705550000000, '', 0, '');
INSERT IGNORE INTO `sys_dict_data` VALUES (223, 223, 'job.nms_cxy.config_upload_oss_remark', 'Set the data reporting time to 0:00 and 12:00 every day.', 'i18n_en', '', '', '1', 'supervisor', 1705550000000, '', 0, '');

SET FOREIGN_KEY_CHECKS = 1;