INNER CODE UNIT · Java

pollDelay

RuedigerMoeller/kontraktor · attic/ElasticScheduler.java:91

    public void pollDelay(int count) {
        backOffStrategy.yield(count);
    }

    @Override
    public void put2QueuePolling(Queue q, boolean isCBQ, Object o, Object receiver) {
        int count = 0;
        boolean warningPrinted = false;
        while ( ! q.offer(o) ) {
            pollDelay(count++);
            if ( count > RECURSE_ON_BLOCK_THRESHOLD && isCBQ) {
                // thread is blocked, try to schedule other actors on this dispatcher (only calbacks+futures!)
                if (Thread.currentThread() instanceof DispatcherThread) {

                    // fixme: think about consequences in depth.
	                //

	                // if blocked trying to put a callback onto a callback queue:

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…