Skip to content

Don't recommend forkIO #165

Closed
Closed
@NorfairKing

Description

@NorfairKing

The docs for pubSubForever use forkIO:

-- forkIO $ forever $

but that's probably not what we want to be using.
For example, if the forked thread crashes, the other threads will not notice.
Could we recommend using withAsync instead?

See the docs here for more details on both the problem and the solution: http://hackage.haskell.org/package/async-2.2.3/docs/Control-Concurrent-Async.html

cc @vidocco

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions