nkrode / RedisLive

Visualize your redis instances, analyze query patterns and spikes.

Home Page:http://www.nkrode.com/article/real-time-dashboard-for-redis

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Page refresh stops

markwalkom opened this issue · comments

Someone else mentioned this here - http://www.nkrode.com/article/real-time-dashboard-for-redis - given I've also encountered it I was hoping to help sort it out.
Oddly enough if I am connected to the server running this, via ssh, my connection gets terminated so I think that might be related. Could it be possible that the browser connection is being dropped by redis-live.py?

I redirected the output from redis-live.py and can see this break in the log file that is being generated;
[I 130309 18:48:12 web:1462] 200 GET /api/memory?from=&to=&server=172.16.1.100%3A6379 (192.168.126.25) 1.52ms
[I 130309 18:48:12 web:1462] 200 GET /api/topcommands?from=&to=&server=172.16.1.100%3A6379 (192.168.126.25) 0.85ms
[I 130309 18:48:13 web:1462] 200 GET /api/topkeys?from=&to=&server=172.16.1.100%3A6379 (192.168.126.25) 1.13ms
[I 130309 18:48:13 web:1462] 200 GET /api/commands?from=&to=&server=172.16.1.100%3A6379 (192.168.126.25) 3.91ms
[I 130309 18:48:13 web:1462] 200 GET /api/memory?from=&to=&server=172.16.1.100%3A6379 (192.168.126.25) 1.44ms
[I 130309 18:48:13 web:1462] 200 GET /api/topcommands?from=&to=&server=172.16.1.100%3A6379 (192.168.126.25) 0.86ms
[I 130309 18:56:03 web:1462] 304 GET /index.html (192.168.126.25) 0.48ms
[I 130309 18:56:03 web:1462] 304 GET /js/libs/bootstrap/bootstrap.css (192.168.126.25) 0.28ms
[I 130309 18:56:03 web:1462] 304 GET /js/libs/jquery/jquery-1.7.2.min.js (192.168.126.25) 0.27ms
[I 130309 18:56:03 web:1462] 304 GET /js/libs/less/less-1.3.0.min.js (192.168.126.25) 0.70ms
[I 130309 18:56:03 web:1462] 304 GET /js/libs/bootstrap/js/bootstrap-button.js (192.168.126.25) 0.26ms

You can see it stops at 18:48:13, then restarts when I do a manual page refresh.

This is python 2.7.3, running on Ubuntu 12.04 with redis 2.2.12. I did edit redis-monitor.py to set time.sleep to 10, and then setup a cronjob to run it every minute for duration=60 (the system load isn't unbearable for the server), but even without this I get the same issue.

Let me know if there is some debugging I can enable or anything else I can provide that might help.

Thanks for reporting this, it seems like the issue triggers after continuous usage for an extended period.

This might be related to a memory leak in the javascript code of the app or one of the libraries being used like google charts. To highlight the issue a comparison of the Heap snapshot should help. In Chrome developer tools, under Profiles, there is an option to take Heap Snapshot. Comparing multiple snapshots might be helpful in debugging this.