Interface EnvironmentPostProcessor

Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface @Deprecated(since="4.0.0", forRemoval=true) public interface EnvironmentPostProcessor
Deprecated, for removal: This API element is subject to removal in a future version.
since 4.0.0 for removal in 4.2.0 in favor of EnvironmentPostProcessor
Allows for customization of the application's Environment prior to the application context being refreshed.

EnvironmentPostProcessor implementations have to be registered in META-INF/spring.factories, using the fully qualified name of this class as the key. Implementations may implement the Ordered interface or use an @Order annotation if they wish to be invoked in specific order.

Since Spring Boot 2.4, EnvironmentPostProcessor implementations may optionally take the following constructor parameters:

Since:
1.3.0
Author:
Andy Wilkinson, Stephane Nicoll
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Deprecated, for removal: This API element is subject to removal in a future version.
    Post-process the given environment.
  • Method Details

    • postProcessEnvironment

      void postProcessEnvironment(ConfigurableEnvironment environment, SpringApplication application)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Post-process the given environment.
      Parameters:
      environment - the environment to post-process
      application - the application to which the environment belongs