You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by "Subramanian, N.Venkata" <ns...@informatica.com> on 2008/12/23 10:27:32 UTC

Question on dowloading the deployed artifact

Pardon me if this is a basic question.

 

We have two build setups

          0) 'mvn install' - which does the compilation and installs in
the local repo. 

          1) 'mvn deploy' - If the mvn install is successful, based on
the 'mvn install' source code 'mvn deploy' will be kicked off

          

          While mvn deploy is in progress, mvn install will be kicked
off to the latest changes. We have this parallel setup to avoid delay. 

          w.r.t source code change 'mvn deploy' is always behind to 'mvn
install'.

 

Question:

          Is there a possibility that during 'mvn install' - it picks up
the dependent deployed artifact instead of local repo artifact. (based
on time   stamp it could be that deployed artifact is having new time
stamp but w.r.t source code change local repo is latest than deployed
artifact)

 

          If this is possible, how to overcome this problem. 

 

Regards

-Venkat


RE: Question on dowloading the deployed artifact

Posted by "Subramanian, N.Venkata" <ns...@informatica.com>.
I would appreciate your help on this

Thanks
-Venkat
-----Original Message-----
From: Subramanian, N.Venkata 
Sent: Tuesday, December 23, 2008 3:40 PM
To: Maven Users List
Subject: RE: Question on dowloading the deployed artifact

Thanks Mathus

We are using SNAPSHOT versions only.

As I said we have two setups - two different machines and two different
local repositories. We need this setup to run both the builds parallely
to save time.

'mvn insall' will always based on latest code and 'mvn deploy' will be
behind w.r.t to source code change as it is based on successful 'mvn
install' source code.

Problem is:
Let's say 'mvn install' setup installs an artifact 'xx-SNAPSHOT' in its
local repo at 10:00 a.m and still in progress building other modules.

Meanwhile 'mvn deploy' is also in progress and deploys the artifact
'xx-SNAPSHOT' (old one w.r.t to change). at 10:20 a.m 

In mvn install another artifact which has dependency on xx-SNAPSHOT is
downloading from deployed repository and not from local repo as the time
stamp is later. Because of that we have failure. 


Regards
-Venkat
-----Original Message-----
From: bmathus@gmail.com [mailto:bmathus@gmail.com] On Behalf Of Baptiste
MATHUS
Sent: Tuesday, December 23, 2008 3:11 PM
To: Maven Users List
Subject: Re: Question on dowloading the deployed artifact

I guess I read and replied too fast :-/.
I'm not sure I understand your question. You would like maven to
automatically download new versions if there is one in your deployment
repository?

If so, then sure, there is. Just put a dependency with "-SNAPSHOT"
version
and that will be the default behaviour.
If you're not using SNAPSHOT, then it's not possible by default. Maven
will
always use the local released version without trying to look for new one
(since it's a release and it should not change).

Let us see a bit how you handle versions & dependencies in your poms so
that
we can be more precise if you will.

Cheers.

2008/12/23 Subramanian, N.Venkata <ns...@informatica.com>

> Pardon me if this is a basic question.
>
>
>
> We have two build setups
>
>          0) 'mvn install' - which does the compilation and installs in
> the local repo.
>
>          1) 'mvn deploy' - If the mvn install is successful, based on
> the 'mvn install' source code 'mvn deploy' will be kicked off
>
>
>
>          While mvn deploy is in progress, mvn install will be kicked
> off to the latest changes. We have this parallel setup to avoid delay.
>
>          w.r.t source code change 'mvn deploy' is always behind to
'mvn
> install'.
>
>
>
> Question:
>
>          Is there a possibility that during 'mvn install' - it picks
up
> the dependent deployed artifact instead of local repo artifact. (based
> on time   stamp it could be that deployed artifact is having new time
> stamp but w.r.t source code change local repo is latest than deployed
> artifact)
>
>
>
>          If this is possible, how to overcome this problem.
>
>
>
> Regards
>
> -Venkat
>
>


-- 
Baptiste <Batmat> MATHUS - http://batmat.net
Sauvez un arbre,
Mangez un castor !

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


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


RE: Question on dowloading the deployed artifact

Posted by "Subramanian, N.Venkata" <ns...@informatica.com>.
Thanks Mathus

We are using SNAPSHOT versions only.

As I said we have two setups - two different machines and two different
local repositories. We need this setup to run both the builds parallely
to save time.

'mvn insall' will always based on latest code and 'mvn deploy' will be
behind w.r.t to source code change as it is based on successful 'mvn
install' source code.

Problem is:
Let's say 'mvn install' setup installs an artifact 'xx-SNAPSHOT' in its
local repo at 10:00 a.m and still in progress building other modules.

Meanwhile 'mvn deploy' is also in progress and deploys the artifact
'xx-SNAPSHOT' (old one w.r.t to change). at 10:20 a.m 

In mvn install another artifact which has dependency on xx-SNAPSHOT is
downloading from deployed repository and not from local repo as the time
stamp is later. Because of that we have failure. 


