https://bz.apache.org/bugzilla/show_bug.cgi?id=59939

--- Comment #1 from Hao <[email protected]> ---
A logic should be added so that when there is no method overload, just return
the only method that matches the name, so that it is compatible with the
version 7.0.52. Current behavior broke our code in multiple places and makes
method invocation hard to use. For example, the code below is broken because
actionItems is an ArrayList, but the method writeValueAsString() takes an
Object in method signature.
<c:set target="${actionItemsMap}" property="actionItems"
value="${objectMapper.writeValueAsString(actionItems)}" />

javax.el.MethodNotFoundException: java.lang.NoSuchMethodException:
org.codehaus.jackson.map.ObjectMapper.writeValueAsString(java.util.ArrayList)


Moreover, we have a method in some class defined like this 
  public List<String> getActionOptions(Map<String, String> mappings)

And it is being invoked like this in JSP 
  <c:forEach var="option" items="${doc.getActionOptions(endpointMappings)}">

The new Tomcat version caused exception here too:
Caused by: javax.el.MethodNotFoundException: java.lang.NoSuchMethodException:
com.amazon.edi.ssi.lib.types.IntegrationStatus.getActionOptions(java.util.HashMap)

The exception happens because ELResolver tries to find a method that matches
the runtime argument type of variable 'endpointMappings', which is a HashMap.
But the method signature takes an Map interface argument so it does not match.
That should be fixed.

-- 
You are receiving this mail because:
You are the assignee for the bug.

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to