Just thinking -  Maybe we should give ```EntityManager``` as parameter to getRepository.
Seems more clear for me keep the factory method aware about the EM that's asking for a repository.