[bitbake-devel] [PATCH] bitbake: fetch2/svn: Add tarsnapshots parameter

Niko Mauno niko.mauno at iki.fi
Sun Apr 8 08:28:21 UTC 2018


On 04/04/2018 10:56 AM, Richard Purdie wrote:
> On Fri, 2018-03-23 at 11:28 +0200, Niko Mauno wrote:
>> By adding 'tarsnapshots=currentonly' option to svn-specific component
>> in
>> SRC_URI, associated subversion repository module's existing tarball
>> snapshots are removed from DL_DIR, before creating a new one.
>>
>> This provides a means to avoid downloads directory becoming congested
>> with a subversion repository module's tarball snapshots, which may
>> occur
>> for example during circumstances where source code residing in a
>> subversion repository is subject to long-term development work, and
>> recipe used in continuous integration builds has SRCREV set to
>> AUTOREV.
>>
>> Signed-off-by: Niko Mauno <niko.mauno at iki.fi>
> 
> This model does't really work as if multiple things share the downloads
> directory there is a race window between the old tarballs being removed
> and the new one being created. The downloads and sstate directories are
> commonly shared between builds so we need to be mindful of this.
> 
> Cheers,
> 
> Richard
> 

Thank You for pointing this out.

As an observation related to using a shared downloads directory, it currently seems to already be subject to races when subversion is used - for example in a situation where two (or more) builds perform a temporally overlapping do_fetch for same recipe but with differing SRCREVs, and tarballs for respective SRCREVs have not been created yet.

In such cases error seems to occur because several distinct actors are trying to 'svn update' or 'svn checkout' in same directory at same time, resulting in a bitbake error for all build instances (typically involving a "working copy locked" error message).



More information about the bitbake-devel mailing list