Skip to content

nata79/Log-ActiveUsers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 

Repository files navigation

Log-ActiveUsers

You can pipe the tail of your logfile into this script to get an idea of how many users are currently using your web application (if you're logging their IP addresses on each request).

It will add each IP to a set and expire it after 60 seconds if it there isn't other requests from that IP. It's an easy and fast way to get an idea of how popular is your app.

Usage

tail -f production.log | ruby active_users.rb

Or if you use Heroku

heroku logs -t | ruby active_users.rb

About

A ruby script to infer the number of current users in your web application from the IP addresses in the logs

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages