Return-Path: X-Original-To: apmail-click-dev-archive@www.apache.org Delivered-To: apmail-click-dev-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 4524D9DD4 for ; Sat, 25 Feb 2012 05:22:14 +0000 (UTC) Received: (qmail 32096 invoked by uid 500); 25 Feb 2012 05:22:14 -0000 Delivered-To: apmail-click-dev-archive@click.apache.org Received: (qmail 31980 invoked by uid 500); 25 Feb 2012 05:22:11 -0000 Mailing-List: contact dev-help@click.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@click.apache.org Delivered-To: mailing list dev@click.apache.org Received: (qmail 31938 invoked by uid 99); 25 Feb 2012 05:22:09 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 25 Feb 2012 05:22:09 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 25 Feb 2012 05:22:07 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 44AAF3393B7 for ; Sat, 25 Feb 2012 05:21:46 +0000 (UTC) Date: Sat, 25 Feb 2012 05:21:46 +0000 (UTC) From: "Andrew Fink (Commented) (JIRA)" To: dev@click.apache.org Message-ID: <180914821.18988.1330147306282.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] [Commented] (CLK-306) Replacing OGNL with MVEL MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/CLK-306?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13216316#comment-13216316 ] Andrew Fink commented on CLK-306: --------------------------------- Malcolm Edgar wrote: I think there are a couple of options here: 1. Rollback the changes to use OGNL, 2. Replace OGNL with MVEL, and stop supporting access to private variables (could break a fair bit of code) 3. Have a pluggable PropertyService with OGNL and MVEL implementations (what should be the default?) Of these options I would prefer #3. === Pluggable PropertyService is very good idea! One can implement then Spring's SpEL implementation too. > Replacing OGNL with MVEL > ------------------------ > > Key: CLK-306 > URL: https://issues.apache.org/jira/browse/CLK-306 > Project: Click > Issue Type: New Feature > Components: core > Affects Versions: 1.4 > Environment: Target Click 1.5 > Reporter: Bob Schellink > Assignee: Bob Schellink > Fix For: 2.3.1 > > Attachments: expression-language-performance.rar, expression-language-performance.zip > > > I have been following both OGNL and MVEL (another expression language) development the last couple of months. If we are going to make changes to this here are some things you might find interesting: > * OGNL 2.7.1 which is included in tapestry 4.1, now sports byte code enhancement. This was added by one of the tapestry authors to make OGNL much faster than its reflection mode. However in my testing 2.7.1 threw exceptions every now and then. So still buggy. > * MVEL (http://mvel.codehaus.org/) seems like a good replacement for OGNL. It has good docs and is actively developed. They even fixed a bug I logged! Like OGNL, MVEL also runs in two modes, either reflection or byte compiled. Unlike OGNL, MVEL's reflection mode is faster than Click's reflection mode. > I am no expert on this but according to the article below (from MVEL's author), byte code enhancement have some problems in that generated classes accumulate in java's perm space and will only be removed when their classloader is removed. > http://artexpressive.blogspot.com/2007/07/mvel-by-numbers-real-story.html > So MVEL in reflection mode looks like an ideal solution here. The power of OGNL with the performance of Click reflection. > Table columns can again take advantage of expressions. For example to aggregate a total for the row -> new Column("price * tax"); -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa For more information on JIRA, see: http://www.atlassian.com/software/jira