Skip to content

rust 如何避免 async 任务泄漏呢? #1

Open
@sober-wang

Description

作为 golang 程序员,我知道可以用 done channel 或 context 将 goroutine 关闭,以防止 goroutine 的泄漏。

如果一个 rust 程序中有大量的 async 并行,程序员忘记 close() 或 join() 势必会造成 async 泄漏。rust 是如何避免这种情况的?

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions