Skip to content

Document HttpMessageConverters detection changes in 4.0.1 #48574

@gurpreetsingh85

Description

@gurpreetsingh85

Problem

With the 4.0.1-SNAPSHOT build, if a custom JacksonJsonHttpMessageConverter bean is declared and the controller returns ResponseEntity<String> instead of ResponseEntity<?>, the framework will escape an already created JSON string response.

I have added a sample with both 4.0.0 and 4.0.1-SNAPSHOT versions.

With 4.0.0 it returns a valid json as {"Hello": "World"} but with 4.0.1-SNAPSHOT the response becomes "{\"Hello\":\"World\"}"

spring-boot-4-0-0.zip
spring-boot-4-0-1.zip

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions