Skip to content

StringHttpMessageConverter lost a fix that assumed charset UTF-8 for "application/json" #24123

@iorjfeiofjseoirf

Description

@iorjfeiofjseoirf

With #22100 (release 5.1.4) the StringHttpMessageConverter used charset UTF-8 for application/json, which is correct. However, the change to StringHttpMessageConverter.java was undone with #22954 (release 5.2.0).
#22954 aims to remove the charset parameter from Spring MVC JSON content type. But the lines dropped from StringHttpMessageConverter.java do not add a charset parameter to a content type. Instead they define the charset which will be used in interpreting messages. Without the fix from #22100 the charset for JSON messages defaults to ISO_8859_1, which is not correct and would require to set the charset explicitly.

Metadata

Metadata

Assignees

Labels

in: webIssues in web modules (web, webmvc, webflux, websocket)type: regressionA bug that is also a regression

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions