Bug 779167 (SOA-1562)

Summary: Schema validation: DocumentBuilder can be reused between messages
Product: [JBoss] JBoss Enterprise SOA Platform 5 Reporter: Jiri Pechanec <jpechane>
Component: JBossESBAssignee: Kevin Conner <kevin.conner>
Status: CLOSED NEXTRELEASE QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 5.0.0 ER1   
Target Milestone: ---   
Target Release: 5.0.2   
Hardware: Unspecified   
OS: Unspecified   
URL: http://jira.jboss.org/jira/browse/SOA-1562
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2010-05-28 12:42:12 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description Jiri Pechanec 2009-10-27 12:28:21 UTC
Date of First Response: 2009-12-07 14:54:02
project_key: SOA

New DocumentBuilder is created for each incoming message. This is unnecessary and can cause minor performance penalty.

Comment 3 nwallace 2010-01-08 18:54:43 UTC
Moved this up to 5.0.1 as there's a discussion on https://jira.jboss.org/jira/browse/SOA-1763 that probably affects this.

Comment 4 David Le Sage 2010-02-10 04:17:35 UTC
I have documented this for the Release Notes.  The current draft text states:



https://jira.jboss.org/jira/browse/SOA-1562

    Currently, a new DocumentBuilder is created for each incoming message. This has a minor
    impact upon system performance.


Comment 5 Kevin Conner 2010-04-26 09:09:55 UTC
Link: Added: This issue depends JBESB-3290


Comment 6 Tom Fennelly 2010-04-26 11:54:37 UTC
I assume this is talking about the SchemaValidationAction class.

I replaced the DOM parsing with simply wrapping the message payload string in a StreamSource and passing it to the validator (i.e. no DOM parser).  Modified one of the tests and it's x2 faster for 5000 iterations. 

Comment 7 Kevin Conner 2010-04-26 13:40:25 UTC
Updated in ESB codebase, will be in next merge.

Comment 8 Jiri Pechanec 2010-05-28 12:42:12 UTC
Verified in CR1 sources

Comment 9 David Le Sage 2010-06-01 03:06:59 UTC
Release note draft states:


https://jira.jboss.org/browse/JBESB-3290

    A new DocumentBuilder was being created for each incoming message. This had a minor
    impact upon system performance. This has been resolved by eliminating the need for DOM
    parsing by simply wrapping the message payload string in a StreamSource and passing that to
    the validator instead. As a result, performance is now much faster.