MEDIUM: servers: Add a way to keep idle connections alive.
Add a new keyword for servers, "idle-timeout". If set, unused connections are
kept alive until the timeout happens, and will be picked for reuse if no
other connection is available.
diff --git a/include/types/connection.h b/include/types/connection.h
index cd9f1e7..745546c 100644
--- a/include/types/connection.h
+++ b/include/types/connection.h
@@ -444,7 +444,7 @@
struct sockaddr_storage from; /* client address, or address to spoof when connecting to the server */
struct sockaddr_storage to; /* address reached by the client, or address to connect to */
} addr; /* addresses of the remote side, client for producer and server for consumer */
- struct timeval idle_tv; /* Time the connection was added to the idle list */
+ unsigned int idle_time; /* Time the connection was added to the idle list */
};
/* PROTO token registration */