Return-Path: Delivered-To: apmail-geronimo-dev-archive@www.apache.org Received: (qmail 17430 invoked from network); 14 Oct 2010 02:59:56 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 14 Oct 2010 02:59:56 -0000 Received: (qmail 88471 invoked by uid 500); 14 Oct 2010 02:59:55 -0000 Delivered-To: apmail-geronimo-dev-archive@geronimo.apache.org Received: (qmail 88411 invoked by uid 500); 14 Oct 2010 02:59:55 -0000 Mailing-List: contact dev-help@geronimo.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@geronimo.apache.org List-Id: Delivered-To: mailing list dev@geronimo.apache.org Received: (qmail 88404 invoked by uid 99); 14 Oct 2010 02:59:55 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 14 Oct 2010 02:59:55 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 14 Oct 2010 02:59:54 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o9E2xXHZ029152 for ; Thu, 14 Oct 2010 02:59:33 GMT Message-ID: <21715076.135781287025173455.JavaMail.jira@thor> Date: Wed, 13 Oct 2010 22:59:33 -0400 (EDT) From: "viola.lu (JIRA)" To: dev@geronimo.apache.org Subject: [jira] Closed: (GERONIMO-5479) EL 2.2 new feature: method invocation with parameters works incorrectly when the parameter is Integer. In-Reply-To: <24393144.61351280379435889.JavaMail.jira@thor> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/GERONIMO-5479?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] viola.lu closed GERONIMO-5479. ------------------------------ Resolution: Invalid >From tomcat response: https://issues.apache.org/bugzilla/show_bug.cgi?id=49925 The EL spec makes clear (in section 1.19) that integer literals are longs not ints so the behaviour you see is expected. So close it. > EL 2.2 new feature: method invocation with parameters works incorrectly when the parameter is Integer. > ------------------------------------------------------------------------------------------------------ > > Key: GERONIMO-5479 > URL: https://issues.apache.org/jira/browse/GERONIMO-5479 > Project: Geronimo > Issue Type: Bug > Security Level: public(Regular issues) > Components: javaee6 > Affects Versions: 3.0 > Environment: OS: Windows XP SP3, JDK: sun-jdk-1.6.0_18 > Reporter: Wang Guang Zhe > Assignee: viola.lu > Priority: Minor > Fix For: 3.0 > > > I create a simple JSF app to test this new feature. You can check it out from trunk: testsuite/javaee6-testsuite/el2.2-test which has been committed at revision 980368. > In the managed bean User class, I defined a method: > public int calYear(int x) { > return (age + x); > } > and in the page I call it with #{user.calYear(5)}, in both tomcat and jetty assemblies an error occurs: > java.lang.NoSuchMethodException: org.apache.geronimo.testsuite.el22.app.User.calYear(java.lang.Long) which implies that the container recognizes 5 as Long. > The error stack: > javax.faces.FacesException: java.lang.NoSuchMethodException: org.apache.geronimo.testsuite.el22.app.User.calYear(java.lang.Long) > at org.apache.myfaces.shared_impl.context.ExceptionHandlerImpl.wrap(ExceptionHandlerImpl.java:241) > at org.apache.myfaces.shared_impl.context.ExceptionHandlerImpl.handle(ExceptionHandlerImpl.java:156) > at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:222) > at javax.faces.webapp.FacesServlet.service(FacesServlet.java:191) > at org.eclipse.jetty.servlet.ServletHolder.handle(ServletHolder.java:532) > at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:456) > at org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:230) > at org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:966) > at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:391) > at org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193) > at org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:902) > at org.apache.geronimo.jetty8.handler.GeronimoWebAppContext.doScope(GeronimoWebAppContext.java:125) > at org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:117) > at org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:245) > at org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:126) > at org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:113) > at org.eclipse.jetty.server.Server.handle(Server.java:338) > at org.eclipse.jetty.server.HttpConnection.handleRequest(HttpConnection.java:568) > at org.eclipse.jetty.server.HttpConnection$RequestHandler.content(HttpConnection.java:1010) > at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:775) > at org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:228) > at org.eclipse.jetty.server.HttpConnection.handle(HttpConnection.java:403) > at org.eclipse.jetty.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:474) > at org.apache.geronimo.pool.ThreadPool$1.run(ThreadPool.java:214) > at org.apache.geronimo.pool.ThreadPool$ContextClassLoaderRunnable.run(ThreadPool.java:344) > at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source) > at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) > at java.lang.Thread.run(Unknown Source) > Caused by: java.lang.NoSuchMethodException: org.apache.geronimo.testsuite.el22.app.User.calYear(java.lang.Long) > at java.lang.Class.getMethod(Unknown Source) > at javax.el.BeanELResolver.invoke(BeanELResolver.java:394) > at javax.el.CompositeELResolver.invoke(CompositeELResolver.java:228) > at org.apache.el.parser.AstValue.getValue(AstValue.java:158) > at org.apache.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:192) > at org.apache.myfaces.view.facelets.el.TagValueExpression.getValue(TagValueExpression.java:84) > at javax.faces.component._DeltaStateHelper.eval(_DeltaStateHelper.java:243) > at javax.faces.component.UIOutput.getValue(UIOutput.java:71) > at org.apache.myfaces.shared_impl.renderkit.RendererUtils.getValue(RendererUtils.java:349) > at org.apache.myfaces.shared_impl.renderkit.RendererUtils.getStringValue(RendererUtils.java:301) > at org.apache.myfaces.shared_impl.renderkit.html.HtmlTextRendererBase.renderOutput(HtmlTextRendererBase.java:81) > at org.apache.myfaces.shared_impl.renderkit.html.HtmlTextRendererBase.encodeEnd(HtmlTextRendererBase.java:68) > at javax.faces.component.UIComponentBase.encodeEnd(UIComponentBase.java:486) > at javax.faces.component.UIComponent.encodeAll(UIComponent.java:618) > at javax.faces.component.UIComponent.encodeAll(UIComponent.java:614) > at javax.faces.component.UIComponent.encodeAll(UIComponent.java:614) > at org.apache.myfaces.view.facelets.FaceletViewDeclarationLanguage.renderView(FaceletViewDeclarationLanguage.java:1117) > at org.apache.myfaces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:231) > at org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:122) > at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:207) > ... 25 more -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.