-
Notifications
You must be signed in to change notification settings - Fork 197
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
Introducing the Observer pattern to SQL execution #2939
base: 4.9.x
Are you sure you want to change the base?
Introducing the Observer pattern to SQL execution #2939
Conversation
Seems like a good idea but needs tests |
@graemerocher Added tests for the usual suspects (CRUD) and also added a test for |
I wonder if it makes sense to instrument the |
That would require introspecting statements. We have some other issue requesting combining parameters binding logging with the query, so maybe this can be combined. |
good point, but we should probably at least enhance |
What do you mean by enhance? |
@dstepanov I took a peek at that other issue you mentioned and while this mechanism would definitely work for that we would need to add some sort of trigger/done function to the observers in order to perform the actual logging. As I am not that familiar with this codebase I am unsure of where that trigger should actually happen. That said I'm happy to add it if you point me in the general direction of where you think it would be best to do it. |
95890d9
to
37b9a9f
Compare
…ing the same information to Spans (tracing)
37b9a9f
to
20487e7
Compare
Externalising the QUERY_LOG as an observer so the same mechanism can be used for adding the query information to Spans (tracing)