Re: postgres snaplet- resources per stripe?

30 views
Skip to first unread message

mightybyte

unread,
Nov 6, 2012, 11:57:38 PM11/6/12
to snap_fr...@googlegroups.com
snaplet-postgresql-simple uses the resource-pool-catchio package [1] for connection pooling.  We can see here [2] that that value is passed as the last argument to createPool.  The documentation for createPool [3] describes that argument:

[3] http://hackage.haskell.org/packages/archive/resource-pool-catchio/0.2.1.0/doc/html/Data-Pool.html#v:createPool

On Tuesday, November 6, 2012 10:25:31 PM UTC-5, Chris Bolton wrote:
Just getting started with the postgres snaplet, noticed this is the config file:

# Maximum number of resources to keep open per stripe.  The smallest
# acceptable value is 1.
maxResourcesPerStripe = 20

Not a postgres expert, so just wondering if anyone could a quick overview on this parameter? Under what circumstances it should be raised or lowered?

Chris Bolton

unread,
Nov 7, 2012, 12:13:55 AM11/7/12
to snap_fr...@googlegroups.com
Yeah I'm reading the docs.. but I'm just not getting under what exact circumstances you would want to increase the stripe sub-pool count vs resources to have per stripe.
--
 
 
 

MightyByte

unread,
Nov 7, 2012, 12:35:44 AM11/7/12
to snap_fr...@googlegroups.com
On Wed, Nov 7, 2012 at 12:13 AM, Chris Bolton <c...@chrisbolton.me> wrote:
Yeah I'm reading the docs.. but I'm just not getting under what exact circumstances you would want to increase the stripe sub-pool count vs resources to have per stripe.

I'm not exactly sure.  The docs of both resource-pool and resource-pool-catchio are lacking there.  It sounds like it has to do with number of threads created and contention, but you should probably talk to Bryan for a more detailed answer.

Chris Bolton

unread,
Nov 7, 2012, 12:36:14 AM11/7/12
to snap_fr...@googlegroups.com
Alrighty, thankies :)
--
 
 
 

Reply all
Reply to author
Forward
0 new messages