[
https://issues.apache.org/jira/browse/SLING-10831?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17876613#comment-17876613
]
Joerg Hoh edited comment on SLING-10831 at 8/26/24 7:49 AM:
------------------------------------------------------------
Checked with [~rombert] offline and according to him the starter is already
fixed, and this ticket is rather about finding a better solution. So scheduling
for 3.3.2.
was (Author: joerghoh):
Checked with [~rombert] offline and according to him the starter is already
fixed, and this ticket is rather about finding a better solution. So
unscheduling.
> o.a.s.commons.thread fails setting up ThreadLocal cleaner on Java 17
> --------------------------------------------------------------------
>
> Key: SLING-10831
> URL: https://issues.apache.org/jira/browse/SLING-10831
> Project: Sling
> Issue Type: Bug
> Components: Commons
> Reporter: Robert Munteanu
> Priority: Major
> Fix For: Commons Threads 3.3.2
>
>
> When running the Sling Starter with Java 17, the following messages come up:
> {noformat}21.09.2021 11:13:54.247 *WARN* [sling-default-1]
> org.apache.sling.commons.threads.impl.ThreadPoolExecutorCleaningThreadLocals
> Could not set up thread local cleaner (most probably not a compliant JRE): {}
> java.lang.ExceptionInInitializerError: null
> at
> org.apache.sling.commons.threads.impl.ThreadPoolExecutorCleaningThreadLocals.beforeExecute(ThreadPoolExecutorCleaningThreadLocals.java:58)
> [org.apache.sling.commons.threads:3.2.20]
> at
> java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134)
> at
> java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
> at java.base/java.lang.Thread.run(Thread.java:833)
> Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make
> field java.lang.ThreadLocal$ThreadLocalMap java.lang.Thread.threadLocals
> accessible: module java.base does not "opens java.lang" to unnamed module
> @6e04bc96
> at
> java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:354)
> at
> java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
> at
> java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:178)
> at java.base/java.lang.reflect.Field.setAccessible(Field.java:172)
> at
> org.apache.sling.commons.threads.impl.ThreadLocalCleaner.field(ThreadLocalCleaner.java:77)
> [org.apache.sling.commons.threads:3.2.20]
> at
> org.apache.sling.commons.threads.impl.ThreadLocalCleaner.<clinit>(ThreadLocalCleaner.java:54)
> [org.apache.sling.commons.threads:3.2.20]
> ... 4 common frames omitted
> 21.09.2021 11:13:54.248 *ERROR* [sling-default-1]
> org.apache.sling.extensions.threaddump.internal.Activator Uncaught exception
> in Thread Thread[sling-default-1,5,main]
> java.lang.ExceptionInInitializerError: null
> at
> org.apache.sling.commons.threads.impl.ThreadPoolExecutorCleaningThreadLocals.beforeExecute(ThreadPoolExecutorCleaningThreadLocals.java:58)
> [org.apache.sling.commons.threads:3.2.20]
> at
> java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1134)
> at
> java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
> at java.base/java.lang.Thread.run(Thread.java:833)
> Caused by: java.lang.reflect.InaccessibleObjectException: Unable to make
> field java.lang.ThreadLocal$ThreadLocalMap java.lang.Thread.threadLocals
> accessible: module java.base does not "opens java.lang" to unnamed module
> @6e04bc96
> at
> java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:354)
> at
> java.base/java.lang.reflect.AccessibleObject.checkCanSetAccessible(AccessibleObject.java:297)
> at
> java.base/java.lang.reflect.Field.checkCanSetAccessible(Field.java:178)
> at java.base/java.lang.reflect.Field.setAccessible(Field.java:172)
> at
> org.apache.sling.commons.threads.impl.ThreadLocalCleaner.field(ThreadLocalCleaner.java:77)
> [org.apache.sling.commons.threads:3.2.20]
> at
> org.apache.sling.commons.threads.impl.ThreadLocalCleaner.<clinit>(ThreadLocalCleaner.java:54)
> [org.apache.sling.commons.threads:3.2.20]
> ... 4 common frames omitted
> {noformat}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)