SimpleDeprecatedConfigWarner

class SimpleDeprecatedConfigWarner(environment: <Error class: unknown class>, warningConfig: DeprecatedPropertyWarningConfig)

Simple implementation for warning about deprecated configuration usage.

Provides centralized logging and tracking of deprecated configuration warnings during the migration period, including properties, profiles, and conditional annotations. Warnings are rate-limited to prevent log spam and can be aggregated for overview.

Constructors

Link copied to clipboard
constructor(environment: <Error class: unknown class>, warningConfig: DeprecatedPropertyWarningConfig)

Types

Link copied to clipboard
object Companion
Link copied to clipboard

Organized deprecation information by category.

Link copied to clipboard
data class DeprecationInfo(val type: SimpleDeprecatedConfigWarner.DeprecationType, val deprecatedItem: String, val recommendedReplacement: String, val reason: String? = null)

Data class for storing deprecation information.

Link copied to clipboard

Categories of deprecation types.

Functions

Link copied to clipboard

Clear all warning tracking (mainly for testing purposes).

Link copied to clipboard

Get categorized deprecation information for analysis or reporting.

Link copied to clipboard

Get the list of deprecated properties/profiles that have been warned about.

Link copied to clipboard

Get the count of unique deprecated warnings issued.

Link copied to clipboard

Log an aggregated summary of all deprecated configuration usage. Provides a high-level overview with migration details for better user experience.

Link copied to clipboard
fun warnDeprecatedConditional(className: String, annotationDetails: String, recommendedApproach: String)

Issue a warning for deprecated conditional annotation usage.

Link copied to clipboard
fun warnDeprecatedConfigurationProperties(className: String, annotationDetails: String, recommendedApproach: String)

Issue a warning for deprecated @ConfigurationProperties prefix usage.

Link copied to clipboard
fun warnDeprecatedProfile(deprecatedProfile: String, recommendedProperty: String, deprecationReason: String? = null)

Issue a warning for deprecated profile usage. Each unique profile is warned about only once per application lifecycle.

Link copied to clipboard
fun warnDeprecatedProperty(deprecatedProperty: String, recommendedProperty: String, deprecationReason: String? = null)

Issue a warning for deprecated property usage. Each unique property is warned about only once per application lifecycle.