File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Struts and the fly likes Unable to load configuration - struts-plugin.xml on Struts 2 startup Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Spring in Action this week in the Spring forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Unable to load configuration - struts-plugin.xml on Struts 2 startup" Watch "Unable to load configuration - struts-plugin.xml on Struts 2 startup" New topic
Author

Unable to load configuration - struts-plugin.xml on Struts 2 startup

Sebastian Janisch
Ranch Hand

Joined: Feb 23, 2009
Posts: 1183
Hey everybody,

I have started to work with the Struts2 framework. I'm totally new to struts.

So, I downloaded the distribution, and whatever was in the lib folder i copied to my tomcat lib folder.

In the web.xml i added the following filter:



now, upon server startup, i get the following error



the jar exists in the lib folder, so i am not quite sure what to do now.

thanks for help :-)

JDBCSupport - An easy to use, light-weight JDBC framework -
Sebastian Janisch
Ranch Hand

Joined: Feb 23, 2009
Posts: 1183
i have managed to get rid of this error by deleting the code-behind plugin from the lib ..
the question though is why ??

now, however, i have the next error relating to the spring framework that could not be loaded

looks like this:

David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Don't just randomly copy libraries into your application: in particular, Struts 2 plugins introduce their own dependencies, configuration requirements, etc.

Remove all plugins (and associated libraries) you're not using.
Sebastian Janisch
Ranch Hand

Joined: Feb 23, 2009
Posts: 1183
hey,

i removed all unneccessary jars.

i ended up with
  • commons-logging
  • freemarker
  • ognl
  • struts2-core
  • xwork


  • now the server complains about the missing struts-default.xml file...
    David Newton
    Author
    Rancher

    Joined: Sep 29, 2008
    Posts: 12617

    Which version of S2? Where is your Tomcat deployed?

    (At one point I recall an issue about deploying to directories w/ spaces in the name--try a non-spaced Tomcat deploy directory as a sanity-check.) Other than that I can't think of anything off the top of my head; I'm running under that environment just fine on three different OSs.
     
    I agree. Here's the link: http://aspose.com/file-tools
     
    subject: Unable to load configuration - struts-plugin.xml on Struts 2 startup