You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@aries.apache.org by "Alasdair Nottingham (Created) (JIRA)" <ji...@apache.org> on 2011/10/27 14:02:32 UTC

[jira] [Created] (ARIES-768) Application manager can take 5 minutes to shutdown

Application manager can take 5 minutes to shutdown
--------------------------------------------------

                 Key: ARIES-768
                 URL: https://issues.apache.org/jira/browse/ARIES-768
             Project: Aries
          Issue Type: Bug
          Components: Application
    Affects Versions: 0.3
            Reporter: Alasdair Nottingham
            Assignee: Alasdair Nottingham


I thought I had fixed this, but it seems that the application manager can still take 5 minutes to shutdown. The stack trace is:

        at java.lang.Object.wait(Native Method)
        at org.apache.aries.blueprint.container.ReferenceRecipe.getService(ReferenceRecipe.java:172)
        at org.apache.aries.blueprint.container.ReferenceRecipe.access$000(ReferenceRecipe.java:50)
        at org.apache.aries.blueprint.container.ReferenceRecipe$ServiceDispatcher.call(ReferenceRecipe.java:227)
        at Proxy76916cc6_8687_48e9_934d_a5102df76a23.uninstallBundle(Unknown Source)
        at org.apache.aries.application.runtime.isolated.impl.ApplicationContextImpl.uninstall(ApplicationContextImpl.java:148)
        at org.apache.aries.application.runtime.isolated.impl.ApplicationContextManagerImpl.close(ApplicationContextManagerImpl.java:159)

this is waiting for a replacement for the BundleFrameworkManager which never comes. I added a bind/unbind reference listener to do this as the framework was shutting down, but it turns out that we still try to call it during close. So I've updated the close method to only uninstall if it isn't already uninstalled. This should fix the 5 minute issue.

--
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] (ARIES-768) Application manager can take 5 minutes to shutdown

Posted by "Alasdair Nottingham (Commented) (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/ARIES-768?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13138299#comment-13138299 ] 

Alasdair Nottingham commented on ARIES-768:
-------------------------------------------

I wish I could say for certain I know what the problem was, however the state we appear to be in is this:

The BundleFrameworkManager service has gone, but the unbind method hasn't closed things down (or it may have, but it hasn't removed the bundles in the ApplicationContextImpl). This could happen if an exception is thrown, but I wasn't able to prove that an exception was thrown. The close method is called. This then tries to uninstall bundles that are already in the uninstalled state. So I've added the following fixes in:

1) Don't try to uninstall and uninstalled bundle
2) If an exception occurs move onto the next bundle
3) Clear bundles from the list even if an exception occurs as we go down.
4) Syncronization between unbind and close

This appears to solve the problem I was having (at least I haven't seen it since which given it was intermittent before isn't saying much).
                
> Application manager can take 5 minutes to shutdown
> --------------------------------------------------
>
>                 Key: ARIES-768
>                 URL: https://issues.apache.org/jira/browse/ARIES-768
>             Project: Aries
>          Issue Type: Bug
>          Components: Application
>    Affects Versions: 0.3
>            Reporter: Alasdair Nottingham
>            Assignee: Alasdair Nottingham
>
> I thought I had fixed this, but it seems that the application manager can still take 5 minutes to shutdown. The stack trace is:
>         at java.lang.Object.wait(Native Method)
>         at org.apache.aries.blueprint.container.ReferenceRecipe.getService(ReferenceRecipe.java:172)
>         at org.apache.aries.blueprint.container.ReferenceRecipe.access$000(ReferenceRecipe.java:50)
>         at org.apache.aries.blueprint.container.ReferenceRecipe$ServiceDispatcher.call(ReferenceRecipe.java:227)
>         at Proxy76916cc6_8687_48e9_934d_a5102df76a23.uninstallBundle(Unknown Source)
>         at org.apache.aries.application.runtime.isolated.impl.ApplicationContextImpl.uninstall(ApplicationContextImpl.java:148)
>         at org.apache.aries.application.runtime.isolated.impl.ApplicationContextManagerImpl.close(ApplicationContextManagerImpl.java:159)
> this is waiting for a replacement for the BundleFrameworkManager which never comes. I added a bind/unbind reference listener to do this as the framework was shutting down, but it turns out that we still try to call it during close. So I've updated the close method to only uninstall if it isn't already uninstalled. This should fix the 5 minute issue.

--
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] [Resolved] (ARIES-768) Application manager can take 5 minutes to shutdown

Posted by "Alasdair Nottingham (Resolved) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ARIES-768?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alasdair Nottingham resolved ARIES-768.
---------------------------------------

    Resolution: Fixed
    
