[jboss-jira] [JBoss JIRA] Updated: (BPEL-309) Performance improvement: use a HashMap in SetNamespaceContext instead of iterating through all namespaces

Aleksander Adamowski (JIRA) jira-events at lists.jboss.org
Fri Oct 9 11:12:06 EDT 2009


     [ https://jira.jboss.org/jira/browse/BPEL-309?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Aleksander Adamowski updated BPEL-309:
--------------------------------------

    Attachment: jbpm-bpel-SetNamespaceContext-HashMap.patch


The patch.

> Performance improvement: use a HashMap in SetNamespaceContext instead of iterating through all namespaces
> ---------------------------------------------------------------------------------------------------------
>
>                 Key: BPEL-309
>                 URL: https://jira.jboss.org/jira/browse/BPEL-309
>             Project: jBPM BPEL
>          Issue Type: Patch
>      Security Level: Public(Everyone can see) 
>          Components: Engine
>    Affects Versions: jBPM BPEL 1.1.1
>            Reporter: Aleksander Adamowski
>            Assignee: Alejandro Guizar
>         Attachments: jbpm-bpel-SetNamespaceContext-HashMap.patch
>
>
> During profiling of an application based on jBPM-BPEL, we've discovered that the dominating method which has the largest inherent CPU time is org.jbpm.bpel.sublang.xpath.SetNamespaceContext.translateNamespacePrefixToUri, being invoked over 70000 times for a single business process execution, and consuming unreasonably large amounts of CPU time do this amount of invocations when compared to other methods.
> After closer inspection, it turned out that the method simply iterates over the set of all known namespaces when looking for an URI.
> This seriously impacts jBPM-BPEL performance.
> Adding a simple HashMap allows performing the lookup much faster and eliminates the biggest CPU hog in jBPM-BPEL for us.
> Attaching the trivial patch.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jboss-jira mailing list