We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent f770cc5 commit 5532e12Copy full SHA for 5532e12
lib/consumer_supervisor.ex
@@ -44,6 +44,10 @@ defmodule ConsumerSupervisor do
44
45
defmodule Printer do
46
def start_link(event) do
47
+ # Note: this function must return the format of `{:ok, pid}` and like
48
+ # all children started by a Supervisor, the process must be linked
49
+ # back to the supervisor (if you use `Task.start_link/1` then both
50
+ # these requirements are met automatically)
51
Task.start_link(fn ->
52
IO.inspect({self(), event})
53
end)
0 commit comments