From ecd0ba74e984cee658457321601b9305300b71ab Mon Sep 17 00:00:00 2001 From: Eelco Dolstra Date: Tue, 11 Nov 2008 12:54:37 +0000 Subject: [PATCH] * Merged the Build and Job tables. --- .../lib/HydraFrontend/Controller/Root.pm | 19 ++- src/HydraFrontend/lib/HydraFrontend/Schema.pm | 4 +- .../Schema/{Inputs.pm => Buildinputs.pm} | 17 ++- .../lib/HydraFrontend/Schema/Buildlogs.pm | 6 +- .../lib/HydraFrontend/Schema/Buildproducts.pm | 6 +- .../HydraFrontend/Schema/Buildresultinfo.pm | 33 +++++ .../lib/HydraFrontend/Schema/Builds.pm | 53 +++++--- .../Schema/Buildschedulinginfo.pm | 31 +++++ .../lib/HydraFrontend/Schema/Jobs.pm | 58 -------- .../HydraFrontend/Schema/Jobsetinputalts.pm | 6 +- .../lib/HydraFrontend/Schema/Jobsetinputs.pm | 6 +- .../lib/HydraFrontend/Schema/Jobsets.pm | 14 +- .../lib/HydraFrontend/Schema/Projects.pm | 11 +- src/HydraFrontend/root/build.tt | 65 +++++---- src/HydraFrontend/root/index.tt | 18 +-- src/HydraFrontend/root/short-build-info.tt | 2 +- src/build.pl | 77 +++++------ src/hydra.sql | 125 ++++++++++-------- src/runner.pl | 28 ++-- src/scheduler.pl | 34 +++-- 20 files changed, 327 insertions(+), 286 deletions(-) rename src/HydraFrontend/lib/HydraFrontend/Schema/{Inputs.pm => Buildinputs.pm} (69%) create mode 100644 src/HydraFrontend/lib/HydraFrontend/Schema/Buildresultinfo.pm create mode 100644 src/HydraFrontend/lib/HydraFrontend/Schema/Buildschedulinginfo.pm delete mode 100644 src/HydraFrontend/lib/HydraFrontend/Schema/Jobs.pm diff --git a/src/HydraFrontend/lib/HydraFrontend/Controller/Root.pm b/src/HydraFrontend/lib/HydraFrontend/Controller/Root.pm index 9bf9caba..5c9e8f91 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Controller/Root.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Controller/Root.pm @@ -29,12 +29,17 @@ sub getBuild { sub index :Path :Args(0) { my ( $self, $c ) = @_; $c->stash->{template} = 'index.tt'; - $c->stash->{jobs} = [$c->model('DB::Jobs')->all]; $c->stash->{projects} = [$c->model('DB::Projects')->all]; - $c->stash->{allBuilds} = [$c->model('DB::Builds')->search(undef, {order_by => "timestamp DESC"})]; - # Get the latest build for each unique job. - # select * from builds as x where timestamp == (select max(timestamp) from builds where jobName == x.jobName); - $c->stash->{latestBuilds} = [$c->model('DB::Builds')->search(undef, {order_by => "project, attrName", where => "timestamp == (select max(timestamp) from builds where project == me.project and attrName == me.attrName)"})]; + $c->stash->{scheduled} = [$c->model('DB::Builds')->search( + {finished => 0}, {join => 'schedulingInfo'})]; # !!! + $c->stash->{allBuilds} = [$c->model('DB::Builds')->search( + {finished => 1}, {order_by => "timestamp DESC"})]; + # Get the latest finished build for each unique job. + $c->stash->{latestBuilds} = [$c->model('DB::Builds')->search(undef, + { join => 'resultInfo' + , where => "finished != 0 and timestamp = (select max(timestamp) from Builds where project == me.project and attrName == me.attrName)" + , order_by => "project, attrname" + })]; } @@ -54,7 +59,9 @@ sub job :Local { $c->stash->{template} = 'job.tt'; $c->stash->{projectName} = $project; $c->stash->{jobName} = $jobName; - $c->stash->{builds} = [$c->model('DB::Builds')->search({project => $project, attrName => $jobName}, {order_by => "timestamp DESC"})]; + $c->stash->{builds} = [$c->model('DB::Builds')->search( + {finished => 1, project => $project, attrName => $jobName}, + {order_by => "timestamp DESC"})]; } diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema.pm b/src/HydraFrontend/lib/HydraFrontend/Schema.pm index e9b028ed..052fc9cf 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Schema.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Schema.pm @@ -8,8 +8,8 @@ use base 'DBIx::Class::Schema'; __PACKAGE__->load_classes; -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:dBO/r6lVlITiJ/HlltKcpQ +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:1AgCf4sf5h2RU24Slo0sTA # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Inputs.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildinputs.pm similarity index 69% rename from src/HydraFrontend/lib/HydraFrontend/Schema/Inputs.pm rename to src/HydraFrontend/lib/HydraFrontend/Schema/Buildinputs.pm index 0781f01b..eda11d4d 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Schema/Inputs.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildinputs.pm @@ -1,4 +1,4 @@ -package HydraFrontend::Schema::Inputs; +package HydraFrontend::Schema::Buildinputs; use strict; use warnings; @@ -6,14 +6,12 @@ use warnings; use base 'DBIx::Class'; __PACKAGE__->load_components("Core"); -__PACKAGE__->table("inputs"); +__PACKAGE__->table("BuildInputs"); __PACKAGE__->add_columns( "id", { data_type => "integer", is_nullable => 0, size => undef }, "build", { data_type => "integer", is_nullable => 0, size => undef }, - "job", - { data_type => "integer", is_nullable => 0, size => undef }, "name", { data_type => "text", is_nullable => 0, size => undef }, "type", @@ -33,11 +31,16 @@ __PACKAGE__->add_columns( ); __PACKAGE__->set_primary_key("id"); __PACKAGE__->belongs_to("build", "HydraFrontend::Schema::Builds", { id => "build" }); +__PACKAGE__->belongs_to( + "dependency", + "HydraFrontend::Schema::Builds", + { id => "dependency" }, +); -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:A3Is4VTFkTl2DzrYjzdrZA +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:dKMSSomUN+gJX57Z5e295w -__PACKAGE__->belongs_to("dependency", "HydraFrontend::Schema::Builds", { id => "dependency" }); +# You can replace this text with custom content, and it will be preserved on regeneration 1; diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Buildlogs.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildlogs.pm index 2b6843fd..2f21bb8f 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Schema/Buildlogs.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildlogs.pm @@ -6,7 +6,7 @@ use warnings; use base 'DBIx::Class'; __PACKAGE__->load_components("Core"); -__PACKAGE__->table("buildLogs"); +__PACKAGE__->table("BuildLogs"); __PACKAGE__->add_columns( "build", { data_type => "integer", is_nullable => 0, size => undef }, @@ -21,8 +21,8 @@ __PACKAGE__->set_primary_key("build", "logphase"); __PACKAGE__->belongs_to("build", "HydraFrontend::Schema::Builds", { id => "build" }); -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:eMNna7u2l0ec+OYuvtGRpg +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ZOxJeT+ltgyc/zuDl9aEDQ # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Buildproducts.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildproducts.pm index 68797703..22ef546a 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Schema/Buildproducts.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildproducts.pm @@ -6,7 +6,7 @@ use warnings; use base 'DBIx::Class'; __PACKAGE__->load_components("Core"); -__PACKAGE__->table("buildProducts"); +__PACKAGE__->table("BuildProducts"); __PACKAGE__->add_columns( "build", { data_type => "integer", is_nullable => 0, size => undef }, @@ -21,8 +21,8 @@ __PACKAGE__->set_primary_key("build", "path"); __PACKAGE__->belongs_to("build", "HydraFrontend::Schema::Builds", { id => "build" }); -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:LaXQ4zxxvzdKFBRVcjMdMQ +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rZPTilX/PAiIoxffxc0nJw # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Buildresultinfo.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildresultinfo.pm new file mode 100644 index 00000000..1125256d --- /dev/null +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildresultinfo.pm @@ -0,0 +1,33 @@ +package HydraFrontend::Schema::Buildresultinfo; + +use strict; +use warnings; + +use base 'DBIx::Class'; + +__PACKAGE__->load_components("Core"); +__PACKAGE__->table("BuildResultInfo"); +__PACKAGE__->add_columns( + "id", + { data_type => "integer", is_nullable => 0, size => undef }, + "iscachedbuild", + { data_type => "integer", is_nullable => 0, size => undef }, + "buildstatus", + { data_type => "integer", is_nullable => 0, size => undef }, + "errormsg", + { data_type => "text", is_nullable => 0, size => undef }, + "starttime", + { data_type => "integer", is_nullable => 0, size => undef }, + "stoptime", + { data_type => "integer", is_nullable => 0, size => undef }, +); +__PACKAGE__->set_primary_key("id"); +__PACKAGE__->belongs_to("id", "HydraFrontend::Schema::Builds", { id => "id" }); + + +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:2Vfqs9RUhbDrje18yZb3AA + + +# You can replace this text with custom content, and it will be preserved on regeneration +1; diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Builds.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Builds.pm index c92253ae..92d358d6 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Schema/Builds.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Builds.pm @@ -6,10 +6,12 @@ use warnings; use base 'DBIx::Class'; __PACKAGE__->load_components("Core"); -__PACKAGE__->table("builds"); +__PACKAGE__->table("Builds"); __PACKAGE__->add_columns( "id", { data_type => "integer", is_nullable => 0, size => undef }, + "finished", + { data_type => "integer", is_nullable => 0, size => undef }, "timestamp", { data_type => "integer", is_nullable => 0, size => undef }, "project", @@ -24,16 +26,6 @@ __PACKAGE__->add_columns( { data_type => "text", is_nullable => 0, size => undef }, "outpath", { data_type => "text", is_nullable => 0, size => undef }, - "iscachedbuild", - { data_type => "integer", is_nullable => 0, size => undef }, - "buildstatus", - { data_type => "integer", is_nullable => 0, size => undef }, - "errormsg", - { data_type => "text", is_nullable => 0, size => undef }, - "starttime", - { data_type => "integer", is_nullable => 0, size => undef }, - "stoptime", - { data_type => "integer", is_nullable => 0, size => undef }, "system", { data_type => "text", is_nullable => 0, size => undef }, ); @@ -49,10 +41,25 @@ __PACKAGE__->belongs_to( { name => "jobset", project => "project" }, ); __PACKAGE__->has_many( - "inputs", - "HydraFrontend::Schema::Inputs", + "buildschedulinginfoes", + "HydraFrontend::Schema::Buildschedulinginfo", + { "foreign.id" => "self.id" }, +); +__PACKAGE__->has_many( + "buildresultinfoes", + "HydraFrontend::Schema::Buildresultinfo", + { "foreign.id" => "self.id" }, +); +__PACKAGE__->has_many( + "buildinputs_builds", + "HydraFrontend::Schema::Buildinputs", { "foreign.build" => "self.id" }, ); +__PACKAGE__->has_many( + "buildinputs_dependencies", + "HydraFrontend::Schema::Buildinputs", + { "foreign.dependency" => "self.id" }, +); __PACKAGE__->has_many( "buildproducts", "HydraFrontend::Schema::Buildproducts", @@ -65,9 +72,23 @@ __PACKAGE__->has_many( ); -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:C1XPkCXQImyXduKER0Dllg +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:1GZeB3YVr064AZrGargmFg -__PACKAGE__->has_many(dependents => 'HydraFrontend::Schema::Inputs', 'dependency'); +__PACKAGE__->has_many(dependents => 'HydraFrontend::Schema::Buildinputs', 'dependency'); + +__PACKAGE__->has_many(inputs => 'HydraFrontend::Schema::Buildinputs', 'build'); + +__PACKAGE__->belongs_to( + "schedulingInfo", + "HydraFrontend::Schema::Buildschedulinginfo", + { id => "id" }, +); + +__PACKAGE__->belongs_to( + "resultInfo", + "HydraFrontend::Schema::Buildresultinfo", + { id => "id" }, +); 1; diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Buildschedulinginfo.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildschedulinginfo.pm new file mode 100644 index 00000000..851a75b0 --- /dev/null +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Buildschedulinginfo.pm @@ -0,0 +1,31 @@ +package HydraFrontend::Schema::Buildschedulinginfo; + +use strict; +use warnings; + +use base 'DBIx::Class'; + +__PACKAGE__->load_components("Core"); +__PACKAGE__->table("BuildSchedulingInfo"); +__PACKAGE__->add_columns( + "id", + { data_type => "integer", is_nullable => 0, size => undef }, + "priority", + { data_type => "integer", is_nullable => 0, size => undef }, + "busy", + { data_type => "integer", is_nullable => 0, size => undef }, + "locker", + { data_type => "text", is_nullable => 0, size => undef }, + "logfile", + { data_type => "text", is_nullable => 0, size => undef }, +); +__PACKAGE__->set_primary_key("id"); +__PACKAGE__->belongs_to("id", "HydraFrontend::Schema::Builds", { id => "id" }); + + +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:rN7v2+MnC8TkrEHUzt2Gqg + + +# You can replace this text with custom content, and it will be preserved on regeneration +1; diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Jobs.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Jobs.pm deleted file mode 100644 index 86250094..00000000 --- a/src/HydraFrontend/lib/HydraFrontend/Schema/Jobs.pm +++ /dev/null @@ -1,58 +0,0 @@ -package HydraFrontend::Schema::Jobs; - -use strict; -use warnings; - -use base 'DBIx::Class'; - -__PACKAGE__->load_components("Core"); -__PACKAGE__->table("jobs"); -__PACKAGE__->add_columns( - "id", - { data_type => "integer", is_nullable => 0, size => undef }, - "timestamp", - { data_type => "integer", is_nullable => 0, size => undef }, - "priority", - { data_type => "integer", is_nullable => 0, size => undef }, - "busy", - { data_type => "integer", is_nullable => 0, size => undef }, - "locker", - { data_type => "text", is_nullable => 0, size => undef }, - "project", - { data_type => "text", is_nullable => 0, size => undef }, - "jobset", - { data_type => "text", is_nullable => 0, size => undef }, - "attrname", - { data_type => "text", is_nullable => 0, size => undef }, - "description", - { data_type => "text", is_nullable => 0, size => undef }, - "drvpath", - { data_type => "text", is_nullable => 0, size => undef }, - "outpath", - { data_type => "text", is_nullable => 0, size => undef }, - "system", - { data_type => "text", is_nullable => 0, size => undef }, -); -__PACKAGE__->set_primary_key("id"); -__PACKAGE__->belongs_to( - "project", - "HydraFrontend::Schema::Projects", - { name => "project" }, -); -__PACKAGE__->belongs_to( - "jobset", - "HydraFrontend::Schema::Jobsets", - { name => "jobset", project => "project" }, -); - - -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ZF8UB1MtbPuOk7wTSFJR5Q - -__PACKAGE__->has_many( - "inputs", - "HydraFrontend::Schema::Inputs", - { "foreign.job" => "self.id" }, -); - -1; diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsetinputalts.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsetinputalts.pm index 033c2c50..f7603979 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsetinputalts.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsetinputalts.pm @@ -6,7 +6,7 @@ use warnings; use base 'DBIx::Class'; __PACKAGE__->load_components("Core"); -__PACKAGE__->table("jobsetInputAlts"); +__PACKAGE__->table("JobsetInputAlts"); __PACKAGE__->add_columns( "project", { data_type => "text", is_nullable => 0, size => undef }, @@ -33,8 +33,8 @@ __PACKAGE__->belongs_to( ); -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:ibTncC1AslPWt1eiTtwplA +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:bvEulSFMDlAMs39sIyHgZQ # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsetinputs.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsetinputs.pm index f17cf73d..61bfcfd3 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsetinputs.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsetinputs.pm @@ -6,7 +6,7 @@ use warnings; use base 'DBIx::Class'; __PACKAGE__->load_components("Core"); -__PACKAGE__->table("jobsetInputs"); +__PACKAGE__->table("JobsetInputs"); __PACKAGE__->add_columns( "project", { data_type => "text", is_nullable => 0, size => undef }, @@ -43,8 +43,8 @@ __PACKAGE__->has_many( ); -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:D1UzSZwPtwDmOI7q6g8uKQ +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:54xK3D1D0Jm5oKgRelXN7Q # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsets.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsets.pm index 91af1263..06f0d939 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsets.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Jobsets.pm @@ -6,7 +6,7 @@ use warnings; use base 'DBIx::Class'; __PACKAGE__->load_components("Core"); -__PACKAGE__->table("jobsets"); +__PACKAGE__->table("Jobsets"); __PACKAGE__->add_columns( "name", { data_type => "text", is_nullable => 0, size => undef }, @@ -46,18 +46,10 @@ __PACKAGE__->has_many( "foreign.project" => "self.project", }, ); -__PACKAGE__->has_many( - "jobs", - "HydraFrontend::Schema::Jobs", - { - "foreign.jobset" => "self.name", - "foreign.project" => "self.project", - }, -); -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:6Pyrgervmq03S5Nx8QfA1Q +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:JHirlq7Jc8dQOy+Op/VflA # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/src/HydraFrontend/lib/HydraFrontend/Schema/Projects.pm b/src/HydraFrontend/lib/HydraFrontend/Schema/Projects.pm index 1c1104c1..564297e5 100644 --- a/src/HydraFrontend/lib/HydraFrontend/Schema/Projects.pm +++ b/src/HydraFrontend/lib/HydraFrontend/Schema/Projects.pm @@ -6,7 +6,7 @@ use warnings; use base 'DBIx::Class'; __PACKAGE__->load_components("Core"); -__PACKAGE__->table("projects"); +__PACKAGE__->table("Projects"); __PACKAGE__->add_columns( "name", { data_type => "text", is_nullable => 0, size => undef }, @@ -22,15 +22,10 @@ __PACKAGE__->has_many( "HydraFrontend::Schema::Jobsets", { "foreign.project" => "self.name" }, ); -__PACKAGE__->has_many( - "jobs", - "HydraFrontend::Schema::Jobs", - { "foreign.project" => "self.name" }, -); -# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-10 14:25:07 -# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:p8LbF31qRl/JfMK5wfkeCg +# Created by DBIx::Class::Schema::Loader v0.04005 @ 2008-11-11 13:41:38 +# DO NOT MODIFY THIS OR ANYTHING ABOVE! md5sum:7Ag5ZfYVgfw3MJZkNUmBYw # You can replace this text with custom content, and it will be preserved on regeneration diff --git a/src/HydraFrontend/root/build.tt b/src/HydraFrontend/root/build.tt index 2b7137c3..67f29b2b 100644 --- a/src/HydraFrontend/root/build.tt +++ b/src/HydraFrontend/root/build.tt @@ -1,7 +1,12 @@ [% WRAPPER layout.tt title="Hydra Overview" %] [% USE date %] -

Job [% build.project.name %]:[% build.attrname %] build [% id %]

+

+ Job [% build.project.name %]:[% build.attrname %] build [% id %] + [% IF !build.finished %] + (scheduled) + [% END %] +

Information

@@ -11,6 +16,10 @@ Build ID: [% build.id %] + + Time added: + [% date.format(build.timestamp, '%Y-%m-%d %H:%M:%S') %] + Project: [% build.project.name %] @@ -28,26 +37,8 @@ [% build.description %] - Time added: - [% date.format(build.timestamp, '%Y-%m-%d %H:%M:%S') %] - - - Build started: - [% IF build.starttime %][% date.format(build.starttime, '%Y-%m-%d %H:%M:%S') %][% ELSE %](cached build)[% END %] - - - Build finished: - [% IF build.stoptime %][% date.format(build.stoptime, '%Y-%m-%d %H:%M:%S') %][% ELSE %](cached build)[% END %] - - - Duration (seconds): - - [% IF build.iscachedbuild %] - (cached build) - [% ELSE %] - [% build.stoptime - build.starttime %] - [% END %] - + System: + [% build.system %] Derivation store path: @@ -57,20 +48,41 @@ Output store path: [% build.outpath %] + [% IF build.finished %] - System: - [% build.system %] + Build started: + [% IF build.resultInfo.starttime %][% date.format(build.resultInfo.starttime, '%Y-%m-%d %H:%M:%S') %][% ELSE %](cached build)[% END %] + + + Build finished: + [% IF build.resultInfo.stoptime %][% date.format(build.resultInfo.stoptime, '%Y-%m-%d %H:%M:%S') %][% ELSE %](cached build)[% END %] + + + Duration (seconds): + + [% IF build.resultInfo.iscachedbuild %] + (cached build) + [% ELSE %] + [% build.resultInfo.stoptime - build.resultInfo.starttime %] + [% END %] + Status: - [% IF build.buildstatus == 0 %] + [% IF build.resultInfo.buildstatus == 0 %] [% ELSE %] [% END %] + [% ELSE %] + + Priority: + [% build.schedulingInfo.priority %] + + [% END %] @@ -101,6 +113,8 @@ +[% IF build.finished %] +

Build products