Sorry : java.lang.NoClassDefFoundError: org/apache/tiles/TilesContext...
On 11/22/06, Sébastien LABEY <[EMAIL PROTECTED]> wrote:
David, I downloaded the struts2-core-2.0.2-SNAPSHOT-20061122.jar and the tiles-core-2.0-SNAPSHOT-20061122.jar as you told me in your previous mail, but it doesn't work too. I have exactly the same problem while starting Tomcat and initializing the Tiles listener. If I don't register the Tiles listener in the web.xml, Tomcat starts, my webapp works, but when I ask for a page build with tiles, I have a ClassDefNotFoundException on the TilesContext class... Maybe this can help you to help me ;-) Sebastien On 11/22/06, Sébastien LABEY <[EMAIL PROTECTED]> wrote: > > Hi David, > > Thank you for your answer. I did not had enough time to try it until > now, but it doesn't work. I'm quite sure I'm doing something wrong, in > particular I think I did not have the right jars. Depending on the jars > included in my /lib directory, I always have ClassNotFoundExcpetions... > As mentioned in the Tiles Plugin page, I've added in the web.xml : > > <listener> > <listener-class>org.apache.struts2.tiles.StrutsTilesListener > </listener-class> > </listener> > > and starting from the jars included in the struts-blank app, I added : > - tiles-core-2.0-r468346-SNAPSHOT.jar > - struts2-tiles-plugin-2.0.1.jar > > The tiles definition file is tiles.xml in the /WEB-INF/ directory. > > With this configuration, my Tomcat 5.5 doesn't start correctly and my > webapp is not available. In the Tomcat log, I can see that the listener had > errors while starting : > > 22 nov. 2006 23:15:04 org.apache.tiles.listener.TilesListenercontextInitialized > INFO: Initializing TilesListener > 22 nov. 2006 23:15:05 org.apache.tiles.listener.TilesListenerreadFactoryConfig > INFO: CONFIG FILES WERE NOT DEFINED IN WEB.XML, LOOKING FOR > /WEB-INF/tiles.xml > 22 nov. 2006 23:15:05 org.apache.tiles.listener.TilesListenerinitDefinitionsFactory > INFO: initializing definitions factory... > 22 nov. 2006 23:15:05 org.apache.catalina.core.StandardContext start > GRAVE: Error listenerStart > > So, please, could you tell me what I basicaly may configure and what > jars I should have (and maybe not have). If the solution is getting the > Struts2.0.2 version, where can I find it? > > Thank you in advance for your precious help. > > Sebastien > > > > > > On 11/20/06, David H. DeWolf < [EMAIL PROTECTED]> wrote: > > > > Sure. . .have you looked at: > > > > http://cwiki.apache.org/WW/tiles-plugin.html > > > > I'll be updating it shortly to take into account some of the recent > > changes in the plugin, but this should work in 2.0.1. There are a > > couple of different options if your using the snapshot. > > > > > > Also, depending on which tiles-plugin jar you "found", you may be > > depending on the tiles snapshot. There's been a lot of work on this > > since the release, and I'm wondering if you're using a snapshot > > version > > that is out of sync. I think that if you're using struts 2.0.1, > > you'll > > want the tiles 2.0-r468346-SNAPSHOT jar. If you're using struts 2.0.2 > > or later, you'll want the current tiles snapshot. Both are available > > here: > > http://people.apache.org/repo/m2-snapshot-repository/org/apache/struts/tiles/tiles-core/ > > > > > > Let me know if you need more info. > > > > > > David > > > > Sébastien LABEY wrote: > > > Hi all, > > > > > > I've been trying for the past 2 days to configure Struts2 to work > > with > > > tiles. In the Struts 2.0.1 release, I found the jar to deal with > > tiles that > > > was not included in the Struts2.0.0-SNAPSHOT release ( > > > struts2-tiles-plugin-2.0.1.jar), but in the end I can't resolve this > > error > > > that is launched when I try to access a link with result of type > > "tiles" : > > > * > > > java.lang.NullPointerException* > > > > > > > > > org.apache.struts2.views.tiles.TilesResult.getComponentDefinition( > > TilesResult.java:162) > > > > > > > > > org.apache.struts2.views.tiles.TilesResult.doExecute ( > > TilesResult.java:116) > > > > > > org.apache.struts2.dispatcher.StrutsResultSupport.execute( > > StrutsResultSupport.java:175) > > > > > > > > > com.opensymphony.xwork2.DefaultActionInvocation.executeResult( > > DefaultActionInvocation.java :309) > > > > > > > > > com.opensymphony.xwork2.DefaultActionInvocation.invoke( > > DefaultActionInvocation.java:218) > > > > > > > > > > > com.opensymphony.xwork2.interceptor.DefaultWorkflowInterceptor.doIntercept > > (DefaultWorkflowInterceptor.java :177) > > > > > > ... > > > > > > > > > Could someone tell me what jars I exactly need to use tiles with > > struts 2 > > > and the files that I need to configure and how? > > > Thanks very much in advance. > > > > > > Sebastien > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > >