* Inputs of type "build" must now be declared explicitly.

[?]
Mar 9, 2009, 1:58 PM
7ZHHVD6QVZCR7OHF3OIS52DF7ZIQDIS27OXCKOGMFDO2CTIOGI5AC

Dependencies

  • [2] POPU2ATH * hydra_scheduler: use eval-jobs.
  • [3] X27GNHDV * Basic job info in the database.
  • [4] TLZ2SPBR
  • [5] 7UJ5YV4V * Provide a channel for each project containing all the latest
  • [6] 6LTPI6B2
  • [7] FDE3BJAP * Refactoring.
  • [8] AKAZKCR6 * At top-level and for each project, provide two channels: "latest"
  • [9] FPK5LF53 * Put the project-related actions in a separate controller. Put the
  • [*] N22GPKYT * Put info about logs / build products in the DB.
  • [*] ZVTSOVHN * Support Subversion checkouts.

Change contents

  • replacement in src/lib/Hydra/Controller/Project.pm at line 178
    [3.7172][3.7172:7263]()
    $inputType eq "string" || $inputType eq "path" || $inputType eq "boolean";
    [3.7172]
    [3.7263]
    $inputType eq "string" || $inputType eq "path" || $inputType eq "boolean" ||
    $inputType eq "build";
  • replacement in src/script/hydra_scheduler.pl at line 37
    [2.310][2.310:338]()
    my ($input, $alt) = @_;
    [2.310]
    [3.6736]
    my ($project, $jobset, $input, $alt) = @_;
  • edit in src/script/hydra_scheduler.pl at line 153
    [12.5292]
    [12.5292]
    elsif ($type eq "build") {
    my $jobName = $alt->value or die;
    # Pick the most recent successful build of the specified job.
    (my $prevBuild) = $db->resultset('Builds')->search(
    {finished => 1, project => $project->name, jobset => $jobset->name, attrname => $jobName, buildStatus => 0},
    {join => 'resultInfo', order_by => "timestamp DESC", rows => 1});
    if (!defined $prevBuild || !isValidPath($prevBuild->outpath)) {
    print STDERR "no previous build available for `$jobName'";
    return undef;
    }
    my $pkgNameRE = "(?:(?:[A-Za-z0-9]|(?:-[^0-9]))+)";
    my $versionRE = "(?:[A-Za-z0-9\.\-]+)";
    my $relName = ($prevBuild->resultInfo->releasename or $prevBuild->nixname);
    my $version = $2 if $relName =~ /^($pkgNameRE)-($versionRE)$/;
    return
    { type => "build"
    , storePath => $prevBuild->outpath
    , id => $prevBuild->id
    , version => $version
    };
    }
  • replacement in src/script/hydra_scheduler.pl at line 198
    [2.501][2.501:536]()
    my ($jobset, $inputInfo) = @_;
    [2.501]
    [2.536]
    my ($project, $jobset, $inputInfo) = @_;
  • replacement in src/script/hydra_scheduler.pl at line 201
    [2.646][2.646:722]()
    push @{$$inputInfo{$input->name}}, fetchInputAlt($input, $alt);
    [2.646]
    [2.722]
    my $info = fetchInputAlt($project, $jobset, $input, $alt);
    push @{$$inputInfo{$input->name}}, $info if defined $info;
  • replacement in src/script/hydra_scheduler.pl at line 298
    [2.1783][2.1783:1824]()
    when (["svn", "path"]) {
    [2.1783]
    [2.1824]
    when (["svn", "path", "build"]) {
  • replacement in src/script/hydra_scheduler.pl at line 301
    [2.1959][2.1959:2024]()
    "; rev = \"" . $alt->{revision} . "\"" .
    [2.1959]
    [2.2024]
    (defined $alt->{revision} ? "; rev = \"" . $alt->{revision} . "\"" : "") .
    (defined $alt->{version} ? "; version = \"" . $alt->{version} . "\"" : "") .
  • replacement in src/script/hydra_scheduler.pl at line 324
    [2.2152][2.2152:2190]()
    fetchInputs($jobset, $inputInfo);
    [2.2152]
    [3.4018]
    fetchInputs($project, $jobset, $inputInfo);