in spring boot 3.2.3 ContentCachingResponseWrapper is not reading content-type and content-length #39818
Labels
for: external-project
For an external project and not something we can fix
status: duplicate
A duplicate of another issue
We tried to upgrade the spring boot version to 3.2.3, however, we have several tests failing because the ContentCachingResponseWrapper getHeader() is throwing a NullPointerExecption. The last working version is 3.2.2.
In the version 3.2.2, the content-length and content-type are read from the raw response, however, in the 3.2.3, both fields are read from the attribution of the wrapper.
The function getHeaderNames() returns a list of header keys, both content-type and content-length are included in the list. However, when we use the getHeader() to get the value, it returns a null.
I noticed that not every response has the same problem with ContentCachingResponseWrapper, but in some cases both values are not read correctly.
The text was updated successfully, but these errors were encountered: