lograge
lograge copied to clipboard
How to add extra log payload in action cable?
I am looking for a way to do something like this, but in ActionCable context :
# app/controllers/application_controller.rb
class ApplicationController < ActionController::Base
def append_info_to_payload(payload)
super
payload[:host] = request.host
end
end
I could not find an example; any suggestion? I looked at the lograge code too, but the ActionCable log patching is a bit complex, to say the least. Is it even possible to hook ourselves in the log process in a similar manner with ActionCable?
Thanks!