mirror of
https://github.com/elastic/logstash.git
synced 2025-04-25 07:07:54 -04:00
- LogStash::Search::Result#to_json
This commit is contained in:
parent
d0a5dfb5a0
commit
d669639c99
1 changed files with 9 additions and 0 deletions
|
@ -26,5 +26,14 @@ class LogStash::Search::Result
|
|||
def error?
|
||||
return !@error_message.nil?
|
||||
end
|
||||
|
||||
def to_json
|
||||
return {
|
||||
"events" => @events,
|
||||
"duration" => @duration,
|
||||
"offset" => @offset,
|
||||
"total" => @total,
|
||||
}.to_json
|
||||
end # def to_json
|
||||
end # class LogStash::Search::Result
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue