- This topic has 35 replies, 10 voices, and was last updated 20 years, 5 months ago by Riyad Kalla.
-
AuthorPosts
-
support-michaelKeymasterThere is a problem with your project structure. MyEclipse does not allow a WebProject to serve as the web-root folder. Instead you must create a web-root folder with in webProject. The web-root folder is organized as an exploded WAR.
Here is what I did after downloading and unzipping the StrutsSample.zip.
1) Create a new ME WebProject named MyStrutsSample and point the wizard to the StrutsSample folder created from unzipping StrutsSample.zip.
2) Next rearrage the project’s files and folders using drag-drop from the Package Explorer into the exploded war structure rooted under the web-root folder:
/MySampleStruts
/MySampleStruts/src
/MySampleStruts/web-root <– JSP folder
/MySampleStruts/web-root/META-INF
/MySampleStruts/web-root/WEB-INF/struts-config.xml
/MySampleStruts/web-root/WEB-INF/web.xml
/MySampleStruts/web-root/WEB-INF/*.tld
/MySampleStruts/web-root/WEB-INF/classes
/MySampleStruts/web-root/WEB-INF/lib3) I added Struts Capabilities to the project. During the process the wizard detected the existing struts action and form.
4) I deployed the project to Tomcat5, started Tomcat5, and invoke http://localhost:8080/MyStrutsSample/ and boom the login-form is displayed.
Note-1: The Add Struts Capabilities did not identify the orielly ActionServlet and added a second entry. I manually removed the second ActionServlet from the web.xml file using the ME XML editor. This problem has been fixed in the current codebase and will be part of the next release.
Note-2: Requiring an explicit web-root folder clearly deliniates the web-app’s deployment content from other project artifacts. Our initial decision to use this model was based on similar requirements of IDE’s such as WSAD and JBuilder ver something (not sure if it still applies). We are working on a model that allows users to make their physical project structure to a logical version of the web-root folder.
Kyle AdamsMemberI don’t think that’s the problem. I’ll try to be a little more clear on the project structure in the example webApp I set up:
/StrutsPartII
/StrutsPartII/src
/StrutsPartII/StrutsSample <– JSP folder
/StrutsPartII/StrutsSample/META-INF
/StrutsPartII/StrutsSample/WEB-INF/struts-config.xml
/StrutsPartII/StrutsSample/WEB-INF/web.xml
/StrutsPartII/StrutsSample/WEB-INF/*.tld
/StrutsPartII/StrutsSample/WEB-INF/classes
/StrutsPartII/StrutsSample/WEB-INF/libAs you can see, StrutsPartII (my my project’s base directory) is not the same directory as the one I selected as the web-root directory (StrutsSample). My web-root is indeed an exploded WAR, and the project follows the exact same layout (with different names) as you listed.
The test case I went through gave all directories relative to the project’s base directory (StrutsPartII). Since posting it, I’ve duplicated the problem on other Windows 2000 machines running clean installs of Eclipse 3.0M7 and MyEclipse 3.7.1.
support-michaelKeymasterSorry, about the project structure misunderstanding. I’ll run back through and test it again exactly as you specify in your description.
jazzfeiglingMemberAny luck on fixing this one? I’m having the problem as well on an existing project. I erased everything and started over with a fresh install of M8, but same problem, just as described.
support-michaelKeymasterAre you seeing error messages related to the “org.apache.commons.logging.LogConfigurationException: …” at the top of this thread? We recently isolated and resolved a bug related to internal log configuration problem. This fix will be in the next ME release. Here is a possible workaround procedure until the next ME release:
Add the following bold text to the end of your Eclipse/MyEclipse commandline. It uses the -D option to specify a logFactory. Enter the
-vmargs -Dorg.apache.commons.logging.LogFactory=
org.easystruts.struts.config.EasyStrutsLogFactoryIf your commandline already uses the -vmargs option for other JVM args then omit its use here. Also the editor unintentionally wrapped the statement. Please enter it w/o the break at the “=”.
maddesaMemberThis message has not been recovered.
Riyad KallaMemberThis message has not been recovered.
maddesaMemberThis message has not been recovered.
Riyad KallaMemberThis message has not been recovered.
maddesaMemberThis message has not been recovered.
Riyad KallaMemberThis message has not been recovered.
maddesaMemberThis message has not been recovered.
maddesaMemberThis message has not been recovered.
Scott AndersonParticipantThis message has not been recovered.
jsissomMemberWhere do I find this log file? I’m running on Mac OSX and I can’t edit my struts-config.xml file. When I try to add struts support, I get a dialog box that says this:
Invalid struts 1.0 config file found.
org.apache.commons.logging.LogconfigurationException:
java.lang.ClassNotFoundException:
org.easystruts.struts.config.EasyStrutsLogFactory:
java.lang.ClassNotFoundException:
org.easystruts.struts.config.EasyStrutsLogFactoryI have a valid Struts 1.1 config file. No matter what I do, I can’t add Struts support to my project and I can’t edit my struts config file using Eclipse.
-
AuthorPosts