Added flexible migrations to 3.0 branch