MSR Features & Adapter Support

MSR provides a core set of features for managing migrations. Different adapters implement these features to varying degrees. The table below shows which features are available in each adapter.

Feature
MSR Firebase
MSR PostgreSQL
Multi-Format Migrations

Use TypeScript, JavaScript, or SQL for your migrations, often in the same project.

βœ… Supported

TS and JS supported. SQL is not applicable.

πŸ”„ In Progress
Up/Down Methods

Define both forward and reverse logic for each migration, enabling safe rollbacks.

βœ… Supported
πŸ”„ In Progress
Timestamp & Sequential Migrations

Organize migrations with timestamps or simple numeric sequences for clear ordering.

βœ… Supported
πŸ”„ In Progress
State Tracking

Automatically track which migrations have run in your database to prevent re-runs.

βœ… Supported

Uses a dedicated node in Firebase RTDB.

πŸ”„ In Progress

Will use a dedicated schema table.

Dry Run Mode

Simulate a migration run without making any actual changes to your database.

βœ… Supported

Supported via Firebase RTDB transactions.

πŸ”„ In Progress

Will be supported via SQL transactions.

Database Backups

Automatically back up your data before a migration runs for an extra layer of safety.

βœ… Supported
❌ Not Supported
Rollback Strategies

Choose how to roll back: use the "down" method, restore from backup, or both.

βœ… Supported
⚠️ Partial

Down method will be supported. Backup-based rollback is TBD.

Transaction Management

Control how migrations are wrapped in transactions for atomic operations.

⚠️ Partial

Supports transactions on a single data node per migration.

πŸ”„ In Progress

Full transaction control per migration or per batch.

Checksum Validation

Verify that executed migration files haven't been altered to ensure consistency.

βœ… Supported
πŸ”„ In Progress
Custom Validators

Create your own rules to check migrations for correctness before they run.

βœ… Supported
πŸ”„ In Progress
Lifecycle Hooks

Run custom code at different stages of the migration process (e.g., beforeAll, afterEach).

βœ… Supported
πŸ”„ In Progress
Extensible Handlers

Build your own adapter to add MSR support for any database or data store.

βœ… Supported
πŸ”„ In Progress
CLI and Programmatic API

Use MSR via its intuitive command-line interface or as a library in your Node.js app.

βœ… Supported
πŸ”„ In Progress
Migration Locking

Prevent multiple instances from running migrations at the same time in distributed environments.

βœ… Supported
πŸ”„ In Progress
.env & Environment Variable Support

Configure MSR easily using .env files or environment variables instead of config files.

βœ… Supported
πŸ”„ In Progress

All features come from the MSR core. Adapter support may vary.