Execute logstash script as batch

Use the stdin input instead of the file input.

Your input should be:

input { 
    stdin { } 
}

Then you will need to use the command that @warkolm posted before.

type testLog.log | logstash.bat -f myconf.conf 

Also, read this topic, it seems to be what you want, maybe it will help: stop logstash after processing the file.

1 Like