Heroku Log Lights is a visualisation of Heroku router logs for a LED matrix.
This little tool allows you to monitor all your applications router logs in real time. All requests are displayed in a logarithmic scale. 2xx responses are green, 3xx are blue, 4xx yellow & 5xx are red. The longer a request takes the more the color shifts to red. If a request hits the top, it ran for 30s and Heroku throws a H12 (request timeout).
It sounds simple but it provides you with incredible feedback about your applications health.
Everything is green: That's great, but you should think about cache control and ETags. (2xx response)
Everything is purple: That's the heroku way! But maybe your CDN isn't working. (3xx response)
Everything is yellow: Upsy daisy, the latest version of your Android or Angular App is sending wrong requests to your backend... (4xx response)
Everything is red: Run and hide! You have about 10min until your boss comes storming the office and heads are rolling. (5xx response)
- RGB LED Matrix
- Raspberry Pi
- Adafruit RGB Matrix HAT (optional)
- power supply (5V and ~5A per 32x32 pixel)
- for the Adafrouit HAT
- or this one
Henner Zeller not only wrote the library that powers LED matrixes on the Pi, but also wrote a very detailed documentation that should help you assemble all the parts.
Once you have the demo running and all pixels are in the right place, come back and continue with the setup.
You are almost done. All we need now is Python 3 because we are using asyncio (duh).
sudo apt-get install git python3-dev python3-pillow python3-pip -y
cd /tmp
git clone --recursive https://github.com/codingjoe/heroku-log-lights.git
cd heroku-log-lights
make
sudo make install
To access the router logs of your Heroku application, you will need an API token. You can ether install the heroku toolbelt or obtain the API AUTH token from the heroku website.
Via heroku toolbelt:
heroku-log-lights -a YOUR_APP_NAME -t `heroku auth:token`
or via token:
export HEROKU_API_TOKEN=YOUR_SECRET_TOKEN
heroku-log-lights -a YOUR_APP_NAME
That's it, you are ready to roll! Enjoy