Add wikipedia track ESQL profiling#984
Conversation
…or-esql-profiling # Conflicts: # so_vector/track.py
…or-esql-profiling # Conflicts: # so_vector/track.py
…or-esql-wikipedia-profiling
|
|
||
| # Build took_ms entries for each profiled phase | ||
| result = {} | ||
| if profile: |
There was a problem hiding this comment.
we have a check here to see that profile is present, but we don't have one after this if statement when we iterate over the drivers and plans.
I wonder if profile can ever be empty - and if it can - wouldn't it be better to just return early, e.g:
result = {}
if not profile:
return result
There was a problem hiding this comment.
Makes sense - I modified both the wikipedia and so_vector versions in 92e06d5
ioanatia
left a comment
There was a problem hiding this comment.
i wonder if we can avoid the duplication of EsqlProfileRunner from both so_vector and the wikipedia track since they look identical.
but fine with me to follow up on that separately.
We could for now add a TODO comment in the declarations of EsqlProfileRunner to deduplicate them. This can also act as a reminder that if someone modifies just one of them, it might be useful to do the same for the other.
Yep - the only way that I found is to move them to rally itself as a new runner. Given that this is still WIP as we may add / change the profile information, I opted to duplicate the code for now (this is similar to +1 to move that to rally eventually. |
|
@carlosdelest
Backporting entails:
Thank you! |
Adds ES|QL profiling metrics to the ES|QL queries in the wikipedia track.
Related #973, elastic/elasticsearch#139540, elastic/elasticsearch#138564