You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by solo1970 <so...@ericsson.com> on 2008/11/07 15:54:16 UTC

Re: duplicate copies of SNAPSHOT dependencies in war artifact

We are having the same issue and using Maven 2.0.9

Can anyone help???

When creating a war for our webapp project, we use snapshots for 3rd party
dependencies.
Maven does not erase the old snapshot versions for the same jar.  Which
means we have 2 jars jars for the same module, example
Webapp/WEB-INF/lib/ppp-PA1-200834234293-7.jar   
Webapp/WEB-INF/lib/ppp-PA1-200834234293-8.jar

How do we resolve this????

Sonia L.



carlos f wrote:
> 
> using maven 2.0.4
> 
> When we generate a war we end up getting duplicates of all 3rd party
> SNAPSHOT dependencies.
> 
> For instance we use
> com.javaforge.tapestry.tapestry-spring:jar:1.0.0-SNAPSHOT.  we end up
> with:
> 
> tapestry-spring-1.0.0-SNAPSHOT.jar and
> tapestry-spring-1.0.0-20061122.201931-1.jar in the war.
> 
> This does not happen with snapshots we publish internally.  I can only
> assume that this is because we do not publish our snapshot using timestamp
> "versioning".
> 
> I am sure this is because of some convoluted way we set up the project's
> pom or the project's parent pom.  However, I can't seem to get a good fix
> on the problem and was hoping that someone might point me in the right
> direction.
> 
> fyi - we are using maven 2.0.4 because an earlier attempt to upgrade broke
> our build.  I can only assume that somehow we set up our build using a
> "defect" that was later fix  after 2.0.4.  When we have some room we are
> planning on addressing this an upgrading our build tools.
> 
> Carlos
> 

-- 
View this message in context: http://www.nabble.com/duplicate-copies-of-SNAPSHOT-dependencies-in-war-artifact-tp18893733p20382088.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org


Re: duplicate copies of SNAPSHOT dependencies in war artifact

Posted by Stephen Connolly <st...@gmail.com>.
are you doing a clean build each time or is this in-between clean builds?

i.e.

if you do

mvn clean package
wait some time
mvn clean package

is the problem there or is it only

mvn clean package
wait some time
mvn package

or... does running "mvn clean package" fix the problem?

2008/11/7 solo1970 <so...@ericsson.com>

>
> We are having the same issue and using Maven 2.0.9
>
> Can anyone help???
>
> When creating a war for our webapp project, we use snapshots for 3rd party
> dependencies.
> Maven does not erase the old snapshot versions for the same jar.  Which
> means we have 2 jars jars for the same module, example
> Webapp/WEB-INF/lib/ppp-PA1-200834234293-7.jar
> Webapp/WEB-INF/lib/ppp-PA1-200834234293-8.jar
>
> How do we resolve this????
>
> Sonia L.
>
>
>
> carlos f wrote:
> >
> > using maven 2.0.4
> >
> > When we generate a war we end up getting duplicates of all 3rd party
> > SNAPSHOT dependencies.
> >
> > For instance we use
> > com.javaforge.tapestry.tapestry-spring:jar:1.0.0-SNAPSHOT.  we end up
> > with:
> >
> > tapestry-spring-1.0.0-SNAPSHOT.jar and
> > tapestry-spring-1.0.0-20061122.201931-1.jar in the war.
> >
> > This does not happen with snapshots we publish internally.  I can only
> > assume that this is because we do not publish our snapshot using
> timestamp
> > "versioning".
> >
> > I am sure this is because of some convoluted way we set up the project's
> > pom or the project's parent pom.  However, I can't seem to get a good fix
> > on the problem and was hoping that someone might point me in the right
> > direction.
> >
> > fyi - we are using maven 2.0.4 because an earlier attempt to upgrade
> broke
> > our build.  I can only assume that somehow we set up our build using a
> > "defect" that was later fix  after 2.0.4.  When we have some room we are
> > planning on addressing this an upgrading our build tools.
> >
> > Carlos
> >
>
> --
> View this message in context:
> http://www.nabble.com/duplicate-copies-of-SNAPSHOT-dependencies-in-war-artifact-tp18893733p20382088.html
> Sent from the Maven - Users mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
> For additional commands, e-mail: users-help@maven.apache.org
>
>

Re: duplicate copies of SNAPSHOT dependencies in war artifact

Posted by carlos f <ca...@yahoo.com>.
not sure what your particular circumstances are ... but for some odd reasons
our project, "A" of type war, depended on another project, "B" of type war. 
When maven would resolve the dependency from A -> B it would unpack B and
add it to A.  This is how we ended up with duplicates.

Carlos
-- 
View this message in context: http://www.nabble.com/duplicate-copies-of-SNAPSHOT-dependencies-in-war-artifact-tp18893733p20384561.html
Sent from the Maven - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org