|
| 1 | +// Copyright (C) 2025 The Android Open Source Project |
| 2 | +// |
| 3 | +// Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 | +// you may not use this file except in compliance with the License. |
| 5 | +// You may obtain a copy of the License at |
| 6 | +// |
| 7 | +// http://www.apache.org/licenses/LICENSE-2.0 |
| 8 | +// |
| 9 | +// Unless required by applicable law or agreed to in writing, software |
| 10 | +// distributed under the License is distributed on an "AS IS" BASIS, |
| 11 | +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 | +// See the License for the specific language governing permissions and |
| 13 | +// limitations under the License. |
| 14 | + |
| 15 | +syntax = "proto2"; |
| 16 | + |
| 17 | +package perfetto.protos; |
| 18 | + |
| 19 | +// A journald log event packet, collected from the Linux systemd journal. |
| 20 | +// Emitted by the "linux.journald" data source in traced_probes. |
| 21 | +// Next field id: 13, statistics starting at 20 |
| 22 | +message JournaldEventPacket { |
| 23 | + // _PID: PID of the process that wrote the log entry (trusted). |
| 24 | + optional uint32 pid = 1; |
| 25 | + |
| 26 | + // _TID: thread ID of the logging thread (trusted, set by journald for |
| 27 | + // native journal protocol entries). Absent for syslog, stdout-piped, and |
| 28 | + // kernel entries. |
| 29 | + optional uint32 tid = 2; |
| 30 | + |
| 31 | + // _UID: user ID of the process (trusted). |
| 32 | + optional uint32 uid = 3; |
| 33 | + |
| 34 | + // _GID: group ID of the process (trusted). |
| 35 | + optional uint32 gid = 4; |
| 36 | + |
| 37 | + // PRIORITY: syslog priority level 0 (EMERG) .. 7 (DEBUG). |
| 38 | + optional uint32 prio = 5; |
| 39 | + |
| 40 | + // SYSLOG_IDENTIFIER: program name / tag, set by the logging application. |
| 41 | + optional string tag = 6; |
| 42 | + |
| 43 | + // MESSAGE: the human-readable log message text. |
| 44 | + optional string message = 7; |
| 45 | + |
| 46 | + // _COMM: short process name as known to the kernel (trusted). |
| 47 | + optional string comm = 8; |
| 48 | + |
| 49 | + // _EXE: full executable path (trusted). |
| 50 | + optional string exe = 9; |
| 51 | + |
| 52 | + // _SYSTEMD_UNIT: the systemd unit that owns this process (trusted). |
| 53 | + optional string systemd_unit = 10; |
| 54 | + |
| 55 | + // _HOSTNAME: hostname of the machine (trusted). |
| 56 | + optional string hostname = 11; |
| 57 | + |
| 58 | + // _TRANSPORT: how the entry was received by journald (trusted). |
| 59 | + // Values: "audit", "driver", "syslog", "journal", "stdout", "kernel". |
| 60 | + optional string transport = 12; |
| 61 | + |
| 62 | + // These statistics emitted once on Flush() |
| 63 | + optional uint64 num_total = 20; |
| 64 | + optional uint64 num_failed = 21; |
| 65 | + optional uint64 num_skipped = 22; |
| 66 | +} |
0 commit comments