Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Can Logstash Work With Ruby on rails?

Has anyone gotten Logstash working with ruby on rails?

My client is telling to use Logstash for log collector etc. I am using ruby on rails technology. most of the part is almost done. But requirement is to get logs into logstash.

Please let me know Is it possible,how?

like image 415
Manish Shrivastava Avatar asked Feb 28 '12 08:02

Manish Shrivastava


2 Answers

I wrote a gem for the same - logstasher . It writes rails logs in a separate file, in pure json format which can be consumed by logstash without any processing.

See my blog for complete instructions on how to setup Logstash and Kibana

like image 70
ShadyKiller Avatar answered Nov 05 '22 14:11

ShadyKiller


Here is a gist link on integrating logstash. Also, there is logstash-lite, a ruby gem and the subsequent github project might shed some light on it if you want to roll your own and not trust the gem

like image 20
ScottJShea Avatar answered Nov 05 '22 13:11

ScottJShea