You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@struts.apache.org by "Lukasz Lenart (JIRA)" <ji...@apache.org> on 2014/07/28 21:02:40 UTC

[jira] [Resolved] (WW-4318) Logging message when OgnlValueStack fail to set expression is cryptic most of the time

     [ https://issues.apache.org/jira/browse/WW-4318?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lukasz Lenart resolved WW-4318.
-------------------------------

    Resolution: Fixed
      Assignee: Lukasz Lenart

Patch applied! Thanks!

> Logging message when OgnlValueStack fail to set expression is cryptic most of the time
> --------------------------------------------------------------------------------------
>
>                 Key: WW-4318
>                 URL: https://issues.apache.org/jira/browse/WW-4318
>             Project: Struts 2
>          Issue Type: Bug
>          Components: Value Stack
>    Affects Versions: 2.3.16.1
>            Reporter: Brendan Le Ny
>            Assignee: Lukasz Lenart
>            Priority: Trivial
>              Labels: logging
>             Fix For: 2.3.18
>
>         Attachments: WW-4318.patch
>
>   Original Estimate: 5m
>  Remaining Estimate: 5m
>
> Most of the time, the logging message printed by OgnlValueStack class is useless because it doesn't show the value that causes the problem.
> Exemple log:
> {quote}
> 2014/03/20 02:23:28  WARN (CommonsLogger.java:64) warn Error setting expression 'myIntField' with value '[Ljava.lang.String;@55227e4a'
> ognl.MethodFailedException: Method "setMyIntField" failed for object fr.my.company.MyAction@df39b8b4 [java.lang.NoSuchMethodException: fr.my.company.MyAction@df39b8b4.setMyIntField([Ljava.lang.String;)]
> {quote}
> I can't find the reason because toString() is on a array show  '[Ljava.lang.String;@55227e4a' but i would like to see the actual value in the array.
> The exact same problem is fixed right in the method above the buggy one: the trivial patch is included.



--
This message was sent by Atlassian JIRA
(v6.2#6252)