-
Notifications
You must be signed in to change notification settings - Fork 123
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Nested LoggerChains causing big call stack #72
Nested LoggerChains causing big call stack #72
Conversation
…ding AuditLogger. Also added null check to AuditHelper
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some tests are failing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just have a look at my last comments and I think it will be all good
Made the changes requested. Let me know if everything looks alright! Thanks! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for this contribution, I'll change the strict type comparison on my own ;)
See Issue 70. LoggerChains are nested inside each other and when Doctrine calls startQuery on the EntityManager's SQLLogger, the LoggerChains will create call stacks for each nest. If xdebug is enabled, once the call stack reaches the "max_nesting_level", an Exception will be thrown.
This code flattens the EntityManager's SQLLogger by detecting if it is already a LoggerChain and if so only appending the AuditLogger created.