mirror of
https://github.com/elastic/logstash.git
synced 2025-04-24 06:37:19 -04:00
Try to improve the docs for xml
This commit is contained in:
parent
6cf40c15fa
commit
444a19c9d9
1 changed files with 13 additions and 1 deletions
|
@ -10,11 +10,23 @@ class LogStash::Filters::Xml < LogStash::Filters::Base
|
|||
|
||||
# Config for xml to hash is:
|
||||
#
|
||||
# source => dest
|
||||
# source_field => destination_field
|
||||
#
|
||||
# XML in the value of the source field will be expanded into a
|
||||
# datastructure in the "dest" field. Note: if the "dest" field
|
||||
# already exists, it will be overridden.
|
||||
#
|
||||
# For example, if you have the whole xml document in your @message field:
|
||||
#
|
||||
# filter {
|
||||
# xml {
|
||||
# "@message" => "doc"
|
||||
# }
|
||||
# }
|
||||
#
|
||||
# The above would parse the xml from @message and store the resulting
|
||||
# document into the 'doc' field.
|
||||
#
|
||||
config /[A-Za-z0-9_-]+/, :validate => :string
|
||||
|
||||
# xpath will additionally select string values (.to_s on whatever is selected)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue