Return-Path: X-Original-To: apmail-tomcat-users-archive@www.apache.org Delivered-To: apmail-tomcat-users-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 757B176D9 for ; Fri, 23 Dec 2011 03:23:51 +0000 (UTC) Received: (qmail 81233 invoked by uid 500); 23 Dec 2011 03:23:48 -0000 Delivered-To: apmail-tomcat-users-archive@tomcat.apache.org Received: (qmail 81043 invoked by uid 500); 23 Dec 2011 03:23:46 -0000 Mailing-List: contact users-help@tomcat.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "Tomcat Users List" Delivered-To: mailing list users@tomcat.apache.org Received: (qmail 81034 invoked by uid 99); 23 Dec 2011 03:23:44 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 Dec 2011 03:23:44 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=5.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of pnicoluc@us.ibm.com designates 32.97.110.151 as permitted sender) Received: from [32.97.110.151] (HELO e33.co.us.ibm.com) (32.97.110.151) by apache.org (qpsmtpd/0.29) with ESMTP; Fri, 23 Dec 2011 03:23:35 +0000 Received: from /spool/local by e33.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Thu, 22 Dec 2011 20:23:13 -0700 Received: from d03relay01.boulder.ibm.com (9.17.195.226) by e33.co.us.ibm.com (192.168.1.133) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Thu, 22 Dec 2011 20:23:03 -0700 Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by d03relay01.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id pBN3N2hb131238 for ; Thu, 22 Dec 2011 20:23:02 -0700 Received: from d03av02.boulder.ibm.com (loopback [127.0.0.1]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id pBN3N2Bk027585 for ; Thu, 22 Dec 2011 20:23:02 -0700 Received: from d03nm690.boulder.ibm.com (d03nm690.boulder.ibm.com [9.63.40.13]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id pBN3N1po027529 for ; Thu, 22 Dec 2011 20:23:01 -0700 In-Reply-To: References: <4EF22CE7.6000008@pidster.com> Subject: Re: [Discussion]Problem passing parameters to a Method ( Looking for incorrect argument Type ) X-KeepSent: 38FCDF02:750A2053-8725796F:00127506; type=4; name=$KeepSent To: "Tomcat Users List" X-Mailer: Lotus Notes Release 8.0.2 HF88 September 24, 2008 Message-ID: From: Paul Nicolucci Date: Thu, 22 Dec 2011 22:22:59 -0500 X-MIMETrack: Serialize by Router on D03NM690/03/M/IBM(Release 8.5.2FP1 ZX852FP1HF12|September 28, 2011) at 12/22/2011 20:23:01 MIME-Version: 1.0 Content-type: text/plain; charset=ISO-8859-1 Content-transfer-encoding: quoted-printable x-cbid: 11122303-2398-0000-0000-000002EEC1BC X-Virus-Checked: Checked by ClamAV on apache.org Thanks for your input! I've actually figured out what I was missing. = I had to also pull in the following fix: https://issues.apache.org/bugzilla/show_bug.cgi?id=3D50790 With the above fix everything works as it does on Tomcat 7.0.23 ( I was= able to successfully execute my test on Tomcat). Regards, Paul Nicolucci = Konstantin = Kolinko = Tomcat Users List = = 12/22/2011 12:16 = cc AM = Subj= ect Re: [Discussion]Problem passing = Please respond to parameters to a Method ( Looking= "Tomcat Users for incorrect argument Type ) = List" = = = = = 2011/12/22 Paul Nicolucci : > Thanks for the response, I'll try to clarify as best I can and can provide > a test case directly if needed ( since the mailing list strips attachments, > sorry about that =A0I was unaware ). > > -We are experiencing this problem on Websphere Application Server V8 which > included a snap shot of the org.apache.el code. > > - This problem only seems to happen after we pulled in the following = fix > for org.apache.el code : > https://issues.apache.org/bugzilla/show_bug.cgi?id=3D51177 > > - It seems that if we try to pass a parameter using JSF to a method u= sing > the EL when using a value stored in a Map then we always look for a method > signature having Object type parameters since the MapELResolver.getTy= pe() > always returns Object.class now. > > What further information can I provide? =A0Should I open a JIRA issue= with > more details and attach a test case there ? > 1. If you can provide a simple sample application that demonstrates the issue on a clean installation of Tomcat 7.0.23, then please open an issue in Bugzilla and attach it there. (So that we can fix it and a test to our testsuite). http://tomcat.apache.org/bugreport.html 2. Regarding BZ 51177 fix as far as I remember (without looking at commit logs), the old code was looking up the actual type of element contained in the map or in the list, which is just plainly wrong. There is specification fragment cited in https://issues.apache.org/bugzilla/show_bug.cgi?id=3D51177#c0 Regarding your use case where target class contains no "foo(Object)" method, from pure logic I would expect "foo(String)" to be found (if it is the only candidate) and then a classcast to be attempted, but I would like to see some quote from specification (from PDFs or from Javadoc) to support that. A close match is from page #34 (48 of 130) of expression_language-2_2-mrel-spec.pdf regarding BeanELResolver [quote] For method resolution, the method string is the name of the method in the bean. The parameter types can be optionally specified to identify the method. If the parameter types are not specified, the parameter objects are used in the method resolution. [/quote] and page #38 (52 of 130) [quote] The provided method object will first be coerced to a String. The methods in the bean is then examined and an attempt will be made to select one for invocation. If no suitable can be found, a MethodNotFoundException is thrown. If the given paramTypes is not null, select the method with the given name and parameter types. Else select the method with the given name that has the same number of parameters. If there are more than one such method, the method selection process is undefined. (...) [/quote] So the method name and the count of parameters is what matters. Best regards, Konstantin Kolinko --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org = --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org For additional commands, e-mail: users-help@tomcat.apache.org