summaryrefslogtreecommitdiffstats
path: root/rpc/rpc-lib
diff options
context:
space:
mode:
Diffstat (limited to 'rpc/rpc-lib')
-rw-r--r--rpc/rpc-lib/src/rpc-transport.c7
-rw-r--r--rpc/rpc-lib/src/rpc-transport.h2
2 files changed, 7 insertions, 2 deletions
diff --git a/rpc/rpc-lib/src/rpc-transport.c b/rpc/rpc-lib/src/rpc-transport.c
index f6774b72353..23fbf37360d 100644
--- a/rpc/rpc-lib/src/rpc-transport.c
+++ b/rpc/rpc-lib/src/rpc-transport.c
@@ -572,7 +572,7 @@ out:
//why call it if you dont set it.
int
rpc_transport_keepalive_options_set (dict_t *options, int32_t interval,
- int32_t time)
+ int32_t time, int32_t timeout)
{
int ret = -1;
@@ -588,6 +588,11 @@ rpc_transport_keepalive_options_set (dict_t *options, int32_t interval,
"transport.socket.keepalive-time", time);
if (ret)
goto out;
+
+ ret = dict_set_int32 (options,
+ "transport.tcp-user-timeout", timeout);
+ if (ret)
+ goto out;
out:
return ret;
}
diff --git a/rpc/rpc-lib/src/rpc-transport.h b/rpc/rpc-lib/src/rpc-transport.h
index d1c650e7ec1..d0572a16333 100644
--- a/rpc/rpc-lib/src/rpc-transport.h
+++ b/rpc/rpc-lib/src/rpc-transport.h
@@ -306,7 +306,7 @@ rpc_transport_pollin_destroy (rpc_transport_pollin_t *pollin);
int
rpc_transport_keepalive_options_set (dict_t *options, int32_t interval,
- int32_t time);
+ int32_t time, int32_t timeout);
int
rpc_transport_unix_options_build (dict_t **options, char *filepath,