- This topic has 4 replies, 3 voices, and was last updated 19 years, 10 months ago by Tony Herstell.
-
AuthorPosts
-
Lorenzo JimenezMemberHi,
Eclipse4Web had a nice feature that can import a Struts 1.2 application.
Does MyEclipse has the same capability?Thanks,
Lorenzo Jimenez
Riyad KallaMemberLorenzo,
At this time we do not provide import functionality for web apps, sorry for the inconvenience.
Lorenzo JimenezMember@support-rkalla wrote:
Lorenzo,
At this time we do not provide import functionality for web apps, sorry for the inconvenience.Do you have a time frame?
Thanks,
Lorenzo
Riyad KallaMemberSorry, no.
Tony HerstellParticipantStarting with a EasyStuts project (1.1 Struts, Tomcat 5.0, MySql) I have “moved” this across to MyEclipse.
First installed Tomcat 5.5 (basically as I wanted to set up apache-tomcat mod-jk), then MyEclipse, then linked them together, then linked them into MySQL (including fixing the new format for the connection pooling under Tomcat), then downloaded from CVS (once the server came back after the fire) the source and that worked ok. {breath}
The source ran up ok (i Think), and all was well, but I wanted to see what myeclipse had to offer in the way esay struts does in making it really easy to create new action etc. so I pressed on trying to make MyEclipse treat the project as a Struts project (as it kept saying it was not a struts project when I tried to view the struts-config.
So…
I then made the project a Web project in MyEclipse (as per the myEclipse help (which I HAD to resort to as I could not find ANY menu options about Struts!) on starting a Struts project, and this worked by adding in a NEW folder called J2EE 1.4 Library Container (and making a new menu option appear called Add Struts Capability!) containing a lot of Jars I already had (So for now I have both till I bother to fix this).
I then, outside MyEclipse, updated my source to struts 1.2 by dropping in the right jars and .tlds and had to solve a lot of renaming of Action Errors etc. and it all worked ok apart from this error reported in MyEclipse which I can’t figure out:
1 Run-time exception java.lang.InternalError occurred during validation. The validator being run was JSP Validator and the message thrown was jzentry == 0,
jzfile = 68463040,
total = 189,
name = C:\eclipse\workspace\justhorses\WEB-INF\lib\commons-collections.jar,
i = 3,
message = invalid LOC header (bad signature). justhorses 12 March 2005 22:25:01As this was a dropped in jar I have no idea why It woudl fail .jsp validation nd frankly don’t really care unless it impacts my code.
However, regardless to this, things still seem to work when I run it, so I might get round to this one day too.
I then tried to add struts capabilites using the new menu option (as per the help page on creating a struts project) which cleverly sees all 29 existing actions etc. and this works FINE if I select struts 1.1. (I just unticked the fact I wanted it to drop in the xtra jars/tlds as I already had them and didnt know how Old myeclipses were)… and then I can view the struts-config in the designer layout.
However, if I select 1.2 I get a problem that I cannot figure out where it says:
Invalid struts 1.2 config file found.
org.jdom.JDOMException:Error on line 3:Element type “struts-config” must be declared. :Error on line 3:Element type “struts-config” must be declared.Now this same eror appears when I select 1.0 or 1.2 but not 1.1… I have compared the struts-config file created with a NEW 1.2 Struts project under MyEclipse with my struts-config and can find NO probelms.
So for now I select 1.1 Struts (for my 1.2 struts project) and just tell it not to copy in files and hope that there is not really anything in MyEclipse theat actaully depends on the difference between 1.1 and 1.2.
So…. This is how I imported an existing Struts project.
If any of this helps then great; and if not then at least I tried more than
some people have.:/
Now.. lets see how MyEclipse caompares to EasyStruts… I have NOT deleted my old installs of Eclipse with Easy Struts in case its easier with easyStruts to create new actions with forwards etc. still.
-
AuthorPosts