|
GridGain 2.1.0
Java API Specification |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.concurrent.AbstractExecutorService
java.util.concurrent.ThreadPoolExecutor
org.gridgain.grid.thread.GridThreadPoolExecutorService
public class GridThreadPoolExecutorService
An ExecutorService that executes submitted tasks using pooled grid threads.
See Also:
Documentation
Email Support
Online Forums
Issue Tracking
Author: 2005-2008 Copyright © GridGain Systems. All Rights Reserved. ver. 2.1.0
![]() |
![]() |
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class java.util.concurrent.ThreadPoolExecutor |
|---|
ThreadPoolExecutor.AbortPolicy, ThreadPoolExecutor.CallerRunsPolicy, ThreadPoolExecutor.DiscardOldestPolicy, ThreadPoolExecutor.DiscardPolicy |
| Field Summary | |
|---|---|
static int |
DFLT_CORE_POOL_SIZE
Default core pool size (value is 100). |
static int |
DFLT_MAX_POOL_SIZE
Default maximum pool size (value is 100). |
| Constructor Summary | |
|---|---|
GridThreadPoolExecutorService()
Creates a new service with default initial parameters. |
|
GridThreadPoolExecutorService(int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue)
Creates a new service with the given initial parameters. |
|
GridThreadPoolExecutorService(int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue,
RejectedExecutionHandler handler)
Creates a new service with the given initial parameters. |
|
GridThreadPoolExecutorService(int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue,
ThreadFactory threadFactory,
RejectedExecutionHandler handler)
Creates a new service with the given initial parameters. |
|
GridThreadPoolExecutorService(String gridName)
Creates a new service with default initial parameters. |
|
GridThreadPoolExecutorService(String gridName,
int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue)
Creates a new service with the given initial parameters. |
|
GridThreadPoolExecutorService(String gridName,
int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue,
RejectedExecutionHandler handler)
Creates a new service with the given initial parameters. |
|
| Method Summary |
|---|
| Methods inherited from class java.util.concurrent.AbstractExecutorService |
|---|
invokeAll, invokeAll, invokeAny, invokeAny, submit, submit, submit |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int DFLT_CORE_POOL_SIZE
public static final int DFLT_MAX_POOL_SIZE
| Constructor Detail |
|---|
public GridThreadPoolExecutorService()
| Name | Default Value |
|---|---|
| Core Pool Size | 100 (see GridThreadPoolExecutorService.DFLT_CORE_POOL_SIZE). |
| Maximum Pool Size | None, is it is not used for unbounded queues. |
| Keep alive time | No limit (see Long.MAX_VALUE). |
Blocking Queue (see BlockingQueue). |
Unbounded linked blocking queue (see LinkedBlockingQueue). |
public GridThreadPoolExecutorService(int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue)
corePoolSize - The number of threads to keep in the pool, even if they are idle.maxPoolSize - The maximum number of threads to allow in the pool.keepAliveTime - When the number of threads is greater than the core, this is the maximum time
that excess idle threads will wait for new tasks before terminating.workQueue - The queue to use for holding tasks before they are executed. This queue will hold only
runnable tasks submitted by the ThreadPoolExecutor.execute(Runnable) method.
public GridThreadPoolExecutorService(int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue,
RejectedExecutionHandler handler)
corePoolSize - The number of threads to keep in the pool, even if they are idle.maxPoolSize - The maximum number of threads to allow in the pool.keepAliveTime - When the number of threads is greater than the core, this is the maximum time
that excess idle threads will wait for new tasks before terminating.workQueue - The queue to use for holding tasks before they are executed. This queue will hold only the
runnable tasks submitted by the ThreadPoolExecutor.execute(Runnable) method.handler - Optional handler to use when execution is blocked because the thread bounds and queue
capacities are reached. If null then ThreadPoolExecutor.AbortPolicy
handler is used by default.public GridThreadPoolExecutorService(String gridName)
| Name | Default Value |
|---|---|
| Core Pool Size | 100 (see GridThreadPoolExecutorService.DFLT_CORE_POOL_SIZE). |
| Maximum Pool Size | None, is it is not used for unbounded queues. |
| Keep alive time | No limit (see Long.MAX_VALUE). |
Blocking Queue (see BlockingQueue). |
Unbounded linked blocking queue (see LinkedBlockingQueue). |
gridName - Name of the grid.
public GridThreadPoolExecutorService(String gridName,
int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue)
gridName - Name of the gridcorePoolSize - The number of threads to keep in the pool, even if they are idle.maxPoolSize - The maximum number of threads to allow in the pool.keepAliveTime - When the number of threads is greater than the core, this is the maximum time
that excess idle threads will wait for new tasks before terminating.workQueue - The queue to use for holding tasks before they are executed. This queue will hold only
runnable tasks submitted by the ThreadPoolExecutor.execute(Runnable) method.
public GridThreadPoolExecutorService(String gridName,
int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue,
RejectedExecutionHandler handler)
gridName - Name of the grid.corePoolSize - The number of threads to keep in the pool, even if they are idle.maxPoolSize - The maximum number of threads to allow in the pool.keepAliveTime - When the number of threads is greater than the core, this is the maximum time
that excess idle threads will wait for new tasks before terminating.workQueue - The queue to use for holding tasks before they are executed. This queue will hold only the
runnable tasks submitted by the ThreadPoolExecutor.execute(Runnable) method.handler - Optional handler to use when execution is blocked because the thread bounds and queue
capacities are reached. If null then ThreadPoolExecutor.AbortPolicy
handler is used by default.
public GridThreadPoolExecutorService(int corePoolSize,
int maxPoolSize,
long keepAliveTime,
BlockingQueue<Runnable> workQueue,
ThreadFactory threadFactory,
RejectedExecutionHandler handler)
corePoolSize - The number of threads to keep in the pool, even if they are idle.maxPoolSize - The maximum number of threads to allow in the pool.keepAliveTime - When the number of threads is greater than the core, this is the maximum time
that excess idle threads will wait for new tasks before terminating.workQueue - The queue to use for holding tasks before they are executed. This queue will hold only the
runnable tasks submitted by the ThreadPoolExecutor.execute(Runnable) method.threadFactory - Thread factory.handler - Optional handler to use when execution is blocked because the thread bounds and queue
capacities are reached. If null then ThreadPoolExecutor.AbortPolicy
handler is used by default.
|
GridGain 2.1.0
Java API Specification |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
|
GridGain - Grid Computing Made Simple, ver. 2.1.0.19122008
2005-2008 Copyright © GridGain Systems. All Rights Reserved. |
|
|