[Infrastructures] ISconf: Cache.py - bcast method

Daniel Hagerty Daniel Hagerty <hag@linnaean.org>
Mon, 19 Dec 2005 15:34:31 -0500


 > Keeps crashing on me on the last line of the bcast method in Cache.py.
 > It throws a socket.error exception with the EAGAIN error. I did some
 > looking and other places in the code ignore that error. I trapped the
 > exception and everything runs fine.
 >
 > Is that a bug or am I misunderstanding things.

    Not speaking for what isconf is *supposed* to do, but it's almost
universally the case that the correct response to EAGAIN is to try the
system call that failed again.  Something in the kernel interuptted
the system call, preventing it from completing.  You usually want to
complete whatever it is, rather than pretending the kernel performed
the task, when in fact it didn't.

    (There are some system call toolkits that actually go so far as to
prevent you seeing EAGAIN in high level interfaces -- if you really
want to see EAGAIN, the low level interface is still there).