mirror of https://github.com/freeCodeCamp/devdocs
parent
f2faacc50a
commit
9e37ff5c8a
@ -0,0 +1,13 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
module Docs
|
||||
class RequesterSubscriber < Subscriber
|
||||
self.namespace = 'requester'
|
||||
|
||||
def handle_response(event)
|
||||
if event.duration > 10_000
|
||||
log "WARN: #{format_url event.payload[:url]} was slow to process (#{(event.duration / 1000).round}s)"
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
Loading…
Reference in new issue