You need to sign in or sign up before continuing.
This MR extracts Monitoring logic from Watchdog.
This allows us to introduce multiple monitors to run within the watchdog.
We can even enable experimental monitors directly in the initializer and have different ones for Puma and Sidekiq.
Configuration:
watchdog = Gitlab::Memory::Watchdog.new
watchdog.configure do |config|
config.handler = Gitlab::Memory::Watchdog::NullHandler.instance
config.sleep_time_seconds = 30
# config.monitor.use MonitorClass, args**, &block
config.monitor.use Gitlab::Memory::Watchdog::Monitors::HeapFragmentationMonitor
config.monitor.use Gitlab::Memory::Watchdog::Monitors::MemoryGrowthMonitor
end
Gitlab::BackgroundTask.new(watchdog).start
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
Numbered steps to set up and validate the change are strongly suggested.
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
related to: #379196 (closed)