Browse Source

Add Bootstrapper initialize method to fix typo

See gh-25400
pull/25523/head
cprayer 5 years ago committed by Andy Wilkinson
parent
commit
bee6f41393
  1. 11
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/Bootstrapper.java
  2. 2
      spring-boot-project/spring-boot/src/main/java/org/springframework/boot/SpringApplication.java

11
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/Bootstrapper.java

@ -31,6 +31,17 @@ public interface Bootstrapper { @@ -31,6 +31,17 @@ public interface Bootstrapper {
* Initialize the given {@link BootstrapRegistry} with any required registrations.
* @param registry the registry to initialize
*/
default void initialize(BootstrapRegistry registry) {
intitialize(registry);
}
/**
* Initialize the given {@link BootstrapRegistry} with any required registrations.
* @param registry the registry to initialize
* @deprecated since 2.4.4 in favor of
* {@link Bootstrapper#initialize(BootstrapRegistry)}
*/
@Deprecated
void intitialize(BootstrapRegistry registry);
}

2
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/SpringApplication.java

@ -349,7 +349,7 @@ public class SpringApplication { @@ -349,7 +349,7 @@ public class SpringApplication {
private DefaultBootstrapContext createBootstrapContext() {
DefaultBootstrapContext bootstrapContext = new DefaultBootstrapContext();
this.bootstrappers.forEach((initializer) -> initializer.intitialize(bootstrapContext));
this.bootstrappers.forEach((initializer) -> initializer.initialize(bootstrapContext));
return bootstrapContext;
}

Loading…
Cancel
Save