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

Possible memory leak issues with React and HiGlass plugins #1196

Open
alexpreynolds opened this issue May 2, 2024 · 0 comments
Open

Possible memory leak issues with React and HiGlass plugins #1196

alexpreynolds opened this issue May 2, 2024 · 0 comments

Comments

@alexpreynolds
Copy link
Collaborator

I have been working on a React-based genome browser based off HiGlass 1.12.4 and various plugins, including higlass-bigwig-datafetcher, higlass-pileup, higlass-sequence, and higlass-transcripts. Some plugins have been customized to support the type and scale of data we are working with.

It is a promising application, but it has been suffering from performance and stability issues that make it difficult to deploy, specifically with creeping memory usage by a tab containing the HiGlass-backed application.

In my case, this has lead to the application slowing down, the host device fan turning on due to increased GPU and CPU resource usage, and Chrome tabs crashing. We're trying to figure out why.

With some assistance, I have been looking at memory usage of (what I believe are React-backed) HiGlass view configurations from the higlass.io examples page that suggest that there may perhaps be memory leaks or issues with garbage collection, perhaps in Pixijs or d3 assets used by HiGlass and plugins, or perhaps elsewhere, such as in React and with event handlers or other objects not being released.

To demonstrate this, I have recorded a few videos of tab memory usage while panning and zooming tracks in higlass.io examples, with some voiceover to note when memory usage creeps up:

Variant interpretation

https://higlass.io/app/?config=Yzld015XRFaCfCIYbB2MZQ

https://www.youtube.com/watch?v=C46vP8gwfX4

Bam file viewer

https://higlass.io/app/?config=TA_BP0R5R8GfKHkKX7-TzQ

https://www.youtube.com/watch?v=C46vP8gwfX4

In general, memory usage jumps up — sometimes dramatically — but it does not fall back down.

We have observed this with two computers running Chrome, Firefox and Safari on Mac OS X. I have noticed similar symptoms under Chrome on Windows.

I also have another video recorded of memory usage of the internal application I am working on, which uses the various customized plugins I mentioned above. I can share this privately (perhaps in a message on the HiGlass Slack channel?). This also demonstrates creeping memory usage.

Other users of this internal application have noted per-tab memory usage and related symptoms (and more quickly, perhaps because of the scale of the datasets being loaded into memory).

In any case, the idea of looking at the examples on higlass.io was to isolate the symptoms we see to either my customizations or to issues with how a stock installation of HiGlass might be affected by leaks of objects from dependencies, and to ask if you folks might have thoughts on this issue, if it is something you have noticed?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant