- This topic has 11 replies, 6 voices, and was last updated 21 years, 5 months ago by
Riyad Kalla.
-
AuthorPosts
-
mrzeldMemberok. i have two web projects currenlty. i am wanting to create some objects that will be used by both of these projects. so i created a third project (plain java project). this third project will create a jar file that needs to be placed into the WEB-INF/lib directories of the two original web projects. how do i get this jar there using ME?
the web projects compile fine in eclipse (i set those projects to depend on the third project). but nothing is being put into the WEB-INF/lib or WEB-INF/classes directory on the web server for either web project. so the web apps don’t work when you access them on the web server.
thanks!
February 9, 2004 at 4:57 am #203073
Bill WinspurMemberRight click on the WEB-INF/lib/ directory in the navigator pane and pick the import menu item.
Pick the filesystem source in the resulting import wizard and click next
Click the browse button
Use the import directory dialog to navigate to the directory that has your jar file and click OK
In the right hand pane, of the wizard check the box next to your jar file and clik finish.Your jar should be transferred to WEB-INF/lib/
February 9, 2004 at 11:30 am #203082
mrzeldMemberthanks for the suggestion, but it doesn’t solve the problem. doing the import, copies the jar file to the WEB-INF/lib directory in eclipse. and that is it. if i make changes to the jar file then i have to re-import into all my webprojects? there has to be a better way to do this. i can’t be the only person that has wanted to do this.
i could create seperate jar desciptions in the java project and create each into the webapp’s lib directory (inside the tomcat folder) directly , but that isn’t pretty. or is it?
February 17, 2004 at 9:30 am #203455
wattypMemberI have the same question…
Is there a way to auto build and link dependent utility jars in web projects, or is the tool deficient in this respect?
[yes] then this needs to be added to the feature list IMHO PDQ!
plus is there any type of workaround
[no] show us how to do it
regards,
Paul.
February 17, 2004 at 9:31 am #203456
wattypMembermmm, got my no’s and yes’s the wrong way around 🙂
February 17, 2004 at 9:36 am #203458
wattypMembersorry, ignore, just read another post indicating it will be an enhancement in 2.7
February 17, 2004 at 9:40 am #203459
mrzeldMemberwattyp,
can you post the link to the other post?February 17, 2004 at 9:52 am #203461
wattypMemberhttps://www.genuitec.com/forums/topic/library-files-in-a-web-project-enhancement/
although, it doesn’t solve anything at the moment…
AFAIS there is also no way to create an utility project that creates an .jar archive as part of the build process automagically, or have I missed something? (apart from using the one shot export menu).
The list of tasks for each new build of an web project utility jar I see as:
1. (re)build utility project
2. manually export a jar to /WEB-INF/lib of all dependent projects
3. once only: add to build path within each of dependent projects this new jar
4. deploy web projects
Do you agree?
Paul.
February 17, 2004 at 9:56 am #203462
mrzeldMemberi believe the “hard-to-swallow” solution to this is to edit the build.xml file yourself and make it happen. but for those of us less gifted in the art of ANT, it would be nice for such functionality to be included by ME in some way.
i have enough to learn right now, ANT isn’t up there on the list yet.
thanks
February 18, 2004 at 9:17 pm #203554
Scott AndersonParticipantWe’ll be adding support for dependent utility projects as part of 2.8. That will allow you to specify projects that should be packaged as jars when your application is deployed. I think this is what you’re after.
February 20, 2004 at 12:55 am #203598
James I. FalekMember💡 One work-around (prior to ME 2.8 ) is to add the jars/class directories to the application server paths ( preferences>My Eclipse>Application Servers><<server>>paths ) . It is not pretty, but it may do the trick for you.
February 20, 2004 at 8:26 am #203606
Riyad KallaMemberGSX thanks for the followup, I’m sure other users will find it helpful.
-
AuthorPosts