Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.4.0
    • Component/s: None
    • Labels:
      None
    • Patch Info:
      Patch Available

      Description

      The main pom.xml defines a dependency on stax:stax-api:jar:1.0.1 which:
      1. is old (Mar 2006)
      2. defines a javax.xml.XMLConstants class that does not define XMLConstants.NULL_NS_URI and causes compile errors in some ides.
      3. mvn dependency:tree in servicemix-core shows dependencies on two different version of stax-api (edited for brevity):

      INFO] org.apache.servicemix:servicemix-audit:jar:3.4.0-fuse-SNAPSHOT
      [INFO] +- org.apache.servicemix:servicemix-core:jar:3.4.0-fuse-SNAPSHOT:compile
      [INFO] |  +- org.apache.geronimo.modules:geronimo-transaction:jar:2.1.4:compile
      [INFO] |  |  +- org.apache.geronimo.framework:geronimo-core:jar:2.1.4:compile
      [INFO] |  |  |  +- org.apache.geronimo.framework:geronimo-system:jar:2.1.4:compile
      [INFO] |  |  |  |  |  \- javax.xml.stream:stax-api:jar:1.0-2:compile
      [...]
      [INFO] |  +- stax:stax-api:jar:1.0.1:compile
      

      I believe the correct version we should use is javax.xml.stream:stax-api:jar:1.0-2 (the groupId has changed as well). I tested the attached patch and everything sees in order. I hope I didn't miss anything.

        Activity

        Hide
        hadrian Hadrian Zbarcea added a comment - - edited

        Removed patch as not complete. There are other indirect dependencies on stax-api 1.0.1. I'll try to provide a better one shortly.

        Actually woodstox has a dependency on stax-api 1.0.1 I am not sure how to get rid of.

        Show
        hadrian Hadrian Zbarcea added a comment - - edited Removed patch as not complete. There are other indirect dependencies on stax-api 1.0.1. I'll try to provide a better one shortly. Actually woodstox has a dependency on stax-api 1.0.1 I am not sure how to get rid of.
        Hide
        hadrian Hadrian Zbarcea added a comment -

        I should probably reattach the patch, I think it was good and all the other fixes should go outside smx. I raised an issue with woodstox for now: http://jira.codehaus.org/browse/WSTX-235.

        Show
        hadrian Hadrian Zbarcea added a comment - I should probably reattach the patch, I think it was good and all the other fixes should go outside smx. I raised an issue with woodstox for now: http://jira.codehaus.org/browse/WSTX-235 .
        Hide
        cowtowncoder Tatu Saloranta added a comment -

        Hmmh. Codehaus Jira is now down, so I can't add comments to Woodstox issue.

        But this all is very confusing. Firstly, it is 1.0-2, not 1.0.2; meaning that strictly speaking it is not a newer version (as in they probably come from different source tree – 1.0.1 came from stax.codehaus.org, stuff BEA wrote).
        Also, I don't know if it actually contains the fix to NPE that 1.0.0 had (I hope, but it all depends on where exactly sources came from). The whole STAX API is such a cluster.

        At any rate, ideally there would just be a range, but since I don't have a good way to verify that what I use works, I probably don't want to do that.

        In the meantime, maybe ActiveMQ could just override stax api version Woodstox claims?
        Stax API is included in JDK 1.6, so in most cases it should not even be deployed at all, but Maven does not have a way indicate "provided by JDK X.X" option. Woodstox itself should work on any 1.0.x version.

        Show
        cowtowncoder Tatu Saloranta added a comment - Hmmh. Codehaus Jira is now down, so I can't add comments to Woodstox issue. But this all is very confusing. Firstly, it is 1.0-2, not 1.0.2; meaning that strictly speaking it is not a newer version (as in they probably come from different source tree – 1.0.1 came from stax.codehaus.org, stuff BEA wrote). Also, I don't know if it actually contains the fix to NPE that 1.0.0 had (I hope, but it all depends on where exactly sources came from). The whole STAX API is such a cluster. At any rate, ideally there would just be a range, but since I don't have a good way to verify that what I use works, I probably don't want to do that. In the meantime, maybe ActiveMQ could just override stax api version Woodstox claims? Stax API is included in JDK 1.6, so in most cases it should not even be deployed at all, but Maven does not have a way indicate "provided by JDK X.X" option. Woodstox itself should work on any 1.0.x version.
        Hide
        cowtowncoder Tatu Saloranta added a comment -

        Ok: I changed dependency, and pushed a snapshot of 4.0.8, to be found at http://snapshots.repository.codehaus.org/org/codehaus/woodstox/

        I would appreciate help in verifying that it works – right now I don't have a project with woodstox 4.0 dependency.

        Show
        cowtowncoder Tatu Saloranta added a comment - Ok: I changed dependency, and pushed a snapshot of 4.0.8, to be found at http://snapshots.repository.codehaus.org/org/codehaus/woodstox/ I would appreciate help in verifying that it works – right now I don't have a project with woodstox 4.0 dependency.
        Hide
        hadrian Hadrian Zbarcea added a comment -

        Awesome, thanks! I will test today and post the result.

        Show
        hadrian Hadrian Zbarcea added a comment - Awesome, thanks! I will test today and post the result.
        Hide
        jb@nanthrax.net Jean-Baptiste Onofré added a comment -

        Chris, do you manage the patch review or do you want that I take it ?

        Show
        jb@nanthrax.net Jean-Baptiste Onofré added a comment - Chris, do you manage the patch review or do you want that I take it ?
        Hide
        jb@nanthrax.net Jean-Baptiste Onofré added a comment -

        I'm gonna re-assign this bug to me and review the path (and ad some test cases).

        Show
        jb@nanthrax.net Jean-Baptiste Onofré added a comment - I'm gonna re-assign this bug to me and review the path (and ad some test cases).
        Hide
        jb@nanthrax.net Jean-Baptiste Onofré added a comment -

        Woodstox 4.0.8 has been released, I'm going to upgrade ServiceMix projects to use it and check the stax-api dependencies.

        Show
        jb@nanthrax.net Jean-Baptiste Onofré added a comment - Woodstox 4.0.8 has been released, I'm going to upgrade ServiceMix projects to use it and check the stax-api dependencies.
        Hide
        jb@nanthrax.net Jean-Baptiste Onofré added a comment -

        ServiceMix 3 upgraded to use woodstox 4.0.8 and stax-api 1.0-2.
        Revision 960386.

        I'm checking other ServiceMix sub-projects.

        Show
        jb@nanthrax.net Jean-Baptiste Onofré added a comment - ServiceMix 3 upgraded to use woodstox 4.0.8 and stax-api 1.0-2. Revision 960386. I'm checking other ServiceMix sub-projects.
        Hide
        jb@nanthrax.net Jean-Baptiste Onofré added a comment -

        NMR updated: revision 960469.

        Show
        jb@nanthrax.net Jean-Baptiste Onofré added a comment - NMR updated: revision 960469.
        Show
        ffang Freeman Fang added a comment - update groupId in components http://svn.apache.org/viewvc?rev=960775&view=rev http://svn.apache.org/viewvc?rev=960774&view=rev http://svn.apache.org/viewvc?rev=960776&view=rev http://svn.apache.org/viewvc?rev=960777&view=rev http://svn.apache.org/viewvc?rev=960778&view=rev
        Hide
        jb@nanthrax.net Jean-Baptiste Onofré added a comment -

        All ServiceMix project now use woodstox 4.0.8 and stax-api 1.0-2.

        Show
        jb@nanthrax.net Jean-Baptiste Onofré added a comment - All ServiceMix project now use woodstox 4.0.8 and stax-api 1.0-2.

          People

          • Assignee:
            jb@nanthrax.net Jean-Baptiste Onofré
            Reporter:
            hadrian Hadrian Zbarcea
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development