Annotation Interface DeprecatedConfigurationProperty


@Target(METHOD) @Retention(RUNTIME) @Documented public @interface DeprecatedConfigurationProperty
Indicates that a getter in a @ConfigurationProperties object is deprecated. This annotation has no bearing on the actual binding processes, but it is used by the spring-boot-configuration-processor to add deprecation meta-data.

This annotation must be used on the getter of the deprecated element.

Since:
1.3.0
Author:
Phillip Webb, Scott Frederick
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    The reason for the deprecation.
    The field that should be used instead (if any).
    The version in which the property became deprecated.
  • Element Details

    • reason

      String reason
      The reason for the deprecation.
      Returns:
      the deprecation reason
      Default:
      ""
    • replacement

      String replacement
      The field that should be used instead (if any).
      Returns:
      the replacement field
      Default:
      ""
    • since

      String since
      The version in which the property became deprecated.
      Returns:
      the version
      Default:
      ""