Class InboundThreadFactory
- java.lang.Object
-
- org.apache.synapse.util.concurrent.InboundThreadFactory
-
- All Implemented Interfaces:
ThreadFactory
public class InboundThreadFactory extends Object implements ThreadFactory
This is the thread factory for Synapse threads which are accessible through the SynapseEnvironment as pooled threads.
-
-
Constructor Summary
Constructors Constructor Description InboundThreadFactory(ThreadGroup group, String namePrefix)
Constructor for the ThreadFactory to create new threads
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Thread
newThread(Runnable runnable)
This method is the implementation of the the newThread method and will create new threads under the group and with the nameprefix followed by the thread number as the id
-
-
-
Constructor Detail
-
InboundThreadFactory
public InboundThreadFactory(ThreadGroup group, String namePrefix)
Constructor for the ThreadFactory to create new threads- Parameters:
group
- - all the threads are created under this group by this factorynamePrefix
- - name prefix of the threads created by this factory
-
-
Method Detail
-
newThread
public Thread newThread(Runnable runnable)
This method is the implementation of the the newThread method and will create new threads under the group and with the nameprefix followed by the thread number as the id- Specified by:
newThread
in interfaceThreadFactory
- Parameters:
runnable
- - Runnable class to run by the created thread- Returns:
- a Thread executing the given runnable
-
-