Home / Function/ preinitialize() — spring-boot Function Reference

preinitialize() — spring-boot Function Reference

Architecture documentation for the preinitialize() function in BackgroundPreinitializingApplicationListener.java from the spring-boot codebase.

Function java GradlePlugin DslExtensions calls 1 called by 2

Entity Profile

Dependency Diagram

graph TD
  847434dc_63b9_7456_6cfd_a7056f78068f["preinitialize()"]
  b5ffbed3_3e79_b7f1_7f90_e0cdf5ec8c71["onApplicationEvent()"]
  b5ffbed3_3e79_b7f1_7f90_e0cdf5ec8c71 -->|calls| 847434dc_63b9_7456_6cfd_a7056f78068f
  26f781da_90a1_367b_ce7a_f5abf28db10f["run()"]
  26f781da_90a1_367b_ce7a_f5abf28db10f -->|calls| 847434dc_63b9_7456_6cfd_a7056f78068f
  29fa8646_4e69_445f_9824_8abcc086390c["start()"]
  847434dc_63b9_7456_6cfd_a7056f78068f -->|calls| 29fa8646_4e69_445f_9824_8abcc086390c
  style 847434dc_63b9_7456_6cfd_a7056f78068f fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

core/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/preinitialize/BackgroundPreinitializingApplicationListener.java lines 98–110

	private void preinitialize() {
		Runner runner = new Runner(this.factoriesLoader.load(BackgroundPreinitializer.class));
		try {
			Thread thread = new Thread(runner, "background-preinit");
			thread.start();
		}
		catch (Exception ex) {
			// This will fail on Google App Engine where creating threads is
			// prohibited. We can safely continue but startup will be slightly slower
			// as the initialization will now happen on the main thread.
			complete.countDown();
		}
	}

Domain

Subdomains

Calls

  • start()

Called By

  • onApplicationEvent()
  • run()

Frequently Asked Questions

What does preinitialize() do?
preinitialize() is a function in the spring-boot codebase.
What does preinitialize() call?
preinitialize() calls 1 function(s): start.
What calls preinitialize()?
preinitialize() is called by 2 function(s): onApplicationEvent, run.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free