Skip to content

Commit b85860d

Browse files
committed
[INLONG-5555][Manager] Add random suffix to generated source task name
1 parent ebcf67d commit b85860d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

inlong-manager/manager-test/src/main/resources/h2/apache_inlong_manager.sql

+1-1
Original file line numberDiff line numberDiff line change
@@ -398,7 +398,7 @@ CREATE TABLE IF NOT EXISTS `stream_source`
398398
`create_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Create time',
399399
`modify_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT 'Modify time',
400400
PRIMARY KEY (`id`),
401-
KEY `group_stream_index` (`inlong_group_id`, `inlong_stream_id`, `is_deleted`),
401+
UNIQUE KEY `unique_source_name` (`inlong_group_id`, `inlong_stream_id`, `source_name`, `is_deleted`),
402402
KEY `source_status_index` (`status`, `is_deleted`),
403403
KEY `source_agent_ip_index` (`agent_ip`, `is_deleted`)
404404
);

inlong-manager/manager-web/sql/apache_inlong_manager.sql

+1-1
Original file line numberDiff line numberDiff line change
@@ -419,7 +419,7 @@ CREATE TABLE IF NOT EXISTS `stream_source`
419419
`create_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP COMMENT 'Create time',
420420
`modify_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT 'Modify time',
421421
PRIMARY KEY (`id`),
422-
KEY `group_stream_index` (`inlong_group_id`, `inlong_stream_id`, `is_deleted`),
422+
UNIQUE KEY `unique_source_name` (`inlong_group_id`, `inlong_stream_id`, `source_name`, `is_deleted`),
423423
KEY `source_status_index` (`status`, `is_deleted`),
424424
KEY `source_agent_ip_index` (`agent_ip`, `is_deleted`)
425425
) ENGINE = InnoDB

0 commit comments

Comments
 (0)