How can I get an ObjectMapper instance in Spring Boot without inheriting from spring-boot-starter-web?
You can add spring-boot-starter-json
if you want to avoid to include the full web stack (since Spring Boot v.2.0.0M4).
Why don't you just initialize it yourself.
@Bean
ObjectMapper objectMapper() {
return new ObjectMapper();
}
You can try and JUST add org.springframework:spring-web
dependency as that class is located in it.