8000 Move query to req body instead of uri by BelferMan · Pull Request #23 · depyronick/clickhouse-client · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Move query to req body instead of uri #23

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 3 commits into from
Feb 20, 2023
Merged

Conversation

BelferMan
Copy link
Contributor
@BelferMan BelferMan commented Feb 13, 2023

Hi

My team and I are using this library, and it's really great.
Yesterday, we stumbled upon a problem with one of our queries.
We have a huge query (Can't paste it here because of our db privacy:)),
and we got an error from our Click house server:

<html>
<head><title>414 Request-URI Too Large</title></head>
<body>
<center><h1>414 Request-URI Too Large</h1></center>
</body>
</html>

The problem is, that in "_getRequestOptions" the query is forward inside the URI,
and there is a limit of that: https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/414

So I moved the query to the request body, you can see in the CH documentation that they support the query in the URI and in the body as well: https://clickhouse.com/docs/en/interfaces/http/#cli-queries-with-parameters

After that change, the problem solved for us.

Many thanks for your work!
Ilan

@depyronick depyronick changed the base branch from main to dev February 20, 2023 12:15
@depyronick
Copy link
Owner

Thank you for your contribution!

@depyronick depyronick merged commit a863f5a into depyronick:dev Feb 20, 2023
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
0