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

Inconsistent comunication with buddy on /sql?mode=raw #2840

Open
5 tasks
donhardman opened this issue Dec 12, 2024 · 2 comments
Open
5 tasks

Inconsistent comunication with buddy on /sql?mode=raw #2840

donhardman opened this issue Dec 12, 2024 · 2 comments
Assignees
Labels

Comments

@donhardman
Copy link
Contributor

donhardman commented Dec 12, 2024

Bug Description:

When we send a request to /sql?mode=raw, we can send it in 2 ways: POST and GET.

When we send a POST request, it works well, and in the logs with Buddy, we can see that the daemon sends proper information.

curl "0:9308/sql?mode=raw" -d "query=show%20queries"
{"type":"unknown sql request","error":{"message":"P01: syntax error, unexpected identifier, expecting VARIABLES near 'queries'","body":{"error":"P01: syntax error, unexpected identifier, expecting VARIABLES near 'queries'"}},"version":3,"user":"","message":{"path_query":"/sql?mode=raw","body":"show queries","http_method":""}}

When we send it as a GET request, the request fails due to different daemon behavior.

curl "0:9308/sql?mode=raw&query=show%20queries"
{"type":"unknown sql request","error":{"message":"P01: syntax error, unexpected identifier, expecting VARIABLES near 'queries'","body":{"error":"P01: syntax error, unexpected identifier, expecting VARIABLES near 'queries'"}},"version":3,"user":"","message":{"path_query":"/sql?mode=raw&query=show querieses","body":"mode=raw&query=show queries","http_method":""}}

We expect that the daemon will send the same information in the GET method as it sends with POST.

Manticore Search Version:

Latest dev version

Operating System Version:

Ubuntu Jammy

Have you tried the latest development version?

None

Internal Checklist:

To be completed by the assignee. Check off tasks that have been completed or are not applicable.

  • Implementation completed
  • Tests developed
  • Documentation updated
  • Documentation reviewed
  • Changelog updated
@tomatolog
Copy link
Contributor

I've just fixed the issue with wrong URI pass into buddy at 15a08f1

Now sure if the CLT test should be created

@tomatolog tomatolog reopened this Dec 12, 2024
@tomatolog tomatolog assigned donhardman and unassigned tomatolog Dec 12, 2024
@donhardman
Copy link
Contributor Author

@PavelShilin89 let's validate it with new tests

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants