Dandandan opened a new pull request #698:
URL: https://github.com/apache/arrow-datafusion/pull/698


   # Which issue does this PR close?
   Closes #697
   
    # Rationale for this change
   <!--
    Why are you proposing this change? If this is already explained clearly in 
the issue then this section is not needed.
    Explaining clearly why changes are proposed helps reviewers understand your 
changes and offer better suggestions for fixes.  
   -->
   
   Currently, when polling for work, the executor always waits 250 ms in 
between polling for tasks.
   This means if the tasks themselves are small, it can be unproductive for a 
large percent of the time.
   
   We can track whether we received tasks in the last iterations to avoid 
sleeping.
   
   Also a slightly lower sleep time (e.g. 100ms) can help reduce the initial 
delay.
   
   
   # What changes are included in this PR?
   <!--
   There is no need to duplicate the description in the issue here but it is 
sometimes worth providing a summary of the individual changes in this PR.
   -->
   
   Keep track of whether we received some tasks last time. If it's the case we 
don't sleep, otherwise we do.
   
   Also reduce hard-coded 250 to 100ms to reduce initial delay a bit.
   
   # Are there any user-facing changes?
   <!--
   If there are user-facing changes then we may require documentation to be 
updated before approving the PR.
   -->
   
   <!--
   If there are any breaking changes to public APIs, please add the `api 
change` label.
   -->
   


-- 
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]


Reply via email to