org.apache.camel
Enum ThreadPoolRejectedPolicy
java.lang.Object
java.lang.Enum<ThreadPoolRejectedPolicy>
org.apache.camel.ThreadPoolRejectedPolicy
- All Implemented Interfaces:
- Serializable, Comparable<ThreadPoolRejectedPolicy>
public enum ThreadPoolRejectedPolicy
- extends Enum<ThreadPoolRejectedPolicy>
Represent the kinds of options for rejection handlers for thread pools.
These options are used for fine grained thread pool settings, where you
want to control which handler to use when a thread pool cannot execute
a new task.
Camel will by default use CallerRuns.
- Version:
- $Revision: 924437 $
Abort
public static final ThreadPoolRejectedPolicy Abort
CallerRuns
public static final ThreadPoolRejectedPolicy CallerRuns
DiscardOldest
public static final ThreadPoolRejectedPolicy DiscardOldest
Discard
public static final ThreadPoolRejectedPolicy Discard
values
public static final ThreadPoolRejectedPolicy[] values()
- Returns an array containing the constants of this enum type, in
the order they're declared. This method may be used to iterate
over the constants as follows:
for(ThreadPoolRejectedPolicy c : ThreadPoolRejectedPolicy.values())
System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in
the order they're declared
valueOf
public static ThreadPoolRejectedPolicy valueOf(String name)
- Returns the enum constant of this type with the specified name.
The string must match exactly an identifier used to declare an
enum constant in this type. (Extraneous whitespace characters are
not permitted.)
- Parameters:
name
- the name of the enum constant to be returned.
- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant
with the specified name
asRejectedExecutionHandler
public RejectedExecutionHandler asRejectedExecutionHandler()
Copyright © 2007-2010 The Apache Software Foundation. All Rights Reserved.