Clifford Jansen created PROTON-2930:
---------------------------------------
Summary: Epoll proactor busy loop on socket error
Key: PROTON-2930
URL: https://issues.apache.org/jira/browse/PROTON-2930
Project: Qpid Proton
Issue Type: Bug
Components: proton-c
Affects Versions: proton-c-0.40.0
Environment: Linux
Reporter: Clifford Jansen
Assignee: Clifford Jansen
The epoll proactor code for AMQP connections notes EPOLLHUP and EPOLLERR
conditions but defers reacting to the error until the next read or write on the
socket.
It is possible for Linux sockets to note an EPOLLERR for a socket and leave
EPOLLIN and EPOLLOUT unset. At the same time, a send or recv on the socket
will not provide a conclusive error condition, returning EAGAIN. The excellent
reproducer program from PROTON-2928 will trigger this behaviour. Eventually
the kernel does signal one of EPOLLIN or EPOLLOUT providing the expected
winding up of the connection, but the procator busy loops in the interim
waiting for the change to the IO events.
It is possible there are other ways to trigger this beyond the known reproducer.
If the proactor knows the socket is no longer operational, it should not rearm
the socket for polling as it does now. Instead, it should determine the errno
associated with the socket and force the closing of the connection's transport.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]