GitInput: Include deepClone option in the cache key
Without this commit, two jobsets using the same repository as input, but different `deepClone` options, end up incorrectly sharing the same "checkout" for a given (`uri`, `branch`, `revision`) tuple. The presence or absence of `.git` is determined by the jobset execution order. This patch adds the missing `isDeepClone` boolean to the cache key. The database upgrade script empties the `CachedGitInputs` table, as we don't know if existing checkouts are deep clones. Unfortunately, this generally forces rebuilds even for correct `deepClone` checkouts, as the binary contents of `.git` are not deterministic. Fixes #510
This commit is contained in:
@ -50,6 +50,11 @@ __PACKAGE__->table("cachedgitinputs");
|
||||
data_type: 'text'
|
||||
is_nullable: 0
|
||||
|
||||
=head2 isdeepclone
|
||||
|
||||
data_type: 'boolean'
|
||||
is_nullable: 0
|
||||
|
||||
=head2 sha256hash
|
||||
|
||||
data_type: 'text'
|
||||
@ -69,6 +74,8 @@ __PACKAGE__->add_columns(
|
||||
{ data_type => "text", is_nullable => 0 },
|
||||
"revision",
|
||||
{ data_type => "text", is_nullable => 0 },
|
||||
"isdeepclone",
|
||||
{ data_type => "boolean", is_nullable => 0 },
|
||||
"sha256hash",
|
||||
{ data_type => "text", is_nullable => 0 },
|
||||
"storepath",
|
||||
@ -85,14 +92,16 @@ __PACKAGE__->add_columns(
|
||||
|
||||
=item * L</revision>
|
||||
|
||||
=item * L</isdeepclone>
|
||||
|
||||
=back
|
||||
|
||||
=cut
|
||||
|
||||
__PACKAGE__->set_primary_key("uri", "branch", "revision");
|
||||
__PACKAGE__->set_primary_key("uri", "branch", "revision", "isdeepclone");
|
||||
|
||||
|
||||
# Created by DBIx::Class::Schema::Loader v0.07049 @ 2020-02-06 12:22:36
|
||||
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:0sdK9uQZpx869oqS5thRLw
|
||||
# Created by DBIx::Class::Schema::Loader v0.07049 @ 2021-06-19 17:26:24
|
||||
# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:Wr0grsFTaqRlMeM9vpXjrw
|
||||
|
||||
1;
|
||||
|
Reference in New Issue
Block a user