You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Peng Zhang (JIRA)" <ji...@apache.org> on 2012/11/26 03:42:58 UTC

[jira] [Created] (CXF-4650) Pool JAXB Unmarshallers/Marshallers for better performance

Peng Zhang created CXF-4650:
-------------------------------

             Summary: Pool JAXB Unmarshallers/Marshallers for better performance
                 Key: CXF-4650
                 URL: https://issues.apache.org/jira/browse/CXF-4650
             Project: CXF
          Issue Type: Improvement
          Components: JAXB Databinding
            Reporter: Peng Zhang
            Priority: Minor
             Fix For: 2.6.4


To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
>From our performance test, it can improve throughput by around 10 percent.

http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CXF-4650) Pool JAXB Unmarshallers/Marshallers for better performance

Posted by "Peng Zhang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-4650?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Peng Zhang updated CXF-4650:
----------------------------

    Attachment: CXF-4650.patch

Add unmarshaller/marshaller pool
                
> Pool JAXB Unmarshallers/Marshallers for better performance
> ----------------------------------------------------------
>
>                 Key: CXF-4650
>                 URL: https://issues.apache.org/jira/browse/CXF-4650
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAXB Databinding
>            Reporter: Peng Zhang
>            Priority: Minor
>             Fix For: 2.6.4
>
>         Attachments: CXF-4650.patch
>
>
> To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
> From our performance test, it can improve throughput by around 10 percent.
> Please check the attached patch.
> http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CXF-4650) Pool JAXB Unmarshallers/Marshallers for better performance

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

Daniel Kulp updated CXF-4650:
-----------------------------

    Attachment: patch-4650.txt
    
> Pool JAXB Unmarshallers/Marshallers for better performance
> ----------------------------------------------------------
>
>                 Key: CXF-4650
>                 URL: https://issues.apache.org/jira/browse/CXF-4650
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAXB Databinding
>            Reporter: Peng Zhang
>            Assignee: Daniel Kulp
>            Priority: Minor
>             Fix For: 2.6.4
>
>         Attachments: CXF-4650.patch, patch-4650.txt
>
>
> To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
> From our performance test, it can improve throughput by around 10 percent.
> Please check the attached patch for 2.6.x branch. Thanks.
> http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CXF-4650) Pool JAXB Unmarshallers/Marshallers for better performance

Posted by "Peng Zhang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-4650?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Peng Zhang updated CXF-4650:
----------------------------

    Description: 
To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
>From our performance test, it can improve throughput by around 10 percent.
Please check the attached patch.

http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java


  was:
To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
>From our performance test, it can improve throughput by around 10 percent.

http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java


    
> Pool JAXB Unmarshallers/Marshallers for better performance
> ----------------------------------------------------------
>
>                 Key: CXF-4650
>                 URL: https://issues.apache.org/jira/browse/CXF-4650
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAXB Databinding
>            Reporter: Peng Zhang
>            Priority: Minor
>             Fix For: 2.6.4
>
>
> To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
> From our performance test, it can improve throughput by around 10 percent.
> Please check the attached patch.
> http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CXF-4650) Pool JAXB Unmarshallers/Marshallers for better performance

Posted by "Peng Zhang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-4650?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Peng Zhang updated CXF-4650:
----------------------------

    Description: 
To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
>From our performance test, it can improve throughput by around 10 percent.
Please check the attached patch. Thanks.

http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java


  was:
To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
>From our performance test, it can improve throughput by around 10 percent.
Please check the attached patch.

http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java


    
> Pool JAXB Unmarshallers/Marshallers for better performance
> ----------------------------------------------------------
>
>                 Key: CXF-4650
>                 URL: https://issues.apache.org/jira/browse/CXF-4650
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAXB Databinding
>            Reporter: Peng Zhang
>            Priority: Minor
>             Fix For: 2.6.4
>
>         Attachments: CXF-4650.patch
>
>
> To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
> From our performance test, it can improve throughput by around 10 percent.
> Please check the attached patch. Thanks.
> http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CXF-4650) Pool JAXB Unmarshallers/Marshallers for better performance

Posted by "Peng Zhang (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/CXF-4650?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Peng Zhang updated CXF-4650:
----------------------------

    Description: 
To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
>From our performance test, it can improve throughput by around 10 percent.
Please check the attached patch for 2.6.x branch. Thanks.

http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java


  was:
To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
>From our performance test, it can improve throughput by around 10 percent.
Please check the attached patch. Thanks.

http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java


    
> Pool JAXB Unmarshallers/Marshallers for better performance
> ----------------------------------------------------------
>
>                 Key: CXF-4650
>                 URL: https://issues.apache.org/jira/browse/CXF-4650
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAXB Databinding
>            Reporter: Peng Zhang
>            Priority: Minor
>             Fix For: 2.6.4
>
>         Attachments: CXF-4650.patch
>
>
> To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
> From our performance test, it can improve throughput by around 10 percent.
> Please check the attached patch for 2.6.x branch. Thanks.
> http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Updated] (CXF-4650) Pool JAXB Unmarshallers/Marshallers for better performance

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

Daniel Kulp updated CXF-4650:
-----------------------------

    Fix Version/s:     (was: 2.6.4)
                   NeedMoreInfo
    
> Pool JAXB Unmarshallers/Marshallers for better performance
> ----------------------------------------------------------
>
>                 Key: CXF-4650
>                 URL: https://issues.apache.org/jira/browse/CXF-4650
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAXB Databinding
>            Reporter: Peng Zhang
>            Assignee: Daniel Kulp
>            Priority: Minor
>             Fix For: NeedMoreInfo
>
>         Attachments: CXF-4650.patch, patch-4650.txt
>
>
> To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
> From our performance test, it can improve throughput by around 10 percent.
> Please check the attached patch for 2.6.x branch. Thanks.
> http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Assigned] (CXF-4650) Pool JAXB Unmarshallers/Marshallers for better performance

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

Daniel Kulp reassigned CXF-4650:
--------------------------------

    Assignee: Daniel Kulp
    
> Pool JAXB Unmarshallers/Marshallers for better performance
> ----------------------------------------------------------
>
>                 Key: CXF-4650
>                 URL: https://issues.apache.org/jira/browse/CXF-4650
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAXB Databinding
>            Reporter: Peng Zhang
>            Assignee: Daniel Kulp
>            Priority: Minor
>             Fix For: 2.6.4
>
>         Attachments: CXF-4650.patch, patch-4650.txt
>
>
> To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
> From our performance test, it can improve throughput by around 10 percent.
> Please check the attached patch for 2.6.x branch. Thanks.
> http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] [Commented] (CXF-4650) Pool JAXB Unmarshallers/Marshallers for better performance

Posted by "Daniel Kulp (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-4650?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13503900#comment-13503900 ] 

Daniel Kulp commented on CXF-4650:
----------------------------------

First off, the patch is not usable.  The API module cannot reference the JAXBDataBinding object.    I've gone ahead and moved the pools directly into the JAXBDataBinding object and updated the code to use that.  I've attached a new patch that shows that for you to look at.

HOWEVER, I'm not seeing ANY performance increase at all with it. In fact, I'm seeing a very slight performance decrease.   On my machine, the benchmark/performance/soap_http_doc_lit (in the cxf trunk) drops from ~4840 tps to about 4725 tps.  

In previous testing that I've done, the only time pooling them has yielded any benefit is when you are passing an InputStream or Source into the unmarshaller.   There are some major locks and other things in the unmarshaller around setting up the parsers for those cases which does improve by pooling them.  However, CXF doesn't use those methods.  It uses the method that takes the XmlStreamReader which does not have to setup the parsers.   Thus, there is no benefit to the pooling (and the overhead of maintaining the pool becomes a detriment).

In addition, the patch also does some things with like: unmarshaller.setEventHandler(null);    With the RI JAXB, there is a big difference in behavior if you call unmarshaller.setEventHandler(null);  or not call it at all.   We certainly would not be able to call it in many cases.   We'd like need separate pools for the unmarshallers that have had an event handler set compared to those that have not (and won't).



                
> Pool JAXB Unmarshallers/Marshallers for better performance
> ----------------------------------------------------------
>
>                 Key: CXF-4650
>                 URL: https://issues.apache.org/jira/browse/CXF-4650
>             Project: CXF
>          Issue Type: Improvement
>          Components: JAXB Databinding
>            Reporter: Peng Zhang
>            Assignee: Daniel Kulp
>            Priority: Minor
>             Fix For: NeedMoreInfo
>
>         Attachments: CXF-4650.patch, patch-4650.txt
>
>
> To help improve performance, refer to code from Axis2 to pool unmarshallers/marshallers.
> From our performance test, it can improve throughput by around 10 percent.
> Please check the attached patch for 2.6.x branch. Thanks.
> http://svn.apache.org/viewvc/axis/axis2/java/core/trunk/modules/jaxws/src/org/apache/axis2/jaxws/message/databinding/JAXBUtils.java

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira