Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Reduce callproc roundtrip time #636

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

Merged
merged 2 commits into from
Mar 14, 2018
Merged

Conversation

vtermanis
Copy link
Contributor

@vtermanis vtermanis commented Jan 20, 2018

Rather than making an individual SET query for each and every parameter specified for a callproc call, use one single call instead, saving round-trip time (if one has more than one parameter). This can be significant if one is making many repeated callproc calls which have multiple arguments.

Then only downside I can think of is that if one or more arguments are quite large, combining them all could hit the max_allowed_packet limit. However, if it is only e.g. one large argument this will make next to no difference and the user should have an increased max_allowed_packet value in anticipation of e.g. larger blobs already.

Edit: As far as I can tell the CI test failures are nothing to do with my change, producing errors about invalid syntax for unrelated queries. test_callproc in fact passes.

- Make only one single call to SET variables used as procedure parameters
@methane methane merged commit 9c1b0d8 into PyMySQL:master Mar 14, 2018
@vtermanis vtermanis deleted the callproc_single_set branch March 15, 2018 10:36
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Aug 2, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
Morty Proxy This is a proxified and sanitized view of the page, visit original site.