migrate: add db index on artifact repository name (#17035)

Signed-off-by: chlins <chenyuzh@vmware.com>
This commit is contained in:
Chenyu Zhang 2022-06-20 16:01:04 +08:00 committed by GitHub
parent c91d2f618c
commit 5de1a62002
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -15,4 +15,6 @@ Github proposal link : https://github.com/goharbor/community/pull/181
create_time timestamp default CURRENT_TIMESTAMP,
extra_attrs text NOT NULL DEFAULT '' ,
UNIQUE ("repository", "digest", "vendor")
);
);
CREATE INDEX IF NOT EXISTS idx_artifact_repository_name ON artifact (repository_name);