You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@servicemix.apache.org by "Daniel Kulp (JIRA)" <ji...@apache.org> on 2010/02/03 23:44:34 UTC

[jira] Created: (SMXCOMP-706) Poor interceptor chain management and memory leak in CxfBc

Poor interceptor chain management and memory leak in CxfBc
----------------------------------------------------------

                 Key: SMXCOMP-706
                 URL: https://issues.apache.org/activemq/browse/SMXCOMP-706
             Project: ServiceMix Components
          Issue Type: Bug
          Components: servicemix-cxf-bc
            Reporter: Daniel Kulp



CxfBcProvider and CxfBcProviderMessageObserver use a PhaseChainCache object to create the PhaseInterceptorChain.  However, it doesn't actually use it as a cache so that is useless.   The cache object creates a chain, then clones it and holds onto the original.   Thus, double the memory is used at the start plus the processing time of the clone.

Also, the BcProvider calls getOutInterceptors().addAll(getBus().getOutInterceptors()); for EVERY request causing the getOutInterceptors list to grow causing a memory leak.

I'll attach a patch that fixes them both.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (SMXCOMP-706) Poor interceptor chain management and memory leak in CxfBc

Posted by "Freeman Fang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/SMXCOMP-706?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Freeman Fang reassigned SMXCOMP-706:
------------------------------------

    Assignee: Freeman Fang

> Poor interceptor chain management and memory leak in CxfBc
> ----------------------------------------------------------
>
>                 Key: SMXCOMP-706
>                 URL: https://issues.apache.org/activemq/browse/SMXCOMP-706
>             Project: ServiceMix Components
>          Issue Type: Bug
>          Components: servicemix-cxf-bc
>            Reporter: Daniel Kulp
>            Assignee: Freeman Fang
>         Attachments: cxf-bc-bug.txt
>
>
> CxfBcProvider and CxfBcProviderMessageObserver use a PhaseChainCache object to create the PhaseInterceptorChain.  However, it doesn't actually use it as a cache so that is useless.   The cache object creates a chain, then clones it and holds onto the original.   Thus, double the memory is used at the start plus the processing time of the clone.
> Also, the BcProvider calls getOutInterceptors().addAll(getBus().getOutInterceptors()); for EVERY request causing the getOutInterceptors list to grow causing a memory leak.
> I'll attach a patch that fixes them both.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Work started: (SMXCOMP-706) Poor interceptor chain management and memory leak in CxfBc

Posted by "Freeman Fang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/SMXCOMP-706?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Work on SMXCOMP-706 started by Freeman Fang.

> Poor interceptor chain management and memory leak in CxfBc
> ----------------------------------------------------------
>
>                 Key: SMXCOMP-706
>                 URL: https://issues.apache.org/activemq/browse/SMXCOMP-706
>             Project: ServiceMix Components
>          Issue Type: Bug
>          Components: servicemix-cxf-bc
>            Reporter: Daniel Kulp
>            Assignee: Freeman Fang
>         Attachments: cxf-bc-bug.txt
>
>
> CxfBcProvider and CxfBcProviderMessageObserver use a PhaseChainCache object to create the PhaseInterceptorChain.  However, it doesn't actually use it as a cache so that is useless.   The cache object creates a chain, then clones it and holds onto the original.   Thus, double the memory is used at the start plus the processing time of the clone.
> Also, the BcProvider calls getOutInterceptors().addAll(getBus().getOutInterceptors()); for EVERY request causing the getOutInterceptors list to grow causing a memory leak.
> I'll attach a patch that fixes them both.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SMXCOMP-706) Poor interceptor chain management and memory leak in CxfBc

Posted by "Freeman Fang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/SMXCOMP-706?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Freeman Fang updated SMXCOMP-706:
---------------------------------

      Description: 
CxfBcProvider and CxfBcProviderMessageObserver use a PhaseChainCache object to create the PhaseInterceptorChain.  However, it doesn't actually use it as a cache so that is useless.   The cache object creates a chain, then clones it and holds onto the original.   Thus, double the memory is used at the start plus the processing time of the clone.

Also, the BcProvider calls getOutInterceptors().addAll(getBus().getOutInterceptors()); for EVERY request causing the getOutInterceptors list to grow causing a memory leak.

