You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Heikki Hyyrö <he...@tuni.fi> on 2024/10/01 10:38:26 UTC

Tiles errors in Struts versions > 6.3.0.2

Our web application based on Struts 2 + Tiles framework starts to give 
errors on some jsp pages if I try to use a newer Struts version than 
6.3.0.2.

Exactly the same codebase works fine on previous Struts versions (the 
only changes are in the pom file and concern the versions of 
struts2-core, struts2-tiles-plugin, struts2-config-browser-plugin and 
strutrs2-json-plugin).

On 6.6.0 the stacktrace has snippets like:

> Caused by: org.apache.tiles.request.render.CannotRenderException: 
> java.io.IOException: JSPException including path 'xyz.jsp'.
>     at 
> org.apache.tiles.core.impl.BasicTilesContainer.render(BasicTilesContainer.java:395)
> ...
> Caused by: java.io.IOException: java.io.IOException: JSPException 
> including path 'xyz.jsp'.
>     at 
> org.apache.tiles.request.servlet.ServletUtil.wrapServletException(ServletUtil.java:56)
>     at 
> org.apache.tiles.request.jsp.JspRequest.doInclude(JspRequest.java:118)
> ...
> Caused by: java.lang.NullPointerException
>     at 
> org.apache.struts2.components.IteratorComponent.start(IteratorComponent.java:309)
>     at 
> org.apache.struts2.views.jsp.ComponentTagSupport.doStartTag(ComponentTagSupport.java:51)
where xyz is a path to a jsp file of ours.

Curiously, Struts 6.4.0 stacktrace for the very same page gives a 
different error:

> HTTP ERROR 500 Cannot find definition named 'nodeGradesView.page'
> Caused by: org.apache.tiles.core.definition.NoSuchDefinitionException: 
> Cannot find definition named 'xyz.page'
>     at 
> org.apache.tiles.core.impl.mgmt.CachingTilesContainer.render(CachingTilesContainer.java:108)
> ...

where xyz.page is a tiles definition of the view that xyz.jsp would 
belong to.

These errors are a bit cumbersome and have left as stuck at Struts 
version 6.3.0.2.

Best regards

Heikki


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org


Re: Tiles errors in Struts versions > 6.3.0.2

Posted by 哈哈哈哈 <ya...@gmail.com>.
There is a bug cause the error you get at 6.4.0

https://issues.apache.org/jira/plugins/servlet/mobile#issue/WW-5419

You can set init param at web.xml or change where you store tiles.xml to
fix issue if you want to use 6.4.0


But Im not sure what cause you get error at 6.6.0

You might need turn struts.xml devMode to true and open log to trace  for
more detail

Maybe other people can help you

Best regards

Heikki Hyyrö <he...@tuni.fi> 於 2024年10月1日 週二 下午6:38 寫道:

> Our web application based on Struts 2 + Tiles framework starts to give
> errors on some jsp pages if I try to use a newer Struts version than
> 6.3.0.2.
>
> Exactly the same codebase works fine on previous Struts versions (the
> only changes are in the pom file and concern the versions of
> struts2-core, struts2-tiles-plugin, struts2-config-browser-plugin and
> strutrs2-json-plugin).
>
> On 6.6.0 the stacktrace has snippets like:
>
> > Caused by: org.apache.tiles.request.render.CannotRenderException:
> > java.io.IOException: JSPException including path 'xyz.jsp'.
> >     at
> >
> org.apache.tiles.core.impl.BasicTilesContainer.render(BasicTilesContainer.java:395)
> > ...
> > Caused by: java.io.IOException: java.io.IOException: JSPException
> > including path 'xyz.jsp'.
> >     at
> >
> org.apache.tiles.request.servlet.ServletUtil.wrapServletException(ServletUtil.java:56)
> >     at
> > org.apache.tiles.request.jsp.JspRequest.doInclude(JspRequest.java:118)
> > ...
> > Caused by: java.lang.NullPointerException
> >     at
> >
> org.apache.struts2.components.IteratorComponent.start(IteratorComponent.java:309)
> >     at
> >
> org.apache.struts2.views.jsp.ComponentTagSupport.doStartTag(ComponentTagSupport.java:51)
> where xyz is a path to a jsp file of ours.
>
> Curiously, Struts 6.4.0 stacktrace for the very same page gives a
> different error:
>
> > HTTP ERROR 500 Cannot find definition named 'nodeGradesView.page'
> > Caused by: org.apache.tiles.core.definition.NoSuchDefinitionException:
> > Cannot find definition named 'xyz.page'
> >     at
> >
> org.apache.tiles.core.impl.mgmt.CachingTilesContainer.render(CachingTilesContainer.java:108)
> > ...
>
> where xyz.page is a tiles definition of the view that xyz.jsp would
> belong to.
>
> These errors are a bit cumbersome and have left as stuck at Struts
> version 6.3.0.2.
>
> Best regards
>
> Heikki
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>
>

Re: Tiles errors in Struts versions > 6.3.0.2

Posted by Lukasz Lenart <lu...@apache.org>.
It is probably related to this issue
https://issues.apache.org/jira/browse/WW-5451

wt., 1 paź 2024 o 12:39 Heikki Hyyrö <he...@tuni.fi> napisał(a):
>
> Our web application based on Struts 2 + Tiles framework starts to give
> errors on some jsp pages if I try to use a newer Struts version than
> 6.3.0.2.
>
> Exactly the same codebase works fine on previous Struts versions (the
> only changes are in the pom file and concern the versions of
> struts2-core, struts2-tiles-plugin, struts2-config-browser-plugin and
> strutrs2-json-plugin).
>
> On 6.6.0 the stacktrace has snippets like:
>
> > Caused by: org.apache.tiles.request.render.CannotRenderException:
> > java.io.IOException: JSPException including path 'xyz.jsp'.
> >     at
> > org.apache.tiles.core.impl.BasicTilesContainer.render(BasicTilesContainer.java:395)
> > ...
> > Caused by: java.io.IOException: java.io.IOException: JSPException
> > including path 'xyz.jsp'.
> >     at
> > org.apache.tiles.request.servlet.ServletUtil.wrapServletException(ServletUtil.java:56)
> >     at
> > org.apache.tiles.request.jsp.JspRequest.doInclude(JspRequest.java:118)
> > ...
> > Caused by: java.lang.NullPointerException
> >     at
> > org.apache.struts2.components.IteratorComponent.start(IteratorComponent.java:309)
> >     at
> > org.apache.struts2.views.jsp.ComponentTagSupport.doStartTag(ComponentTagSupport.java:51)
> where xyz is a path to a jsp file of ours.
>
> Curiously, Struts 6.4.0 stacktrace for the very same page gives a
> different error:
>
> > HTTP ERROR 500 Cannot find definition named 'nodeGradesView.page'
> > Caused by: org.apache.tiles.core.definition.NoSuchDefinitionException:
> > Cannot find definition named 'xyz.page'
> >     at
> > org.apache.tiles.core.impl.mgmt.CachingTilesContainer.render(CachingTilesContainer.java:108)
> > ...
>
> where xyz.page is a tiles definition of the view that xyz.jsp would
> belong to.
>
> These errors are a bit cumbersome and have left as stuck at Struts
> version 6.3.0.2.
>
> Best regards
>
> Heikki
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
> For additional commands, e-mail: user-help@struts.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@struts.apache.org
For additional commands, e-mail: user-help@struts.apache.org