Skip to content

WIP: Bundle pgpool-II 3.6.1

yorickpeterse-staging requested to merge pgpool into master

General

  • Get the absolute most basic pgpool setup up and running: 1 pgpool instance, one host to forward queries to (in staging)
  • Figure out how to add hosts to pgpool, and if this can be done dynamically
  • Log to STDERR so runit can take care of it
    • Logging to STDERR is the default
  • Figure out if relation caching is useful to us (this might speed up application bootups)
    • Used for caching system catalog information, doesn't seem to be flushed automatically upon an ALTER table; requires a timeout instead. This could speed up queries used by Rails to get the columns for every model, though it's not clear how great that overhead is to begin with
  • Figure out what pgpool uses in-memory caching for, and if it's useful
    • This appears to be used for caching the output of SELECT queries. This could be quite useful for caching frequently executed queries. The cache appears to be flushed automatically.
  • Figure out if we use temporary tables, disable pgpool checking this if we don't use them (reduces master load)
    • As far as I can tell we only use this in lib/gitlab/database/median.rb and only for MySQL

PostgreSQL

pgpool

  • pgpool configuration generation/management (pgpool.conf and pgpool_hba.conf)
  • Set up pgpool watchdog (required for managing multiple nodes, reaching consensus, failovers, etc: http://www.pgpool.net/docs/latest/en/html/tutorial-watchdog-intro.html)
  • Create/configure the PID directory (if necessary when using runit)
  • Support & enable pgpool health checks
  • Support & enable pgpool replication checks
  • Create/configure the socket directory

Replication

The following is required to set up replication, which is necessary to ensure all load balanced nodes have the same data:

Merge request reports