Class ConfigCompatibility

java.lang.Object
io.quarkus.deployment.configuration.ConfigCompatibility

public final class ConfigCompatibility extends Object
A class which manages configuration compatibility for the build-time configuration. The mechanism is to keep a matching table of old names and new names. Old names are detected at the front end iterator and mapped to the corresponding new name(s) that replace them. New names are detected at the back end getter, which queries the corresponding old name(s) to determine the new value.

This is intended to be a temporary and evolutionary solution to be replaced by generative remapping. It is more flexible than fallback remapping, allowing 1:N and N:1 remappings and support for submaps. Unfortunately it is also very verbose.

  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static final class 
    The interceptor at the back of the chain which provides compatibility defaults for new property names.
    static final class 
    The interceptor at the front of the chain which handles hiding deprecated properties from the iterator.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final io.smallrye.config.KeyMap<BiFunction<io.smallrye.config.ConfigSourceInterceptorContext,io.smallrye.config.NameIterator,io.smallrye.config.ConfigValue>>
    When these new name patterns are detected on get, see if legacy values are present and if so, provide a default based on those value(s).
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • newNames

      public static final io.smallrye.config.KeyMap<BiFunction<io.smallrye.config.ConfigSourceInterceptorContext,io.smallrye.config.NameIterator,io.smallrye.config.ConfigValue>> newNames
      When these new name patterns are detected on get, see if legacy values are present and if so, provide a default based on those value(s).
  • Constructor Details

    • ConfigCompatibility

      public ConfigCompatibility()