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

Bundles without feature-origin result in empty bundle to feature mapping

    XMLWordPrintableJSON

Details

    Description

      When installing a feature archive of a feature similar to the following

      {
        "id":"com.exmaple:my-feature-pkg:slingosgifeature:tiera:12345-SNAPSHOT",
        "bundles":[
          {
            "id":"com.example:my-bundle:1.2.3-SNAPSHOT",
            "start-order":"20"
          }
        ],
        "api-regions:JSON|false":[
          {
            "name":"global",
            "exports":[
              "com.example.my"
            ]
          }
        ]
      } 

      A bundle to feature mapping like

      com.example:my-bundle:1.2.3-SNAPSHOT=
      

      will be created in the feature's org.apache.sling.feature.apiregions.factory configuration. This is because the bundle does not specify any feature-origin(s).

      For those cases the feature it self should be the origin of the bundle. The current version of the api regions runtime will otherwise not find the feature a bundle belongs to and so may not be able to resolve the api regions the bundle belongs to.

      An example where that can happen is the usage of the slingfeature-maven-plugin without using the aggregation feature. When just building far from a hand-crafted feature model the feature-origin may not be set on the api-region(s).

      Attachments

        Issue Links

          Activity

            People

              cziegeler Carsten Ziegeler
              diru Dirk Rudolph
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: