Proposal: Task.Supervisor.async_stream_nolink to monitor created tasks same as Task.Supervisor.async_nolink

45 views
Skip to first unread message

Anastasiya Dyachenko

unread,
May 15, 2020, 3:51:13 PM5/15/20
to elixir-lang-core
Hi!
I propose to add monitoring of tasks, created in Task.Supervisor.async_stream_nolink, so it would work the same as Task.Supervisor.async_nolink for cases when it used in OTP behaviour. 
For now, there is no info in docs that there are no monitoring and handle_info would not call, cause docs say it works same as async_nolink. And I think it would be better to repeat that behaviour at async_stream_nolink, cause it is barely possible to monitor these tasks manually. At least it would be great to add info in docs that there are no monitoring and example how to add monitoring manually. Thanks!


José Valim

unread,
May 15, 2020, 4:31:14 PM5/15/20
to elixir-l...@googlegroups.com
In async_stream there is a separate process that controls the stream, so there isn't much the parent process can do, even in terms of monitors. If you need monitors and control, then it is best to not use the stream. I will update the docs, thanks!

--
You received this message because you are subscribed to the Google Groups "elixir-lang-core" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elixir-lang-co...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/elixir-lang-core/f41d0091-23c8-4af1-9bb6-67c8f22f54f1%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages