paul-rogers commented on PR #13206:
URL: https://github.com/apache/druid/pull/13206#issuecomment-1276855442

   > The idea here would be to let the cursor drive the bucketing, rather than 
letting the bucketing drive the cursor.
   
   This seems like a good longer-term solution. Can we go further? Any reason 
to create buckets that will be empty? If we're doing time-based grouping, and 
data is time ordered, we can create buckets on the fly as we read the data. 
This is the classic streaming grouping solution: one doesn't normally enumerate 
all possible customers, say, to group sales by customer.
   
   There would have to be code to handle empty groups, if we we want to fill 
empty time slots. But, this can be done by enumerating the time buckets as we 
return results. If the next result is greater than the current time bucket, 
return zeros. For this, the set of buckets need not be materialized, just 
enumerated.
   
   > Improving the performance of timestamp_floor...
   
   For fixed-length intervals, (week or less), the time floor should be a 
simple mod-then-subtract. For variable-length intervals, the logic is more 
complex. Can we split the implementations for those two cases? Week-or-less is 
super fast, Month-or-more pays the extra compute cost?


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to