facebook

Maven2 WAR project not honoring pom dpndncy scope on deploy

  1. MyEclipse Archived
  2.  > 
  3. Application Servers and Deployment
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #302771 Reply

    hubbardr1
    Member

    The MyEclipse integration with maven doesnt seem to honor the scopes rules defined within a war’s pom. I have a simple project that pulls in hibernate as a “provided” transitive dependency. The hibernate dependency of course gets put in the .classpath for eclipse when you run the eclipse:myeclipse plugin. That part works great as expected. The problem is that when you deploy, it seems to also use the .classpath to determine how to package the war and deploy to configured server instead of letting maven do it. My “provided” transitive dependencies should not get deployed to the war’s lib dir but they do.

    I’m unable to have hibernate in the classpath (so unit tests inside the war can be run) AND also deploy to a server like JBoss (where hibernate is already packaged with the server – causes conflicts). I have to mark hibernate as excluded in the pom in order for my project to run.

    Is there a workaround to this? This is a huge hindrance and has forced me to look at basic eclipse+WTP. Would appreciate any tips or hints as to what I might be doing wrong.

    Thanks!

    #302775 Reply

    hubbardr1
    Member

    Sorry…I didnt look hard enough. There is an existing thread on this. And one that apparently I contributed to in the past no less. 😉

    https://www.genuitec.com/forums/topic/7-0-1-ignoring-quot-provided-quot-scope-when-deploying-to/

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: Maven2 WAR project not honoring pom dpndncy scope on deploy

You must be logged in to post in the forum log in