I'm writing a new input plugin. I have a need to run some logic everytime a new event is captured by Logstash.
Based on the outcome of the logic I want to decide whether the event will be further processed or will it be dropped.
Ex: say with file input plugin - I want to do some validation on the new file and based on it I want to allow it to be processed or terminated.
For this where do I write my logic?? I tried in the run(queue) method but seems like it is only run at the initiation of the input plugin.