Hi Logstash Jedi Masters
I need an example of a Ruby script which:
- Accepts a data record from Logstash
- Adds a new field to the record (e.g. : [ “NewField” ] )
- Fills in a default value (e.g. : [ “NewField” ] = “abc123” )
- Returns the record back to Logstash
I’ve been Googling this for an hour or so, but just can’t begin to guess at the syntax here. The syntax for creating the field and then accessing it really confuses me. Can anyone throw me a line? Thank you!