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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
870ee5fe
Commit
870ee5fe
authored
Jul 31, 2019
by
Douglas Barbosa Alexandre
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Disable built-in Sidekiq retry for verification workers
parent
21a21d04
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
20 additions
and
0 deletions
+20
-0
ee/app/workers/geo/repository_verification/primary/single_worker.rb
...kers/geo/repository_verification/primary/single_worker.rb
+2
-0
ee/app/workers/geo/repository_verification/secondary/single_worker.rb
...rs/geo/repository_verification/secondary/single_worker.rb
+2
-0
ee/spec/workers/geo/repository_verification/primary/single_worker_spec.rb
...geo/repository_verification/primary/single_worker_spec.rb
+8
-0
ee/spec/workers/geo/repository_verification/secondary/single_worker_spec.rb
...o/repository_verification/secondary/single_worker_spec.rb
+8
-0
No files found.
ee/app/workers/geo/repository_verification/primary/single_worker.rb
View file @
870ee5fe
...
...
@@ -8,6 +8,8 @@ module Geo
include
GeoQueue
include
ExclusiveLeaseGuard
sidekiq_options
retry:
false
LEASE_TIMEOUT
=
1
.
hour
.
to_i
attr_reader
:project
...
...
ee/app/workers/geo/repository_verification/secondary/single_worker.rb
View file @
870ee5fe
...
...
@@ -9,6 +9,8 @@ module Geo
include
ExclusiveLeaseGuard
include
Gitlab
::
Geo
::
ProjectLogHelpers
sidekiq_options
retry:
false
LEASE_TIMEOUT
=
1
.
hour
.
to_i
attr_reader
:registry
...
...
ee/spec/workers/geo/repository_verification/primary/single_worker_spec.rb
View file @
870ee5fe
...
...
@@ -12,6 +12,14 @@ describe Geo::RepositoryVerification::Primary::SingleWorker, :clean_gitlab_redis
stub_current_geo_node
(
primary
)
end
it
'disables retrying of failed jobs'
do
expect
(
subject
.
sidekiq_options_hash
).
to
eq
(
'retry'
=>
false
,
'queue'
=>
'geo:geo_repository_verification_primary_single'
,
'queue_namespace'
=>
:geo
)
end
describe
'#perform'
do
it
'does not calculate the checksum when not running on a primary'
do
allow
(
Gitlab
::
Geo
).
to
receive
(
:primary?
)
{
false
}
...
...
ee/spec/workers/geo/repository_verification/secondary/single_worker_spec.rb
View file @
870ee5fe
...
...
@@ -12,6 +12,14 @@ describe Geo::RepositoryVerification::Secondary::SingleWorker, :clean_gitlab_red
stub_current_geo_node
(
secondary
)
end
it
'disables retrying of failed jobs'
do
expect
(
subject
.
sidekiq_options_hash
).
to
eq
(
'retry'
=>
false
,
'queue'
=>
'geo:geo_repository_verification_secondary_single'
,
'queue_namespace'
=>
:geo
)
end
describe
'#perform'
do
it
'does not calculate the checksum when not running on a secondary'
do
allow
(
Gitlab
::
Geo
).
to
receive
(
:secondary?
)
{
false
}
...
...
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