Class: SentryMessageFormat
- Inherits:
-
Object
- Object
- SentryMessageFormat
- Defined in:
- lib/fluent/plugin/out_sentry.rb
Instance Attribute Summary collapse
-
#environment ⇒ Object
Returns the value of attribute environment.
-
#error_message ⇒ Object
Returns the value of attribute error_message.
-
#error_type ⇒ Object
Returns the value of attribute error_type.
-
#event_id ⇒ Object
Returns the value of attribute event_id.
-
#exception ⇒ Object
Returns the value of attribute exception.
-
#platform ⇒ Object
Returns the value of attribute platform.
-
#release ⇒ Object
Returns the value of attribute release.
-
#request ⇒ Object
Returns the value of attribute request.
-
#server_name ⇒ Object
Returns the value of attribute server_name.
-
#tags ⇒ Object
Returns the value of attribute tags.
-
#timestamp ⇒ Object
Returns the value of attribute timestamp.
-
#transaction ⇒ Object
Returns the value of attribute transaction.
-
#user ⇒ Object
Returns the value of attribute user.
Instance Method Summary collapse
-
#initialize(timestamp, event_id, component_name, environment, release, tags, request, exception, platform, transaction) ⇒ SentryMessageFormat
constructor
A new instance of SentryMessageFormat.
- #to_json(*_args) ⇒ Object
Constructor Details
#initialize(timestamp, event_id, component_name, environment, release, tags, request, exception, platform, transaction) ⇒ SentryMessageFormat
Returns a new instance of SentryMessageFormat.
58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 |
# File 'lib/fluent/plugin/out_sentry.rb', line 58 def initialize( , event_id, component_name, environment, release, , request, exception, platform, transaction ) @event_id = event_id @timestamp = @server_name = component_name @environment = environment @release = release @tags = @request = request @platform = platform @transaction = transaction self.exception = SentryException.new(exception) end |
Instance Attribute Details
#environment ⇒ Object
Returns the value of attribute environment.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def environment @environment end |
#error_message ⇒ Object
Returns the value of attribute error_message.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def @error_message end |
#error_type ⇒ Object
Returns the value of attribute error_type.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def error_type @error_type end |
#event_id ⇒ Object
Returns the value of attribute event_id.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def event_id @event_id end |
#exception ⇒ Object
Returns the value of attribute exception.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def exception @exception end |
#platform ⇒ Object
Returns the value of attribute platform.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def platform @platform end |
#release ⇒ Object
Returns the value of attribute release.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def release @release end |
#request ⇒ Object
Returns the value of attribute request.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def request @request end |
#server_name ⇒ Object
Returns the value of attribute server_name.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def server_name @server_name end |
#tags ⇒ Object
Returns the value of attribute tags.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def @tags end |
#timestamp ⇒ Object
Returns the value of attribute timestamp.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def @timestamp end |
#transaction ⇒ Object
Returns the value of attribute transaction.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def transaction @transaction end |
#user ⇒ Object
Returns the value of attribute user.
54 55 56 |
# File 'lib/fluent/plugin/out_sentry.rb', line 54 def user @user end |
Instance Method Details
#to_json(*_args) ⇒ Object
82 83 84 85 86 87 88 89 |
# File 'lib/fluent/plugin/out_sentry.rb', line 82 def to_json(*_args) hash = {} instance_variables.each do |var| hash[var.to_s.delete '@'] = instance_variable_get var end hash.to_json end |