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

Context-Aware Config: Provide configuration parameter metadata

    XMLWordPrintableJSON

Details

    Description

      in order to support configuration editors GUIs we need to provide metadata which configurations with parameter metadata are defined by the applications.

      this means:

      • list of all configurations registered (singleton, collections, nested) with
        • their respective configuration names
        • label (optional)
        • description (optional)
      • list of all parameters for each configuration
      • parameter metadata:
        • name
        • type (only supported: String,int,long,double,boolean and arrays of them)
        • label (optional)
        • description (optional)
        • default value
        • further custom properties that may customized the configuration editor (e.g. widget type to use, optional)

      the applications needs a possibility to provide such configuration+parameter metadata. by default the annotation interface classes are used for this. they have to be detected on the runtime in the classpath when a new bundle is deployed using an osgi extender pattern (quite similar to sling models). to the annotation classes further annotations can be applied an class and property level to provide the additional metadata (label, description etc.).

      currently we can only support automatic detection of parameter metadata for configurations which are defined and accessed with annotation classes, not when the application used direct valuemap access or the low-level ConfigurationResourceResolver.

      by making the configuration metadata provider pluggable via an SPI we can ship the default configuration providing metadata detected from the deployed annotation classes, but leave a door open to add other sources as well.

      Attachments

        Issue Links

          Activity

            People

              sseifert Stefan Seifert
              sseifert Stefan Seifert
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: