Closed
Description
Thomas Hehl opened SPR-14394 and commented
The error handling provides insufficient information to resolve the error when no converter is found. What follows is lines 117-120 of PayloadArgumentResolver.java.
{{ if (payload == null) {
throw new MessageConversionException(message,
"No converter found to convert to " + targetClass + ", message=" + message);
}}}
This does not provide information about the payload class that it's trying to convert. Error handling should be:
{{ if (payload == null) {
throw new MessageConversionException(message,
"No converter found to convert to " + targetClass + ", from " + payload.getClass() + ", message=" + message);
}}}
Affects: 4.2.5, 4.2.6
Referenced from: commits 07c9c55, f5282bc
Backported to: 4.2.7