Phillip Webb 33c6c600a9 Split up adoc files
Closes gh-23254
2021-04-29 17:32:27 -07:00

35 lines
1.1 KiB
Plaintext

[[features.json]]
== JSON
Spring Boot provides integration with three JSON mapping libraries:
- Gson
- Jackson
- JSON-B
Jackson is the preferred and default library.
[[features.json.jackson]]
=== Jackson
Auto-configuration for Jackson is provided and Jackson is part of `spring-boot-starter-json`.
When Jackson is on the classpath an `ObjectMapper` bean is automatically configured.
Several configuration properties are provided for <<howto#howto.spring-mvc.customize-jackson-objectmapper,customizing the configuration of the `ObjectMapper`>>.
[[features.json.gson]]
=== Gson
Auto-configuration for Gson is provided.
When Gson is on the classpath a `Gson` bean is automatically configured.
Several `+spring.gson.*+` configuration properties are provided for customizing the configuration.
To take more control, one or more `GsonBuilderCustomizer` beans can be used.
[[features.json.json-b]]
=== JSON-B
Auto-configuration for JSON-B is provided.
When the JSON-B API and an implementation are on the classpath a `Jsonb` bean will be automatically configured.
The preferred JSON-B implementation is Apache Johnzon for which dependency management is provided.