apex-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bhupesh Chawda <bhupeshcha...@gmail.com>
Subject Handling idle time for operator
Date Wed, 02 Sep 2015 08:26:07 GMT
Hi All,

I understand that handleIdleTime() is called when the operator is idling
and is intended for auxiliary processing. Also, if the operator does not
have anything to do, it must block for some time to avoid busy loop.
What happens if my processing within handleIdleTime() exceeds the amount of
time it would have blocked otherwise? In that case does it make a
difference whether the processing is done in handleIdleTime() or in
endWindow() call?

To clarify the question, is this the right approach:

  do some work W;
  t = time to do work W;
  sleep(SPIN_MILLIS - t);

What is the right approach if t > SPIN_MILLIS?

Bhupesh Chawda

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message