On Thursday, July 19, 2018 at 10:10:40 AM UTC-7, 
[email protected] wrote:
>
> Currently we can only specify max connections and it seems that they will 
> stay in pool forever. However if we have spiking load it may be better to 
> close unused connections after some inactivity timeout.
>

The connection_expiration extension can probably be used to do this, though 
that will eventually disconnect and reconnect even if for actively used 
connections.  If you wanted purely to remove connections only when 
inactive, you would probably have to write a new extension.  Note that 
because Sequel uses the equivalent of a queue for the connection pool, all 
connections in the pool will be used on a regular basis even if there is 
low activity.  You would have to have no activity for a substantial period 
of time for connections to become inactive.

Thanks,
Jeremy 

-- 
You received this message because you are subscribed to the Google Groups 
"sequel-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/sequel-talk.
For more options, visit https://groups.google.com/d/optout.

Reply via email to