You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Andrei Pozolotin (JIRA)" <ji...@apache.org> on 2012/05/03 16:06:50 UTC
[jira] [Created] (FELIX-3496) URLHandlers deadlock in jnlp context
Andrei Pozolotin created FELIX-3496:
---------------------------------------
Summary: URLHandlers deadlock in jnlp context
Key: FELIX-3496
URL: https://issues.apache.org/jira/browse/FELIX-3496
Project: Felix
Issue Type: Bug
Components: Framework
Affects Versions: framework-4.0.2
Environment: oracle jre 1.6.0_31 x64 @ windows
Reporter: Andrei Pozolotin
1) we are seeing URLHandlers deadlock in jnlp context
2) this happens:
* in jnlp mode only (can not reproduce in non-jnlp)
* with frequency 1:10
* with multiple threads, both internal-felix-related and external-embedder-host-related
doing heavy downloading of url resources;
3) seeming problem area is here:
http://svn.apache.org/viewvc/felix/trunk/framework/src/main/java/org/apache/felix/framework/URLHandlers.java?view=markup
public static Object getFrameworkFromContext()
{
// This is a hack. The idea is to return the only registered framework
synchronized (m_classloaderToFrameworkLists)
{
if (m_classloaderToFrameworkLists.isEmpty())
{
synchronized (m_frameworks)
{
if ((m_counter == 1) && (m_frameworks.size() == 1))
{
return m_frameworks.get(0);
}
}
}
}
4) stack traces attached
5) the workaround is to disable URLHandlers service via
config.put("felix.service.urlhandlers", "false");
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (FELIX-3496) URLHandlers deadlock in jnlp context
Posted by "Andrei Pozolotin (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-3496?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Andrei Pozolotin updated FELIX-3496:
------------------------------------
Attachment: dead_lock_5.txt
dead_lock_4.txt
dead_lock_3.txt
dead_lock_2.txt
dead_lock_1.txt
dead_lock_0.txt
dead lock stack traces
> URLHandlers deadlock in jnlp context
> ------------------------------------
>
> Key: FELIX-3496
> URL: https://issues.apache.org/jira/browse/FELIX-3496
> Project: Felix
> Issue Type: Bug
> Components: Framework
> Affects Versions: framework-4.0.2
> Environment: oracle jre 1.6.0_31 x64 @ windows
> Reporter: Andrei Pozolotin
> Attachments: dead_lock_0.txt, dead_lock_1.txt, dead_lock_2.txt, dead_lock_3.txt, dead_lock_4.txt, dead_lock_5.txt
>
>
> 1) we are seeing URLHandlers deadlock in jnlp context
> 2) this happens:
> * in jnlp mode only (can not reproduce in non-jnlp)
> * with frequency 1:10
> * with multiple threads, both internal-felix-related and external-embedder-host-related
> doing heavy downloading of url resources;
> 3) seeming problem area is here:
> http://svn.apache.org/viewvc/felix/trunk/framework/src/main/java/org/apache/felix/framework/URLHandlers.java?view=markup
> public static Object getFrameworkFromContext()
> {
> // This is a hack. The idea is to return the only registered framework
> synchronized (m_classloaderToFrameworkLists)
> {
> if (m_classloaderToFrameworkLists.isEmpty())
> {
> synchronized (m_frameworks)
> {
> if ((m_counter == 1) && (m_frameworks.size() == 1))
> {
> return m_frameworks.get(0);
> }
> }
> }
> }
> 4) stack traces attached
> 5) the workaround is to disable URLHandlers service via
> config.put("felix.service.urlhandlers", "false");
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Assigned] (FELIX-3496) URLHandlers deadlock in jnlp context
Posted by "Karl Pauls (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-3496?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Karl Pauls reassigned FELIX-3496:
---------------------------------
Assignee: Karl Pauls
> URLHandlers deadlock in jnlp context
> ------------------------------------
>
> Key: FELIX-3496
> URL: https://issues.apache.org/jira/browse/FELIX-3496
> Project: Felix
> Issue Type: Bug
> Components: Framework
> Affects Versions: framework-4.0.2
> Environment: oracle jre 1.6.0_31 x64 @ windows
> Reporter: Andrei Pozolotin
> Assignee: Karl Pauls
> Attachments: dead_lock_0.txt, dead_lock_1.txt, dead_lock_2.txt, dead_lock_3.txt, dead_lock_4.txt, dead_lock_5.txt
>
>
> 1) we are seeing URLHandlers deadlock in jnlp context
> 2) this happens:
> * in jnlp mode only (can not reproduce in non-jnlp)
> * with frequency 1:10
> * with multiple threads, both internal-felix-related and external-embedder-host-related
> doing heavy downloading of url resources;
> 3) seeming problem area is here:
> http://svn.apache.org/viewvc/felix/trunk/framework/src/main/java/org/apache/felix/framework/URLHandlers.java?view=markup
> public static Object getFrameworkFromContext()
> {
> // This is a hack. The idea is to return the only registered framework
> synchronized (m_classloaderToFrameworkLists)
> {
> if (m_classloaderToFrameworkLists.isEmpty())
> {
> synchronized (m_frameworks)
> {
> if ((m_counter == 1) && (m_frameworks.size() == 1))
> {
> return m_frameworks.get(0);
> }
> }
> }
> }
> 4) stack traces attached
> 5) the workaround is to disable URLHandlers service via
> config.put("felix.service.urlhandlers", "false");
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (FELIX-3496) URLHandlers deadlock in jnlp
context
Posted by "Karl Pauls (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/FELIX-3496?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13267500#comment-13267500 ]
Karl Pauls commented on FELIX-3496:
-----------------------------------
I think you are running into this:
http://underlap.blogspot.de/2006/11/experimental-fix-for-sunbug-4670071.html
can you either try the workaround options given there or otherwise, try to not have the outside thread working while the framework starts up?
> URLHandlers deadlock in jnlp context
> ------------------------------------
>
> Key: FELIX-3496
> URL: https://issues.apache.org/jira/browse/FELIX-3496
> Project: Felix
> Issue Type: Bug
> Components: Framework
> Affects Versions: framework-4.0.2
> Environment: oracle jre 1.6.0_31 x64 @ windows
> Reporter: Andrei Pozolotin
> Assignee: Karl Pauls
> Attachments: dead_lock_0.txt, dead_lock_1.txt, dead_lock_2.txt, dead_lock_3.txt, dead_lock_4.txt, dead_lock_5.txt
>
>
> 1) we are seeing URLHandlers deadlock in jnlp context
> 2) this happens:
> * in jnlp mode only (can not reproduce in non-jnlp)
> * with frequency 1:10
> * with multiple threads, both internal-felix-related and external-embedder-host-related
> doing heavy downloading of url resources;
> 3) seeming problem area is here:
> http://svn.apache.org/viewvc/felix/trunk/framework/src/main/java/org/apache/felix/framework/URLHandlers.java?view=markup
> public static Object getFrameworkFromContext()
> {
> // This is a hack. The idea is to return the only registered framework
> synchronized (m_classloaderToFrameworkLists)
> {
> if (m_classloaderToFrameworkLists.isEmpty())
> {
> synchronized (m_frameworks)
> {
> if ((m_counter == 1) && (m_frameworks.size() == 1))
> {
> return m_frameworks.get(0);
> }
> }
> }
> }
> 4) stack traces attached
> 5) the workaround is to disable URLHandlers service via
> config.put("felix.service.urlhandlers", "false");
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira