springernature / boomcatch

A standalone, node.js-based beacon receiver for boomerang.
GNU General Public License v3.0
110 stars 33 forks source link

Appended newline to data in file forwarder #100

Open evisong opened 6 years ago

evisong commented 6 years ago

Hi, team,

I've been using Boomcatch together with ELK stacks, my solution depends on unmapped mapper and file forwarder, and then let FileBeat to collect generated json files. However FileBeat doesn't recognize any record if a json file doesn't end with newline (\n).

When I read Boomcatch source code, I think I could append the newline (\n) to the end of data in file forwarder, and I guess it won't break any downstream usages.

I've also adjusted UT.

Could you please help review this PR?

Thanks.