Rework factory methods for MPI types