Chapter 13. Scaling with PL/Proxy
Adding a slave here and there is really a nice scalability strategy, which is basically enough for most modern applications. Many applications will run perfectly well with just one server; you might want to add a replica to add some security to the setup, but in many cases, this is pretty much what people need.
If your application grows larger, you can, in many cases, just add slaves and scale out reading. This too is not a big deal and can be done quite easily. If you want to add even more slaves, you might have to cascade your replication infrastructure, but for 98 percent of all applications, this is going to be enough.
In those rare, leftover 2 percent of cases, PL/Proxy can come to the rescue. The idea of PL/Proxy is to be able to scale out writes. Remember that transaction-log-based replication can scale out only reads; there is no way to scale out writes.
Tip
If you want to scale out writes, turn to PL/Proxy. However, before this is done, consider...