Thanks Noam

I’ve decided to change my repositories to use the maven layout with unique
snapshots. Now deploying unique snapshots seems to work automatically from
Jenkins + Gradle. The artifacts get published with a unique identifier added
to their name. The folder name in artifactory is still 1.0.0-SNAPSHOT. As
far as I understand, that's how it's supposed to work.

Attached is a screenshot of what it looks like in the artifactory web UI:

http://forums.jfrog.org/file/n7578105/ScreenClip.png 

However, when I try to refer to this artifact from another Gradle project,
if I use the dependency declaration as provided by Artifactory (see
screenshot), it fails to find the required version. To get it to resolve I
need to declare the dependency as 1.0.0-SNAPSHOT. 

I realize that in most cases I won't want to depend on a specific unique
snapshot version anyway, but isn't this supposed to work? Am I doing
something wrong? What's the point of having unique snapshot artifacts in the
repository if I can't depend on them or even see which version Gradle
downloaded to my machine?

Thanks,



Noam Y. Tenne wrote
> 
> Although they've quite distanced themselves, Gradle was initially built
> around Ivy and although Ivy has no real standard layout, the general use
> case is that Ivy creates these integration revisions itself.
> The concept of unique and non-unique integration revisions, and the
> conversion between them is done more around Maven as it also has
> a standardized layout; Artifactory can handle these conversions if your
> artifacts and repository configuration adhere to the standard Maven
> layout.
> 
> 
> Obviously every case has it's exceptions and it's easier at times to build
> locally, but a couple of points to consider are:
> 
>    - If project X depends on project Y, then project Y should be developed
>    and tested as an independent unit and without "knowing" X.
>    - Building locally exposes the developer to some intricate but
> sometimes
>    crucial differences between the build environments.
> 
> 
> On Mon, Jun 4, 2012 at 11:22 AM, spock <yair.halevi@> wrote:
> 
>> Thanks Noam
>>
>> Makes sense that Gradle should handle it, I was just surprised that there
>> is
>> no standard support or plugin for generating these timestamps in
>> integration
>> builds, because it sounds like a pretty standard scenario (judging from
>> the
>> "gradle-default" layout in Artifactory, at least).
>>
>> Regarding local developer builds - for most cases I agree, but what if a
>> developer working on project A needs to modify project B to support some
>> feature in A? She could modify, commit and build B (in the CI server),
>> but
>> isn't it sometimes beneficial to be able to test A and B together locally
>> before committing the change in B?
>>
>>
>>
>> --
>> View this message in context:
>> http://forums.jfrog.org/How-do-I-publish-unique-snapshots-into-Artifactory-with-gradle-and-Jenkins-tp7577988p7577990.html
>> Sent from the Artifactory - Users mailing list archive at Nabble.com.
>>
>>
>> ------------------------------------------------------------------------------
>> Live Security Virtual Conference
>> Exclusive live event will cover all the ways today's security and
>> threat landscape has changed and how IT managers can respond. Discussions
>> will include endpoint security, mobile security and the latest in malware
>> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
>> _______________________________________________
>> Artifactory-users mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/artifactory-users
>>
> 
> ------------------------------------------------------------------------------
> Live Security Virtual Conference
> Exclusive live event will cover all the ways today's security and 
> threat landscape has changed and how IT managers can respond. Discussions 
> will include endpoint security, mobile security and the latest in malware 
> threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
> _______________________________________________
> Artifactory-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/artifactory-users
> 


--
View this message in context: 
http://forums.jfrog.org/How-do-I-publish-unique-snapshots-into-Artifactory-with-gradle-and-Jenkins-tp7577988p7578105.html
Sent from the Artifactory - Users mailing list archive at Nabble.com.

------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and 
threat landscape has changed and how IT managers can respond. Discussions 
will include endpoint security, mobile security and the latest in malware 
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Artifactory-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/artifactory-users

Reply via email to