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

Incorrect handling of NamespaceMapper bindings within SlingServerRepositoryManager

    XMLWordPrintableJSON

Details

    Description

      The bind method for the namespace service references within class org.apache.sling.jcr.jackrabbit.server.impl.SlingServerRepositoryManager is accessing the ComponentContext set by the activate method but unfortunately that is incorrect because the Declarative Services Specification Version 1.1 - section 112.5.6 states that the binding happens before the activation. So the attempt to bind the TestNamespaceMapper Service to the SlingServerRepositoryManager always results in a NullPointerException.

      Attachments

        1. namespacemapper_binding_fix.patch
          4 kB
          Stefan Scheidewig
        2. namespacemapper_binding_fix_with_service_pid.patch
          4 kB
          Stefan Scheidewig
        3. namespacemapper_binding_fix_for_oak.patch
          3 kB
          Stefan Scheidewig

        Activity

          People

            cziegeler Carsten Ziegeler
            thalis Stefan Scheidewig
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: