This makes it easy to track the beginning and end of request.
i.e.:
$app->log->debug(sub {
my $timing = $self->helpers->timing;
my $elapsed = $timing->elapsed('mojo.timer') // 0;
my $rps = $timing->rps($elapsed) // '??';
my $code = $res->code;
my $msg = $res->message || $res->default_message($code);
my $route = $self->match->endpoint->route->to_string;
my $req_id = $self->req->request_id;
return "\"$route\" ($req_id) $code $msg (${elapsed}s, $rps/s)";
}) unless $stash->{'mojo.static'};
--
You received this message because you are subscribed to the Google Groups
"Mojolicious" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/mojolicious.
To view this discussion on the web visit
https://groups.google.com/d/msgid/mojolicious/129c0390-81cb-4cbb-8a53-a26c48c724c6%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.