core: add ExecMainHandoverTimestamp property recording time-of-execve
Enable the exec_fd logic for Type=notify* services too, and change it to send a timestamp instead of a '1' byte. Record the timestamp in a new ExecMainHandoverTimestamp property so that users can track accurately when control is handed over from systemd to the service payload, so that latency and startup performance can be trivially and accurately tracked and attributed.
This commit is contained in:
committed by
Zbigniew Jędrzejewski-Szmek
parent
489ae6b3d5
commit
93cb78aee2
@@ -1866,6 +1866,11 @@ void exec_status_dump(const ExecStatus *s, FILE *f, const char *prefix) {
|
||||
"%sStart Timestamp: %s\n",
|
||||
prefix, FORMAT_TIMESTAMP(s->start_timestamp.realtime));
|
||||
|
||||
if (dual_timestamp_is_set(&s->handover_timestamp))
|
||||
fprintf(f,
|
||||
"%sHandover Timestamp: %s\n",
|
||||
prefix, FORMAT_TIMESTAMP(s->handover_timestamp.realtime));
|
||||
|
||||
if (dual_timestamp_is_set(&s->exit_timestamp))
|
||||
fprintf(f,
|
||||
"%sExit Timestamp: %s\n"
|
||||
|
||||
Reference in New Issue
Block a user