Iterating and then collecting the results was sync and a bottleneck for the ingester queries, and we fixed that in https://github.com/grafana/tempo/pull/4100. we did it by pushing down the collection of results and that makes it a parallel and removes the iteration step.
we can do the same for the call to generators in the queries and make them fast.
along with these changes, removed the type assertions and use of interface{} return types from forGivenGenerators and callback function forEachGeneratorFn
Which issue(s) this PR fixes:
Fixes #
Checklist
[x] Tests updated
[ ] Documentation added
[x] CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]
What this PR does:
Iterating and then collecting the results was sync and a bottleneck for the ingester queries, and we fixed that in https://github.com/grafana/tempo/pull/4100. we did it by pushing down the collection of results and that makes it a parallel and removes the iteration step.
we can do the same for the call to generators in the queries and make them fast.
this is a follow up on https://github.com/grafana/tempo/pull/4100, as discussed https://github.com/grafana/tempo/pull/4100#discussion_r1772783985
along with these changes, removed the type assertions and use of
interface{}
return types fromforGivenGenerators
and callback functionforEachGeneratorFn
Which issue(s) this PR fixes: Fixes #
Checklist
CHANGELOG.md
updated - the order of entries should be[CHANGE]
,[FEATURE]
,[ENHANCEMENT]
,[BUGFIX]