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

Simplify prepared statement parameters handling #35

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

a-urth
Copy link
Member

@a-urth a-urth commented Jan 5, 2022

Problem
If my understanding of the logic below is correct then named arguments which are not correctly prefixed (X-Trino-...) are considered as prepared statement's parameters. If so then logic was a bit convoluted - for example there was no need to check for empty prepared statement header for each argument.

Solution
Restructure argument parsing logic so headers and non headers (prepared statement parameters) cases are more explicit and verbose. Add corresponding comments and improve readability.

@cla-bot cla-bot bot added the cla-signed label Jan 5, 2022
@a-urth a-urth requested review from hashhar, nineinchnick and losipiuk and removed request for hashhar January 5, 2022 11:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

None yet

1 participant