[Xapian-tickets] [Xapian] #546: xapian-replicate reads from a socket without using timeouts
Xapian
nobody at xapian.org
Thu Nov 15 04:33:04 GMT 2012
#546: xapian-replicate reads from a socket without using timeouts
-------------------------+--------------------------------------------------
Reporter: nkvoll | Owner: olly
Type: defect | Status: new
Priority: normal | Milestone: 1.3.2
Component: Replication | Version:
Severity: normal | Keywords:
Blockedby: | Platform: All
Blocking: |
-------------------------+--------------------------------------------------
Changes (by olly):
* milestone: 1.3.x => 1.3.2
Comment:
Marking to consider soonish.
The patch as-is seems too problematic if it adds a timeout on the
replication as a whole.
Details of the socket timeout options (from {{{man 7 socket}}}):
{{{
SO_RCVTIMEO and SO_SNDTIMEO
Specify the receiving or sending timeouts until reporting
an
error. The argument is a struct timeval. If an input or
output
function blocks for this period of time, and data has been
sent
or received, the return value of that function will be
the
amount of data transferred; if no data has been transferred
and
the timeout has been reached then -1 is returned with errno
set
to EAGAIN or EWOULDBLOCK just as if the socket was specified
to
be nonblocking. If the timeout is set to zero (the
default)
then the operation will never timeout. Timeouts only
have
effect for system calls that perform socket I/O (e.g.,
read(2),
recvmsg(2), send(2), sendmsg(2)); timeouts have no effect
for
select(2), poll(2), epoll_wait(2), and so on.
}}}
Though I've read a few (perhaps dated) warnings that they aren't
implemented everywhere.
--
Ticket URL: <http://trac.xapian.org/ticket/546#comment:10>
Xapian <http://xapian.org/>
Xapian
More information about the Xapian-tickets
mailing list