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
7ce20dfb
Commit
7ce20dfb
authored
May 25, 2021
by
Thong Kuah
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Do not check licenses table as we don't refer to License anymore
parent
2d72120f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
16 deletions
+11
-16
config/initializers/load_balancing.rb
config/initializers/load_balancing.rb
+11
-16
No files found.
config/initializers/load_balancing.rb
View file @
7ce20dfb
# frozen_string_literal: true
# We need to run this initializer after migrations are done so it doesn't fail on CI
if
Gitlab
::
Database
::
LoadBalancing
.
enable?
Gitlab
::
Database
.
disable_prepared_statements
if
Gitlab
::
Database
.
cached_table_exists?
(
'licenses'
)
if
Gitlab
::
Database
::
LoadBalancing
.
enable?
Gitlab
::
Database
.
disable_prepared_statements
Gitlab
::
Application
.
configure
do
|
config
|
config
.
middleware
.
use
(
Gitlab
::
Database
::
LoadBalancing
::
RackMiddleware
)
end
Gitlab
::
Database
::
LoadBalancing
.
configure_proxy
Gitlab
::
Application
.
configure
do
|
config
|
config
.
middleware
.
use
(
Gitlab
::
Database
::
LoadBalancing
::
RackMiddleware
)
end
# This needs to be executed after fork of clustered processes
Gitlab
::
Cluster
::
LifecycleEvents
.
on_worker_start
do
# Service discovery must be started after configuring the proxy, as service
# discovery depends on this.
Gitlab
::
Database
::
LoadBalancing
.
start_service_discovery
end
Gitlab
::
Database
::
LoadBalancing
.
configure_proxy
# This needs to be executed after fork of clustered processes
Gitlab
::
Cluster
::
LifecycleEvents
.
on_worker_start
do
# Service discovery must be started after configuring the proxy, as service
# discovery depends on this.
Gitlab
::
Database
::
LoadBalancing
.
start_service_discovery
end
end
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