PIM-3446: Fix memory issue when loading a lot of warning

Fix associated with current upstream bug, for performance and memory issues.
http://doctrine-orm.readthedocs.org/en/latest/tutorials/extra-lazy-associations.html