| 640 | REGISTER_NOTIFICATION(deprecated_oneshot); |
| 641 | |
| 642 | static void log_notification_serialize(struct json_stream *stream, |
| 643 | enum log_level level, |
| 644 | struct timeabs time, |
| 645 | const char *source, |
| 646 | const char *logmsg) |
| 647 | { |
| 648 | json_add_string(stream, "level", log_level_name(level)); |
| 649 | json_add_timestr(stream, "time", time.ts); |
| 650 | json_add_timeiso(stream, "timestamp", time); |
| 651 | json_add_string(stream, "source", source); |
| 652 | json_add_string(stream, "log", logmsg); |
| 653 | } |
| 654 | |
| 655 | |
| 656 | REGISTER_NOTIFICATION(log); |
no test coverage detected