MEDIUM: servers: Add a command to limit the number of idling connections.
Add a new command, "pool-max-conn" that sets the maximum number of connections
waiting in the orphan idling connections list (as activated with idle-timeout).
Using "-1" means unlimited. Using pools is now dependant on this.
diff --git a/include/types/connection.h b/include/types/connection.h
index bcc2965..eff1001 100644
--- a/include/types/connection.h
+++ b/include/types/connection.h
@@ -446,7 +446,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 */
- unsigned int idle_time; /* Time the connection was added to the idle list */
+ unsigned int idle_time; /* Time the connection was added to the idle list, or 0 if not in the idle list */
};
/* PROTO token registration */