-
Notifications
You must be signed in to change notification settings - Fork 6
Spring Boot Applications
The plugin enables you to compile Spring Boot applications down to native binaries using Excelsior JET. Compared to running your application on a conventional JVM, this has the following benefits:
-
More predictable latency for your Web application, as no code de-optimizations may occur suddenly at run time
-
Better startup time, which may be important if you need to launch a multitude of microservices upon updating your distributed application
-
Better initial performance that remains stable later on, which can be important for load balancing inside an application cluster
-
Security and IP protection, as reverse engineering of sensitive application code becomes much more expensive and the exposure of yet unknown to you security vulnerabilities is reduced
Excelsior JET 15.3 supports Spring Boot versions from 1.4 and above.
To enable native compilation of your Spring Boot application, you need to add the plugin dependency to the buildscript
configuration of the build.gradle
file, e.g.:
buildscript {
def jetPluginVersion = '1.3.1'
repositories {
mavenCentral()
}
dependencies {
classpath "com.excelsiorjet:excelsior-jet-gradle-plugin:$jetPluginVersion"
}
}
then apply and configure the excelsiorJet
plugin as follows:
apply plugin: 'excelsiorJet'
excelsiorJet {
appType = "spring-boot"
}
You can launch your Spring Boot application on the Excelsior JET JVM using a JIT compiler
before pre-compiling it to native code using the
jetTestRun
task the same way
as with plain Java SE applications.
Use the jetStop
task
to ensure correct application termination at the end of a Test Run.
Technically, you can terminate the application using Ctrl-C, but that would terminate the entire Gradle build
and would not constitute a correct termination.
Profiling Spring Boot applications is supported via the jetProfile
task.
However, the same notice as for the Test Run applies: use the jetStop
task
to ensure correct termination.
Compilation Settings:
- Incremental Compilation
- Dependency-Specific Settings
- Optimizations
- Target Executable
- Application Apperarance
- Raw Compiler Options
Packaging Settings:
- Package Contents
- System Properties And JVM Arguments
- Excelsior JET Runtime
- Excelsior Installer (Windows/Linux)
- OS X App Bundles And Installers
Application Type Specifics: