Files
monasca-api/doc/source/contributor/db_migrations.rst
Witek Bedyk 01b59aa66c Move DB migrations documentation to its own file
This part does not really belong to the contributor guide. Also
following up on the comment from the previous review [1].

[1] https://review.opendev.org/729270

Change-Id: Id49130044c3be3ec3c4b00736f678b541bdc5dfa
2020-05-22 17:06:02 +02:00

661 B

Database Migrations

Monasca uses Alembic migrations to set up its configuration database. If you need to change the configuration database's schema, you need to create a migration to adjust the database accordingly, as follows:

cd monasca_api/db/
alembic revision

This will create a new skeleton revision for you to edit. You will find existing revisions to use for inspiration in the /monasca_api/db/alembic/versions/ directory.

Measurement data stored in a Time Series database (such as InfluxDB) would be migrated to a new version using standard practice for a given TSDB.