[Dbix-class] Stick to single slave with Replicated? Anyone using PgBouncer?

Peter Edwards peter at dragonstaff.co.uk
Wed Oct 6 07:22:46 GMT 2010

On 6 October 2010 03:01, Bill Moseley <moseley at hank.org> wrote:

> I have a master and two slaves configured.  Each web server process then
> has three database connections.
> I've been asked if it possible to make Replicated randomly pick one of the
> slave and only connect to that one slave.  The idea is that *about* 1/2 t=
> web server processes would use one slave and 1/2 the other to reduce numb=
> of connections total on the slaves.
> The plan now is to put PgBouncer for connection pooling in front of the
> actual slaves and master.  Anyone using PgBouncer with DBIC?
> Also, does/will Replicated notice (say by a ping) if a slave is unavailab=
> and take it out of the pool?

I'd be interested to hear what you go with.

Have you considered trialling Postgresql 9.0 now it has built-in replication
and read slaves?

>From http://developer.postgresql.org/pgdocs/postgres/release-9-0.html

Built-in replication based on log shipping. This advance consists of two
features: Streaming Replication, allowing continuous archive (WAL) files to
be streamed over a network connection to a standby server, and Hot Standby,
allowing continuous archive standby servers to execute read-only queries.
The net effect is to support a single master with multiple read-only slave

Regards, Peter
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.scsys.co.uk/pipermail/dbix-class/attachments/20101006/5d5=

More information about the DBIx-Class mailing list