question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Exposing ObjectMapper disables Spring Boot JacksonAutoConfiguration

See original GitHub issue

Exposing ObjectMapper used by JsonSerializer implemented here: https://github.com/spring-projects/spring-data-couchbase/pull/1132, disables Spring Boot JacksonAutoConfiguration#jacksonObjectMapper(), since it is annotated with @ConditionalOnMissingBean.

It forces usage of Couchbase ObjectMapper Bean which disables Spring Boot Jackson customizations (properties, modules, …).

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
mikereichecommented, Sep 23, 2021

Right. Not sure what I was thinking.

@override ObjectMapper couchbaseObjectMapper(){ theObjectMapper = super.couchbaseObjectMapper(); theObjectMapper… // customizations return theObjectMapper; }

1reaction
mikereichecommented, Sep 1, 2021

seems that removing the @Bean from couchbaseObjectMapper() would fix this.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Spring Boot Autoconfigured ObjectMapper plus additional ...
Our aim is to not override the spring auto configuration in class JacksonAutoConfiguration so that every customization by clients of the ...
Read more >
JacksonAutoConfiguration (Spring Boot 3.0.0 API)
Auto configuration for Jackson. The following auto-configuration will get applied: an ObjectMapper in case none is already configured.
Read more >
spring-boot/JacksonAutoConfiguration.java at main - GitHub
package org.springframework.boot.autoconfigure.jackson;. import java.lang.reflect. ... <li>an {@link ObjectMapper} in case none is already configured.</li>.
Read more >
Configuring Spring Boot to use Gson instead of Jackson
Spring Boot uses Jackson by default for serializing and deserializing request and response objects in your REST APIs.
Read more >
Spring Boot: Customize the Jackson ObjectMapper - Baeldung
By default, the Spring Boot configuration will disable the following: MapperFeature.DEFAULT_VIEW_INCLUSION; DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found