Explain how to run memray and send file over the network for containers #598
Labels
documentation
Improvements or additions to documentation
enhancement
New feature or request
good first issue
Good for newcomers
Is there an existing proposal for this?
Is your feature request related to a problem?
When a process runs out of memory in a container, it is common for it to be killed by its orchestration, e.g. with Kubernetes. This means that running
memray run ...
would create a file on the file system, which will be immediately thrown away as soon as the process crashes with a OOM (Out Of Memory) error.Memray itself cannot post-process the file (sending it over the network for example) because any work it does will be interrupted when the process crashes. So even though we already have a part of our code that compresses the capture file after it's finished writing, memray couldn't call that code because the process would be interrupted already.
Describe the solution you'd like
Adding documentation on how to wrap
memray run ...
with a shell script to (for example) compress and send the capture file over the network for later analysis would be helpful, given that we have at least two different people who have come to us with this problem already.Alternatives you considered
No response
The text was updated successfully, but these errors were encountered: