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

[Query Fuzz] Fill(none) in query hangs #8067

Closed
e-dard opened this issue Feb 27, 2017 · 1 comment
Closed

[Query Fuzz] Fill(none) in query hangs #8067

e-dard opened this issue Feb 27, 2017 · 1 comment

Comments

@e-dard
Copy link
Contributor

e-dard commented Feb 27, 2017

This issue was found by fuzzing the database with a query generator tool. It may be possible to simplify the query to help identify the root cause.

Dataset
$ curl https://s3.amazonaws.com/noaa.water-database/NOAA_data.txt -o NOAA_data.txt
$ influx -import -path=NOAA_data.txt
Query
USE NOAA_water_database

SELECT  "pH" / "degrees", "degrees" FROM  "average_temperature" GROUP BY "pq" FILL(none)
Result

The query hangs. Heap remains very low, no CPU activity.

See attached SIGQUIT on the server.

If you remove the FILL(none) the query returns fine. If you change the query to:

SELECT  "pH" / "degrees", "degrees" FROM  "average_temperature" GROUP BY "pq" FILL(null)

it also returns fine.

1488220500085551134-freeze.txt

@jsternberg
Copy link
Contributor

The issue seems to be because of a mismatch between auxiliary iterators.

All auxiliary iterators are read from the same source and have to be read with each other. pH seems to be an empty value so it returns a null point for everything. That causes FILL(null) to want to skip everything since it produces no values. But the degrees part of the query does want to return a value. Since the expression iterator tries to skip past all of the points, but the second field has not read the first point yet, that causes the query to hang on a goroutine (why there is no cpu usage).

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

No branches or pull requests

2 participants