- This topic has 2 replies, 2 voices, and was last updated 20 years, 5 months ago by Walter Riley.
-
AuthorPosts
-
Walter RileyMemberI am running the cardemo and components JSF examples from the JWSDP 1.3 in MyEclipse 3.8beta1 and Tomcat 5.0.19 If you are not familiar with this example, the cardemo web project references classes in the components web project. I added the components/web/WEB-INF/classes Class Folder to the cardemo project by using cardemo-Properties-Java Build Path-Libraries-Add Class Folder. This is very similar to the way external jars can be added to the web project. The ‘web/WEB-INF/classes – components’ folder then appears in the cardemo project and the cardemo app builds fine.
The problem is that unlike external jars, the external ‘web/WEB-INF/classes – components’ folder does not deploy with the cardemo app. When I manually deploy this external classes folder by copying the ‘components’ folder from components/WEB-INF/classes to cardemo/WEB-INF/classes before starting Tomcat, the cardemo app works fine. (I hope that using ‘components’ for both the project name and a package name has not been too confusing.)
Walter
Scott AndersonParticipantWalter,
It’s not the name that’s the problem. The dependent project support in Beta 1 specifically supports Java project dependencies. So if you have a Web project that lists a Java project on its build path, then that Java project’s classes can be configured for deployment. In the example you’ve given, is the components web project really a web application all by itself, or does it just contain Java? If it is a full web application, I’d suggest creating a new plain Java project to contain common classes that are used by both the components project and the cardemo project and then referencing the new Java project from both web projects build paths, which will enable the new project’s classes to be deployed with each web project. On the other hand, if the components project really isn’t a web project you can simply create a new version of the project as a simple Java project and copy all the code into it (there’s no way to remove web project capabilities). Then you can reference this new Java project version of components from the cardemo project directly and deployment will then be possible.
Walter RileyMemberScott,
I thought the name might make the description of the problem confusing, not that it was the problem. 🙂
Both cardemo and components are full ‘Sun-created’ web apps. I’m just trying to plug them into MyEclipse. The components app demonstrates several of Sun’s custom JSF web components. The cardemo app uses only a couple of the components demoed in the components app.
The dependent project does not grab the class files from the project on which it depends and deploy them along with its own class files, even though the dependent project builds ok as long as the dependency is noted in the project’s properties.
I guess I’m missing something here. Are you sure this issue has been adressed in the beta? You’re not saying that that it should work for dependencies on plain java projects and not on other web projects, are you?
Thanks,
Walter -
AuthorPosts