summaryrefslogtreecommitdiff
path: root/docs
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2018-04-14 12:46:15 -0700
committerGarrett D'Amore <garrett@damore.org>2018-04-14 12:46:15 -0700
commit5dfd550c68284438aeaacbaef815fc7d2f75f068 (patch)
treef6e1d0139e673f133cdcc4114977f5b67689c80d /docs
parentc66ef25c7dfd0c2a3c4a8aa8eea223fa186c2311 (diff)
downloadnng-5dfd550c68284438aeaacbaef815fc7d2f75f068.tar.gz
nng-5dfd550c68284438aeaacbaef815fc7d2f75f068.tar.bz2
nng-5dfd550c68284438aeaacbaef815fc7d2f75f068.zip
fixes #308 Close can block
Ultimately, this just removes the support for lingering altogether. Based on prior experience, lingering has always been unreliable, and was removed in legacy libnanomsg ages ago. The problem is that operating system support for lingering is very inconsistent at best, and for some transports the very concept is somewhat meaningless. Making things worse, we were never able to adequately capture an exit() event from another thread -- so lingering was always a false promise. Applications that need to be sure that messages are delivered should either include an ack in their protocol, use req/rep (which has an ack), or inject a suitable delay of their own. For things going over local networks, an extra delay of 100 msec should be sufficient *most of the time*.
Diffstat (limited to 'docs')
-rw-r--r--docs/man/nng_options.5.adoc14
1 files changed, 0 insertions, 14 deletions
diff --git a/docs/man/nng_options.5.adoc b/docs/man/nng_options.5.adoc
index b5b62815..d71a7b54 100644
--- a/docs/man/nng_options.5.adoc
+++ b/docs/man/nng_options.5.adoc
@@ -21,7 +21,6 @@ nng_options - socket, dialer, listener, and pipe options
#define NNG_OPT_SOCKNAME "socket-name"
#define NNG_OPT_RAW "raw"
-#define NNG_OPT_LINGER "linger"
#define NNG_OPT_RECVBUF "recv-buffer"
#define NNG_OPT_SENDBUF "send-buffer"
#define NNG_OPT_RECVFD "recv-fd"
@@ -73,19 +72,6 @@ can have multiple dialers and endpoints associated with them.
An attempt has been made to include details about such restrictions in the
description of the option.
-[[NNG_OPT_LINGER]]
-((`NNG_OPT_LINGER`))::
-(((lingering)))
-(`<<nng_duration.5#,nng_duration>>`)
-This is the linger time of the socket in milliseconds.
-When this value is non-zero, then the system will
-attempt to defer closing until it has undelivered data, or until the specified
-timeout has expired.
-
-NOTE: Not all transports support lingering, and
-so closing a socket or exiting the application can still result in the loss
-of undelivered messages.
-
[[NNG_OPT_LOCADDR]]
((`NNG_OPT_LOCADDR`))::
(`<<nng_sockaddr.5#,nng_sockaddr>>`)