with JSON input, i have field like
Name:Value
build.artifacts.hyper-mingw64-x86_64-debug-master.0.0.1677.rd3e0b27a.tgz.archive: "SOME VALUE1"
build.artifacts.hyper-mingw64-x86_64-debug-master.0.0.1677.rd3e0b27a.zip.archive: "SOME VALUE2"
build.artifacts.hyper-symbols-mingw64-x86_64-debug-master.0.0.1677.rd3e0b27a.tgz.archive : "SOME VALUE3"
etc
I would like to suppress/ mutate->remove fields to such fields. in logstash filter,
how can we search for pattern like field names starting with "build.artifacts*"?
how can we find the length of field name if needed?
note: here i want to search the key and not its value.
Objective: to ignore any json fields that are under this structure "build.artifacts.*"
Example:
build.artifacts.hyper-mingw64-x86_64-debug-master.0.0.1677.rd3e0b27a.tgz.archive: "SOME VALUE1"
build.artifacts.hyper-mingw64-x86_64-debug-master.0.0.1677.rd3e0b27a.zip.archive: "SOME VALUE2"
i tried the following construct that didint work
prune{
blacklist_names => [ "%{[build][artifacts]}"]
Yeah, the prune filter doesn't work with nested fields. If you want to delete the whole [build][artifacts] hierarchy a simple mutate filter that deletes [build][artifacts] should do.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.