How to add value to the output file using FileBeats?

Im learning filebeats where I am try to copy the data from input file to output file. I am able to do it like below by giving options in filebeats.yml file as.

- input_type: log

  # Paths that should be crawled and fetched. Glob based paths.
  paths:
- /home/cloudera/Desktop/inpB

#----------------------------- Writing output file-----------------------------
output.file:
  path: "/home/cloudera/Desktop"
  filename: outB
#----------------------------- Writing output file-----------------------------

Current output in my file looks like below:
{"@timestamp":"2017-03-28T07:17:58.910Z","beat": {"hostname":"quickstart.cloudera","name":"quickstart.cloudera","version":"5.2.2"},"input_type":"log","message":"1989 NewYork","offset":4,"source":"/home/cloudera/Desktop/inpB","type":"log"}
{"@timestamp":"2017-03-28T07:17:58.910Z","beat":{"hostname":"quickstart.cloudera","name":"quickstart.cloudera","version":"5.2.2"},"input_type":"log","message":"1989 Amsterdam","offset":9,"source":"/home/cloudera/Desktop/inpB","type":"log"}

In the next step, I want to add/concatenate some value to the existing record present in the input file and send it to the output file. For example: My input file has two records in two lines: 1.1989 NewYork 2. 1989 Amsterdam. What I want to do is, if the record contains keyword 'NewYork' add 'America' in the end and for 'Amsterdam' add 'Netherlands' to it and send it to the output file.
Can anyone tell me how to perform this. Thanks in advance.

You need to use Logstash for that, beats are not built to do any sort of transformation.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.