Re: Comm API notes

From: Amos Jeffries <squid3_at_treenet.co.nz>
Date: Thu, 11 Sep 2008 14:34:29 +1200 (NZST)

> On Thu, 2008-09-04 at 23:27 -0600, Alex Rousskov wrote:
>
> The comm_close API will be split into "stop I/O" and "kill me" APIs.
> New user code should not use comm_close for the purpose of ending a
> job (and should not assume it does). In most cases, the job has more
> tasks to do even if the descriptor is closed. AsyncJob API provides
> job-ending tools.

Well, after reading the whole docs and your comment to Henrik earlier, I
don't see a point to the 'kill me' part of this.

If a comm user wants to die based on the FD closing, then its close
handler should do it. Comm does not need to know when its users are
closing. Just like it does not need to know about non-comm calls. All it
needs to know is that it has a user handler to call or if Dialing that
handler failed.

Some users will kill themselves when that handler is called, others will
shift their queueing to async calls for a slow wind down and cleanup. But
none of that can or need depend on comm.

Amos
Received on Thu Sep 11 2008 - 02:34:32 MDT

This archive was generated by hypermail 2.2.0 : Thu Sep 11 2008 - 12:00:12 MDT