sync: getting migrationTools code from 6.0.x branch