Sha256: 2c82a0cb0257917c6d2d710eb9c0bbf94e8430a08db073931353629715986363
Contents?: true
Size: 929 Bytes
Versions: 7
Compression:
Stored size: 929 Bytes
Contents
require 'middleware' require 'protobuf/rpc/middleware/exception_handler' require 'protobuf/rpc/middleware/logger' require 'protobuf/rpc/middleware/request_decoder' require 'protobuf/rpc/middleware/response_encoder' require 'protobuf/rpc/middleware/statsd' require 'protobuf/rpc/middleware/runner' module Protobuf module Rpc def self.middleware @middleware ||= ::Middleware::Builder.new(:runner_class => ::Protobuf::Rpc::Middleware::Runner) end # Ensure the middleware stack is initialized middleware end # Statsd comes first so it gets full timing and access to exceptions Rpc.middleware.use(Rpc::Middleware::Statsd) Rpc.middleware.use(Rpc::Middleware::ExceptionHandler) Rpc.middleware.use(Rpc::Middleware::RequestDecoder) Rpc.middleware.use(Rpc::Middleware::Logger) Rpc.middleware.use(Rpc::Middleware::ResponseEncoder) ActiveSupport.run_load_hooks(:protobuf_rpc_middleware, Rpc) end
Version data entries
7 entries across 7 versions & 1 rubygems