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
64716b33
Commit
64716b33
authored
Aug 17, 2021
by
Siddharth Asthana
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Set total of Progress bar nil when replication is disabled
Changelog: other EE: true
parent
fff3d03e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
6 deletions
+23
-6
ee/app/models/geo_node_status.rb
ee/app/models/geo_node_status.rb
+11
-6
ee/spec/models/geo_node_status_spec.rb
ee/spec/models/geo_node_status_spec.rb
+12
-0
No files found.
ee/app/models/geo_node_status.rb
View file @
64716b33
...
...
@@ -477,12 +477,17 @@ class GeoNodeStatus < ApplicationRecord
end
def
load_container_registry_data
return
unless
container_repositories_replication_enabled
self
.
container_repositories_count
=
container_registry_finder
.
registry_count
self
.
container_repositories_synced_count
=
container_registry_finder
.
synced_count
self
.
container_repositories_failed_count
=
container_registry_finder
.
failed_count
self
.
container_repositories_registry_count
=
container_registry_finder
.
registry_count
if
container_repositories_replication_enabled
self
.
container_repositories_count
=
container_registry_finder
.
registry_count
self
.
container_repositories_synced_count
=
container_registry_finder
.
synced_count
self
.
container_repositories_failed_count
=
container_registry_finder
.
failed_count
self
.
container_repositories_registry_count
=
container_registry_finder
.
registry_count
else
self
.
container_repositories_count
=
nil
self
.
container_repositories_synced_count
=
nil
self
.
container_repositories_failed_count
=
nil
self
.
container_repositories_registry_count
=
nil
end
end
def
load_designs_data
...
...
ee/spec/models/geo_node_status_spec.rb
View file @
64716b33
...
...
@@ -502,6 +502,18 @@ RSpec.describe GeoNodeStatus, :geo do
expect
(
subject
.
container_repositories_count
).
to
be_nil
end
end
context
'when old container repositories counts exist'
do
before
do
stub_geo_setting
(
registry_replication:
{
enabled:
false
})
end
it
'returns nil'
do
described_class
.
current_node_status
.
update!
(
container_repositories_count:
3
)
expect
(
subject
.
container_repositories_count
).
to
be_nil
end
end
end
describe
'#container_repositories_synced_count'
do
...
...
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