2018-10-22 03:00:50 -04:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2015-11-04 13:13:19 -05:00
|
|
|
require 'securerandom'
|
|
|
|
|
|
|
|
module Gitlab
|
|
|
|
module Sherlock
|
|
|
|
@collection = Collection.new
|
|
|
|
|
|
|
|
class << self
|
|
|
|
attr_reader :collection
|
|
|
|
end
|
|
|
|
|
|
|
|
def self.enabled?
|
|
|
|
Rails.env.development? && !!ENV['ENABLE_SHERLOCK']
|
|
|
|
end
|
|
|
|
|
|
|
|
def self.enable_line_profiler?
|
|
|
|
RUBY_ENGINE == 'ruby'
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|