You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to Doctrine best practices, I implemented an EntityManagerDecorator. But then the jms-job-queue:run command yielded:
Return value of JMS\JobQueueBundle\Command\RunCommand::getEntityManager() must be an instance of Doctrine\ORM\EntityManager, instance of App\Service\EntityManagerDecorator returned.
My App\Service\EntityManagerDecorator extends Doctrine\ORM\Decorator\EntityManagerDecorator, according to https://github.com/doctrine/orm/blob/2.7/lib/Doctrine/ORM/EntityManager.php#L55
This is not really documented and I'm not sure if I did it correctly, but I guess JMS\JobQueueBundle\Command\RunCommand should expect Doctrine\ORM\EntityManagerInterface instead of Doctrine\ORM\EntityManager for its return value.
I'll gladly provide more details if necessary.
The text was updated successfully, but these errors were encountered:
mcorteel-harel
changed the title
Using an EntityManagerDecorator yelds a fatal error
Using an EntityManagerDecorator yields a fatal error
Feb 6, 2020
According to Doctrine best practices, I implemented an EntityManagerDecorator. But then the
jms-job-queue:run
command yielded:My
App\Service\EntityManagerDecorator
extendsDoctrine\ORM\Decorator\EntityManagerDecorator
, according to https://github.com/doctrine/orm/blob/2.7/lib/Doctrine/ORM/EntityManager.php#L55This is not really documented and I'm not sure if I did it correctly, but I guess
JMS\JobQueueBundle\Command\RunCommand
should expectDoctrine\ORM\EntityManagerInterface
instead ofDoctrine\ORM\EntityManager
for its return value.I'll gladly provide more details if necessary.
The text was updated successfully, but these errors were encountered: