All properties
Every property spring_boot_dart reads, with the keys of spring_core_dart that decide which config files are read (they are read by the same start). Each row gives the key, its type, its default and what it does, with the page that explains it.
Why
This is the one place where every key of the start is listed. The classes that read them (MainProperties, JsonProperties, MessagesProperties... in spring_boot_dart, ConfigProperties and ProfilesProperties in spring_core_dart) also produce lib/spring_gen/spring_metadata.json, so editors with completion offer the same keys, and the description cannot drift from what the code reads.
Example
A realistic configuration of a server, in both formats:
# lib/resources/application.yml
spring:
application:
name: neon-books
main:
banner-mode: log
log-startup-info: true
lazy-initialization: false
register-shutdown-hook: true
allow-bean-definition-overriding: false
lifecycle:
timeout-per-shutdown-phase: 20s
profiles:
group:
prod: [eu, monitoring]
config:
import:
- resources:db.yml
- optional:file:./local.yml
- optional:configtree:/run/secrets/
autoconfigure:
exclude: [ApplicationAvailabilityAutoConfiguration]
json:
property-naming-strategy: SNAKE_CASE
default-property-inclusion: non_null
time-zone: UTC
messages:
basename: messages,i18n/errors
fallback-to-system-locale: false
logging:
level:
root: info
neon.checkout: debug
# lib/resources/application.properties
spring.application.name=neon-books
spring.main.banner-mode=log
spring.main.log-startup-info=true
spring.main.lazy-initialization=false
spring.main.register-shutdown-hook=true
spring.main.allow-bean-definition-overriding=false
spring.lifecycle.timeout-per-shutdown-phase=20s
spring.profiles.group.prod=eu,monitoring
spring.config.import=resources:db.yml,optional:file:./local.yml,optional:configtree:/run/secrets/
spring.autoconfigure.exclude=ApplicationAvailabilityAutoConfiguration
spring.json.property-naming-strategy=SNAKE_CASE
spring.json.default-property-inclusion=non_null
spring.json.time-zone=UTC
spring.messages.basename=messages,i18n/errors
spring.messages.fallback-to-system-locale=false
logging.level.root=info
logging.level.neon.checkout=debug
Writing values
- Durations:
30s, 500ms, 5m, 1h, 2d, or ISO-8601 (PT30S). A plain number is milliseconds, except where the table says seconds.
- Booleans:
true/false (also on, off, yes, no, 1, 0). Anything else stops the start.
- Enums: in any case and with any separator (
console, CONSOLE; non_null, NON_NULL).
- Lists: a comma list or a YAML list. A list given in a higher source replaces the whole list.
- Relaxed names:
spring.main.lazy-initialization, spring.main.lazyInitialization and SPRING_MAIN_LAZYINITIALIZATION are the same key.
- Read early: the
spring.config.* keys marked early are read only from the command line, --dart-define, the environment, SPRING_APPLICATION_JSON and default properties, never from a config file.
See Command line, environment and --dart-define.
spring.config.*: which files are read
| Key |
Type |
Default |
Meaning |
spring.config.name |
List<String> |
application |
Early. The base names of the config files; a later name wins → Config files |
spring.config.location |
locations |
optional:resources:/;optional:resources:/config/, optional:file:./;optional:file:./config/;optional:file:./config/*/ |
Early. Replaces the default locations. , separates groups, ; joins locations into one group → Config files |
spring.config.additional-location |
locations |
none |
Early. Groups searched after the locations, so they win over them → Config files |
spring.config.on-not-found |
fail / ignore |
fail |
Early. ignore makes every location optional → Config files |
spring.config.import |
List<String> of locations |
none |
More configuration: files, directories, configtree:, https://, package:, asset:; optional: allowed. In a file, or on the command line where it imports above every location → Imports |
spring.config.activate.on-profile |
profile expression |
none |
In a document: the document applies when the expression matches → Profiles |
spring.config.activate.on-cloud-platform |
CloudPlatform |
none |
In a document: the document applies on that platform (kubernetes, heroku, cloud-foundry, azure-app-service, amazon-ecs, nomad, sap, none) → Profiles |
spring.profiles.*: profiles
| Key |
Type |
Default |
Meaning |
spring.profiles.active |
List<String> |
none |
The active profiles; the first source that has the key wins. Not allowed in a profile file → Profiles |
spring.profiles.include |
List<String> |
none |
Profiles added to the active ones, from every source → Profiles |
spring.profiles.default |
List<String> |
default |
The profiles used while none is active → Profiles |
spring.profiles.group.<name> |
List<String> |
none |
Activating <name> activates these too; groups can nest → Profiles |
spring.profiles.validate |
bool |
true |
Checks the profile names (letters, digits, -_.+@, starting and ending with a letter or digit) → Profiles |
spring.main.*: the start
| Key |
Type |
Default |
Meaning |
spring.main.banner-mode |
console / log / off |
console, or SpringApplication(bannerMode:) |
Where the banner goes. false (YAML's off) is off → SpringApplication |
spring.main.log-startup-info |
bool |
true |
Logs the Starting ..., active profiles and Started ... in N seconds lines → SpringApplication |
spring.main.lazy-initialization |
bool |
false |
Creates every singleton on first use; LazyInitializationExcludeFilter beans keep some eager → SpringApplication |
spring.main.register-shutdown-hook |
bool |
false (Spring Boot: true) |
Closes the context on SIGINT or SIGTERM (VM only), then exits with 130 or 143. Wins over SpringApplication(registerShutdownHook:) → Shutdown |
spring.main.allow-bean-definition-overriding |
bool |
false |
A bean definition may replace another of the same name instead of failing the start → SpringApplication |
spring.main.cloud-platform |
CloudPlatform or none |
detected from the environment |
Forces the cloud platform, or turns detection off → Profiles |
spring.main.startup-checks.enabled |
bool |
not set: debug and profile builds |
Read by the generator when it writes the application (in application.yml or application.properties without a profile), not at run time: whether the starters' startup checks are in the build (the data starter's transactionValidator and dataFailureAnalyzer, the cache starter's cacheOperationValidator, the edge starter's warning list). true: in every build. false: in none, no code at all. Not set: in debug and profile builds only, so a release build compiles them away and a mistake they would have found fails at the first call instead of the start → Modules left out of the build |
spring.main.web-application-type=none is read by spring_boot_starter_web (no server starts); see spring_boot_starter_web.
spring.application.*, spring.banner.*
| Key |
Type |
Default |
Meaning |
spring.application.name |
String |
none: application in the startup lines |
The application's name: the context's id and the name in the startup lines → SpringApplication |
spring.application.json |
JSON object |
none |
Properties as one JSON object, also as SPRING_APPLICATION_JSON; placed above the environment → Sources |
spring.banner.location |
location |
resources:banner.txt |
The banner file; ${spring-boot.version}, ${spring-boot.formatted-version} and other ${...} are replaced → SpringApplication |
| Key |
Type |
Default |
Meaning |
spring.autoconfigure.exclude |
List<String> |
none |
Auto-configurations not to apply, by class or module name; adds to @SpringBootApplication(exclude:, excludeName:) → Auto-configuration |
spring.lifecycle.timeout-per-shutdown-phase |
Duration |
30s |
How long the context waits for the beans of one shutdown phase to stop → Shutdown |
spring.devtools.restart.enabled |
bool |
true |
Whether a hot reload on the Dart VM restarts the context when the generated code changed → Hot reload |
spring.task.execution.isolates.*: the task executor
The pool of the isolateTaskExecutor bean. Spring Boot's counterpart is spring.task.execution.pool.*, for threads.
| Key |
Type |
Default |
Meaning |
spring.task.execution.isolates.core-size |
int |
not set: one less than the machine has processors, at least one |
The isolates started before tasks wait in the queue → The task executor |
spring.task.execution.isolates.max-size |
int |
not set: as many as core-size |
The most isolates, reached only when the queue is full |
spring.task.execution.isolates.queue-capacity |
int |
not set: any number |
How many tasks may wait for an isolate. Not set, the pool never grows past core-size |
spring.task.execution.isolates.keep-alive |
Duration |
60s |
How long an idle isolate stays before it is stopped |
spring.task.execution.isolates.allow-core-timeout |
bool |
true |
Whether the first core-size isolates are stopped when idle too |
spring.task.execution.isolates.name-prefix |
String |
task- |
The isolates' names in the logs, a number added: task-1; in an isolate of the web server's pool, after its name: isolate-2-task-1 |
spring.json.*: the ObjectMapper
| Key |
Type |
Default |
Meaning |
spring.json.property-naming-strategy |
SNAKE_CASE / UPPER_SNAKE_CASE / UPPER_CAMEL_CASE / LOWER_CAMEL_CASE / LOWER_CASE / KEBAB_CASE / LOWER_DOT_CASE |
LOWER_CAMEL_CASE |
How field names become JSON names |
spring.json.default-property-inclusion |
always / non_null / non_absent / non_empty / non_default |
always |
Which properties are written |
spring.json.time-zone |
String |
none: each date in its own zone |
UTC, Z or a fixed offset (+02:00); a named zone stops the start |
spring.json.serialization.indent-output |
bool |
false |
Pretty-printed JSON |
spring.json.serialization.write-dates-as-timestamps |
bool |
false |
DateTime as epoch seconds with a fraction |
spring.json.serialization.write-durations-as-timestamps |
bool |
false |
Duration as seconds |
spring.json.serialization.write-date-timestamps-as-nanoseconds |
bool |
true |
Timestamps with a fraction; false: milliseconds |
spring.json.deserialization.read-date-timestamps-as-nanoseconds |
bool |
true |
Integer timestamps read as seconds; false: milliseconds |
spring.json.deserialization.fail-on-unknown-properties |
bool |
false |
A JSON property the class does not have fails the read |
spring.json.deserialization.accept-float-as-int |
bool |
true |
1.5 into an int truncates; false rejects it |
spring.json.deserialization.fail-on-null-for-primitives |
bool |
true |
null for a non-nullable int, double, num or bool fails the read |
spring.json.mapper.sort-properties-alphabetically |
bool |
true |
Properties sorted by JSON name, constructor parameters first |
spring.json.mapper.default-view-inclusion |
bool |
false |
Properties without @JsonView are written with a view |
spring.json.datatype.datetime.write-dates-as-timestamps |
bool |
the serialization. value |
Spring Boot 4's name; wins over the serialization. key |
spring.json.datatype.datetime.write-durations-as-timestamps |
bool |
the serialization. value |
Wins over the serialization. key |
spring.json.datatype.datetime.write-date-timestamps-as-nanoseconds |
bool |
the serialization. value |
Wins over the serialization. key |
spring.json.datatype.datetime.read-date-timestamps-as-nanoseconds |
bool |
the deserialization. value |
Wins over the deserialization. key |
spring.json.schemas[n].location |
String |
none |
A JSON Schema of the app: resources:schemas/order.json, https:// or github:owner/repo/path@ref; the build writes its classes and downloads a remote one → JSON Schema beans |
spring.json.schemas[n].sha256 |
String |
none |
The SHA-256 (hex) of a remote schema; the build refuses another |
spring.json.schemas[n].prefix |
String |
none |
What the names of the schema's classes start with |
spring.json.schemas[n].name |
String |
the schema's title |
The name of the root class |
spring.json.schemas-registry.properties |
bool |
true |
false: the schemas of spring.json.schemas, @JsonSchemaSource and JsonSchema beans stay out of the registry |
Any other spring.json.* key is warned about and ignored. See Built-in beans.
spring.messages.*: the message source
| Key |
Type |
Default |
Meaning |
spring.messages.basename |
List<String> |
messages |
The base names below lib/resources/; i18n/errors or i18n.errors |
spring.messages.encoding |
charset |
UTF-8 |
The files' encoding; an unknown one stops the start |
spring.messages.cache-duration |
Duration; a plain number is seconds |
kept forever |
How long a loaded file is kept before it is read again |
spring.messages.fallback-to-system-locale |
bool |
true |
Tries the system's locale before the file without a locale |
spring.messages.use-code-as-default-message |
bool |
false |
A missing key returns the key instead of failing |
spring.messages.always-use-message-format |
bool |
false |
Formats messages without arguments too, so '' becomes ' |
spring.messages.default-locale |
locale |
none |
A locale tried before the system's (not in Spring Boot) |
spring.messages.common-messages |
List<String> of locations |
none |
Texts shared by every locale; a later file wins |
See Built-in beans.
spring.resources.*: shipping the files of lib/resources/
| Key |
Type |
Default |
Meaning |
spring.resources.embed.exclude |
list of globs below lib/resources/ (content/**) |
none |
Files the build does not embed in the binary. A Flutter app reads them as Flutter assets under the same resources: locations; declare their directories under flutter: assets:. The configuration (application*, *.properties, config/) is always embedded. Read by the generator. |
spring.resources.prefetch.locations |
list of globs below lib/resources/ |
none |
Text files the build puts in one file a Flutter web app downloads once (Downloading them together). Read by the generator. |
spring.resources.prefetch.stage |
app, tasks |
app |
app: after the app is shown; tasks: behind the splash, which waits for it |
spring.resources.prefetch.delay |
duration |
1s |
How long after the app is shown (stage: app) |
spring.observations.annotations.enabled |
bool |
false |
Whether @Observed works: with true the build has the advisor and writes a proxy for each bean marked @Observed; without it, no proxy at all (Observations). Read by the generator. |
See Embedded resources.
logging.*: levels
logging.*: levels
| Key |
Type |
Default |
Meaning |
logging.level.root (or logging.level) |
level |
info |
The level of every logger without one of its own |
logging.level.<logger> |
trace / debug / info / warn / error / fatal / off |
inherited |
The level of a logger and the loggers below it; LOGGING_LEVEL_<LOGGER> as a variable |
logging.group.<group> |
List<String> |
web and sql predefined |
Logger names that logging.level.<group> sets together |
The outputs (logging.pattern.*, logging.file.*, logging.threshold.*...) belong to spring_boot_starter_logging. See Logging levels.
Keys without a prefix
| Key |
Type |
Default |
Meaning |
debug |
any; on unless false |
none |
--debug logs the condition evaluation report and sets the framework loggers to debug → Conditions |
trace |
any; on unless false |
none |
--trace sets the framework loggers to trace → Logging levels |
spring.remote.*: downloads of the configuration
| Key |
Type |
Default |
Meaning |
spring.remote.allow-insecure |
bool |
false |
Allows http:// and https:// with an invalid certificate for the downloads the configuration names (Flutter themes, images, page loaders); a warning lists them. Without it an insecure address stops the start. Not used by spring.config.import |
Environment variables with a meaning of their own
| Variable |
Meaning |
SPRING_APPLICATION_JSON |
Properties as one JSON object |
SPRING_PROFILES_ACTIVE, SPRING_CONFIG_IMPORT, SPRING_CONFIG_LOCATION... |
The keys above, in relaxed form |
KUBERNETES_SERVICE_HOST and KUBERNETES_SERVICE_PORT, DYNO, VCAP_APPLICATION, VCAP_SERVICES, WEBSITE_*, ECS_CONTAINER_METADATA_URI(_V4), NOMAD_ALLOC_ID, HC_LANDSCAPE |
Cloud platform detection → Profiles |
Renamed keys
spring.jackson.*, spring.cloud.openfeign.*, spring.servlet.multipart.*, server.servlet.*, logging.logback.rollingpolicy.* and spring.flyway.* stop the start and name their new keys (spring.json.*, spring.feign.*, spring.web.multipart.*, server.*, logging.file.rolling-policy.*, spring.sql.migration.*). See Renamed properties.
Not read
spring.main.allow-circular-references (a cycle is always an error), spring.main.web-application-type values other than none, spring.aop.*, spring.task.execution.* other than spring.task.execution.isolates.*, spring.task.scheduling.pool.*, logging.config, logging.structured.*, and spring.json.* keys other than those above.
See also