]> git.openfabrics.org - ~shefty/librdmacm.git/commit
rsocket: Succeed setting SO_KEEPALIVE option rsocket
authorSean Hefty <sean.hefty@intel.com>
Mon, 9 Apr 2012 19:05:39 +0000 (12:05 -0700)
committerSean Hefty <sean.hefty@intel.com>
Mon, 16 Apr 2012 18:23:40 +0000 (11:23 -0700)
commit960d584eff6ed929951b87e7e235e378be3c1026
treeefccb146a38888a3e615a81017329971c08b8fc1
parentbe2701f40e57c583ed7ca4f37a3e9027be9170ad
rsocket: Succeed setting SO_KEEPALIVE option

memcached sets SO_KEEPALIVE, so succeed any requests to set
that option.  We don't actually implement keepalive at this time.

To implement keepalive, we would need to record the last time
that a message was sent or received on an rsocket.  If no
new messages are processed within the keepalive timeout, then
we would need to issue a keepalive message.  For rsockets,
this would simply mean sending a 0-byte control message that
gets ignored on the remote side.

The only real difficulty with handlng keepalive is doing it
without adding threads.  This requires additional work in
poll to occasionally timeout, send keepalive messages, then
return to polling if no new data has arrived.  Alternatively,
we can add a thread to handle sending keepalive messages.

Signed-off-by: Sean Hefty <sean.hefty@intel.com>
src/rsocket.c