Uploaded image for project: 'Felix'
  1. Felix
  2. FELIX-4288

Bundle not updated when unused capabilities changed (ResolverImpl.getResolvableRequirements)

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: bundlerepository-1.6.6
    • Fix Version/s: None
    • Labels:
      None

      Description

      It is common (and recommended) practice for bundles to Import the same packages they Export. This means a bundle, if it exports any packages, always depends on its own capabilities.

      The ResolverImpl.getResolvableRequirements() ignores whether the requirements are coming from the bundle that is trying to be updated. The resolver will always considered the old bundle's capabilities as "used" since the old bundle depends on itself. This prevents the resolver from performing an in-place update on the bundle even though there may be no other bundles depending on that capability.

      To reproduce, create and deploy a bundle that exports a single package (and imports that same package). Now create a newer version of the bundle that no longer exports the package. Try to update the old bundle with the new one will result in both bundles being installed (since the required capabilities don't match). This is unexpected since no other bundles on the system depend on the unused export.

      Proposed fix would skip requirements from the resource that is trying to be updated (performed in ResolverImpl.getResolvableRequirements()).

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              krieb Karl Rieb
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:

                Time Tracking

                Estimated:
                Original Estimate - 24h
                24h
                Remaining:
                Remaining Estimate - 24h
                24h
                Logged:
                Time Spent - Not Specified
                Not Specified