aspose file tools*
The moose likes Struts and the fly likes ognl.OgnlException: target is null for setProperty(null, Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "ognl.OgnlException: target is null for setProperty(null, "preventCache", [Ljava.lang.String;@6dc5f0b" Watch "ognl.OgnlException: target is null for setProperty(null, "preventCache", [Ljava.lang.String;@6dc5f0b" New topic
Author

ognl.OgnlException: target is null for setProperty(null, "preventCache", [Ljava.lang.String;@6dc5f0b

Tony Evans
Ranch Hand

Joined: Jun 29, 2002
Posts: 573
Not sure if this is a struts problem more a OGNL problem

I am getting the following exception, I just want to understand it first.

21-Apr-2010 17:26:35 com.opensymphony.xwork2.util.logging.commons.CommonsLogger warn
WARNING: Error setting value
ognl.OgnlException: target is null for setProperty(null, "preventCache", [Ljava.lang.String;@6dc5f0ba)
at ognl.OgnlRuntime.setProperty(OgnlRuntime.java:1651)
at ognl.ASTProperty.setValueBody(ASTProperty.java:101)
at ognl.SimpleNode.evaluateSetValueBody(SimpleNode.java:177)
at ognl.SimpleNode.setValue(SimpleNode.java:246)
at ognl.ASTChain.setValueBody(ASTChain.java:172)
at ognl.SimpleNode.evaluateSetValueBody(SimpleNode.java:177)
at ognl.SimpleNode.setValue(SimpleNode.java:246)
at ognl.Ognl.setValue(Ognl.java:476)


As I understand it looking at http://www.docjar.com/html/api/ognl/OgnlRuntime.java.html

its trying to set a value Ljava.lang.String;@6dc5f0ba on a target object that if I am reading the code right has as a setter setPreventCache

Target = null
name = preventCache
value = Ljava.lang.String;@6dc5f0ba.

I am not sure how this is being called from my code.

In my struts properties I have struts.ognl.allowStaticMethodAccess=true .



 
wood burning stoves
 
subject: ognl.OgnlException: target is null for setProperty(null, "preventCache", [Ljava.lang.String;@6dc5f0b