### GET /admin/ready Source: https://docs.spring.io/spring-boot/3.4/api/java/index-files/index-9.html Checks if the application has fully started and is ready to accept requests. ```APIDOC ## GET /admin/ready ### Description Specify if the application has fully started and is now ready. ### Method GET ### Endpoint /admin/ready ### Response #### Success Response (200) - **ready** (boolean) - Indicates if the application is ready. ``` -------------------------------- ### Start Mojo Source: https://docs.spring.io/spring-boot/3.4/maven-plugin/api/java/index.html Starts a Spring application. ```APIDOC ## POST /api/start ### Description Starts a Spring application. ### Method POST ### Endpoint /api/start ``` -------------------------------- ### start() Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/web/embedded/netty/NettyWebServer.html Starts the web server. Calling this method on an already started server has no effect. ```APIDOC ## start() ### Description Starts the web server. Calling this method on an already started server has no effect. ### Method `void` ### Throws * `WebServerException` - if the server cannot be started ``` -------------------------------- ### start Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/context/metrics/buffering/BufferingApplicationStartup.html Starts a new startup step with the given name. ```APIDOC ## start(String name) ### Description Starts a new startup step with the given name. ### Specified by: - `start` in interface `ApplicationStartup` ### Parameters #### Path Parameters - **name** (String) - Required - the name of the startup step. ``` -------------------------------- ### Retrieve Startup Steps Snapshot (GET) Source: https://docs.spring.io/spring-boot/3.4/api/rest/actuator/startup.html Make a GET request to /actuator/startup to retrieve the steps recorded so far during application startup. ```bash $ curl 'http://localhost:8080/actuator/startup' -i -X GET Copied! ``` -------------------------------- ### Native Image Application Startup Output Source: https://docs.spring.io/spring-boot/3.4/how-to/native-image/developing-your-first-application.html Example output when a Spring Boot native image application starts. Note the significantly faster startup time compared to a JVM-based application. ```text . ____ _ __ _ _ /\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \ ( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \ \/ ___)| |_)| | | | | || (_| | ) ) ) ) ' |____| .__|_| |_|_| |_\[__] | / / / / =========|_|==============|___/=/_/_/_/ :: Spring Boot :: (v{version-spring-boot}) ....... ....... ....... ........ Started MyApplication in 0.08 seconds (process running for 0.095) ``` -------------------------------- ### Start init.d Service Source: https://docs.spring.io/spring-boot/3.4/how-to/deployment/installing.html Command to start an init.d service on Debian-based systems. ```bash $ service myapp start ``` -------------------------------- ### Functional WebMvc Endpoint Example Source: https://docs.spring.io/spring-boot/3.4/reference/web/servlet.html Configuration for functional endpoints using WebMvc.fn, separating routing from request handling. This example defines routes for getting a user, getting a user's customers, and deleting a user. ```APIDOC ## GET /{user} ### Description Retrieves a specific user. ### Method GET ### Endpoint /{user} ### Parameters #### Path Parameters - **user** (string) - Required - Identifier for the user. ### Response #### Success Response (200) - **ServerResponse** (ServerResponse) - The response containing user information. ## GET /{user}/customers ### Description Retrieves customers associated with a specific user. ### Method GET ### Endpoint /{user}/customers ### Parameters #### Path Parameters - **user** (string) - Required - Identifier for the user. ### Response #### Success Response (200) - **ServerResponse** (ServerResponse) - The response containing customer information. ## DELETE /{user} ### Description Deletes a specific user. ### Method DELETE ### Endpoint /{user} ### Parameters #### Path Parameters - **user** (string) - Required - Identifier for the user. ### Response #### Success Response (200) - (void) - Indicates successful deletion. ``` -------------------------------- ### Setup for JSON Testing Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/test/json/JacksonTester.html Example setup method for JSON tests using JacksonTester. It initializes an ObjectMapper and then uses JacksonTester.initFields to set up the tester. ```java private JacksonTester json; @Before public void setup() { ObjectMapper objectMapper = new ObjectMapper(); JacksonTester.initFields(this, objectMapper); } ``` -------------------------------- ### WebServer.start() Source: https://docs.spring.io/spring-boot/3.4/api/java/index-files/index-19.html Starts the web server instance. ```APIDOC ## POST /web/server/start ### Description Starts the web server. ### Method POST ### Endpoint /web/server/start ``` -------------------------------- ### TestcontainersStartup.start() Method Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/testcontainers/lifecycle/TestcontainersStartup.html Documentation for the static `start` method, which initiates the startup of a given `Startable`. ```APIDOC ## Method Details ### start public static void start(org.testcontainers.lifecycle.Startable startable) Start the given `Startable` unless is's detected as already running. Parameters: `startable` - the startable to start Since: 3.4.1 ``` -------------------------------- ### Get Help for a Specific Command Source: https://docs.spring.io/spring-boot/3.4/cli/using-the-cli.html Type `spring help ` to get detailed usage information for a specific command, including its options and examples. ```bash $ spring help init spring init - Initialize a new project using Spring Initializr (start.spring.io) usage: spring init [options] [location] Option Description ------ ----------- -a, --artifact-id Project coordinates; infer archive name (for example 'test') -b, --boot-version Spring Boot version (for example '1.2.0.RELEASE') --build Build system to use (for example 'maven' or 'gradle') (default: maven) -d, --dependencies Comma-separated list of dependency identifiers to include in the generated project --description Project description -f, --force Force overwrite of existing files --format Format of the generated content (for example 'build' for a build file, 'project' for a project archive) (default: project) -g, --group-id Project coordinates (for example 'org.test') -j, --java-version Language level (for example '1.8') -l, --language Programming language (for example 'java') --list List the capabilities of the service. Use it to discover the dependencies and the types that are available -n, --name Project name; infer application name -p, --packaging Project packaging (for example 'jar') --package-name Package name -t, --type Project type. Not normally needed if you use -- build and/or --format. Check the capabilities of the service (--list) for more details --target URL of the service to use (default: https://start. spring.io) -v, --version Project version (for example '0.0.1-SNAPSHOT') -x, --extract Extract the project archive. Inferred if a location is specified without an extension examples: To list all the capabilities of the service: $ spring init --list To creates a default project: $ spring init To create a web my-app.zip: $ spring init -d=web my-app.zip To create a web/data-jpa gradle project unpacked: $ spring init -d=web,jpa --build=gradle my-dir ``` -------------------------------- ### BufferingApplicationStartup Constructor Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/context/metrics/buffering/BufferingApplicationStartup.html Creates a new buffered ApplicationStartup with a limited capacity and starts the recording of steps. ```APIDOC ## BufferingApplicationStartup(int capacity) ### Description Creates a new buffered `ApplicationStartup` with a limited capacity and starts the recording of steps. ### Parameters #### Path Parameters - **capacity** (int) - Required - the configured capacity; once reached, new steps are not recorded. ``` -------------------------------- ### Initialize with Command Line Arguments Source: https://docs.spring.io/spring-boot/3.4/reference/features/spring-application.html Example of initializing application logic based on command line arguments, including a debug flag. ```kotlin init { val debug = args.containsOption("debug") val files = args.nonOptionArgs if (debug) { println(files) } // if run with "--debug logfile.txt" prints ["logfile.txt"] } } ``` -------------------------------- ### Get Startup Failure Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/test/context/assertj/ApplicationContextAssert.html Obtains assertions on the failure that prevented the application context from starting. Use this to inspect the cause of the startup failure. ```java assertThat(context).getFailure().containsMessage("missing bean"); ``` -------------------------------- ### void onStartup(ServletContext servletContext) Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/web/servlet/ServletContextInitializer.html Configures the provided ServletContext with necessary servlets, filters, listeners, context-params, and attributes. ```APIDOC ## void onStartup(ServletContext servletContext) ### Description Configures the given ServletContext with any servlets, filters, listeners, context-params, and attributes necessary for initialization. ### Parameters #### Path Parameters - **servletContext** (ServletContext) - Required - The ServletContext to initialize ### Response #### Success Response (200) - **void** - Returns nothing upon successful configuration. ### Errors - **ServletException** - Thrown if any call against the given ServletContext fails. ``` -------------------------------- ### Retrieve Liquibase Changes Source: https://docs.spring.io/spring-boot/3.4/api/rest/actuator/liquibase.html Make a GET request to the /actuator/liquibase endpoint to retrieve information about Liquibase change sets. This example uses curl. ```bash $ curl 'http://localhost:8080/actuator/liquibase' -i -X GET ``` -------------------------------- ### Retrieve Conditions Report using curl Source: https://docs.spring.io/spring-boot/3.4/api/rest/actuator/conditions.html Make a GET request to the /actuator/conditions endpoint to retrieve the report. This example uses curl to demonstrate the request. ```bash $ curl 'http://localhost:8080/actuator/conditions' -i -X GET ``` -------------------------------- ### Asserting Captured Output with AssertJ Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/test/system/CapturedOutput.html Use AssertJ to apply assertions on captured output. This example checks if all captured output contains the string 'started'. ```java assertThat(output).contains("started"); // Checks all output ``` -------------------------------- ### initialize with all parameters Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/devtools/restart/Restarter.html Initialize restart support with all available parameters. ```APIDOC ## initialize ### Description Initialize restart support. See `initialize(String[], boolean, RestartInitializer, boolean)` for details. ### Parameters * **args** (String[]) - main application arguments * **forceReferenceCleanup** (boolean) - if forcing of soft/weak reference should happen on * **initializer** (RestartInitializer) - the restart initializer ### Method public static void initialize(String[] args, boolean forceReferenceCleanup, RestartInitializer initializer) ### See Also * `initialize(String[], boolean, RestartInitializer)` ``` -------------------------------- ### Drain Startup Steps (POST) Source: https://docs.spring.io/spring-boot/3.4/api/rest/actuator/startup.html Make a POST request to /actuator/startup to drain and return the steps recorded so far during application startup. ```bash $ curl 'http://localhost:8080/actuator/startup' -i -X POST Copied! ``` -------------------------------- ### RSocket GraphQL Client Setup (Kotlin) Source: https://docs.spring.io/spring-boot/3.4/reference/web/spring-graphql.html Example of configuring an RSocket GraphQL client in Kotlin. It shows injecting the builder and preparing for client construction. ```kotlin @Component class RSocketGraphQlClientExample(private val builder: RSocketGraphQlClient.Builder<*>) { ``` -------------------------------- ### Retrieve Log File using curl Source: https://docs.spring.io/spring-boot/3.4/api/rest/actuator/logfile.html Make a GET request to the /actuator/logfile endpoint to retrieve the application's log file. This example uses curl. ```bash $ curl 'http://localhost:8080/actuator/logfile' -i -X GET Copied! ``` -------------------------------- ### build (with args) Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/builder/SpringApplicationBuilder.html Returns a fully configured SpringApplication ready to run, with parent applications started with the given arguments. ```APIDOC ### build public SpringApplication build(String... args) Returns a fully configured `SpringApplication` that is ready to run. Any parent that has been configured will be run with the given `args`. Parameters: `args` - the parent's args Returns: the fully configured `SpringApplication`. ``` -------------------------------- ### run Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/builder/SpringApplicationBuilder.html Creates an application context with the provided command line arguments. ```APIDOC ### run public ConfigurableApplicationContext run(String... args) Create an application context (and its parent if specified) with the command line args provided. The parent is run first with the same arguments if it has not yet been started. Parameters: `args` - the command line arguments Returns: an application context created from the current state ``` -------------------------------- ### Global CORS Configuration (Java) Source: https://docs.spring.io/spring-boot/3.4/reference/web/servlet.html Configure global CORS mappings by defining a WebMvcConfigurer bean and overriding the addCorsMappings method. This example maps all requests starting with /api/**. ```java import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.web.servlet.config.annotation.CorsRegistry; import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; @Configuration(proxyBeanMethods = false) public class MyCorsConfiguration { @Bean public WebMvcConfigurer corsConfigurer() { return new WebMvcConfigurer() { @Override public void addCorsMappings(CorsRegistry registry) { registry.addMapping("/api/**"); } }; } } ``` -------------------------------- ### Retrieve Application Startup Steps Snapshot Source: https://docs.spring.io/spring-boot/3.4/api/rest/actuator/startup.html Fetches the recorded startup steps as a snapshot without clearing the buffer. ```APIDOC ## GET /actuator/startup ### Description Retrieves a snapshot of the steps recorded so far during the application startup phase. ### Method GET ### Endpoint /actuator/startup ### Response #### Success Response (200) - **springBootVersion** (string) - The Spring Boot version. - **timeline** (object) - Contains startup events. - **startTime** (string) - The timestamp when the timeline started. - **events** (array) - A list of startup events. - **endTime** (string) - The timestamp when the event ended. - **duration** (string) - The duration of the event in ISO 8601 format. - **startTime** (string) - The timestamp when the event started. - **startupStep** (object) - Details about the startup step. - **name** (string) - The name of the startup step. - **id** (integer) - The unique identifier for the startup step. - **tags** (array) - Optional tags associated with the startup step. - **key** (string) - The key of the tag. - **value** (string) - The value of the tag. - **parentId** (integer) - The ID of the parent startup step, if any. ### Request Example ```bash $ curl 'http://localhost:8080/actuator/startup' -i -X GET ``` ### Response Example ```json { "springBootVersion" : "3.4.13", "timeline" : { "startTime" : "2025-12-18T07:13:26.071231143Z", "events" : [ { "endTime" : "2025-12-18T07:13:26.657897941Z", "duration" : "PT0.000006613S", "startTime" : "2025-12-18T07:13:26.657891328Z", "startupStep" : { "name" : "spring.beans.instantiate", "id" : 3, "tags" : [ { "key" : "beanName", "value" : "homeController" } ], "parentId" : 2 } }, { "endTime" : "2025-12-18T07:13:26.657904212Z", "duration" : "PT0.000022071S", "startTime" : "2025-12-18T07:13:26.657882141Z", "startupStep" : { "name" : "spring.boot.application.starting", "id" : 2, "tags" : [ { "key" : "mainApplicationClass", "value" : "com.example.startup.StartupApplication" } ] } } ] } } ``` ``` -------------------------------- ### RSocket GraphQL Client Setup (Java) Source: https://docs.spring.io/spring-boot/3.4/reference/web/spring-graphql.html Example of configuring an RSocket GraphQL client in Java. It demonstrates building a client that connects to a specific TCP address and route. ```java @Component public class RSocketGraphQlClientExample { private final RSocketGraphQlClient graphQlClient; public RSocketGraphQlClientExample(RSocketGraphQlClient.Builder builder) { this.graphQlClient = builder.tcp("example.spring.io", 8181).route("graphql").build(); } } ``` -------------------------------- ### DockerComposeProperties.Start Configuration Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/docker/compose/lifecycle/DockerComposeProperties.Start.html Provides methods to get and set various properties for Docker Compose start operations, including the command, log level, skip mode, and additional arguments. ```APIDOC ## Class DockerComposeProperties.Start ### Description Start properties for Docker Compose. ### Methods #### `getCommand()` - **Returns**: `StartCommand` - The Docker Compose start command. #### `setCommand(StartCommand command)` - **Parameters**: - `command` (StartCommand) - The Docker Compose start command to set. #### `getLogLevel()` - **Returns**: `LogLevel` - The log level for the Docker Compose operation. #### `setLogLevel(LogLevel logLevel)` - **Parameters**: - `logLevel` (LogLevel) - The log level to set. #### `getSkip()` - **Returns**: `DockerComposeProperties.Start.Skip` - The skip mode for the Docker Compose start. #### `setSkip(DockerComposeProperties.Start.Skip skip)` - **Parameters**: - `skip` (DockerComposeProperties.Start.Skip) - The skip mode to set. #### `getArguments()` - **Returns**: `List` - A list of additional arguments for the Docker Compose start command. ``` -------------------------------- ### Classpath Index Example Source: https://docs.spring.io/spring-boot/3.4/specification/executable-jar/nested-jars.html The classpath index file lists jar names in the order they should be added to the classpath. Each line must start with '- ' and names must be in double quotes. ```text - "BOOT-INF/lib/dependency2.jar" - "BOOT-INF/lib/dependency1.jar" ``` -------------------------------- ### Enable FlightRecorderApplicationStartup for Profiling Source: https://docs.spring.io/spring-boot/3.4/reference/features/spring-application.html Use FlightRecorderApplicationStartup to integrate Spring-specific startup events with Java Flight Recorder sessions for detailed profiling. ```bash $ java -XX:StartFlightRecording=filename=recording.jfr,duration=10s -jar demo.jar ``` -------------------------------- ### Kotlin Pulsar Reader Configuration Source: https://docs.spring.io/spring-boot/3.4/reference/messaging/pulsar.html Configure a Kotlin component to consume messages from a Pulsar topic using the `@PulsarReader` annotation. This example starts reading from the earliest available message. ```kotlin import org.springframework.pulsar.annotation.PulsarReader import org.springframework.stereotype.Component @Component class MyBean { @PulsarReader(topics = ["someTopic"], startMessageId = "earliest") fun processMessage(content: String?) { // ... } } ``` -------------------------------- ### initialize Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/logging/AbstractLoggingSystem.html Fully initializes the logging system with the provided context, configuration location, and log file. ```APIDOC ## initialize ### Description Fully initializes the logging system. ### Signature public void initialize(LoggingInitializationContext initializationContext, String configLocation, LogFile logFile) ### Parameters * `initializationContext` (LoggingInitializationContext) - The logging initialization context. * `configLocation` (String) - A log configuration location or `null` if default initialization is required. * `logFile` (LogFile) - The log output file that should be written or `null` for console only output. ### Overrides `LoggingSystem.initialize` ``` -------------------------------- ### Java Pulsar Reader Configuration Source: https://docs.spring.io/spring-boot/3.4/reference/messaging/pulsar.html Configure a Java component to consume messages from a Pulsar topic using the `@PulsarReader` annotation. This example starts reading from the earliest available message. ```java import org.springframework.pulsar.annotation.PulsarReader; import org.springframework.stereotype.Component; @Component public class MyBean { @PulsarReader(topics = "someTopic", startMessageId = "earliest") public void processMessage(String content) { // ... } } ``` -------------------------------- ### List Available Capabilities Source: https://docs.spring.io/spring-boot/3.4/cli/using-the-cli.html Lists all available dependencies and project types supported by the start.spring.io service. This helps in understanding the options for project initialization. ```bash $ spring init --list ======================================= Capabilities of https://start.spring.io ======================================= Available dependencies: ----------------------- actuator - Actuator: Production ready features to help you monitor and manage your application ... web - Web: Support for full-stack web development, including Tomcat and spring-webmvc websocket - Websocket: Support for WebSocket development ws - WS: Support for Spring Web Services Available project types: ------------------------ gradle-build - Gradle Config [format:build, build:gradle] gradle-project - Gradle Project [format:project, build:gradle] maven-build - Maven POM [format:build, build:maven] maven-project - Maven Project [format:project, build:maven] (default) ... Copied! ``` -------------------------------- ### Configure CORS for Actuator Endpoints Source: https://docs.spring.io/spring-boot/3.4/reference/actuator/endpoints.html Enable CORS support for Actuator web endpoints by setting `management.endpoints.web.cors.allowed-origins` and `management.endpoints.web.cors.allowed-methods`. This example permits GET and POST calls from `https://example.com`. ```properties management.endpoints.web.cors.allowed-origins=https://example.com management.endpoints.web.cors.allowed-methods=GET,POST ``` ```yaml management: endpoints: web: cors: allowed-origins: "https://example.com" allowed-methods: "GET,POST" ``` -------------------------------- ### onStartup Method Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/web/servlet/RegistrationBean.html Configures the given ServletContext with necessary components for initialization. ```APIDOC ## void onStartup(ServletContext servletContext) ### Description Configures the given ServletContext with any servlets, filters, listeners context-params and attributes necessary for initialization. ### Parameters #### Path Parameters - **servletContext** (ServletContext) - Required - The ServletContext to initialize ### Response - **Throws** (ServletException) - If any call against the given ServletContext throws a ServletException ``` -------------------------------- ### Global CORS Configuration (Kotlin) Source: https://docs.spring.io/spring-boot/3.4/reference/web/servlet.html Configure global CORS mappings using Kotlin by defining a WebMvcConfigurer bean and overriding the addCorsMappings method. This example maps all requests starting with /api/**. ```kotlin import org.springframework.context.annotation.Bean import org.springframework.context.annotation.Configuration import org.springframework.web.servlet.config.annotation.CorsRegistry import org.springframework.web.servlet.config.annotation.WebMvcConfigurer @Configuration(proxyBeanMethods = false) class MyCorsConfiguration { @Bean fun corsConfigurer(): WebMvcConfigurer { return object : WebMvcConfigurer { override fun addCorsMappings(registry: CorsRegistry) { registry.addMapping("/api/**") } } } } ``` -------------------------------- ### Configure BufferingApplicationStartup in Java Source: https://docs.spring.io/spring-boot/3.4/reference/features/spring-application.html Use BufferingApplicationStartup to buffer startup events for later analysis. Set the buffer size during instantiation. ```java import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.context.metrics.buffering.BufferingApplicationStartup; @SpringBootApplication public class MyApplication { public static void main(String[] args) { SpringApplication application = new SpringApplication(MyApplication.class); application.setApplicationStartup(new BufferingApplicationStartup(2048)); application.run(args); } } ``` -------------------------------- ### LiveReloadServer.start() Source: https://docs.spring.io/spring-boot/3.4/api/java/index-files/index-19.html Starts the livereload server and accepts incoming connections. ```APIDOC ## POST /devtools/livereload/start ### Description Start the livereload server and accept incoming connections. ### Method POST ### Endpoint /devtools/livereload/start ``` -------------------------------- ### Spring Boot Application Startup Output Source: https://docs.spring.io/spring-boot/3.4/reference/features/spring-application.html This is an example of the typical log output when a Spring Boot application starts. It includes the Spring Boot banner, startup information, and server port details. ```log . ____ _ __ _ _ /\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \ ( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \ \/ ___)| |_)| | | | | || (_| | ) ) ) ) ' |____| .__|_| |_|_| |_\[__] | / / / / =========|_|==============|___/=/_/_/_/ :: Spring Boot :: (v3.4.13) 2025-12-18T07:25:12.738Z INFO 132973 --- [ main] o.s.b.d.f.logexample.MyApplication : Starting MyApplication using Java 17.0.17 with PID 132973 (/opt/apps/myapp.jar started by myuser in /opt/apps/) 2025-12-18T07:25:12.747Z INFO 132973 --- [ main] o.s.b.d.f.logexample.MyApplication : No active profile set, falling back to 1 default profile: "default" 2025-12-18T07:25:15.404Z INFO 132973 --- [ main] o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat initialized with port 8080 (http) 2025-12-18T07:25:15.461Z INFO 132973 --- [ main] o.apache.catalina.core.StandardService : Starting service [Tomcat] 2025-12-18T07:25:15.464Z INFO 132973 --- [ main] o.apache.catalina.core.StandardEngine : Starting Servlet engine: [Apache Tomcat/10.1.50] 2025-12-18T07:25:15.574Z INFO 132973 --- [ main] o.a.c.c.C.[Tomcat].[localhost].[/] : Initializing Spring embedded WebApplicationContext 2025-12-18T07:25:15.576Z INFO 132973 --- [ main] w.s.c.ServletWebServerApplicationContext : Root WebApplicationContext: initialization completed in 2680 ms 2025-12-18T07:25:16.551Z INFO 132973 --- [ main] o.s.b.w.embedded.tomcat.TomcatWebServer : Tomcat started on port 8080 (http) with context path '/' 2025-12-18T07:25:16.575Z INFO 132973 --- [ main] o.s.b.d.f.logexample.MyApplication : Started MyApplication in 5.371 seconds (process running for 5.909) 2025-12-18T07:25:16.592Z INFO 132973 --- [ionShutdownHook] o.s.b.w.e.tomcat.GracefulShutdown : Commencing graceful shutdown. Waiting for active requests to complete 2025-12-18T07:25:16.606Z INFO 132973 --- [tomcat-shutdown] o.s.b.w.e.tomcat.GracefulShutdown : Graceful shutdown complete ``` -------------------------------- ### Retrieve Part of the Log File Source: https://docs.spring.io/spring-boot/3.4/api/rest/actuator/logfile.html Use a GET request to the /actuator/logfile endpoint with the Range header to fetch a specific byte range of the log file. This example retrieves the first 1024 bytes. ```bash $ curl 'http://localhost:8080/actuator/logfile' -i -X GET \ -H 'Range: bytes=0-1023' ``` -------------------------------- ### build (no args) Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/builder/SpringApplicationBuilder.html Returns a fully configured SpringApplication ready to run. ```APIDOC ### build public SpringApplication build() Returns a fully configured `SpringApplication` that is ready to run. Returns: the fully configured `SpringApplication`. ``` -------------------------------- ### startRecording Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/context/metrics/buffering/BufferingApplicationStartup.html Starts the recording of steps and marks the beginning of the StartupTimeline. This can be reset if no steps have been recorded yet. ```APIDOC ## startRecording() ### Description Start the recording of steps and mark the beginning of the `StartupTimeline`. The class constructor already implicitly calls this, but it is possible to reset it as long as steps have not been recorded already. ### Throws - `IllegalStateException` - if called and `StartupStep` have been recorded already. ``` -------------------------------- ### Kotlin Handler for WebFlux Functional Endpoints Source: https://docs.spring.io/spring-boot/3.4/reference/web/servlet.html Example of a Kotlin handler class for processing requests in a WebFlux functional endpoint setup. This class defines methods for handling different user-related operations. ```kotlin import org.springframework.stereotype.Component import org.springframework.web.servlet.function.ServerRequest import org.springframework.web.servlet.function.ServerResponse @Component class MyUserHandler { fun getUser(request: ServerRequest?): ServerResponse { ... } fun getUserCustomers(request: ServerRequest?): ServerResponse { ... } fun deleteUser(request: ServerRequest?): ServerResponse { ... } } ``` -------------------------------- ### Java Handler for WebFlux Functional Endpoints Source: https://docs.spring.io/spring-boot/3.4/reference/web/servlet.html Example of a Java handler class for processing requests in a WebFlux functional endpoint setup. This class defines methods for handling different user-related operations. ```java import org.springframework.stereotype.Component; import org.springframework.web.servlet.function.ServerRequest; import org.springframework.web.servlet.function.ServerResponse; @Component public class MyUserHandler { public ServerResponse getUser(ServerRequest request) { ... } public ServerResponse getUserCustomers(ServerRequest request) { ... } public ServerResponse deleteUser(ServerRequest request) { ... } } ``` -------------------------------- ### Application Startup Configuration Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/SpringApplication.html Methods for setting and retrieving the ApplicationStartup for collecting startup metrics. ```APIDOC ## setApplicationStartup ### Description Set the `ApplicationStartup` to use for collecting startup metrics. ### Method public void setApplicationStartup(ApplicationStartup applicationStartup) ### Parameters #### Path Parameters - **applicationStartup** (ApplicationStartup) - Required - the application startup to use ### Since 2.4.0 ## getApplicationStartup ### Description Returns the `ApplicationStartup` used for collecting startup metrics. ### Method public ApplicationStartup getApplicationStartup() ### Returns - **ApplicationStartup** - the application startup ### Since 2.4.0 ``` -------------------------------- ### CloudCaptain Deployment Output Example Source: https://docs.spring.io/spring-boot/3.4/how-to/deployment/cloud.html This output shows the typical steps CloudCaptain takes during deployment, from fusing the image to launching an instance and making the application accessible on AWS. It includes details like image creation, AMI generation, security group setup, instance launching, and IP mapping. ```text Fusing Image for myapp-1.0.jar ... Image fused in 00:06.838s (53937 K) -> axelfontaine/myapp:1.0 Creating axelfontaine/myapp ... Pushing axelfontaine/myapp:1.0 ... Verifying axelfontaine/myapp:1.0 ... Creating Elastic IP ... Mapping myapp-axelfontaine.boxfuse.io to 52.28.233.167 ... Waiting for AWS to create an AMI for axelfontaine/myapp:1.0 in eu-central-1 (this may take up to 50 seconds) ... AMI created in 00:23.557s -> ami-d23f38cf Creating security group boxfuse-sg_axelfontaine/myapp:1.0 ... Launching t2.micro instance of axelfontaine/myapp:1.0 (ami-d23f38cf) in eu-central-1 ... Instance launched in 00:30.306s -> i-92ef9f53 Waiting for AWS to boot Instance i-92ef9f53 and Payload to start at https://52.28.235.61/ ... Payload started in 00:29.266s -> https://52.28.235.61/ Remapping Elastic IP 52.28.233.167 to i-92ef9f53 ... Waiting 15s for AWS to complete Elastic IP Zero Downtime transition ... Deployment completed successfully. axelfontaine/myapp:1.0 is up and running at https://myapp-axelfontaine.boxfuse.io/ ``` -------------------------------- ### WebServer Instantiation Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/web/embedded/undertow/UndertowReactiveWebServerFactory.html Method for obtaining a configured WebServer instance. ```APIDOC ## POST /api/webserver ### Description Gets a new fully configured but paused `WebServer` instance. Clients should not be able to connect to the returned server until `WebServer.start()` is called. ### Method POST ### Endpoint /api/webserver ### Parameters #### Request Body - **httpHandler** (HttpHandler) - Required - The HTTP handler in charge of processing requests. ### Request Example { "httpHandler": "com.example.MyHttpHandler" } ### Response #### Success Response (200) - **webServer** (WebServer) - A fully configured and started `WebServer` instance. #### Response Example { "webServer": { "port": 8080, "isRunning": false } } ``` -------------------------------- ### Native Application Startup Output Source: https://docs.spring.io/spring-boot/3.4/how-to/native-image/developing-your-first-application.html Example output demonstrating the fast startup of a Spring Boot application compiled into a native image. Note the significantly reduced startup time compared to a JVM-based application. ```text . ____ _ __ _ _ /\ / ___'_ __ _ _(_)_ __ __ _ \ \ \ \ ( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \ \/ ___)| |_)| | | | | |\__, | ) ) ) ) ' |____| .__|_| |_|_| |_ =========|_|==============|___/=/_/_/_/ :: Spring Boot :: (v3.4.13) ....... . . . ....... . . . (log output here) ....... . . . ........ Started MyApplication in 0.08 seconds (process running for 0.095) ``` -------------------------------- ### DockerCompose.start Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/docker/compose/core/DockerCompose.html Runs `docker compose start` to start services. It waits until all containers are started and healthy. ```APIDOC ## DockerCompose.start ### Description Runs `docker compose start` to start services. Waits until all containers are started and healthy. ### Method `void` ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) None #### Response Example None ### Method Signature `void start(LogLevel logLevel)` `void start(LogLevel logLevel, List arguments)` ### Parameters - `logLevel` (LogLevel) - The log level used to report progress. - `arguments` (List) - The arguments to pass to the start command. (Optional) ``` -------------------------------- ### POST /start Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/buildpack/platform/docker/DockerApi.ContainerApi.html Starts a specific Docker container. ```APIDOC ## POST /start ### Description Start a specific container. ### Method POST ### Endpoint /start ### Parameters #### Request Body - **reference** (ContainerReference) - Required - The container reference to start. ### Response #### Success Response (200) - **void** - Indicates successful execution. #### Response Example { "example": "void" } ``` -------------------------------- ### spring-boot:start Goal Source: https://docs.spring.io/spring-boot/3.4/maven-plugin/integration-tests.html The `start` goal from the `spring-boot-maven-plugin` allows starting a Spring application without blocking, suitable for integration tests. ```APIDOC ## `spring-boot:start` `org.springframework.boot:spring-boot-maven-plugin:3.4.13` Start a spring application. Contrary to the `run` goal, this does not block and allows other goals to operate on the application. This goal is typically used in integration test scenario where the application is started before a test suite and stopped after. ### Required parameters Name | Type | Default ---|---|--- classesDirectory | `File` | `${project.build.outputDirectory}` ### Optional parameters Name | Type | Default ---|---|--- addResources | `boolean` | `false` additionalClasspathElements | `String[]` | agents | `File[]` | arguments | `String[]` | commandlineArguments | `String` | environmentVariables | `Map` | excludeGroupIds | `String` | excludes | `List` | includes | `List` | jmxName | `String` | `org.springframework.boot:type=Admin,name=SpringApplication` jmxPort | `int` | `9001` jvmArguments | `String` | mainClass | `String` | maxAttempts | `int` | `60` noverify | `boolean` | profiles | `String[]` | skip | `boolean` | `false` systemPropertyVariables | `Map` | useTestClasspath | `Boolean` | `false` wait | `long` | `500` workingDirectory | `File` | ### Parameter details #### `addResources` Add maven resources to the classpath directly, this allows live in-place editing of resources. Duplicate resources are removed from `target/classes` to prevent them from appearing twice if `ClassLoader.getResources()` is called. Please consider adding `spring-boot-devtools` to your project instead as it provides this feature and many more. Name | `addResources` ---|--- Type | `boolean` Default value | `false` User property | `spring-boot.run.addResources` Since | `1.0.0` #### `additionalClasspathElements` Additional classpath elements that should be added to the classpath. An element can be a directory with classes and resources or a jar file. Name | `additionalClasspathElements` ---|--- Type | `java.lang.String[]` Default value | User property | `spring-boot.run.additional-classpath-elements` Since | `3.2.0` #### `agents` Path to agent jars. Name | `agents` ---|--- Type | `java.io.File[]` Default value | User property | `spring-boot.run.agents` Since | `2.2.0` #### `arguments` Arguments that should be passed to the application. Name | `arguments` ---|--- Type | `java.lang.String[]` Default value | User property | Since | `1.0.0` #### `classesDirectory` Directory containing the classes and resource files that should be used to run the application. Name | `classesDirectory` ---|--- Type | `java.io.File` Default value | `${project.build.outputDirectory}` User property | Since | `1.0.0` #### `commandlineArguments` Arguments from the command line that should be passed to the application. Use spaces to separate multiple arguments and make sure to wrap multiple values between quotes. When specified, takes precedence over `#arguments`. Name | `commandlineArguments` ---|--- Type | `java.lang.String` Default value | User property | `spring-boot.run.arguments` Since | `2.2.3` #### `environmentVariables` List of Environment variables that should be associated with the forked process used to run the application. Name | `environmentVariables` ---|--- Type | `java.util.Map` Default value | User property | Since | `2.1.0` #### `excludeGroupIds` Comma separated list of groupId names to exclude (exact match). Name | `excludeGroupIds` ---|--- Type | `java.lang.String` Default value | User property | `spring-boot.excludeGroupIds` Since | `1.1.0` #### `excludes` Collection of artifact definitions to exclude. The `Exclude` element defines mandatory `groupId` and `artifactId` components and an optional `classifier` component. When configured as a property, values should be comma-separated with colon-separated components: `groupId:artifactId,groupId:artifactId:classifier` Name | `excludes` ---|--- Type | `java.util.List` Default value | User property | `spring-boot.excludes` Since | `1.1.0` ``` -------------------------------- ### Basic Spring Boot Application (Kotlin) Source: https://docs.spring.io/spring-boot/3.4/reference/actuator/tracing.html A simple 'Hello World!' web application in Kotlin. This serves as the base for demonstrating tracing. ```kotlin import org.apache.commons.logging.Log import org.apache.commons.logging.LogFactory import org.springframework.boot.autoconfigure.SpringBootApplication import org.springframework.boot.runApplication import org.springframework.web.bind.annotation.RequestMapping import org.springframework.web.bind.annotation.RestController @RestController @SpringBootApplication class MyApplication { private val logger: Log = LogFactory.getLog(MyApplication::class.java) @RequestMapping("/") fun home(): String { logger.info("home() has been called") return "Hello, World!" } } fun main(args: Array) { runApplication(*args) } ``` -------------------------------- ### SpringApplication Source: https://docs.spring.io/spring-boot/3.4/api/java/index-files/index-2.html Provides methods for application startup and environment management. ```APIDOC ## Method in class org.springframework.boot.SpringApplication ### bindSpringApplication(ConfigurableEnvironment) Bind the environment to the `ApplicationProperties`. ### Method instance ### Endpoint N/A ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) None #### Response Example None ``` -------------------------------- ### Install Spring Boot CLI with Homebrew Source: https://docs.spring.io/spring-boot/3.4/installing.html Install the Spring Boot CLI on macOS using Homebrew. This command taps the necessary repository and installs the CLI. ```bash $ brew tap spring-io/tap $ brew install spring-boot ``` -------------------------------- ### Application Starting Event Source: https://docs.spring.io/spring-boot/3.4/api/java/serialized-form.html Represents the event where the application is starting. ```APIDOC ## Class org.springframework.boot.context.event.ApplicationStartingEvent ### Description Represents the event where the application is starting. ### Serialized Fields - **bootstrapContext** (ConfigurableBootstrapContext) - The bootstrap context. ``` -------------------------------- ### GET /buffering-application-startup/timeline Source: https://docs.spring.io/spring-boot/3.4/api/java/index-files/index-7.html Retrieves a snapshot of currently buffered steps from the application startup process. ```APIDOC ## GET /buffering-application-startup/timeline ### Description Return the timeline as a snapshot of currently buffered steps. ### Method GET ### Response #### Success Response (200) - **timeline** (Object) - A snapshot of currently buffered steps. ``` -------------------------------- ### begin Method Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/autoconfigure/jooq/SpringTransactionProvider.html Begins a new transaction context. ```APIDOC ## begin(org.jooq.TransactionContext context) ### Description Begins a new transaction using the provided transaction context. ### Method public void ### Parameters * **context** (org.jooq.TransactionContext) - Required - The transaction context to begin. ``` -------------------------------- ### Application Started Event Source: https://docs.spring.io/spring-boot/3.4/api/java/serialized-form.html Represents the event where the application has started. ```APIDOC ## Class org.springframework.boot.context.event.ApplicationStartedEvent ### Description Represents the event where the application has started. ### Serialized Fields - **context** (ConfigurableApplicationContext) - The application context. - **timeTaken** (Duration) - The time taken for the application to start. ``` -------------------------------- ### logStartupInfo Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/builder/SpringApplicationBuilder.html Configures whether startup information should be logged. This is a boolean flag that defaults to true. ```APIDOC ## logStartupInfo ### Description Flag to indicate the startup information should be logged. ### Method public SpringApplicationBuilder logStartupInfo(boolean logStartupInfo) ### Parameters #### Path Parameters - **logStartupInfo** (boolean) - Required - the flag to set. Default true. ### Returns the current builder ``` -------------------------------- ### Flyway Installed By Source: https://docs.spring.io/spring-boot/3.4/api/java/index-files/index-19.html Configuration for the user who installed the Flyway schema. ```APIDOC ## SET INSTALLED BY ### Description Sets the user who installed the Flyway schema. ### Method SET ### Endpoint N/A ### Parameters #### Query Parameters - **installedBy** (String) - Required - The name of the user. ### Request Example ```json { "installedBy": "admin" } ``` ### Response #### Success Response (200) - **message** (string) - Confirmation of setting the installedBy user. #### Response Example ```json { "message": "Flyway installedBy set to admin" } ``` ``` -------------------------------- ### static void main(String[] args) Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/devtools/RemoteSpringApplication.html Runs the RemoteSpringApplication to establish a link to a remote Spring Boot application. ```APIDOC ## static void main(String[] args) ### Description Run the RemoteSpringApplication to establish a link to a remotely running Spring Boot application. This should be launched from within an IDE with the same classpath configuration as the local application. ### Parameters #### Arguments - **args** (String[]) - Required - The program arguments, including the remote URL of the application as a non-option argument. ``` -------------------------------- ### FileSystemWatcher.start() Source: https://docs.spring.io/spring-boot/3.4/api/java/index-files/index-19.html Starts monitoring the source directory for changes. ```APIDOC ## POST /devtools/filewatch/start ### Description Start monitoring the source directory for changes. ### Method POST ### Endpoint /devtools/filewatch/start ``` -------------------------------- ### GET Operation Source: https://docs.spring.io/spring-boot/3.4/api/java/org/springframework/boot/buildpack/platform/docker/transport/HttpTransport.html Performs an HTTP GET operation to the specified URI. ```APIDOC ## GET /uri ### Description Perform an HTTP GET operation. ### Method GET ### Endpoint `/uri` ### Parameters #### Path Parameters - **uri** (URI) - Required - The destination URI (excluding any host/port). ### Response #### Success Response (200) - **HttpTransport.Response** - The operation response. #### Error Response - **IOException** - on IO error ``` -------------------------------- ### LogbackInitializer initialize Source: https://docs.spring.io/spring-boot/3.4/api/java/index-files/index-9.html Initializes Logback. ```APIDOC ## LogbackInitializer initialize ### Description Initializes Logback. ### Method `static initialize()` ### Endpoint N/A (Static utility method) ``` -------------------------------- ### WebServerSslBundle get Methods Source: https://docs.spring.io/spring-boot/3.4/api/java/index-files/index-7.html Methods to get an SslBundle for the web server. ```APIDOC ## GET get(Ssl) ### Description Get the `SslBundle` that should be used for the given `Ssl` instance. ### Method GET ### Endpoint N/A (Static method in a class) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **SslBundle** (type) - The `SslBundle` to be used. ``` ```APIDOC ## GET get(Ssl, SslBundles) ### Description Get the `SslBundle` that should be used for the given `Ssl` instance. ### Method GET ### Endpoint N/A (Static method in a class) ### Parameters #### Path Parameters None #### Query Parameters None #### Request Body None ### Request Example None ### Response #### Success Response (200) - **SslBundle** (type) - The `SslBundle` to be used. ``` -------------------------------- ### Basic Spring Boot Application (Java) Source: https://docs.spring.io/spring-boot/3.4/reference/actuator/tracing.html A simple 'Hello World!' web application in Java. This serves as the base for demonstrating tracing. ```java import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; @RestController @SpringBootApplication public class MyApplication { private static final Log logger = LogFactory.getLog(MyApplication.class); @RequestMapping("/") String home() { logger.info("home() has been called"); return "Hello World!"; } public static void main(String[] args) { SpringApplication.run(MyApplication.class, args); } } ```