Update your Filebeat configuration to set fields on events from each file. Those fields could e.g. describe the application name and the environment name. Based on that you can apply custom filtering on the Logstash side.
Thanks, I would really appreciate if you can share a way that i can do something to differentiate the files in logstash.conf. Is it possible? Would be a good practice?
Can you review it as i m getting an error in filebeat "Failed to Publish events: write: connection reset by peer" while pushing the file from Filebeat to Logstash.
filebeat.prospectors:
type: log
enabled: true
paths:
/app/uce/uce.csv
document_type: spam
logstash.conf
input {
port => "10011"
[type] => "spam"
}
filter {
if [type] == "spam" {
}
}
output {
if [type] == "spam" {
}
}
Thanks, It is now working.
I can see the harvester is running and sending data to my logstash and logstash is tagging it as i want.
But I am getting something like below, actually its many.
at io.netty.channel.MultipthreadEvenLoopGroup.register
at io.netty.bootstrap.AbstractBootstrap.initAndRegister
at io.netty.bootstrap.AbstractBootstrap.doBind
at io.netty.bootstrap.AbstractBootstrap.bind
at sun.reflect.GeneratedMethodAccessor41
at org.jruby.javasupport.JavaMethod.invokeDirectWithExceptionHandling
at org.jruby.javasupport.JavaMethod.invokeDirect
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.