Commits on Source 5

  • Florian Forster's avatar
    feat(postgres): Add connection pool support via `WithConnectionPool`. · 45495d84
    Florian Forster authored
    Introduces first-class support for routing application traffic through a
    connection pool (e.g. PgBouncer) while allowing migration clients to
    bypass the pool and connect directly to the primary.
    
    New option: `WithConnectionPool(bool)`
    ---------------------------------------
    
    `postgres.New` now accepts `WithConnectionPool(bool)`, defaulting to
    `true`. Pass `WithConnectionPool(false)` to explicitly disable pool
    routing — the intended usage for migration clients, which must bypass
    PgBouncer to avoid statement-timeout kills on long-running queries.
    
    Host and port resolution
    ------------------------
    
    When the connection pool is enabled, host and port resolution follows a
    priority chain before falling back to the primary address:
    
      pool_host config → pool_host secret → host config → host secret
      pool_port config → pool_port secret → port config → port secret
    
    When the connection pool is disabled, `pool_host`/`pool_port` are
    ignored entirely and the chain collapses to the primary address. This
    means pooler-less deployments (e.g. Caproni) work without any
    configuration change.
    
    CrunchyData projection preset
    ------------------------------
    
    The CrunchyData projection preset is extended with `pgbouncer-host` and
    `pgbouncer-port` Secret key mappings. When PgBouncer is enabled in a
    CrunchyData cluster, those keys are present in the pguser Secret and
    will be picked up automatically — no explicit Helm values required.
    Deployments without a pooler fall through to the existing `host`/`port`
    keys.
    
    Pool bypass for migration clients
    ----------------------------------
    
    When `WithConnectionPool(false)` is set, `maxConns` is capped at 1.
    This prevents migration clients from opening a pool of direct primary
    connections, which would defeat the purpose of bypassing PgBouncer.
    
    Bumps Fairway dependency to pick up `pool_host`/`pool_port` fields on
    the `PostgreSQL` proto message (runway/team#920, Fairway side).
    
    Issue: gitlab-com/gl-infra/platform/runway/team#920
    45495d84
  • GitLab Renovate Bot's avatar
    chore(deps): update... · eae2d70b
    GitLab Renovate Bot authored
    chore(deps): update registry.gitlab.com/gitlab-com/gl-infra/common-ci-tasks-images/golang-fips docker tag to v1.26.4
    eae2d70b
  • Florian Forster's avatar
  • Matias Alvarez's avatar
    Merge branch... · 9d8d89ee
    Matias Alvarez authored
    Merge branch 'renovate/registry.gitlab.com-gitlab-com-gl-infra-common-ci-tasks-images-golang-fips-1.x' into 'master'
    
    chore(deps): update registry.gitlab.com/gitlab-com/gl-infra/common-ci-tasks-images/golang-fips docker tag to v1.26.4
    
    See merge request !518
    
    Merged-by: default avatarMatias Alvarez <malvarez@gitlab.com>
    Approved-by: default avatarMatias Alvarez <malvarez@gitlab.com>
    Co-authored-by: default avatarGitLab Renovate Bot <ops-contact+gl-common-ci-tasks-self-renovate@gitlab.com>
    9d8d89ee
  • Elliot Forbes's avatar
    Merge branch 'fforster/postgresql' into 'master' · 12b5123c
    Elliot Forbes authored
    feat(postgres): Add connection pool support via `WithConnectionPool`.
    
    See merge request !515
    
    Merged-by: Elliot Forbes's avatarElliot Forbes <eforbes@gitlab.com>
    Approved-by: Elliot Forbes's avatarElliot Forbes <eforbes@gitlab.com>
    Reviewed-by: Florian Forster's avatarFlorian Forster <fforster@gitlab.com>
    Co-authored-by: Florian Forster's avatarFlorian Forster <fforster@gitlab.com>
    12b5123c
Loading
Loading