On Wed, Aug 21, 2002 at 03:43:58PM -0400, Jeff Boes wrote:
> Does an idle event have a default priority?

Try:

  warn $watcher->prio;
  warn $event->prio

> I have a pair of events.  One's an idle event, with no 'prio' value in
> its constructor.  Another is a timer event with a priority of '0'.  The
> idle event retrieves a bunch of stuff from a queue, and executes the
> first item.  If the queue cache is not empty it does
> 
>   $event->w->now();
> 
> to queue itself again rather than wait for the idle to expire.  The
> problem I'm having is that the timer event never gets a chance to
> execute unless the queue cache is empty, i.e., now() is skipped.
> 
> It acts like either the idle event has a higher priority than '0', or
> that events inserted via now() always outrank pre-existing events.

Do you realize that all idle watchers are excuted every time no
other event is pending?  Is any idle watcher really the appropriate
type of watcher for your application?

-- 
Victory to the Divine Mother!!         after all,
  http://sahajayoga.org                  http://why-compete.org

Reply via email to