Class CamelThreadFactory
java.lang.Object
org.apache.camel.util.concurrent.CamelThreadFactory
- All Implemented Interfaces:
ThreadFactory, ThreadFactoryTypeAware
Thread factory which creates threads supporting a naming pattern. On JDK 21+, this factory creates virtual threads
when the System property
camel.threads.virtual.enabled is set to true. On JDK 17, only platform
threads are available.-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
CamelThreadFactory
-
-
Method Details
-
isVirtual
Description copied from interface:ThreadFactoryTypeAwareIndicates whether the created threads are virtual.- Specified by:
isVirtualin interfaceThreadFactoryTypeAware- Returns:
trueif the created threads are virtual,falseif they are platform threads.
-
newThread
- Specified by:
newThreadin interfaceThreadFactory
-
getName
-
toString
-