[PATCH] testbot/web: Trace how long it takes to generate the JobDetails page.
Francois Gouget
fgouget at codeweavers.com
Fri Nov 8 03:52:41 CST 2019
Signed-off-by: Francois Gouget <fgouget at codeweavers.com>
---
The parsing of the reference reports to detect new failres makes it slow
(see bug 48035).
testbot/web/JobDetails.pl | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/testbot/web/JobDetails.pl b/testbot/web/JobDetails.pl
index fc98e14b0..a59fa000d 100644
--- a/testbot/web/JobDetails.pl
+++ b/testbot/web/JobDetails.pl
@@ -31,6 +31,7 @@ use URI::Escape;
use WineTestBot::Config;
use WineTestBot::Jobs;
+use WineTestBot::Log; # For Elapsed()
use WineTestBot::LogUtils;
use WineTestBot::Missions;
use WineTestBot::StepsTasks;
@@ -41,6 +42,7 @@ use WineTestBot::Engine::Notify;
sub _initialize($$$)
{
my ($self, $Request, $RequiredRole) = @_;
+ $self->{start} = Time();
my $JobId = $self->GetParam("Key");
if (! defined($JobId))
@@ -645,6 +647,12 @@ sub GenerateDataCell($$$$$)
}
}
+sub GenerateFooter($)
+{
+ my ($self) = @_;
+ print "<p class='GeneralFooterText'>Generated in ", Elapsed($self->{start}), " s</p>\n";
+}
+
package main;
--
2.20.1
More information about the wine-devel
mailing list