Forbid null HttpMessageConverter in RestTemplate and HttpMessageConverterExtractor #23151
Labels
in: web
Issues in web modules (web, webmvc, webflux, websocket)
type: enhancement
A general enhancement
Milestone
This issue supersedes #23123 and #23140 with the intention of forbidding
null
HttpMessageConverter
references supplied directly toRestTemplate
andHttpMessageConverterExtractor
.Note, however, that we will not seek to prevent users from inserting
null
values into the list returned byRestTemplate#getMessageConverters()
. If a user modifies the list returned bygetMessageConverters()
so that it containsnull
values, that will still lead to aNullPointerException
when the converters are accessed.See #23140 (comment) for further details.
The text was updated successfully, but these errors were encountered: