Class: Actions::Middleware::KeepCurrentRequestID

Inherits:
Dynflow::Middleware
  • Object
show all
Defined in:
lib/smart_proxy_dynflow/middleware/keep_current_request_id.rb

Instance Method Summary collapse

Instance Method Details

#delay(*args) ⇒ Object



6
7
8
# File 'lib/smart_proxy_dynflow/middleware/keep_current_request_id.rb', line 6

def delay(*args)
  pass(*args).tap { store_current_request_id }
end

#finalizeObject



20
21
22
# File 'lib/smart_proxy_dynflow/middleware/keep_current_request_id.rb', line 20

def finalize
  restore_current_request_id { pass }
end

#hook(*args) ⇒ Object

Run all execution plan lifecycle hooks as the original request_id



25
26
27
# File 'lib/smart_proxy_dynflow/middleware/keep_current_request_id.rb', line 25

def hook(*args)
  restore_current_request_id { pass(*args) }
end

#plan(*args) ⇒ Object



10
11
12
13
14
# File 'lib/smart_proxy_dynflow/middleware/keep_current_request_id.rb', line 10

def plan(*args)
  with_current_request_id do
    pass(*args).tap { store_current_request_id }
  end
end

#run(*args) ⇒ Object



16
17
18
# File 'lib/smart_proxy_dynflow/middleware/keep_current_request_id.rb', line 16

def run(*args)
  restore_current_request_id { pass(*args) }
end