MCPcopy Create free account
hub / github.com/apache/httpd / md_job_log_append

Function md_job_log_append

modules/md/md_status.c:437–453  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

435}
436
437void md_job_log_append(md_job_t *job, const char *type,
438 const char *status, const char *detail)
439{
440 md_json_t *entry;
441 char ts[APR_RFC822_DATE_LEN];
442
443 entry = md_json_create(job->p);
444 apr_rfc822_date(ts, apr_time_now());
445 md_json_sets(ts, entry, MD_KEY_WHEN, NULL);
446 md_json_sets(type, entry, MD_KEY_TYPE, NULL);
447 if (status) md_json_sets(status, entry, MD_KEY_STATUS, NULL);
448 if (detail) md_json_sets(detail, entry, MD_KEY_DETAIL, NULL);
449 if (!job->log) job->log = md_json_create(job->p);
450 md_json_insertj(entry, 0, job->log, MD_KEY_ENTRIES, NULL);
451 md_json_limita(job->max_log, job->log, MD_KEY_ENTRIES, NULL);
452 job->dirty = 1;
453}
454
455typedef struct {
456 md_job_t *job;

Callers 6

ostat_on_req_statusFunction · 0.85
process_drive_jobFunction · 0.85
job_result_updateFunction · 0.85
md_job_start_runFunction · 0.85
md_job_end_runFunction · 0.85
notifyFunction · 0.85

Calls 4

md_json_createFunction · 0.85
md_json_setsFunction · 0.85
md_json_insertjFunction · 0.85
md_json_limitaFunction · 0.85

Tested by

no test coverage detected