lib/timber/contexts/runtime.rb in timber-2.1.1 vs lib/timber/contexts/runtime.rb in timber-2.1.2
- old
+ new
@@ -7,24 +7,25 @@
# origin in your code. For example, if you are debugging a specific class, you can narrow
# by that class and see only it's logs.
class Runtime < Context
@keyspace = :runtime
- attr_reader :application, :class_name, :file, :function, :line, :module_name
+ attr_reader :application, :class_name, :file, :function, :line, :module_name, :vm_pid
def initialize(attributes)
@application = attributes[:application]
@class_name = attributes[:class_name]
@file = attributes[:file]
@function = attributes[:function]
@line = attributes[:line]
@module_name = attributes[:module_name]
+ @vm_pid = attributes[:vm_pid]
end
# Builds a hash representation containing simple objects, suitable for serialization (JSON).
def as_json(_options = {})
{application: application, class_name: class_name, file: file, function: function,
- line: line, module_name: module_name}
+ line: line, module_name: module_name, vm_pid: vm_pid}
end
end
end
end
\ No newline at end of file