Regards
-Venkat
-----Original Message-----
From: bmathus@gmail.com [mailto:bmathus@gmail.com] On Behalf Of Baptiste
MATHUS
Sent: Tuesday, December 23, 2008 3:11 PM
To: Maven Users List
Subject: Re: Question on dowloading the deployed artifact

I guess I read and replied too fast :-/.
I'm not sure I understand your question. You would like maven to
automatically download new versions if there is one in your deployment
repository?

If so, then sure, there is. Just put a dependency with "-SNAPSHOT"
version
and that will be the default behaviour.
If you're not using SNAPSHOT, then it's not possible by default. Maven
will
always use the local released version without trying to look for new one
(since it's a release and it should not change).

Let us see a bit how you handle versions & dependencies in your poms so
that
we can be more precise if you will.

Cheers.

2008/12/23 Subramanian, N.Venkata <ns...@informatica.com>

> Pardon me if this is a basic question.
>
>
>
> We have two build setups
>
>          0) 'mvn install' - which does the compilation and installs in
> the local repo.
>
>          1) 'mvn deploy' - If the mvn install is successful, based on
> the 'mvn install' source code 'mvn deploy' will be kicked off
>
>
>
>          While mvn deploy is in progress, mvn install will be kicked
> off to the latest changes. We have this parallel setup to avoid delay.
>
>          w.r.t source code change 'mvn deploy' is always behind to
'mvn
> install'.
>
>
>
> Question:
>
>          Is there a possibility that during 'mvn install' - it picks
up
> the dependent deployed artifact instead of local repo artifact. (based
> on time   stamp it could be that deployed artifact is having new time
> stamp but w.r.t source code change local repo is latest than deployed
> artifact)
>
>
>
>          If this is possible, how to overcome this problem.
>
>
>
> Regards
>
> -Venkat
>
>


-- 
Baptiste <Batmat> MATHUS - http://batmat.net
Sauvez un arbre,
Mangez un castor !

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


Re: Question on dowloading the deployed artifact

Posted by Baptiste MATHUS <ml...@batmat.net>.
I guess I read and replied too fast :-/.
I'm not sure I understand your question. You would like maven to
automatically download new versions if there is one in your deployment
repository?

If so, then sure, there is. Just put a dependency with "-SNAPSHOT" version
and that will be the default behaviour.
If you're not using SNAPSHOT, then it's not possible by default. Maven will
always use the local released version without trying to look for new one
(since it's a release and it should not change).

Let us see a bit how you handle versions & dependencies in your poms so that
we can be more precise if you will.

Cheers.

2008/12/23 Subramanian, N.Venkata <ns...@informatica.com>

> Pardon me if this is a basic question.
>
>
>
> We have two build setups
>
>          0) 'mvn install' - which does the compilation and installs in
> the local repo.
>
>          1) 'mvn deploy' - If the mvn install is successful, based on
> the 'mvn install' source code 'mvn deploy' will be kicked off
>
>
>
>          While mvn deploy is in progress, mvn install will be kicked
> off to the latest changes. We have this parallel setup to avoid delay.
>
>          w.r.t source code change 'mvn deploy' is always behind to 'mvn
> install'.
>
>
>
> Question:
>
>          Is there a possibility that during 'mvn install' - it picks up
> the dependent deployed artifact instead of local repo artifact. (based
> on time   stamp it could be that deployed artifact is having new time
> stamp but w.r.t source code change local repo is latest than deployed
> artifact)
>
>
>
>          If this is possible, how to overcome this problem.
>
>
>
> Regards
>
> -Venkat
>
>


-- 
Baptiste <Batmat> MATHUS - http://batmat.net
Sauvez un arbre,
Mangez un castor !

Re: Question on dowloading the deployed artifact

Posted by Baptiste MATHUS <ml...@batmat.net>.
Hi,

As mvn deploy includes mvn install (see
http://maven.apache.org/guides/introduction/introduction-to-the-lifecycle.html#Build_Lifecycle_Basicsto
know more about it). You could just delete your "mvn install" setup.

Fwiw, that's what we run in our Continuous Integration server : "mvn clean
deploy".

Cheers.

2008/12/23 Subramanian, N.Venkata <ns...@informatica.com>

> Pardon me if this is a basic question.
>
>
>
> We have two build setups
>
>          0) 'mvn install' - which does the compilation and installs in
> the local repo.
>
>          1) 'mvn deploy' - If the mvn install is successful, based on
> the 'mvn install' source code 'mvn deploy' will be kicked off
>
>
>
>          While mvn deploy is in progress, mvn install will be kicked
> off to the latest changes. We have this parallel setup to avoid delay.
>
>          w.r.t source code change 'mvn deploy' is always behind to 'mvn
> install'.
>
>
>
> Question:
>
>          Is there a possibility that during 'mvn install' - it picks up
> the dependent deployed artifact instead of local repo artifact. (based
> on time   stamp it could be that deployed artifact is having new time
> stamp but w.r.t source code change local repo is latest than deployed
> artifact)
>
>
>
>          If this is possible, how to overcome this problem.
>
>
>
> Regards
>
> -Venkat
>
>


-- 
Baptiste <Batmat> MATHUS - http://batmat.net
Sauvez un arbre,
Mangez un castor !