Skip to content

x/pkgsite: transient 500 errors on frontend during DB replica maintenance #80045

Description

@hyangah

When a DB replica is offline for maintenance, frontend instances bound to that replica fail all requests, resulting in a high request failure rate across the frontend pool.

  • Cause:

    • Frontend instances randomize their primary DB host choice at startup.
    • The current fallback mechanism to the secondary DB host is only executed during startup connection check.
    • Once running, the connection pool remains static and cannot route around the dead replica.
  • Potential solution to look into:
    The driver supports multi-host DSN. Configure connection strings with all the replica hosts.
    Configure the connect timeout in the DSN, so connection attempts to an offline host time out quickly and fail over to the healthy one.

Metadata

Metadata

Assignees

No one assigned

    Labels

    NeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.pkgsite

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions