| Summary: | Improvement in the code for XsltAction.java approximatly 20% better throughput with this one change | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [JBoss] JBoss Enterprise SOA Platform 5 | Reporter: | Jim Tyrrell <jtyrrell> | ||||||||||
| Component: | JBossESB, Performance | Assignee: | Kevin Conner <kevin.conner> | ||||||||||
| Status: | CLOSED NEXTRELEASE | QA Contact: | |||||||||||
| Severity: | high | Docs Contact: | |||||||||||
| Priority: | high | ||||||||||||
| Version: | 5.0.0 ER5 | ||||||||||||
| Target Milestone: | --- | ||||||||||||
| Target Release: | 5.0.0 GA, 5.0.0 ER7 | ||||||||||||
| Hardware: | Unspecified | ||||||||||||
| OS: | Unspecified | ||||||||||||
| URL: | http://jira.jboss.org/jira/browse/SOA-1763 | ||||||||||||
| Whiteboard: | |||||||||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||||||||
| Doc Text: | Story Points: | --- | |||||||||||
| Clone Of: | Environment: |
Linux JDK 6 with SOA-P 5.0 Beta 1
|
|||||||||||
| Last Closed: | 2010-01-28 11:06:44 UTC | Type: | Feature Request | ||||||||||
| Regression: | --- | Mount Type: | --- | ||||||||||
| Documentation: | --- | CRM: | |||||||||||
| Verified Versions: | Category: | --- | |||||||||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||||||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||||||||
| Attachments: |
|
||||||||||||
Entire source file if you wish to compare it. Attachment: Added: TestXsltAction.java Hi Jim, It was intentional to not have the creation of the transformer in the initialize method and instead have it in the process methods because, as far as I am aware, a Transformer instance is not thread safe and depending on the setting of maxThreads setting this could lead to problems. Regards, /Daniel Daniel is spot on, Transformer is not thread safe. Okay I stand corrected, but can this be written to create a "transformer" pool so that each thread running can get their own instance. This would be a big improvement "approximately 20%" or so in my testing performance? I assume in a http_gateway multiple threads are running, is that true, how can that be confirmed? In my testing I saw no errors, so at least with my configuration is it possible this is only single threaded? Comment in either xslttransformation as needed Attachment: Added: jboss-esb.xml Transform XSLT file Attachment: Added: MyTransform.xslt Attachment: Added: PerformanceTesting-soapui-project.xml The SOAP UI attached project can drive thoughput, I usually run the 10k test called 10k Average Load and I have to set the end point with the 10k Throughput Request both under the 10k Average Payload Size Link: Added: This issue depends JBESB-3098 The fix won't work in some cases. JBR gateway is an example, since the configuration parameter has a different name: <jbr-listener name="Socket-Gateway" busidref="Socket-1" is-gateway="true"> <property name="jbr-maxThreads" value="4" /> </jbr-listener> Sorry, what does the gateway have to do with this? I found out that this is a different attribute. Thanks to Kevin. Verified in ER7. |
Date of First Response: 2010-01-03 21:40:15 project_key: SOA With this change: adding this member variable: private Transformer transformer = null; Commenting out/removing this line: // final Transformer transformer = xslTemplate.newTransformer(); and moving it to the initialize method as: //Line for point of reference in the method. xslTemplate = createTemplate(transformerConfig.getTemplateFile(), factory); //New line added in transformer = xslTemplate.newTransformer();