mirror of
https://github.com/goharbor/harbor.git
synced 2024-11-25 11:46:43 +01:00
Create index on task with job_id
Missing index with job_id, when query task with job_id, it cause a full table scan, caused performance issue Fixes #15271 Signed-off-by: stonezdj <stonezdj@gmail.com>
This commit is contained in:
parent
74d2670616
commit
9d480a84d2
@ -30,3 +30,5 @@ ALTER TABLE vulnerability_record ALTER COLUMN id TYPE BIGINT;
|
||||
ALTER SEQUENCE vulnerability_record_id_seq AS BIGINT;
|
||||
ALTER TABLE report_vulnerability_record ALTER COLUMN id TYPE BIGINT;
|
||||
ALTER SEQUENCE report_vulnerability_record_id_seq AS BIGINT;
|
||||
|
||||
CREATE INDEX IF NOT EXISTS idx_task_job_id ON task (job_id);
|
||||
|
Loading…
Reference in New Issue
Block a user