Skip to main content
One Hit Wonder
March 31, 2018
Answered

Memory leak in browser and Deezer desktop app

  • March 31, 2018
  • 99 replies
  • 4594 views
Recently, there is a memory leak when using the player in the browser. After closing the tab with the player, the memory returns.
OS: Debian 8.8 amd64 / 3.16.0-4-amd64 #1 SMP Debian 3.16.51-3 (2017-12-13) x86_64 GNU/Linux
Browser: Firefox Quantum 59.0.2 (64-bit)
Best answer by Ana.
Hi there, we don't support Linux on the web version, so I'm unable to offer much help, maybe someone else will have some input. In the meantime, there's a topic on our ideas forum about Linux support, make sure you vote for it to be implemented and join the conversation - https://en.deezercommunity.com/ideas/321

99 replies

bandithedoge
Guitar Hero
Guitar Hero
December 29, 2020

I’d also like to add my 2 cents to this. The memory leaks happen a lot on my Arch Linux system regardless of what I use. Firefox, Vivaldi (Chromium-based), MellowPlayer (Chromium-based music streaming wrapper) and the unofficial Linux port of the desktop app. Most of the time it just uses about 2 GB of RAM, which is still way too much, other times it fills up my entire RAM even when just browsing an artist page.

Roadie
January 8, 2021

Iḿ facing this problem with both Linux and Windows. It was reported 2 years ago and it is still there. It affects both Linux and Windows users. It happens with my Fedora 33 machine running Firefox 84.0.1 and also with my Windows 10 machine running the same version of firefox for windows.

@Deezer, do you have any plans to fix this, or should I stop using the service and sign up to youtube music or spotify?

Rudi
Ultimate Superstar
Ultimate Superstar
January 9, 2021

Hey @bandithedoge @vinRocha 

The plans are to improve our player across all apps this year, so we should see an improvement of the performance of our desktop app :relaxed: please hang in there and stay tuned to our community for updates, it'll be worth it!

Happy New Year!

Richard B. Kreckel
Guitar Hero
Guitar Hero
January 10, 2021

A long while ago, you said that the developers were on it. Now, “the plans are to improve our player across all apps this year, so we should see an improvement of the performance of our desktop app” unforuntately does not sound like a plan to address the particular problem that has been reported here and confirmed multiple times.

It rather sounds like Deezer doesn’t care about fixing this. Or cannot. Or management has set other priorities.

In the meantime, Deezer keeps crashing browsers and freezing computers.

Would it be possible to hear something concrete and convincing from Deezer apart from vague marketing-speak?

Rudi
Ultimate Superstar
Ultimate Superstar
January 11, 2021

Hi @Richard B. Kreckel, appreciate your opinion. In all honesty, it actually sounds we're going back to basics and improve the player as a whole, from scratch, not trying to fix a patch that may not offer a solution in the long term. One of our big focuses this year is to improve reliability, and that's why I suggested you to stay tuned for further updates.

Take good care and have a great week!

Hitmaker
January 26, 2021

Same bug. After an hour or two of HD music on FF 86.

(image from about:memory snapshot)

 

Rudi
Ultimate Superstar
Ultimate Superstar
January 27, 2021

Performance-wise there's a long road to go @bytesnz, that makes sense.

This feedback is always important - could you please confirm you're on version 4.32?

Hitmaker
February 1, 2021

Performance-wise there's a long road to go @bytesnz, that makes sense.

This feedback is always important - could you please confirm you're on version 4.32?


Apologies the memory stats are for the web app (FF being Firefox). Will try in Chromium and see if I have the same issue.

Rudi
Ultimate Superstar
Ultimate Superstar
February 2, 2021

Please do @bytesnz it'll be interesting to compare Deezer's performance between browsers :thumbsup_tone2:

Hitmaker
February 2, 2021

I tested on Chrommium 88 and it seems to be fine. I did a little more digging into the memory snapshot and found “memory-file-data/string” is “Memory used to back a File/Blob based on a string”. In the snapshot above, it would have been ~10274 ~524KB chunks of blobby memory. Haven’t figured out how to dig further or do a clean up, but was wondering if they are stayin around if you are calling createObjectURL on Blobs/Files/MediaSources without then calling revokeObjectURL on them. Also noticed https://developer.mozilla.org/en-US/docs/Web/API/URL/createObjectURL#using_object_urls_for_media_streams which might be valid for you ¯\_(ツ)_/¯

 

I know you are working on a new and improved interface, but fixing this bug would make the current one not have to be closed and refreshed every couple of hours.

 

Just did a quick test to replicate it in FF (ran in console)
 

const part = 'zzzzzzzzz ';
let big = '';

for (let i = 0;i < 52000; i++) {
big += part;
}
// Take memory snapshot (60MB)
// Try making blobs without url
for (let i = 0; i < 400; i++) {
const blob = new Blob([big], {type: 'text/plain'});
}
// Take memory snapshot (60MB)
// Make blobs with urls
let urls = [];
for (let i = 0; i < 400; i++) {
const blob = new Blob([big], {type: 'text/plain'});
urls.push(URL.createObjectURL(blob));
}
// Take memory snapshot (260MB)
// Clear URLs
urls.forEach((url) => URL.revokeObjectURL(url))
// Take memory snapshot (60MB)