Add page showing latest build steps
[?]
Jul 10, 2015, 1:08 PM
TX7Q4RASUYPTHIHZFACQ227BIZYLNJGRA5HHIAFQWCL4FHEHVGPQCDependencies
- [2]
FHOH54HQWhen searching a path / drv path, use separate queries for both options to prevent seq. scan. - [3]
6GZZDDQBMove the store path size chart to the job page - [4]
AFNDUSGDSet Expires headers for Hydra's binary cache - [5]
PH3DFCNURender machine correctly if it doesn't contain @ - [6]
KDBWLKRPIndex BuildSteps on propagatedFrom - [7]
LCLXI7PTSearch: Mark disabled projects/jobsets/jobs - [8]
24BMQDZAStart of single-process hydra-queue-runner - [9]
YM27DTVTRemove superfluous HYDRA_LOGO environment variable - [10]
HRAFVVOEmake logo configurable via HYDRA_LOGO env var - [11]
VH5ZABDRAdd a page to show the latest evaluations for the entire server - [12]
R6APT7HGFix hydra_logo setting - [13]
UICHT2PSAdd a search feature - [14]
WUCOEIFASearch: Limit the number of results - [15]
2GUAKGTBFix indentation of build.tt - [16]
GK326R5NSearch: Don't return hidden projects/jobsets - [17]
WXV6M6XNAdd a convenient way to get logs of a path/drv. Requested by phreedom. - [18]
EJ7C77C3Allow searching for store and drv paths. Only does a complete match to reduce load on database. - [*]
J5UVLXOK* Start of a basic Catalyst web interface. - [*]
LBNVQXUB* Build the /build stuff in a separate controller. - [*]
CS7T2XFI - [*]
IK53RV4V - [*]
QCGCX2BRGeneralize lazy tabs - [*]
D5QIOJGP* Move everything up one directory. - [*]
QL55ECJ6- adapted ui for hydra, more in line with nixos.org website - [*]
4JS4DWHDAll/recent builds -> Latest builds - [*]
JZVRK5QJGroup some menu items together under a "Status" menu - [*]
N22GPKYT* Put info about logs / build products in the DB. - [*]
PMNWRTGJAdd multiple output support
Change contents
- edit in src/lib/Hydra/Controller/Root.pm at line 293
}sub steps :Local Args(0) {my ($self, $c) = @_;$c->stash->{template} = 'steps.tt';my $page = int($c->req->param('page') || "1") || 1;my $resultsPerPage = 20;$c->stash->{page} = $page;$c->stash->{resultsPerPage} = $resultsPerPage;$c->stash->{steps} = [ $c->model('DB::BuildSteps')->search({ starttime => { '!=', undef },stoptime => { '!=', undef }},{ order_by => [ "stoptime desc" ],rows => $resultsPerPage,offset => ($page - 1) * $resultsPerPage}) ];$c->stash->{total} = approxTableSize($c, "IndexBuildStepsOnStopTime"); - edit in src/lib/Hydra/Controller/Root.pm at line 367
} - edit in src/lib/Hydra/Controller/Root.pm at line 369[7.266]→[7.416:418](∅→∅),[2.286]→[7.416:418](∅→∅),[7.353]→[7.416:418](∅→∅),[7.709]→[7.416:418](∅→∅),[7.843]→[7.416:418](∅→∅),[7.905]→[7.416:418](∅→∅),[7.416]→[7.416:418](∅→∅)
} - edit in src/lib/Hydra/Helper/CatalystUtils.pm at line 26
approxTableSize - edit in src/lib/Hydra/Helper/CatalystUtils.pm at line 297
}sub approxTableSize {my ($c, $name) = @_;return $c->model('DB')->schema->storage->dbh->selectrow_hashref("select reltuples::int from pg_class where relname = lower(?)", { }, $name)->{"reltuples"}; - replacement in src/root/build.tt at line 48
<td>[% step.machine.split('@').1 || step.machine %]</td><td>[% INCLUDE renderMachineName machine=step.machine %]</td> - edit in src/root/common.tt at line 646
BLOCK renderMachineName;machine ? stripSSHUser(machine).match('^([^\.]*)').0 : "localhost";END; - file addition: steps.tt[25.1486]
[% WRAPPER layout.tt title="Latest steps" %][% PROCESS common.tt %]<p>Showing steps [% (page - 1) * resultsPerPage + 1 %] - [% (page - 1)* resultsPerPage + steps.size %] of about [% total %] inorder of descending finish time.</p><table class="table table-striped table-condensed clickable-rows"><thead><tr><th></th><th>What</th><th>Job</th><th>Build</th><th>Step</th><th>When</th><th>Duration</th><th>Machine</th></tr></thead><tbody>[% FOREACH step IN steps %]<tr><td>[% INCLUDE renderBuildStatusIcon buildstatus=step.status size=16 %]</td><td><tt>[% step.drvpath.match('-(.*).drv').0 %]</tt></td><td><tt>[% INCLUDE renderFullJobNameOfBuild build=step.build %]</tt></td><td><a href="[% c.uri_for('/build' step.build.id) %]">[% step.build.id %]</a></td><td><a class="row-link" href="[% c.uri_for('/build' step.build.id 'nixlog' step.stepnr 'tail-reload') %]">[% step.stepnr %]</a></td><td>[% INCLUDE renderRelativeDate timestamp=step.stoptime %]</td><td style="width: 10em">[% INCLUDE renderDuration duration = step.stoptime - step.starttime %] </td><td><tt>[% INCLUDE renderMachineName machine=step.machine %]</tt></td></tr>[% END %]</tbody></table>[% INCLUDE renderPager %][% END %] - edit in src/root/topbar.tt at line 34
[% INCLUDE menuItemuri = c.uri_for(c.controller('Root').action_for('steps'))title = "Latest steps" %] - edit in src/sql/hydra.sql at line 598[6.109][30.20632]
create index IndexBuildStepsOnStopTime on BuildSteps(stopTime desc) where startTime is not null and stopTime is not null; - file addition: upgrade-37.sql[25.3004]
create index IndexBuildStepsOnStopTime on BuildSteps(stopTime desc) where startTime is not null and stopTime is not null;