Need reviewer for 6913877: (fs) AsynchronousFileChannel.write can return wrong result under load [win]
Alan.Bateman at Sun.COM
Tue Jan 5 03:03:32 PST 2010
Christopher Hegarty -Sun Microsystems Ireland wrote:
> This change looks good. I have just one question about the requirement
> to call Invoker.invoke(result) at the end of the run method of
> WriteTask. I can see that in the ReadTask case this may be an
> optimization for EOF, but I don't think it is necessary for write. If
> you run with system assertions enabled and write throws an Exception
> then the assertion in Invoker.invoke will be triggered, right?
> Otherwise looks good.
Thanks Chris. If a write operation is initiated specifying a completion
handler, and the write operation cannot be initiated then the completion
handler's failed method must be invoked. That Invoker.invoke(result)
does that (directly or indirectly depending on if it's a pooled-thread
More information about the nio-dev