Fix temp file being deleted after the request while importing a GitLab project
Fixes https://gitlab.com/gitlab-com/infrastructure/issues/151
In production, the temporary uploaded file is getting deleted straight after the request so the Sidekiq worker is unable to find it in /tmp
Also, improved erroring/logging of this situation.
Merge request reports
Activity
mentioned in issue #18343 (closed)
Reassigned to @rymai
@rymai it would be awesome if we can get this for
8.9.1
! Thanks!Added 1 commit:
- c3b6eadc - fix params
@jameslopez LGTM!
mentioned in commit 07ea22e5
mentioned in issue #18970 (closed)
mentioned in commit ac7cea30
10 10 end 11 11 12 12 def execute 13 Gitlab::ImportExport::FileImporter.import(archive_file: @archive_file, 14 shared: @shared) 15 if check_version! && [project_tree, repo_restorer, wiki_restorer, uploads_restorer].all?(&:restore) 13 if import_file && check_version! && [project_tree, repo_restorer, wiki_restorer, uploads_restorer].all?(&:restore) 16 14 project_tree.restored_project 17 15 else 18 16 raise Projects::ImportService::Error.new(@shared.errors.join(', ')) 19 17 end 18 19 remove_import_file
Please register or sign in to reply