c

    Chris O'Brien

    2 years ago
    Hi Prefect Team, we have noticed that even without caching, that the results from tasks in a scheduled flow don’t fall out of scope (and therefore eligible for garbage collection) until the 3rd run. Is there a way to stop this behaviour? With large extract functions this can mean a lot of memory being held.
    Chris White

    Chris White

    2 years ago
    Hm I’m not sure what might be going on here. FYI
    flow.run()
    is mainly supported for local testing and development so if you happen to find the root cause we’d be more than happy to make the change but we probably won’t dig too deep ourselves
    c

    Chris O'Brien

    2 years ago
    Thanks @Chris White, so in Production what’s the expected method of starting a flow?
    Chris White

    Chris White

    2 years ago
    Hey @Chris O'Brien in general we recommend our agent model so that each Flow Run gets one short-lived process, and as of last night we have open sourced a backend and UI that supports this workflow! https://github.com/PrefectHQ/prefect/releases/tag/0.10.0