Confusion about maven-war-plugin and jetty-maven-plugin

Posted by waxwing on Stack Overflow See other posts from Stack Overflow or by waxwing
Published on 2010-06-07T12:14:28Z Indexed on 2010/06/07 14:02 UTC
Read the original article Hit count: 604

Filed under:
|
|

I am trying to get the run-exploded goal of the jetty-maven-plugin to work correctly. I find the documentation somewhat lacking on what I need to do to set this up.

I believe I have a standard WAR-file setup. (The reason I wrote "believe" is that I find the maven-war-plugin documentation lacking as well.) When I build my webapp using maven package, I get the following in my target folder:

classes
maven-archiver
surefire-reports
test-classes
tmp
mywebapp-version
mywebapp-version.war

where mywebapp-version is the exploded war and mywebapp-version.war is the packaged one. So far so good (I think?).

Now, running mvn jetty:run-exploded, it seems the default deploy folder is target/tmp/webapp/mywebapp-version.war/. This folder exists, but contains no files except for a webapp-cache.xml. This seems wrong to me.

I also tried to actively set the webApp configuration element to ${project.build.directory}/mywebapp-version/, but run-exploded seems to ignore it (despite the documentation stating otherwise).

What am I doing wrong? It looks as if I am missing something simple since no one else appears to be running into the same problem.

© Stack Overflow or respective owner

Related posts about maven-2

Related posts about jetty