Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

jQuery - Live Visitors Widget memory leak #1662

Closed
anonymous-matomo-user opened this issue Aug 31, 2010 · 6 comments
Closed

jQuery - Live Visitors Widget memory leak #1662

anonymous-matomo-user opened this issue Aug 31, 2010 · 6 comments
Labels
Bug For errors / faults / flaws / inconsistencies etc. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
Milestone

Comments

@anonymous-matomo-user
Copy link

Hi

I have noticed that after having the Piwik dashboard with the Live Visitors widget embedded open for a while, Firefox (and also Chrome) becomes really sluggish.

I've attached a heap dump (from Chrome) ... +235MB image data in quarter an hour is quite bad. I would assume that entries, that are no longer displayed in the widget are not destroyed correctly.

All the best

wirtsi

@anonymous-matomo-user
Copy link
Author

Attachment:
piwik.png

@sgiehl
Copy link
Member

sgiehl commented Aug 31, 2010

Well, there are 3 request sent every 8 seconds even if the further requests are still pending. That may cause the browser to overload with pending requests if server is a bit slow.

We should try to reduce the requests to only one if possible. Also new requests should only be send if latest requests are finished (or they should be aborted).

@robocoder
Copy link
Contributor

(In [3253]) refs #1662 - add appendTo setting so we can attach spy to the #content div; previously it would attach to the <body> and continue to run in the background after the widget was no longer present

@mattab
Copy link
Member

mattab commented Nov 24, 2010

As mentioned by SteveG, Currently, the Live! plugin will start 3 more ajax requests every N seconds. If the previous requests are not done, this will cause some very large requests queuing, eventually crashing the browser and causing load on the Piwik server.

New ajax requests should not be started before the 3 previous ones have returned.

@robocoder
Copy link
Contributor

Looking at spy.js, it looks like it guards against starting requests while there's an outstanding request.

I'm retargeting as this is appears to be a bug in jQuery ajax (see http://bugs.jquery.com/ticket/6242), not fixed in the latest version, jQuery 1.4.4.

@mattab
Copy link
Member

mattab commented Jan 5, 2011

Fixed in r3624

This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws / inconsistencies etc. Major Indicates the severity or impact or benefit of an issue is much higher than normal but not critical.
Projects
None yet
Development

No branches or pull requests

4 participants