Bug 1154936 - [GSS] (6.4.0) Add optional fastinfoset dependency in org.apache.cxf
Summary: [GSS] (6.4.0) Add optional fastinfoset dependency in org.apache.cxf
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: Web Services
Version: 6.3.0
Hardware: Unspecified
OS: All
medium
medium
Target Milestone: DR9
: EAP 6.4.0
Assignee: Kyle Lape
QA Contact: Rostislav Svoboda
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-10-21 04:54 UTC by vgohel
Modified: 2019-08-19 12:46 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
Type: Task
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker JBWS-3560 0 Major Closed Unlock FastInfoset feature in CXF on top of JBossAS 2016-09-17 19:28:33 UTC

Description vgohel 2014-10-21 04:54:34 UTC
Created attachment 948793 [details]
Reproducer that shows missing optional FastInfoSet dependency

Description of problem:

Annotating the SEI with @org.apache.cxf.annotations.FastInfoset and having dependencies of org.apache.cxf and org.apache.cxf.impl in the MANIFEST.MF get the annotation to be resolved. This works fine, application get deployed.

But when i executing the client, you get java.lang.NoClassDefFoundError: com/sun/xml/fastinfoset/stax/StAXDocumentSerializer.

This class is not present in the JBossWS-CXF modules that we ship with EAP 6.x. However, this is present in the Apache CXF version of cxf-api.jar.

Looking at the cxf-api-2.7.7.redhat-1.jar pom file, the FastInFoset dependency is optional,

 <dependency>
        <groupId>com.sun.xml.fastinfoset</groupId>
        <artifactId>FastInfoset</artifactId>
        <optional>true</optional>
      </dependency>

If we are going to use this feature, then for this dependency, since this is 'optional', we need to create a custom module, of 'com.sun.xml.fastinfoset' and the jar FastInfoset-1.2.13.jar from Apache CXF and add, <module name="com.sun.xml.fastinfoset" optional="true"> in our org.apache.cxf module's module.xml

Version-Release number of selected component (if applicable):

JBoss EAP 6.3.0, JBossWS-CXF 4.3.0.Final

How reproducible:

Attached is a test case for this, deployment works fine, but executing the client you get, java.lang.NoClassDefFoundError: com/sun/xml/fastinfoset/stax/StAXDocumentSerializer

Steps to Reproduce:
1. Extract the attachement and set the JBOSS_HOME and JAVA_HOME. eg. export JBOSS_HOME=<path to JBOSS_HOME>, export JAVA_HOME=<path to Java Home>
2.  Then, start EAP and execute, 'ant deploy' for deploying the application.
3. To run the client, 'ant test'.

Actual results:

You get a java.lang.NoClassDefFoundError: com/sun/xml/fastinfoset/stax/StAXDocumentSerializer

Expected results:


Additional info:

Comment 7 Rostislav Svoboda 2014-11-06 11:20:37 UTC
<rsvoboda> asoldano, "Assuming we don't want to productize the fastinfoset lib, I'm fine with this change. Thanks Kyle."
<rsvoboda> asoldano, that means custumer will ad his own module ?
<asoldano> rsvoboda, yes
<asoldano> rsvoboda, I think that's fine
<asoldano> rsvoboda, we don't ship FastInfoset
<asoldano> rsvoboda, but still let users add it
<rsvoboda> asoldano, if fastinfoset module is not delivered in official build I won't test it in standard testing cycles, I will just verify that BZ - one time action
<asoldano> rsvoboda, OK

qa_ack for one time action to check this BZ

Comment 9 Rostislav Svoboda 2014-11-14 07:45:58 UTC
Verified on EAP 6.4.0 DR9


Note You need to log in before you can comment on or make changes to this bug.