Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boxiang Sun
gitlab-ce
Commits
865bb64a
Commit
865bb64a
authored
Jan 26, 2018
by
James Lopez
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
disable retry attempts for Import/Export until that is fixed
parent
85d47384
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
13 additions
and
2 deletions
+13
-2
app/models/project.rb
app/models/project.rb
+2
-0
app/workers/repository_import_worker.rb
app/workers/repository_import_worker.rb
+10
-1
lib/gitlab/import_export/shared.rb
lib/gitlab/import_export/shared.rb
+1
-1
No files found.
app/models/project.rb
View file @
865bb64a
...
...
@@ -568,6 +568,8 @@ class Project < ActiveRecord::Base
RepositoryForkWorker
.
perform_async
(
id
,
forked_from_project
.
repository_storage_path
,
forked_from_project
.
disk_path
)
elsif
gitlab_project_import?
RepositoryImportWorker
.
set
(
retry:
false
).
perform_async
(
self
.
id
)
else
RepositoryImportWorker
.
perform_async
(
self
.
id
)
end
...
...
app/workers/repository_import_worker.rb
View file @
865bb64a
...
...
@@ -20,7 +20,12 @@ class RepositoryImportWorker
# to those importers to mark the import process as complete.
return
if
service
.
async?
raise
result
[
:message
]
if
result
[
:status
]
==
:error
if
result
[
:status
]
==
:error
fail_import
(
project
,
result
[
:message
])
if
project
.
gitlab_project_import?
raise
result
[
:message
]
end
project
.
after_import
end
...
...
@@ -33,4 +38,8 @@ class RepositoryImportWorker
Rails
.
logger
.
info
(
"Project
#{
project
.
full_path
}
was in inconsistent state (
#{
project
.
import_status
}
) while importing."
)
false
end
def
fail_import
(
project
,
message
)
project
.
mark_import_as_failed
(
message
)
end
end
lib/gitlab/import_export/shared.rb
View file @
865bb64a
...
...
@@ -20,7 +20,7 @@ module Gitlab
error_out
(
error
.
message
,
caller
[
0
].
dup
)
@errors
<<
error
.
message
# Debug:
Rails
.
logger
.
error
(
error
.
backtrace
.
join
(
"
\n
"
))
Rails
.
logger
.
error
(
error
.
backtrace
&
.
join
(
"
\n
"
))
end
private
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment