Hi,
I want to upgrade my application to Struts 2.2.3 from struts 1.1. I want to migrate this on shared resource basis i.e. running both Struts1 and struts2 in parallel each handling different action extension (*.action and *.do). Though i could successfully created the Struts2 action class and request is getting routed correctly but i am facing problems with re-using struts-tiles. I added below lines in web.xml
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
</filter>
<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>*.action</url-pattern>
</filter-mapping>
<context-param>
<param-name>org.apache.tiles.impl.BasicTilesContainer.DEFINITIONS_CONFIG</param-name>
<param-value>/WEB-INF/tiles-defs.xml</param-value>
</context-param>
<listener>
<listener-class>org.apache.tiles.extras.complete.CompleteAutoloadTilesListener</listener-class>
</listener>

But it is throwing below action while forwarding request from struts2 action to tile.

org.apache.tiles.impl.InvalidTemplateException: Cannot render a null template
        
org.apache.tiles.renderer.impl.TemplateAttributeRenderer.write(TemplateAttributeRenderer.java:51)
        
org.apache.tiles.renderer.impl.AbstractBaseAttributeRenderer.render(AbstractBaseAttributeRenderer.java:106)
        
org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:670)
        
org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:690)
        
org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:644)
        
org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:627)
        
org.apache.tiles.impl.BasicTilesContainer.render(BasicTilesContainer.java:321)
        
org.apache.struts2.views.tiles.TilesResult.doExecute(TilesResult.java:105)
        
org.apache.struts2.dispatcher.StrutsResultSupport.execute(StrutsResultSupport.java:186)
        
com.opensymphony.xwork2.DefaultActionInvocation.executeResult(DefaultActionInvocation.java:373)
        
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:277)
        
com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept(DefaultWorkflowInterceptor.java:176)
        
com.opensymphony.xwork2.interceptor.MethodFilterInterceptor.intercept(MethodFilterInterceptor.java:98)
        
com.opensymphony.xwork2.DefaultActionInvocation.invoke(DefaultActionInvocation.java:248)
        
com.opensymphony.xwork2.validator.ValidationInterceptor.doIntercept(ValidationInterceptor.java:263)



After couple of search i found there is a struts1 -tiles2 plugin available but it seems to be compatible with struts1.3.

Any help or pointer would be helpful.
Thanks in advance

Best regards,
Sachin Lale

Reply via email to