Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 950402

Summary: Transform tests are failing with EAP Xalan
Product: [JBoss] JBoss Fuse Service Works 6 Reporter: Jiri Pechanec <jpechane>
Component: SwitchYardAssignee: Keith Babo <kbabo>
Status: CLOSED CURRENTRELEASE QA Contact: Jiri Pechanec <jpechane>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 6.0.0 GACC: asantos, atangrin, kconner, ncross, soa-p-jira
Target Milestone: ER1Keywords: Reopened
Target Release: 6.0.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2013-05-09 19:42:35 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:
Embargoed:
Attachments:
Description Flags
Surefire reports none

Description Jiri Pechanec 2013-04-10 08:17:37 UTC
Created attachment 733537 [details]
Surefire reports

When xalan-2.7.1-redhat-3 (from EAP 6.1) is added among dependencies then there are failing tests

Failed tests: 
  test_failonwarn_true_warn(org.switchyard.transform.internal.xslt.XsltTransformerTest)

Tests in error: 
  test_xslt_result(org.switchyard.transform.internal.xslt.XsltTransformerTest)
  test_failonwarn_false_warn(org.switchyard.transform.internal.xslt.XsltTransformerTest)

Comment 1 Keith Babo 2013-04-16 19:18:26 UTC
Can you provide some additional detail on how you handled the replacement of Xalan and why?  I'm able to deploy and test the transform-xslt quickstart on the SOA-P 6 alpha build without any problems.  This quickstart also works in our upstream master branch which now builds against EAP 6.1 Alpha.

My assessment is that this issue is not a blocker and is likely not a bug at all.  If we can reproduce this with a deployed application vs. changing Maven dependencies on the core unit test, then that would be a different story.

Comment 2 Jiri Pechanec 2013-04-23 10:59:45 UTC
Hi,

the problem is that as you will move into the productization phase (Mead build) it will be built and tested with EAP Xalan, not the project one. I do not think that productization will allow to go it through with fail tests.

Comment 3 Keith Babo 2013-04-23 11:29:39 UTC
I haven't heard anything from productization in the builds so far for Alpha.  I also ran the transform tests on the current 1.0 tip in community (post EAP 6.1 rebase) using a revised version of xalan-2.7.1-redhat-3 in parent/pom.xml and it worked.

One last comment.  Checking the module contents in EAP 6.1 Alpha I see this:
jboss-eap-6.1$ ls -1 modules/system/layers/base/org/apache/xalan/main/
module.xml
serializer-2.7.1.jbossorg-1.jar
serializer-2.7.1.jbossorg-1.jar.index
xalan-2.7.1.jbossorg-1.jar
xalan-2.7.1.jbossorg-1.jar.index

And the following in the EAP 6.1 Early Access Maven Repo:
http://maven.repository.redhat.com/earlyaccess/all/org/jboss/as/jboss-as-parent/7.2.0.Alpha1-redhat-4/jboss-as-parent-7.2.0.Alpha1-redhat-4.pom

<version.org.apache.xalan>2.7.1.jbossorg-1</version.org.apache.xalan> 

I'll need a bit more detail on how this can be reproduced and why it applies to Alpha.

Comment 4 Nick Cross 2013-04-23 13:13:56 UTC
The alpha is using community components - we are not aligning to EAP components - that will be done post alpha.

Comment 5 Nick Cross 2013-05-09 19:42:35 UTC

*** This bug has been marked as a duplicate of bug 960890 ***

Comment 6 Keith Babo 2013-07-26 18:41:42 UTC
Reopening this bug as it's still an issue in EAP 6.1 GA.  See the following comment on 960890 for details:

https://bugzilla.redhat.com/show_bug.cgi?id=960890#c2

Comment 7 kconner 2013-07-29 18:57:16 UTC
The failure is caused by two issues

- a change in transformer implementation between 2.7.1.jbossorg-1 and 2.7.1-redhat-1
  2.7.1.jbossorg-1 uses org.apache.xalan.xsltc.trax.TransformerFactoryImpl
  2.7.1-redhat-1 uses org.apache.xalan.processor.TransformerFactoryImpl
- the way in which the DOMSource is created

Currently the DOMSource is being created by passing in the root element of the document rather than the document itself.  This fails under org.apache.xalan.processor.TransformerFactoryImpl as the transformer, when querying the DOMSource, discovers that it is already at an element (orders:order) and tries to find a template matching that element.  In order to match the "/" template the DOMSource needs to contain the Document.

Comment 8 JBoss JIRA Server 2013-07-29 22:04:09 UTC
Kevin Conner <kevin.conner> made a comment on jira SWITCHYARD-1627

PR #559

Comment 9 Nick Cross 2013-08-02 09:56:20 UTC
Removed Xalan override patch from Bug 961476

Comment 10 JBoss JIRA Server 2013-08-14 21:19:01 UTC
Rob Cernich <rcernich> made a comment on jira SWITCHYARD-1627

pushed

Comment 14 Jiri Pechanec 2013-10-09 09:57:17 UTC
Verified in ER4

Comment 15 JBoss JIRA Server 2014-06-16 23:51:29 UTC
Keith Babo <kbabo> updated the status of jira SWITCHYARD-1627 to Closed