Unable to download artifacts immediately after creating asset version using ant tasks
Is there a delay between changing an asset and being able to use it?
I am using Rational Asset Manager to upload the results of a build step using the RAM ant tasks. I am successfully creating a new version of the asset and then adding some artifacts as content.
In a following build step (about 10 seconds later), I use the ram:download ant task to search for that version of the asset and download the content. However I see the message:
[ram:download] Nothing to download.
If I add a 60 second delay then the download works successfully. If there is a delay between the asset becoming available with the latest content, is there any way via the API to know when that has happened?
Thanks for any help, Colin.
One answer
Hi,
Thanks for update.
I agree with you that there is a dely between a asset submit and RAM index. I think you use a asset search here to fetch the newly upload asset, but it is not recorded in index yet.
One way I can think of is that, if you can record the asset identification(guid/version) if the newly uploaded asset, and use ram:asset type in download task instead of search. This could allow download task to fetch asset directly instead of search in index.
<ram:asset guid="${ram.asset.guid}" version="${ram.asset.version}" />
Hope that could help.
Thanks for update.
I agree with you that there is a dely between a asset submit and RAM index. I think you use a asset search here to fetch the newly upload asset, but it is not recorded in index yet.
One way I can think of is that, if you can record the asset identification(guid/version) if the newly uploaded asset, and use ram:asset type in download task instead of search. This could allow download task to fetch asset directly instead of search in index.
<ram:asset guid="${ram.asset.guid}" version="${ram.asset.version}" />
Hope that could help.
Comments
Lin Lu
JAZZ DEVELOPER Jun 23 '14, 10:38 p.m.Hi,
I am curious about how you use the ramDownloadAsset.xml. Did you add a Search type or a Asset type? That would be helpful if you could offer the script here.
Thanks.
Colin Thorne
Jun 24 '14, 3:30 a.m.I am using a search including the name, community and version. Here is a snippet of my code (let me know if you would like to see more):