Giter VIP home page Giter VIP logo

Comments (4)

sadjad avatar sadjad commented on August 21, 2024 1

I see that lambda function has garbage collection in the beginning of the handler but sometime it is not enough.

You're totally right, but now I see that it is not enough. We put all the objects in /tmp/_gg directory and one solution would be getting rid of that altogether (we only write to this directory and /tmp/thunk-execute.*), but it's not the best decision, because it's possible that some of those blobs can be reused for the current thunk, and we would have to re-download them again.

I just pushed a change (5331864) that cleans out /tmp/_gg, only if the Lambda is out of space. It should fix this.

AWS Lambda Execution Context is something that lives inside AWS and does not have any external control capabilities.

This is my understanding, too.

It may help to transfer the tmp cleaning code to the end of the function to avoid situation when the N-1 call "clogged up" memory.

gg execute cleans up the execution directories itself after the task is done; main.py:35 is there to make sure we don't have any leftovers (e.g., in the case that the Lambda dies mid-job).

from gg.

ssnickolay avatar ssnickolay commented on August 21, 2024

The cause of the problem is described here.

I see that lambda function has garbage collection in the beginning of the handler but sometime it is not enough. I saw this error once when all executions of my function failed (there was an error on my side). A simple solution is to just wait for AWS to drop the execution context (~ 10 minutes).

from gg.

wsmoses avatar wsmoses commented on August 21, 2024

Yeah, I noticed this went away after a while. I don't suppose there is a way we could get gg to flush/remove the context if it picks up this error?

from gg.

ssnickolay avatar ssnickolay commented on August 21, 2024

AWS Lambda Execution Context is something that lives inside AWS and does not have any external control capabilities. Moreover, a full description of the Execution Contex lifecycle is also unclear. We only know that it exists and is something like a cache, to support the "warmed up" lambda functions.
It may help to transfer the tmp cleaning code to the end of the function to avoid situation when the N-1 call "clogged up" memory. And only @sadjad can say whether it makes sense.

from gg.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.