Validation on persist breaks with Doctrine Lazy Loading Proxies
I am currently experiencing an error with the Validate-On-Persist:
Fatal error: Call to a member function getClassName() on a non-object in /.../Data/Temporary/Development/Cache/Code/FLOW3_Object_Classes/TYPO3_FLOW3_Persistence_Doctrine_PersistenceManager_Original.php on line 112
The stack trace is attached.
After debugging a little deeper, it appears that this happens when a lazily-loaded entity is updated. In this case, the get_class($object) in ReflectionService returns something like "Doctrine\....Proxies\FooBarDomainModelBar" --> and obviously our Reflection Service cannot deal with this.