James Netherton created CAMEL-23479:
---------------------------------------
Summary: camel-main: camel.main.virtualThreadsEnabled does not work
Key: CAMEL-23479
URL: https://issues.apache.org/jira/browse/CAMEL-23479
Project: Camel
Issue Type: Bug
Components: camel-main
Affects Versions: 4.20.0
Reporter: James Netherton
Relates to changes added for CAMEL-20199.
There are races between setting the required system property in BaseMainSupport
here:
[https://github.com/apache/camel/blob/05d593bc0dfe33a91d6b02285d58b09b3a717de1/core/camel-main/src/main/java/org/apache/camel/main/BaseMainSupport.java#L592-L600]
And retrieving it in ThreadType.current() here:
[https://github.com/apache/camel/blob/05d593bc0dfe33a91d6b02285d58b09b3a717de1/core/camel-util/src/main/java/org/apache/camel/util/concurrent/ThreadType.java#L44]
In theory, anything could (and does) invoke ThreadType.current() before
BaseMainSupport.autoconfigure(). Thus setting the ThreadType to the wrong
default.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)