rswestmoreland / graylog-delimited-file-output-plugin

An output plugin for Graylog2, providing the ability to export messages to disk as CSV, TSV, space or pipe delimited files
GNU General Public License v3.0
7 stars 9 forks source link

Several defined outputs go to last created file #5

Closed mrtndimitrov closed 3 years ago

mrtndimitrov commented 3 years ago

Hello, I have bunch of streams and each has a corresponding file output made by this module. Here is the config of one, the rest are very similar, just the filename is different:

buffersize: 8192
compress: none
debug: false
endline: newline
fields: COMBINEDAPACHELOG
filedone: <empty>
fileformat: space
filepath: /stats/stream1.log
flushinterval: 1
rotateinterval: 0
strategy: count

I get very strange behavior. All logs go to the last generated file meaning if a stream that didn't have any input yet, receives a message, the file is correctly created but them all other outputs start writing to this last one. And then to the next one and so on. I've double checked the streams and they receive and display just the messages they are supposed to. There is no mixing of messages. Any idea? Thanks in advance.

Martin

mrtndimitrov commented 3 years ago

I've examined the code and made changes to allow this. If needed by someone, please check the fork I created: https://github.com/mrtndimitrov/graylog-delimited-file-output-plugin