[
https://issues.apache.org/jira/browse/ISIS-1506?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Andi Huber resolved ISIS-1506.
------------------------------
Resolution: Fixed
Fixed by making ThreadPoolSupport application scoped, and (as Martin suggests)
shutting down the executor at application's end of life-cycle.
> tomcat shutdown - threads in PARK state
> ---------------------------------------
>
> Key: ISIS-1506
> URL: https://issues.apache.org/jira/browse/ISIS-1506
> Project: Isis
> Issue Type: Bug
> Components: Core
> Affects Versions: 1.13.0
> Reporter: Timothy Simecsek
> Assignee: Andi Huber
> Priority: Major
> Fix For: 2.0.0-M1
>
> Attachments: IntelliJ Debug.PNG, Java VisualVM.PNG, catalina.log
>
>
> Hi Dan,
> Today I monitored threads created within our application while running on
> tomcat 8.5.3x64 because of an issue in my code.
> While doing that I noticed that there were two threads called Thread-7 and
> Thread-8 (name was stable during a lot of starts but only on the first start)
> that I wasn't able to find in my code so I debugged a bit deeper and found
> that they were created in
> org.apache.isis.core.runtime.threadpool.ThreadPoolSupport:76 during start-up.
> After that they are going to state PARK and reside even when undeploying the
> application from tomcat.
> I haven't looked much at your code but I believe you should call shutdown on
> the ThreadPoolExecutor that you are using once you are finished or in
> PreDestroy situation. At least I had a very similar issue in my application
> and shutdown() solved it.
> Please find attached a screenshot of IntelliJ view during debug, the
> screenshot of VisualVM and the catalina log from tomcat complaining about
> these two threads.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)