> Application manager can take 5 minutes to shutdown
> --------------------------------------------------
>
>                 Key: ARIES-768
>                 URL: https://issues.apache.org/jira/browse/ARIES-768
>             Project: Aries
>          Issue Type: Bug
>          Components: Application
>    Affects Versions: 0.3
>            Reporter: Alasdair Nottingham
>            Assignee: Alasdair Nottingham
>
> I thought I had fixed this, but it seems that the application manager can still take 5 minutes to shutdown. The stack trace is:
>         at java.lang.Object.wait(Native Method)
>         at org.apache.aries.blueprint.container.ReferenceRecipe.getService(ReferenceRecipe.java:172)
>         at org.apache.aries.blueprint.container.ReferenceRecipe.access$000(ReferenceRecipe.java:50)
>         at org.apache.aries.blueprint.container.ReferenceRecipe$ServiceDispatcher.call(ReferenceRecipe.java:227)
>         at Proxy76916cc6_8687_48e9_934d_a5102df76a23.uninstallBundle(Unknown Source)
>         at org.apache.aries.application.runtime.isolated.impl.ApplicationContextImpl.uninstall(ApplicationContextImpl.java:148)
>         at org.apache.aries.application.runtime.isolated.impl.ApplicationContextManagerImpl.close(ApplicationContextManagerImpl.java:159)
> this is waiting for a replacement for the BundleFrameworkManager which never comes. I added a bind/unbind reference listener to do this as the framework was shutting down, but it turns out that we still try to call it during close. So I've updated the close method to only uninstall if it isn't already uninstalled. This should fix the 5 minute issue.

--
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] [Resolved] (ARIES-768) Application manager can take 5 minutes to shutdown

Posted by "Alasdair Nottingham (Resolved) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ARIES-768?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alasdair Nottingham resolved ARIES-768.
---------------------------------------

    Resolution: Fixed
    
> Application manager can take 5 minutes to shutdown
> --------------------------------------------------
>
>                 Key: ARIES-768
>                 URL: https://issues.apache.org/jira/browse/ARIES-768
>             Project: Aries
>          Issue Type: Bug
>          Components: Application
>    Affects Versions: 0.3
>            Reporter: Alasdair Nottingham
>            Assignee: Alasdair Nottingham
>
> I thought I had fixed this, but it seems that the application manager can still take 5 minutes to shutdown. The stack trace is:
>         at java.lang.Object.wait(Native Method)
>         at org.apache.aries.blueprint.container.ReferenceRecipe.getService(ReferenceRecipe.java:172)
>         at org.apache.aries.blueprint.container.ReferenceRecipe.access$000(ReferenceRecipe.java:50)
>         at org.apache.aries.blueprint.container.ReferenceRecipe$ServiceDispatcher.call(ReferenceRecipe.java:227)
>         at Proxy76916cc6_8687_48e9_934d_a5102df76a23.uninstallBundle(Unknown Source)
>         at org.apache.aries.application.runtime.isolated.impl.ApplicationContextImpl.uninstall(ApplicationContextImpl.java:148)
>         at org.apache.aries.application.runtime.isolated.impl.ApplicationContextManagerImpl.close(ApplicationContextManagerImpl.java:159)
> this is waiting for a replacement for the BundleFrameworkManager which never comes. I added a bind/unbind reference listener to do this as the framework was shutting down, but it turns out that we still try to call it during close. So I've updated the close method to only uninstall if it isn't already uninstalled. This should fix the 5 minute issue.

--
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] [Reopened] (ARIES-768) Application manager can take 5 minutes to shutdown

Posted by "Alasdair Nottingham (Reopened) (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/ARIES-768?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alasdair Nottingham reopened ARIES-768:
---------------------------------------


The fix reduced, but did not remove the problem.
                
> Application manager can take 5 minutes to shutdown
> --------------------------------------------------
>
>                 Key: ARIES-768
>                 URL: https://issues.apache.org/jira/browse/ARIES-768
>             Project: Aries
>          Issue Type: Bug
>          Components: Application
>    Affects Versions: 0.3
>            Reporter: Alasdair Nottingham
>            Assignee: Alasdair Nottingham
>
> I thought I had fixed this, but it seems that the application manager can still take 5 minutes to shutdown. The stack trace is:
>         at java.lang.Object.wait(Native Method)
>         at org.apache.aries.blueprint.container.ReferenceRecipe.getService(ReferenceRecipe.java:172)
>         at org.apache.aries.blueprint.container.ReferenceRecipe.access$000(ReferenceRecipe.java:50)
>         at org.apache.aries.blueprint.container.ReferenceRecipe$ServiceDispatcher.call(ReferenceRecipe.java:227)
>         at Proxy76916cc6_8687_48e9_934d_a5102df76a23.uninstallBundle(Unknown Source)
>         at org.apache.aries.application.runtime.isolated.impl.ApplicationContextImpl.uninstall(ApplicationContextImpl.java:148)
>         at org.apache.aries.application.runtime.isolated.impl.ApplicationContextManagerImpl.close(ApplicationContextManagerImpl.java:159)
> this is waiting for a replacement for the BundleFrameworkManager which never comes. I added a bind/unbind reference listener to do this as the framework was shutting down, but it turns out that we still try to call it during close. So I've updated the close method to only uninstall if it isn't already uninstalled. This should fix the 5 minute issue.

--
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