Class: GoodData::Bricks::STDOUTLoggingMiddleware

Inherits:
Middleware show all
Defined in:
lib/gooddata/bricks/middleware/stdout_middleware.rb

Instance Attribute Summary

Attributes inherited from Middleware

#app

Instance Method Summary collapse

Methods inherited from Middleware

#initialize, #load_defaults

Methods included from Utils

#returning

Constructor Details

This class inherits a constructor from GoodData::Bricks::Middleware

Instance Method Details

#call(params) ⇒ Object



12
13
14
15
16
17
18
19
20
# File 'lib/gooddata/bricks/middleware/stdout_middleware.rb', line 12

def call(params)
  params = params.to_hash
  logger = Logger.new(STDOUT)
  params[:logger] = logger
  logger.info('Pipeline starting with STDOUT logger')
  returning(@app.call(params)) do
    logger.info('Pipeline ending')
  end
end