Class: Temporalio::ScopedLogger::LogMessage

Inherits:
Object
  • Object
show all
Defined in:
lib/temporalio/scoped_logger.rb

Overview

Scoped log message wrapping original log message.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#messageObject (readonly)

Returns Original log message.

Returns:

  • (Object)

    Original log message.



78
79
80
# File 'lib/temporalio/scoped_logger.rb', line 78

def message
  @message
end

#scoped_valuesObject (readonly)

Returns Scoped values.

Returns:

  • (Object)

    Scoped values.



81
82
83
# File 'lib/temporalio/scoped_logger.rb', line 81

def scoped_values
  @scoped_values
end

Instance Method Details

#inspectString

Returns Message with scoped values appended.

Returns:

  • (String)

    Message with scoped values appended.



90
91
92
93
# File 'lib/temporalio/scoped_logger.rb', line 90

def inspect
  message_str = message.is_a?(String) ? message : message.inspect
  "#{message_str} #{scoped_values}"
end