jainankitk commented on PR #14413:
URL: https://github.com/apache/lucene/pull/14413#issuecomment-2774601593

   > I'd have a top-level tree for everything related to initializing the 
search and combining results (rewrite(), createWeight(), 
CollectorManager#reduce) and then a list of trees for each slice.
   
   While working on the code, I realized it is better to have list of slices 
within the tree itself at each level, instead of repeating the query structure 
and information across multiple trees. In this approach, we can easily view the 
tree for specific `sliceId` using jq or simple script. The structure looks like 
below:
   ```
   "query": [ <-- for list of root queries
                 {
                   "type": "TermQuery",
                   "description": "foo:bar",
                   "startTime" : 11972972,
                   "totalTime": 354343,
                   "breakdown" :   {.....}, <-- query level breakdown like 
weight count and time
                   "sliceBreakdowns": [
                   {.....},    <-- first slice information
                   {.....}]    <-- second slice information
                   "queryChildren": [
                   {......},  <-- recursive repetition of above structure
                   {......}]
   ```
   
   
   > Related, it'd be nice if each per-slice object could also tell us about 
the thread that it ran in and its start time so that we could understand how 
exactly Lucene managed to parallelize the search.
   
   Yes, that would be really useful. I have included the threadId as `sliceId`, 
`startTime` and `totalTime` information for each slice object at every query 
level.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to