- This topic has 5 replies, 3 voices, and was last updated 12 years, 3 months ago by support-tony.
-
AuthorPosts
-
yqianMemberHello,
I am currently using MyEclipse 10.1, this week I checked out a project from subversion repository, MyEclipse pop up a window prompt me to update the project working with MyEclipse 9 and later, I clicked update and build the project. And the build was success. I got war file in target folder.
The problem is after I deploy the war file to Tomcat, Tomcat could not be able to deploy this war file, the error message is something like
The import org.apache cannot be resolved The import org.slf4j cannot be resolved ....
seems Tomcat cannot find any dependent jar files, I went to $CATALINA_HOME/webapps/project/WEB-INF/lib, all the jar files are there.
I ran svn and mvn command, checkout, build and deploy the project from console, Tomcat started without any problem, then I used Eclipse JUNO, check out the project, build and deploy, Tomcat also started without any problem. All these make me believe that MyEclipse altered project settings cause the Tomcat deployment failure.
MyEclipse licensed for the development team, we are not suppose to use Eclipse as our IDE, I did not have this problem with older MyEclipse version, 8.6 or older, I just recently upgraded to 10.
I think this problem is maven related, maybe Maven4MyEclipse? so I apologize if I put this topic in wrong place.
support-swapnaModeratoryqian,
Sorry that you are seeing this issue.
1. Is the project in SVN a pure Maven project or a MyEclipse project ?
2. If its a maven project, can you confirm that you have checked it out using File->Import->Maven4MyEclipse->Checkout Maven Projects from SCM ?
3. Take a look at this FAQ to install the SCM connector :
https://www.genuitec.com/forums/topic/maven-how-to-install-maven-scm-connectors/4. Are you deploying to an external Tomcat or ME Tomcat?
5. Can you please export the project using Export -> WAR (MyEclipse) and check its contents ?
yqianMemberThanks, Swapna for the reply
1. yes, it is a maven project, development team using maven even before I join the team couple years ago and all our projects are mavenized.
2. Yes, I did that
3. Thanks, I had my scm handler installed
4. it is external Tomcat, /home/yqian/apache-tomcat-7.0.27
5. I did export to the war file, unzipped it, all the dependent jar files are in WEB-INF/lib
support-swapnaModeratoryqian,
1. Can you please check the deployment policy and make sure you are deploying all the classes which your application needs?
2. The deployment of dependencies is controlled through preferences. Right click on the web project and select Properties. Now go to the MyEclipse->Web page and the Deployment tab. You can modify how dependent projects are deployed from there. You can also modify the library deployment policies at the same place.
3. Go to “Project properties -> Deployment Assembly page”. This page describes how your app will be packaged for deployment or export.Can you see ‘Maven Dependencies’? Is its deploy path ‘WEB-INF/lib’?
4. Can you please attach your project to help us investigate the issue ? You can zip the project and attach it to this thread or email it to support@genuitec.com Subject : ATTN : Swapna , along with a reference to this thread.
yqianMemberThanks, Swapna
1. As far as I can tell, the deployment policy include all the classes and jar files
2. This is where I set up my deployment policy
3. Yes, deploy path is “WEB-INF/lib”
4. We are using encrypted configuration datastore to load environment variables, properties file, etc. without set up configuration datastore, Tomcat would not be able to start, so the error message will be totally different, Sending the project might not help support team to pin down the cause.
support-tonyKeymasteryqian,
That’s a tricky one. From what you’ve described, it seems as though all of the classes and jar files that need to be deployed for your application are, indeed, deployed. The only possibility we can think of for the class not found errors is that the class is being referenced by another class that was not loaded by the application class loader and so does not see any application level classes it might need. However, if you are deploying all the classes your application needs, then that would not seem to be the problem.
It’s not clear how you are attempting the deploy. Are you using the MyEclipse deployment tools or are you using a maven built war file and physically copying that war file to the Tomcat deployment folder? If it’s the latter, then it seems that the MyEclipse maven support is working fine and running the maven build.
In either case, I’m not sure how we can help further, since it seems your application deployment appears to be complete; that is, MyEclipse successfully deployed your application to Tomcat, or successfully ran the maven build. From this point, it looks like some kind of Tomcat configuration problem, perhaps.
Sorry we can give a better answer at this stage. If you think it is still a MyEclipse problem, please provide more information about the MyEclipse function which is failing.
-
AuthorPosts