Method: Gruf::Controllers::Base#call
- Defined in:
- lib/gruf/controllers/base.rb
#call(method_key, &block) ⇒ Object
Call a method on this controller
89 90 91 92 93 94 95 96 97 98 99 |
# File 'lib/gruf/controllers/base.rb', line 89 def call(method_key, &block) Interceptors::Context.new(@interceptors).intercept! do process_action(method_key, &block) end rescue GRPC::BadStatus raise # passthrough, to be caught by Gruf::Interceptors::Timer rescue GRPC::Core::CallError, StandardError => e # CallError is not a StandardError set_debug_info(e., e.backtrace) if Gruf.backtrace_on_error = Gruf. ? e. : Gruf. fail!(:internal, :unknown, ) end |