Commit 01e38af8 authored by Ahmad Sherif's avatar Ahmad Sherif

Merge branch 'ab-server-config-defaults' into 'master'

Fix error on missing `server` config section

See merge request gitlab-org/gitlab-monitor!87
parents f9c788b3 2c3956bd
Pipeline #107041 passed with stage
in 1 minute and 8 seconds
PATH
remote: .
specs:
gitlab-monitor (3.3.0)
gitlab-monitor (3.3.1)
connection_pool (~> 2.2.1)
pg (~> 1.1)
quantile (~> 0.2.0)
......
module GitLab
module Monitor
VERSION = "3.3.0".freeze
VERSION = "3.3.1".freeze
end
end
......@@ -40,7 +40,8 @@ module GitLab
setup_server(config[:server])
setup_probes(config[:probes])
use MemoryKillerMiddleware, config[:server][:memory_threshold] || 1024
memory_threshold = (config[:server] && config[:server][:memory_threshold]) || 1024
use MemoryKillerMiddleware, memory_threshold
end
def setup_server(config)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment