diff options
author | Shinya Maeda <shinya@gitlab.com> | 2019-06-10 21:34:21 +0700 |
---|---|---|
committer | Shinya Maeda <shinya@gitlab.com> | 2019-06-11 18:39:29 +0700 |
commit | c5c41ae0650da8c6174aa05f1cad1c50e90f713a (patch) | |
tree | 1b5b6af72042de1012c40d51abcedf4396a9618a | |
parent | a0af34582cf0f3c5d901dfe9c78d9ef05c900d7f (diff) | |
download | gitlab-ce-c5c41ae0650da8c6174aa05f1cad1c50e90f713a.tar.gz |
Ignore legacy artifact columns in Project Import/Export
Ignore some columns
4 files changed, 15 insertions, 1 deletions
diff --git a/changelogs/unreleased/ignore-artifact-attirbutes-in-project-import-export.yml b/changelogs/unreleased/ignore-artifact-attirbutes-in-project-import-export.yml new file mode 100644 index 00000000000..536aae03f59 --- /dev/null +++ b/changelogs/unreleased/ignore-artifact-attirbutes-in-project-import-export.yml @@ -0,0 +1,5 @@ +--- +title: Ignore legacy artifact columns in Project Import/Export +merge_request: 29427 +author: +type: fixed diff --git a/lib/gitlab/import_export/import_export.yml b/lib/gitlab/import_export/import_export.yml index 7bbcb53f016..71c44af9254 100644 --- a/lib/gitlab/import_export/import_export.yml +++ b/lib/gitlab/import_export/import_export.yml @@ -156,6 +156,9 @@ excluded_attributes: - :when - :artifacts_file - :artifacts_metadata + - :artifacts_file_store + - :artifacts_metadata_store + - :artifacts_size - :commands push_event_payload: - :event_id diff --git a/lib/gitlab/import_export/relation_factory.rb b/lib/gitlab/import_export/relation_factory.rb index e1e70a008d9..efd3f550a22 100644 --- a/lib/gitlab/import_export/relation_factory.rb +++ b/lib/gitlab/import_export/relation_factory.rb @@ -153,6 +153,9 @@ module Gitlab @relation_hash.delete('trace') # old export files have trace @relation_hash.delete('token') @relation_hash.delete('commands') + @relation_hash.delete('artifacts_file_store') + @relation_hash.delete('artifacts_metadata_store') + @relation_hash.delete('artifacts_size') imported_object elsif @relation_name == :merge_requests diff --git a/spec/lib/gitlab/import_export/project.json b/spec/lib/gitlab/import_export/project.json index fb7bddb386c..6512fe80a3b 100644 --- a/spec/lib/gitlab/import_export/project.json +++ b/spec/lib/gitlab/import_export/project.json @@ -6223,7 +6223,10 @@ "erased_by_id": null, "erased_at": null, "type": "Ci::Build", - "token": "abcd" + "token": "abcd", + "artifacts_file_store": 1, + "artifacts_metadata_store": 1, + "artifacts_size": 10 }, { "id": 72, |