I'll attach a patch that fixes them both.

  was:

CxfBcProvider and CxfBcProviderMessageObserver use a PhaseChainCache object to create the PhaseInterceptorChain.  However, it doesn't actually use it as a cache so that is useless.   The cache object creates a chain, then clones it and holds onto the original.   Thus, double the memory is used at the start plus the processing time of the clone.

Also, the BcProvider calls getOutInterceptors().addAll(getBus().getOutInterceptors()); for EVERY request causing the getOutInterceptors list to grow causing a memory leak.

I'll attach a patch that fixes them both.

    Fix Version/s: servicemix-cxf-bc-2010.01

> Poor interceptor chain management and memory leak in CxfBc
> ----------------------------------------------------------
>
>                 Key: SMXCOMP-706
>                 URL: https://issues.apache.org/activemq/browse/SMXCOMP-706
>             Project: ServiceMix Components
>          Issue Type: Bug
>          Components: servicemix-cxf-bc
>            Reporter: Daniel Kulp
>            Assignee: Freeman Fang
>             Fix For: servicemix-cxf-bc-2010.01
>
>         Attachments: cxf-bc-bug.txt
>
>
> CxfBcProvider and CxfBcProviderMessageObserver use a PhaseChainCache object to create the PhaseInterceptorChain.  However, it doesn't actually use it as a cache so that is useless.   The cache object creates a chain, then clones it and holds onto the original.   Thus, double the memory is used at the start plus the processing time of the clone.
> Also, the BcProvider calls getOutInterceptors().addAll(getBus().getOutInterceptors()); for EVERY request causing the getOutInterceptors list to grow causing a memory leak.
> I'll attach a patch that fixes them both.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (SMXCOMP-706) Poor interceptor chain management and memory leak in CxfBc

Posted by "Freeman Fang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/SMXCOMP-706?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Freeman Fang resolved SMXCOMP-706.
----------------------------------

    Resolution: Fixed

Apply patch on behalf of Dan with thanks
http://svn.apache.org/viewvc?rev=906350&view=rev

> Poor interceptor chain management and memory leak in CxfBc
> ----------------------------------------------------------
>
>                 Key: SMXCOMP-706
>                 URL: https://issues.apache.org/activemq/browse/SMXCOMP-706
>             Project: ServiceMix Components
>          Issue Type: Bug
>          Components: servicemix-cxf-bc
>            Reporter: Daniel Kulp
>            Assignee: Freeman Fang
>         Attachments: cxf-bc-bug.txt
>
>
> CxfBcProvider and CxfBcProviderMessageObserver use a PhaseChainCache object to create the PhaseInterceptorChain.  However, it doesn't actually use it as a cache so that is useless.   The cache object creates a chain, then clones it and holds onto the original.   Thus, double the memory is used at the start plus the processing time of the clone.
> Also, the BcProvider calls getOutInterceptors().addAll(getBus().getOutInterceptors()); for EVERY request causing the getOutInterceptors list to grow causing a memory leak.
> I'll attach a patch that fixes them both.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (SMXCOMP-706) Poor interceptor chain management and memory leak in CxfBc

Posted by "Daniel Kulp (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/activemq/browse/SMXCOMP-706?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Daniel Kulp updated SMXCOMP-706:
--------------------------------

    Attachment: cxf-bc-bug.txt

> Poor interceptor chain management and memory leak in CxfBc
> ----------------------------------------------------------
>
>                 Key: SMXCOMP-706
>                 URL: https://issues.apache.org/activemq/browse/SMXCOMP-706
>             Project: ServiceMix Components
>          Issue Type: Bug
>          Components: servicemix-cxf-bc
>            Reporter: Daniel Kulp
>         Attachments: cxf-bc-bug.txt
>
>
> CxfBcProvider and CxfBcProviderMessageObserver use a PhaseChainCache object to create the PhaseInterceptorChain.  However, it doesn't actually use it as a cache so that is useless.   The cache object creates a chain, then clones it and holds onto the original.   Thus, double the memory is used at the start plus the processing time of the clone.
> Also, the BcProvider calls getOutInterceptors().addAll(getBus().getOutInterceptors()); for EVERY request causing the getOutInterceptors list to grow causing a memory leak.
> I'll attach a patch that fixes them both.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.