I'm creating a plugin for WordPress. This plugin will need to save data to the database. In other programming frameworks I've worked with, there are systems called "database migrations". These migrations are
- Sometimes abstracted into the programming language of the framework
- Written and stored in a common way such that a user of my plugin/extension/etc can say "run the migrations" and the database will be update, per my instructions
- And sometimes includes features that allow you to "rollback" those changes
An example migration system is Laravel's.
Does WordPress have a system that's similar to migrations? If not, is there a canonical way (via a particular hook, plugin registration, etc) to package up the new database tables and/or changes to existing WordPress tables my plugin will need?