Pgpool-II

Contents

  • Current Topology
  • Proposed topology
  • Why change
  • Conclusion
  • References

Current topology

When we have a cluster databases based on master and slaves, most of the time read-only databases are idle or has no other jobs than backups, read routines or simply HA with no jobs at all

Proposed topology

Based on the problem, we are proposing the following infrastructure in a way that none of the servers got idle or has no jobs to do.

But Why Change?

To get this proposed topology, we decided to create a PoC (proof of concept) that tested both environments and check it's performance and behavior, then we got those results:

But Why Change?

All tests were made in the same conditions: one master, one slaves, both replicating, both were created by scratch with terraform to no have any cache or S.O jobs running during the tests.

Conclusion

All tests proved that the response time improved by select/inset/updated released agains the database when we are using pgpool-II, at the same time we could do significantly amount more of inserts on the database, it's because of when we are making selects in a idle database, it has more power and resource to consuming while processing write and read in the same database.

References

All tests process and tools and research we made are available here:

 

https://medium.com/@rondineli.gomes.araujo/testing-pgbouncer-pgpool-load-balancing-d0545e6d091



The framework test we used is available here:
https://github.com/Rondineli/pyg-bench/

Pgpool-II

By Rondineli Gomes