Class: LogStash::Inputs::AkamaiSiem::Exception
- Inherits:
-
Struct
- Object
- Struct
- LogStash::Inputs::AkamaiSiem::Exception
- Extended by:
- MiddlewareRegistry
- Defined in:
- lib/logstash/inputs/akamai_siem/exception.rb
Instance Attribute Summary collapse
-
#client_ip ⇒ Object
Returns the value of attribute client_ip.
-
#detail ⇒ Object
Returns the value of attribute detail.
-
#instance ⇒ Object
Returns the value of attribute instance.
-
#request_id ⇒ Object
Returns the value of attribute request_id.
-
#request_time ⇒ Object
Returns the value of attribute request_time.
-
#server_ip ⇒ Object
Returns the value of attribute server_ip.
-
#title ⇒ Object
Returns the value of attribute title.
-
#type ⇒ Object
Returns the value of attribute type.
Class Method Summary collapse
Instance Method Summary collapse
- #backtrace ⇒ Object
- #marshal_dump ⇒ Object
-
#marshal_load(serialised) ⇒ Object
Marshal serialization support.
- #to_s ⇒ Object
Methods included from MiddlewareRegistry
lookup_middleware, register_middleware, registered_middleware, unregister_middleware
Instance Attribute Details
#client_ip ⇒ Object
Returns the value of attribute client_ip
4 5 6 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 4 def client_ip @client_ip end |
#detail ⇒ Object
Returns the value of attribute detail
4 5 6 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 4 def detail @detail end |
#instance ⇒ Object
Returns the value of attribute instance
4 5 6 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 4 def instance @instance end |
#request_id ⇒ Object
Returns the value of attribute request_id
4 5 6 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 4 def request_id @request_id end |
#request_time ⇒ Object
Returns the value of attribute request_time
4 5 6 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 4 def request_time @request_time end |
#server_ip ⇒ Object
Returns the value of attribute server_ip
4 5 6 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 4 def server_ip @server_ip end |
#title ⇒ Object
Returns the value of attribute title
4 5 6 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 4 def title @title end |
#type ⇒ Object
Returns the value of attribute type
4 5 6 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 4 def type @type end |
Class Method Details
.create(body) ⇒ Object
7 8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 7 def self.create(body) data = ::LogStash::Json.jruby_load(body) exception = new(data['type']) exception.type = data['type'] exception.title = data['title'] exception.instance = data['instance'] exception.detail = data['detail'] exception.server_ip = data['serverIp'] exception.client_ip = data['clientIp'] exception.request_id = data['requestId'] exception.request_time = data['requestTime'] exception end |
Instance Method Details
#backtrace ⇒ Object
25 26 27 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 25 def backtrace [] end |
#marshal_dump ⇒ Object
29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 29 def marshal_dump { type: self.type, title: self.title, instance: self.instance, detail: self.detail, server_ip: self.server_ip, client_ip: self.client_ip, request_id: self.request_id, request_time: self.request_time, } end |
#marshal_load(serialised) ⇒ Object
Marshal serialization support. Restores the instance variables according to the serialised
.
45 46 47 48 49 50 51 52 53 54 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 45 def marshal_load(serialised) self.type = serialised[:type] self.title = serialised[:title] self.instance = serialised[:instance] self.detail = serialised[:detail] self.server_ip = serialised[:server_ip] self.client_ip = serialised[:client_ip] self.request_id = serialised[:request_id] self.request_time = serialised[:request_time] end |
#to_s ⇒ Object
21 22 23 |
# File 'lib/logstash/inputs/akamai_siem/exception.rb', line 21 def to_s self.detail end |