Please do not reply directly to this email. All additional comments should be made in the comments box of this bug.
Summary: Missing service provider configuration files in the woodstox jar files
https://bugzilla.redhat.com/show_bug.cgi?id=796739
Summary: Missing service provider configuration files in the woodstox jar files Product: Fedora Version: rawhide Platform: Unspecified OS/Version: Linux Status: NEW Severity: medium Priority: unspecified Component: woodstox-core AssignedTo: jcapik@redhat.com ReportedBy: juan.hernandez@redhat.com QAContact: extras-qa@fedoraproject.org CC: java-sig-commits@lists.fedoraproject.org, jcapik@redhat.com Classification: Fedora Story Points: --- Type: --- Regression: --- Mount Type: --- Documentation: ---
Description of problem:
The jar files provided in the woodstox-jar package don't contain the service provider configuration files needed to use the
Version-Release number of selected component (if applicable):
woodstox-core-4.1.2-2.fc17.x86_64
How reproducible:
Always.
Steps to Reproduce:
1. Write and compile the following java program:
import javax.xml.stream.XMLInputFactory;
public class Test { public static void main(String[] args) throws Exception { System.out.println(XMLInputFactory.newInstance()); } }
2. Run it with the version of the "woodstox-core-asj.jar" provided by the RPM:
$ java -cp $(build-classpath woodstox-core stax2-api):. Test
Actual results:
com.sun.xml.internal.stream.XMLInputFactoryImpl@605df3c5
It is using the internal implementation provided by the JDK.
Expected results:
com.ctc.wstx.stax.WstxInputFactory@a5ae1e7
It should use the implementation provided by the woodstox-core package.
Additional info:
I believe that the problem is that the service provider configuration files that are available in the source of the package in the "src/resources" directory are not copied to the "META-INF/services" directory of the generated jar files.
This can be fixed with the following patch for the spec:
--- a/woodstox-core.spec +++ b/woodstox-core.spec @@ -64,7 +64,6 @@ sed -i "s/@REQ_STAX2_VERSION@/%{stax2_ver}/g" pom.xml pom-lgpl.xml # removing bundled stuff rm -rf lib rm -rf src/maven -rm -rf src/resources rm -rf src/samples rm -rf src/java/org rm -rf src/test/org @@ -76,6 +75,11 @@ mv -f src/java src/main/ mkdir src/test/java mv -f src/test/wstxtest src/test/java/
+# Make sure that the service provider configuration files end up +# in the META-INF/services directory of the resulting jar files: +mkdir -p src/main/resources/META-INF/services +cp src/resources/* src/main/resources/META-INF/services/. + %build # stax2 missing -> cannot compile tests -> tests skipped mvn-rpmbuild -Dmaven.test.skip=true \
https://bugzilla.redhat.com/show_bug.cgi?id=796739
--- Comment #2 from Fedora End Of Life endoflife@fedoraproject.org --- This message is a notice that Fedora 19 is now at end of life. Fedora has stopped maintaining and issuing updates for Fedora 19. It is Fedora's policy to close all bug reports from releases that are no longer maintained. Approximately 4 (four) weeks from now this bug will be closed as EOL if it remains open with a Fedora 'version' of '19'.
Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version.
Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 19 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above.
Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
https://bugzilla.redhat.com/show_bug.cgi?id=796739
Juan Hernández juan.hernandez@redhat.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |CLOSED Resolution|--- |WONTFIX Last Closed| |2015-01-19 04:59:40
java-sig-commits@lists.stg.fedoraproject.org