- Can I use this bundle with Laravel or Symfony 6+?
- No, this bundle is **exclusively for eZPlatform 1/2 or eZPublish 5.x** (Symfony 2/3). It won’t work with Laravel or modern Symfony 6+ stacks. For Ibexa DXP 3/4, use `tanoconsulting/ibexa-migration-bundle` instead.
- How do I generate a migration for content changes (e.g., updating 1000+ nodes)?
- Use `php bin/console kaliop:migration:generate` to scaffold a YAML migration. For bulk operations, leverage the `mass_migrate` command or write custom loops in the DSL. Test with small batches first to avoid timeouts or memory issues.
- What’s the difference between `migrate` and `mass_migrate`?
- `migrate` runs a single migration file sequentially, while `mass_migrate` applies **all pending migrations** in order. Use `mass_migrate` for full deployments and `migrate` for targeted fixes. Both support the `-a` flag to specify a custom admin user ID.
- Will this work in production? How do I handle rollbacks?
- Migrations run in **atomic transactions** by default, but there’s **no native rollback** for content changes (e.g., deleted nodes). For critical data, back up your database before running migrations or implement manual undo steps in a separate migration file.
- Does this bundle support PostgreSQL or only MySQL?
- It supports **any database Doctrine DBAL handles** (MySQL, PostgreSQL, etc.), as long as eZPublish 5.x is configured for it. The bundle itself doesn’t add DB-specific logic, so compatibility depends on your existing setup.
- How do I test migrations before deploying to production?
- There’s no built-in dry-run mode, but you can **test locally** by running migrations against a staging database clone. For validation, add `echo` statements or log checks in your YAML DSL. Use `kaliop:migration:status` to verify pending migrations.
- What if a migration fails mid-execution? Can I resume it?
- Yes, use `kaliop:migration:resume` to pick up where it left off. Failed steps are logged in the `kaliop_migrations` table. For complex failures, check the Symfony debug log (`var/log/dev.log`) for errors.
- Is there a way to encrypt sensitive data (e.g., passwords) in migrations?
- No, the YAML DSL doesn’t natively support encryption. Hardcode sensitive values at your own risk or pre-process them via a **pre-migration script** (e.g., using Symfony’s parameter bag or environment variables).
- How do I handle migrations for multi-tenant eZPublish setups?
- The bundle defaults to admin user ID `14`, which may not work in multi-tenant environments. Override it with the `-a` flag (e.g., `kaliop:migration:migrate -a=99`) or extend the bundle to dynamically fetch the correct user ID per tenant.
- What are the alternatives if I’m on Ibexa DXP 3/4 or Symfony 6+?
- For **Ibexa DXP 3/4**, use `tanoconsulting/ibexa-migration-bundle` (Symfony 5+). For **Symfony 6+**, consider migrating to **Doctrine Migrations** or **Symfony Migrations** with custom eZPlatform content handlers. This bundle is **not future-proof** for modern stacks.