Uploaded image for project: 'Aries'
  1. Aries
  2. ARIES-1338

Bundle manifest parser does not allow multiple packages on Import-Package clause

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • subsystem-2.0.6, subsystem-2.0.8
    • subsystem-2.0.10
    • Subsystem
    • None

    Description

      Parsing a bundle manifest fails on Import-Package if a clause contains more than one target (package) for example, this syntax fails:

      Import-package: org.apache.p1; org.apache.p2; vendor="Apache"

      When the bundle with above manifest appears as content in an esa, an exception is thrown:

      java.lang.IllegalArgumentException: Only one package name per requirement allowed
      at org.apache.aries.subsystem.core.archive.ImportPackageRequirement.<init>(ImportPackageRequirement.java:39)
      at org.apache.aries.subsystem.core.archive.ImportPackageHeader$Clause.toRequirement(ImportPackageHeader.java:159)
      at org.apache.aries.subsystem.core.archive.ImportPackageHeader.toRequirements(ImportPackageHeader.java:218)
      at org.apache.aries.subsystem.core.internal.BundleResource.computeOsgiWiringPackageRequirements(BundleResource.java:182)

      Attachments

        Issue Links

          Activity

            People

              jwross@us.ibm.com John Ross
              sbratton Sam Bratton
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: