<div dir="ltr"><br><div>Hi dear fellow erlangers,</div><div><br></div><div>New to Erlang, I'm building a small comment backend for practice. By my design there are many worker processes that handle comments posted from different URLs, and these workers are all under simple_one_for_one supervision.</div>
<div><br></div><div>I also decide to start a dispatcher process to map certain URL comment to corresponding worker by worker_sup:start_child(URL) and then store returned Pid.</div><div><br></div><div>So here comes the problem, I expect that worker may be restarted by supervisor. Is there a way to get the worker's Pid after restarted by supervisor, so that I can keep track of which URL comment should go for which worker process?</div>
<div><br></div><div>Hope express myself clearly cause not a native speaker :)</div><div><br></div><div>B.R.</div></div>