You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Toni Menzel (JIRA)" <ji...@apache.org> on 2007/07/20 23:32:06 UTC
[jira] Created: (FELIX-329) Calling Felix.stopAndWait() from
Runtime.shutdownHook() freezed thread
Calling Felix.stopAndWait() from Runtime.shutdownHook() freezed thread
----------------------------------------------------------------------
Key: FELIX-329
URL: https://issues.apache.org/jira/browse/FELIX-329
Project: Felix
Issue Type: Bug
Components: Framework
Environment: tested on trunk (r555374)
Reporter: Toni Menzel
Fix For: 1.0.0
if a shutdownHook invokes Felix.stopAndWait() the monitor never gets notified and stays "wait()" forever.
Until now i haven't found a direct way to fix this behaviour "normally" but if we could use the timeout version wait(int) instead of "wait()" this behaviour is not tied to the monitor.notifyAll() functionality. (so perhaps its the better solution anyway and not just a workaround?)
Toni
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (FELIX-329) Calling Felix.stopAndWait() from
Runtime.shutdownHook() freezes thread
Posted by "Toni Menzel (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-329?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Toni Menzel updated FELIX-329:
------------------------------
Summary: Calling Felix.stopAndWait() from Runtime.shutdownHook() freezes thread (was: Calling Felix.stopAndWait() from Runtime.shutdownHook() freezed thread)
> Calling Felix.stopAndWait() from Runtime.shutdownHook() freezes thread
> ----------------------------------------------------------------------
>
> Key: FELIX-329
> URL: https://issues.apache.org/jira/browse/FELIX-329
> Project: Felix
> Issue Type: Bug
> Components: Framework
> Environment: tested on trunk (r555374)
> Reporter: Toni Menzel
> Fix For: 1.0.0
>
>
> if a shutdownHook invokes Felix.stopAndWait() the monitor never gets notified and stays "wait()" forever.
> Until now i haven't found a direct way to fix this behaviour "normally" but if we could use the timeout version wait(int) instead of "wait()" this behaviour is not tied to the monitor.notifyAll() functionality. (so perhaps its the better solution anyway and not just a workaround?)
> Toni
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (FELIX-329) Calling Felix.stopAndWait() from
Runtime.shutdownHook() freezes thread
Posted by "Toni Menzel (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-329?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Toni Menzel closed FELIX-329.
-----------------------------
i just tested the fix and it works fine now! thanks!
Toni
> Calling Felix.stopAndWait() from Runtime.shutdownHook() freezes thread
> ----------------------------------------------------------------------
>
> Key: FELIX-329
> URL: https://issues.apache.org/jira/browse/FELIX-329
> Project: Felix
> Issue Type: Bug
> Components: Framework
> Environment: tested on trunk (r555374)
> Reporter: Toni Menzel
> Assignee: Richard S. Hall
> Fix For: 1.0.0
>
>
> if a shutdownHook invokes Felix.stopAndWait() the monitor never gets notified and stays "wait()" forever.
> Until now i haven't found a direct way to fix this behaviour "normally" but if we could use the timeout version wait(int) instead of "wait()" this behaviour is not tied to the monitor.notifyAll() functionality. (so perhaps its the better solution anyway and not just a workaround?)
> Toni
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (FELIX-329) Calling Felix.stopAndWait() from
Runtime.shutdownHook() freezes thread
Posted by "Richard S. Hall (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-329?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Richard S. Hall resolved FELIX-329.
-----------------------------------
Resolution: Fixed
Assignee: Richard S. Hall
A bug slipped into the framework shutdown process during the refactoring of the code. A "synchronized (this)" was put into an inner class, but not converted to "synchronized (Felix.this)" which was causing threads calling Felix.stopAndWait() to not get notified that the framework had shutdown.
I have committed a fix, please try again and see if it works. If so, please close this issue.
> Calling Felix.stopAndWait() from Runtime.shutdownHook() freezes thread
> ----------------------------------------------------------------------
>
> Key: FELIX-329
> URL: https://issues.apache.org/jira/browse/FELIX-329
> Project: Felix
> Issue Type: Bug
> Components: Framework
> Environment: tested on trunk (r555374)
> Reporter: Toni Menzel
> Assignee: Richard S. Hall
> Fix For: 1.0.0
>
>
> if a shutdownHook invokes Felix.stopAndWait() the monitor never gets notified and stays "wait()" forever.
> Until now i haven't found a direct way to fix this behaviour "normally" but if we could use the timeout version wait(int) instead of "wait()" this behaviour is not tied to the monitor.notifyAll() functionality. (so perhaps its the better solution anyway and not just a workaround?)
> Toni
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.