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

findCandidates for already resolved resources is slow

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • Subsystem
    • None

    Description

      org.apache.aries.subsystem.core.internal.ResolveContext.processWire(Wire, Requirement, List<Capability>)

      The processWire method for ResolveContext is used when doing off-line resolution of a subsystem for resources that are already resolved in the host framework (or the system repository). The problem is the way the candidates are discovered with the existing wirings. The existing code will iterate over every wire looking for a capability that matches the given requirement. This is a lot of work because it requires filter matching against every capability the resolved resource is wired to.

      I see no reason the filter matching is required here. We have the resources requirement and the resources wiring wire which uses the requirement. All we need to do is find the wires that use the requirement. The capabilities attached to these wires have to match. Checking for requirement equality should be faster that checking every capability wired to for a match.

      Attachments

        Activity

          People

            Unassigned Unassigned
            tjwatson Tom Watson
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated: