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

Periodic Memory Management #2781

Open
pankgeorg opened this issue Jan 17, 2024 · 3 comments
Open

Periodic Memory Management #2781

pankgeorg opened this issue Jan 17, 2024 · 3 comments
Assignees
Labels
backend Concerning the julia server and runtime performance

Comments

@pankgeorg
Copy link
Collaborator

pankgeorg commented Jan 17, 2024

Memory management on a Garbage Collected language is something people usually don't think about. Julia is a little bit different, in the sense that there isn't much memory monitoring going on the process, until the process starts feeling some memory pressure.

When the process does start to feel that memory pressure, it will aggressively run the GC when an allocation happens. This is not the time you'd want to run the GC, when a web request is inflight. Until julia is better at this (and if, because this approach is pretty good for a lot of use cases that julia addresses right now, e.g. doing math) we need to manage the GC a bit more manually.

Similar intent to #2774 (comment), but from the active size.

The methodology I'm describing seems to be a lot more important when big objects are being allocated periodically.

@pankgeorg pankgeorg self-assigned this Jan 17, 2024
@fonsp
Copy link
Owner

fonsp commented Jan 17, 2024

Nice! Do you mean on the notebook process (#1850) or the Pluto server? cc @BioTurboNick

@fonsp
Copy link
Owner

fonsp commented Jan 17, 2024

I think a useful first step is a MWE where memory goes up and a reproducible way to measure it

@fonsp fonsp added backend Concerning the julia server and runtime performance labels Jan 17, 2024
@pankgeorg
Copy link
Collaborator Author

pankgeorg commented Jan 17, 2024

Nice! Do you mean on the notebook process (#1850) or the Pluto server? cc @BioTurboNick

I mainly have the server in mind. For the notebook process, the workload is not web-like/preemptive and in any case, it's much less predictable (And less statistically related to the one I've conducted analysis on)

I think a useful first step is a MWE where memory goes up and a reproducible way to measure it

Good point. The first step is adding observability, which is a whole new issue I'm going to open. Since OpenTelemetry seems to have a memory leak I wouldn't use that, but we can figure something simpler out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Concerning the julia server and runtime performance
Projects
None yet
Development

No branches or pull requests

2 participants