Uploaded image for project: 'Sling'
  1. Sling
  2. SLING-1520

Don't include revision number in package imports

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • Parent 8
    • Parent 9
    • General
    • None

    Description

      some time ago we introduced a version policy configuration for the
      maven-bundle-plugin in our parent pom:
      <_versionpolicy>$${version;===;${@}}</_versionpolicy>

      Basically this includes the patch part of a version number in an import
      package statement. This was necessary as we were not doing proper
      version management with our own modules and a version 2.0.4 might have
      introduced new API compared to version 2.0.2 - therefore an import to
      just 2.0 would not work for modules requiring 2.0.4

      We now fixed the version handling in many modules - not all yet, but we
      are on our way and I think by the time of our new Sling maintenance
      release (Sling 6) we have fixed nearly all of them.

      I think this is one reason for removing the policy before we do a new
      parent release. The other one is that this policy is for all package
      imports and this includes package imports from 3rd party bundles and
      also from the osgi core/compendium. I just ran into a problem where my
      bundle had an import on a 1.3.x version of the service tracker whereas
      the runtime environment only exported 1.3.(x-1) - my bundle would have
      run in that environment without any problems but it never came to this
      situation as it couldn't get resolved.

      Attachments

        Activity

          People

            cziegeler Carsten Ziegeler
            cziegeler Carsten Ziegeler
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: