Deploying as an EAR containing Web and EJB projects should not result in problem you are observing since the EAR classloaders know how to set up the WAR->EJB dependencies. This is the default model of MyEclipse. However the model you describe is not an EAR deployment but rather two separate deployements, an EJB project deployment to server A (ejb.jar) and a Web project deployment (web.war) to server B. At this time the MyEclipse deployment packager is not able to identify and package the service tier client-side dependent classes required by a Web Project for this scenario. The resolution is to use a custom Ant script to do the WAR’s packaging since this is two separate deployments which MyEclipse does not support.
Also, libraries on the build path are not considered part of a deployment. For web project deployment only the contents under the web-root (e.g., <webroot>/WEB-INF/lib) are included in the deployment. We have a concept known as a “dependent project” under development that will support jar packaging of specially marked Java/MyEclipse projects as part of the deployment process of a Web, EJB, or EAR project.
I hope this helps.
Michael
MyEclipse Support