jQuery in Action, 2nd edition*
The moose likes Struts and the fly likes Help with deploying/configuration Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Help with deploying/configuration" Watch "Help with deploying/configuration" New topic
Author

Help with deploying/configuration

Duran Harris
Ranch Hand

Joined: Nov 09, 2008
Posts: 598

Hi all,

I'm getting a filterStart error when I try to start Tomcat and deploy my 1st struts application.Apparently the problem is in configuration of my web-app....Here is a tree of my DBTest web- app:
├───DBTest
│ ├───DBTest
│ └───WEB-INF
│ ├───classes
│ │ └───DBTest
│ └───lib

The lowest DBTest folder in the tree contains test4.jsp...A jsp I am trying to hit using an empty action..
This is my package declaration in struts.xml(struts.xml is in \DBTest\WEB-INF\classes):


And (most) of my web.xml(web.xml is in \DBTest\WEB-INF\):


I just want to enter http://localhost:8080/DBTest/tester.action and use the empty action to hit test4.jsp.This would be like hitting the test4.jsp directly?I also tried making an action class but it can't find package org.apache.action.Action...I have all the necessary JARs in the DBTest web-app's lib folder:
commons-fileupload-1.2.1.jar
commons-io-1.3.2.jar
commons-logging-1.0.4.jar
commons-logging-api-1.1.jar
freemarker-2.3.13.jar
ognl-2.6.11.jar
struts2-core-2.1.6.jar
xwork-2.1.2.jar

Maybe it's my classpath...I have set my classpath to apache\common\lib..Which also contains the above jars(and the others)...
Any tips?

===>SCJP 1.5(72%)<===
==>SCWCD1.5(76%)<===
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

You get a filter start error with no stacktrace?
Duran Harris
Ranch Hand

Joined: Nov 09, 2008
Posts: 598

Is this it:
org.Apache.catalina.core.StandardContext start
[SEVERE]:Error filterStart
org.Apache.catalina.core.StandardContext start
[SEVERE]:Context [\DBTest] startup failed due to previous errors


I took that output directly from the Tomcat console(not the logs) if that makes a difference.
And if I try to compile the action class I get the following:
tester.java:2: package org.apache.struts.action does not exist
import org.apache.struts.action.Action;
^
tester.java:3: cannot find symbol
symbol: class Action
public class tester implements Action
^
2 errors
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Are you saying you're not able to compile the action class? What are you deploying, then?
Duran Harris
Ranch Hand

Joined: Nov 09, 2008
Posts: 598

My struts is not working at all...The Struts2InAction.war that I deployed doesn't even work...But I thought this application contains all the dependancies it needs...so how could I have stopped it from working(I redownloaded the sample application to make sure that I hadn't edited any of the files)I no longer get struts errors when I try to run the application either.....just the regular tomcat errors...
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

Without knowing anything about how you're deploying it, what URLs you're using to access it, and so on, it's difficult to help.
Duran Harris
Ranch Hand

Joined: Nov 09, 2008
Posts: 598

Ok well this is definitely an installation problem..I'm going to reinstall tomcat and struts
David Newton
Author
Rancher

Joined: Sep 29, 2008
Posts: 12617

I find it unlikely it's a Tomcat installation issue; that's a matter of unzipping the distro. One doesn't really "install" Struts, but it could be an issue with how you tried to deploy the application (normally just putting the war file into the "webapps" directory is sufficient--by default Tomcat will deploy war files found there).
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Help with deploying/configuration
 
Similar Threads
ERROR convention.PackageBasedActionConfigBuilder - Unable to load class
Struts2 with RAD7
struts2 + Json and JQuery.
Exception in Struts2
Struts2 config error