Skip to content

How to do a high-availability rolling update? #4270

@wolfchimneyrock

Description

@wolfchimneyrock

Description

Registry
Version
: 2.5.8
Persistence type: sql

For our in progress high-availability Apicurio deployment, I am trying to understand how we will be able to do rolling upgrades without causing an outage window.

Environment

We are running Apicurio Registry on a clustered set of VM's, each VM connecting to a shared distributed PostgreSQL db.

When upgrades occur, the new software is installed and started on one VM at a time. If the process fails then a roll-back is usually automatically attempted before going to the next VM.

This typically lets us upgrade software without impacting availability during.

With Apicurio Registry, it looks like database schema changes can occur between releases which are automatically applied when the software is started. Also there is a strict requirement that only one database version can work with a given software version.

because of this, when the first VM gets its upgraded software it will upgrade the database, and the other VM's will continue to serve client requests running the old software fetching from the new database. I don't see any indication that this will always work, as sometimes updates remove tables or columns etc...

If there is an issue with the new software we can't roll-back to the prior version since the database has been upgraded and the old software doesn't work with a new database.

Do you have any insight on how we can achieve rolling upgrades?

One Idea is to remove the strict software - db version requirement, instead the software has a minimum db version requirement (even a window of two db versions allowed would help), since you could break db updates into two steps

  1. add new features, deprecate old ones
  2. remove old features

and then have a guarantee that any software version can work with two different database versions.

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions