class Vizsla::Middleware

Public Class Methods

new(app) click to toggle source
# File lib/vizsla/middleware.rb, line 6
def initialize(app)
  @app = app
end

Public Instance Methods

__call(env) click to toggle source
# File lib/vizsla/middleware.rb, line 14
def __call(env)
  timer = Timer.new
  timer.start!

  status, headers, response = @app.call(env)

  timer.stop!

  PuppetMaster.new(timer).process

  [status, headers, response]
end
call(env) click to toggle source
# File lib/vizsla/middleware.rb, line 10
def call(env)
  dup.__call(env)
end