Uploaded image for project: 'DeltaSpike'
  1. DeltaSpike
  2. DELTASPIKE-897

check configuration of a ClassDeactivator

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.5.0
    • Core
    • None

    Description

      currently it's needed to configure a custom ClassDeactivator via apache-deltaspike.properties, but not via META-INF/services/org.apache.deltaspike.core.spi.activation.ClassDeactivator
      this limitation was required, because it isn't possible to deactivate/overrule a ClassDeactivator configured via the std. spi-config, but via config-sources and ordinals it's possible to overrule it.

      that's basically fine, but not that intuitive esp. because it's a spi for a low-level functionality -> users expect a std. spi-config. therefore we should combine both or provide a corresponding hint/warning.

      #1
      usually there is just one configured ClassDeactivator and therefore we can support both config formats easily. once there is at least one ClassDeactivator configured in apache-deltaspike.properties, we can ignore all implementations of ClassDeactivator configured via the std. spi-config. that allows to deactivate/overrule such a configuration. currently we just support one ClassDeactivator at runtime. that's limited by the config-format itself. since a std. spi-config allows multiple config-entries, we would need to use an internal instance which aggregates instances of the configured classes.

      #2
      we just check if there is an active spi-config for 1-n implementations of ClassDeactivator and in such cases we log a warning that they are ignored and how to configure a ClassDeactivator correctly (and that only one active implementation is supported).

      Attachments

        Activity

          People

            gpetracek Gerhard Petracek
            gpetracek Gerhard Petracek
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: