-
Notifications
You must be signed in to change notification settings - Fork 38.8k
Description
Gary Russell opened SPR-9566 and commented
- A Map<?,?> that doesn't need conversion and does not have a no-arg constructor causes execution failure (works in 3.0). (INT-2630)
- A large byte[] is unnecessarily copied, causing high cpu utilization (not copied in 3.0). (INT-2650).
A simple example showing #2 is provided in spring-framework-issues is shown here (to-be-supplied).
The parameter 'argumentsRequiringConversion' to ReflectionUtils.convertArguments is completely ignored.
Before reading #13163, I tried "fixing" this method, as shown here (to-be-supplied). This fixed the problem, but broke ExpressionTestsUsingCoreConversionService.testConvert, because the logic in ReflectiveMethodResolver.resolve, for the test case that fails (with my patch to ReflectionHelper), considers "Collection<String> foos" a "close match" to the parameter in the method
public void setFoos(Collection<Foo> foos)
which results in argumentsRequiringConversion being null. Seems to me this shouldn't be a CLOSE match, but a REQUIRES_CONVERSION match, in which case my suggested fix to ReflectionUtils would work.
We can work around these issues in Spring Integration, but the core issue remains.
Affects: 3.1.1
Reference URL: http://forum.springsource.org/showthread.php?127694-TCP-Endpoint-binary-incoming-transfer-high-cpu-load
Issue Links:
- Refactor GenericConversionService [SPR-9927] #14560 Refactor GenericConversionService ("depends on")
- INT-2650 TCP Endpoint - using SpEL in Spring 3.1 to convert byte[] to byte[] - high cpu load and handle time delay
- INT-2630 Unable to convert MessageHistory, MessageHeaders via bundled converters.