Skip to content

pending client won't wake up when using prepared statement #12

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

Closed
ycdeng opened this issue Sep 27, 2019 · 2 comments
Closed

pending client won't wake up when using prepared statement #12

ycdeng opened this issue Sep 27, 2019 · 2 comments

Comments

@ycdeng
Copy link

ycdeng commented Sep 27, 2019

Hi, I'm testing builtin-pool.
The problem is channel_read() function of proxy.c.
When using prepared statement, a message contains multiple commands, for example, "Parse", "Bind" ... . If a client execute prepared statement and wait for free backend, on condition "Backend was not assigned", only the first command , for example ,"Parse" will be sent when pending client is served.
therefore, the backend is waiting for next command from client , and client is waiting for the respond from backend.

@knizhnik
Copy link

Thank you for reporting the problem.
Fix by commit 4e7eb6a

@ycdeng
Copy link
Author

ycdeng commented Sep 29, 2019

it's ok now.
thank you

@ycdeng ycdeng closed this as completed Sep 29, 2019
knizhnik pushed a commit that referenced this issue Mar 21, 2021
Test #12 overwrote a 1-byte varlena header to make it look like the
initial byte of a 4-byte varlena header, but the results were
endian-dependent. Also, the byte "abc" that followed the overwritten
byte would be interpreted differently depending on endian-ness.
Overwrite 4 bytes instead, in an endian-aware manner.

Test #13 accidentally managed to depend on TOAST_MAX_CHUNK_SIZE,
which varies slightly depending on MAXIMUM_ALIGNOF. That's not
the point anyway, so make the regexp insensitive to the expected
number of chunks.

Mark Dilger

Discussion: http://postgr.es/m/[email protected]
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

No branches or pull requests

2 participants