Re: very strange error with xwork.xml

Jesse Miller <[email protected]>
Newsgroups gmane.comp.java.open-symphony.webwork
Message-ID <25846572.1165349768400.JavaMail.os-j2ee@opensymphony01.managed.contegix.com>
OK, so we upgraded our local server and couldn't recreate the problem until we upgraded xml-commons, xml-commons-api and xerces-j2.  So the problem seems to at least be affected by these.

One I had the problem recreated I downgraded to WW 2.2.2 and tried out the same action.  It ended up throwing the same exception but with a couple before it.  Here is the stack trace:
[code]
exception

javax.servlet.ServletException: Could not execute action
	com.paxfood.hibernate.HibernateOpenSessionInViewFilter.doFilter(Ljavax/servlet/ServletRequest;Ljavax/servlet/ServletResponse;Ljavax/servlet/FilterChain;)V(HibernateOpenSessionInViewFilter.java:40)

root cause

javax.servlet.ServletException: Could not execute action
	com.opensymphony.webwork.dispatcher.DispatcherUtils.serviceAction(Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletResponse;Ljavax/servlet/ServletContext;Lcom/opensymphony/webwork/dispatcher/mapper/ActionMapping;)V(DispatcherUtils.java:246)
	com.opensymphony.webwork.dispatcher.FilterDispatcher.doFilter(Ljavax/servlet/ServletRequest;Ljavax/servlet/ServletResponse;Ljavax/servlet/FilterChain;)V(FilterDispatcher.java:198)
	com.opensymphony.module.sitemesh.filter.PageFilter.parsePage(Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletResponse;Ljavax/servlet/FilterChain;)Lcom/opensymphony/module/sitemesh/Page;(PageFilter.java:118)
	com.opensymphony.module.sitemesh.filter.PageFilter.doFilter(Ljavax/servlet/ServletRequest;Ljavax/servlet/ServletResponse;Ljavax/servlet/FilterChain;)V(PageFilter.java:52)
	com.opensymphony.webwork.dispatcher.ActionContextCleanUp.doFilter(Ljavax/servlet/ServletRequest;Ljavax/servlet/ServletResponse;Ljavax/servlet/FilterChain;)V(ActionContextCleanUp.java:78)
	com.paxfood.hibernate.HibernateOpenSessionInViewFilter.doFilter(Ljavax/servlet/ServletRequest;Ljavax/servlet/ServletResponse;Ljavax/servlet/FilterChain;)V(HibernateOpenSessionInViewFilter.java:30)

root cause

java.lang.NullPointerException
	com.opensymphony.xwork.util.TextParseUtil.translateVariables(CLjava/lang/String;Lcom/opensymphony/xwork/util/OgnlValueStack;Ljava/lang/Class;Lcom/opensymphony/xwork/util/TextParseUtil$ParsedValueEvaluator;)Ljava/lang/Object;(TextParseUtil.java:104)
	com.opensymphony.xwork.util.TextParseUtil.translateVariables(Ljava/lang/String;Lcom/opensymphony/xwork/util/OgnlValueStack;)Ljava/lang/String;(TextParseUtil.java:34)
	com.opensymphony.xwork.ActionChainResult.execute(Lcom/opensymphony/xwork/ActionInvocation;)V(ActionChainResult.java:131)
	com.opensymphony.xwork.DefaultActionInvocation.executeResult()V(DefaultActionInvocation.java:311)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:206)
	com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(AroundInterceptor.java:31)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.opensymphony.xwork.interceptor.DefaultWorkflowInterceptor.doIntercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(DefaultWorkflowInterceptor.java:168)
	com.opensymphony.xwork.interceptor.MethodFilterInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(MethodFilterInterceptor.java:86)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.paxfood.operations.OperationsContextInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(OperationsContextInterceptor.java:32)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.opensymphony.xwork.validator.ValidationInterceptor.doIntercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(ValidationInterceptor.java:115)
	com.opensymphony.xwork.interceptor.MethodFilterInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(MethodFilterInterceptor.java:86)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(AroundInterceptor.java:31)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(AroundInterceptor.java:31)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(AroundInterceptor.java:31)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.opensymphony.xwork.interceptor.AroundInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(AroundInterceptor.java:31)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.paxfood.hibernate.cache.CacheSyncInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(CacheSyncInterceptor.java:37)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.paxfood.hibernate.HibernateTransactionInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(HibernateTransactionInterceptor.java:77)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.paxfood.operations.AdminLoginInterceptor.intercept(Lcom/opensymphony/xwork/ActionInvocation;)Ljava/lang/String;(AdminLoginInterceptor.java:33)
	com.opensymphony.xwork.DefaultActionInvocation.invoke()Ljava/lang/String;(DefaultActionInvocation.java:188)
	com.opensymphony.xwork.DefaultActionProxy.execute()Ljava/lang/String;(DefaultActionProxy.java:113)
	com.opensymphony.webwork.dispatcher.DispatcherUtils.serviceAction(Ljavax/servlet/http/HttpServletRequest;Ljavax/servlet/http/HttpServletResponse;Ljavax/servlet/ServletContext;Lcom/opensymphony/webwork/dispatcher/mapper/ActionMapping;)V(DispatcherUtils.java:233)
	com.opensymphony.webwork.dispatcher.FilterDispatcher.doFilter(Ljavax/servlet/ServletRequest;Ljavax/servlet/ServletResponse;Ljavax/servlet/FilterChain;)V(FilterDispatcher.java:198)
[/code]

Again, I changed the action from:
[code]
      <action name="updateEmailBlast" class="com.paxfood.action.UpdateEmailBlast">
         <result name="success" type="chain">listAllEmailBlasts</result>
      </action>
[/code]

to:
[code]
      <!-- useless comment -->
      <action name="updateEmailBlast" class="com.paxfood.action.UpdateEmailBlast">
         <result name="success" type="chain">listAllEmailBlasts</result>
      </action>
[/code]

and the action works......

any ideas?
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.opensymphony.com/thread.jspa?threadID=52170&messageID=105373#105373

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.