Skip to content

Capture and save state of the thread when suspending #369

@harendra-kumar

Description

@harendra-kumar

When composing multiple streams using concurrent combinators like async, ahead or parallel we stop a thread midway in the stream if we find that the buffer is full. When we resume the stream later we start using a fresh monadic state from the SVar (svarMrun), at this point we have lost the state of the stream as it was when the stream stopped and we are now using incorrect state.

To resolve this we can either block the thread instead of stopping it or we can capture the state of the stream and store it along with the stream in the workqueue.

Metadata

Metadata

Assignees

Labels

type:bugDoes not work as expected

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions