org.jgroups.util
Class ShutdownRejectedExecutionHandler

java.lang.Object
  extended by org.jgroups.util.ShutdownRejectedExecutionHandler
All Implemented Interfaces:
java.util.concurrent.RejectedExecutionHandler

public class ShutdownRejectedExecutionHandler
extends java.lang.Object
implements java.util.concurrent.RejectedExecutionHandler

ShutdownRejectedExecutionHandler is a decorator RejectedExecutionHandler used in all JGroups ThreadPoolExecutor(s). Default RejectedExecutionHandler raises RuntimeException when a task is submitted to ThreadPoolExecutor that has been shutdown. ShutdownRejectedExecutionHandler instead logs only a warning message.

Version:
$Id: ShutdownRejectedExecutionHandler.java,v 1.101 2008/04/08 14:49:05 belaban Exp $
Author:
Vladimir Blagojevic
See Also:
ThreadPoolExecutor, RejectedExecutionHandler

Constructor Summary
ShutdownRejectedExecutionHandler(java.util.concurrent.RejectedExecutionHandler handler)
           
 
Method Summary
 void rejectedExecution(java.lang.Runnable r, java.util.concurrent.ThreadPoolExecutor executor)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ShutdownRejectedExecutionHandler

public ShutdownRejectedExecutionHandler(java.util.concurrent.RejectedExecutionHandler handler)
Method Detail

rejectedExecution

public void rejectedExecution(java.lang.Runnable r,
                              java.util.concurrent.ThreadPoolExecutor executor)
Specified by:
rejectedExecution in interface java.util.concurrent.RejectedExecutionHandler


Copyright © 1998-2008 Bela Ban. All Rights Reserved.