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

            Bug ID: 58327
           Summary: ValueExpressionLiteral should cache the string value
           Product: Tomcat 8
           Version: 8.0.26
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: EL
          Assignee: dev@tomcat.apache.org
          Reporter: andreas.k...@gmail.com

Created attachment 33061
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=33061&action=edit
Proposed patch

ValueExpressionLiteral invokes #getExpressionString() twice for many methods to
notify the context.

Calculating the string value can be expensive, for example in my case my values
are rather "big" JSON wrapper objects. For a literal value this string value
should be cacheable - the thing is read-only and a literal value, after all.

Attached a proposed patch to implement that - but I'm not sure whether there
might be specific tests to run or spec issues preventing this.


For the time being I worked around the issue in our own code by using a
different ValueExpression that has this caching behavior.

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

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org
For additional commands, e-mail: dev-h...@tomcat.apache.org

Reply via email to