Skip to content
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

chore: remove record log and turn on dbm propagation #2285

Merged

Conversation

KishenKumarrrrr
Copy link
Contributor

@KishenKumarrrrr KishenKumarrrrr commented Nov 20, 2024

Problem

This PR is a continuation of #2283. The profile from the latest callback spike indicates that the logging statement in the callback flow is introducing a significant bottleneck to our processing. This could be explained by the log statement that attempts to log out the entire record that is returned to us by SNS.

Screenshot 2024-11-20 at 10 35 18 AM

Solution

In this PR, I avoid logging out the entire record in an attempt to remove the above-mentioned bottleneck. Additionally, I also set dbmPropagationMode: 'full' in our tracers so that we can retrieve explain plans of the SQL statements we are executing in the future. Based on the traces, the DB query is the next potential bottleneck in the execution and generating data on its performance will allow us to optimise in the future.

@KishenKumarrrrr KishenKumarrrrr self-assigned this Nov 20, 2024
@KishenKumarrrrr KishenKumarrrrr marked this pull request as ready for review November 20, 2024 05:28
Copy link
Member

@jia1 jia1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you, @KishenKumarrrrr. There's a 2nd log statement that is taking up time too. Will you be finding that statement, or just dealing with this one alone is sufficient enough?

Update: We sync-ed up and concluded that we should deal with this more resource-intensive log statement first before tackling the next.

@KishenKumarrrrr KishenKumarrrrr merged commit 3ccb15a into master Nov 21, 2024
30 of 31 checks passed
@KishenKumarrrrr KishenKumarrrrr deleted the refactor/remove-logging-in-email-callback-flow branch November 21, 2024 01:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants