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

feat(tsi): optimize series iteration #22316

Merged
merged 3 commits into from
Aug 27, 2021

Conversation

danxmoran
Copy link
Contributor

Closes #22314

Forward-ports #20544

lesam and others added 3 commits August 26, 2021 15:07
When using queries like 'select count(_seriesKey) from bigmeasurement`, we
should iterate over the tsi structures to serve the query instead of loading
all the series into memory up front.
@danxmoran danxmoran requested review from lesam and removed request for lesam August 26, 2021 19:28
@lesam
Copy link
Contributor

lesam commented Aug 26, 2021

This looks like a fine forward port, but are we sure we want it for 2.x ? The main use in 1.x is for SHOW SERIES CARDINALITY FROM foo type queries, but I had understood 2.x already optimized these?

@danxmoran
Copy link
Contributor Author

I don't know of any existing cardinality-related optimizations in 2.x. Flux isn't able to query it directly until #21513 is done, and AFAIK the influxql engine is a close port of the behavior from pre-1.9. There could be something in the code that I'm not aware of, though.

I also think we want to merge this in so we can forward-port the InfluxQL HLL functions that depend on it (@dgnorton confirmed we want those functions in 2.x InfluxQL).

@danxmoran danxmoran merged commit df448c6 into master Aug 27, 2021
@danxmoran danxmoran deleted the dm-forward-port-tsi-optimize-series-iteration branch August 27, 2021 13:59
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.

[forward-port 2.x] Optimize TSI series iteration
2 participants