Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add additional process attributes to registry #564

Merged
merged 30 commits into from
Apr 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
4afb258
Add additional fields to process attribute registry
mjwolf Nov 21, 2023
a25b463
Update field descriptions
mjwolf Nov 21, 2023
e388e84
Update process schema
mjwolf Nov 23, 2023
6dbeac8
Merge remote-tracking branch 'origin/main' into add-process-registry-…
mjwolf Nov 28, 2023
a98e855
Specify ISO 8601 format for start, end fields
mjwolf Nov 28, 2023
2910bc0
Update CHANGELOG
mjwolf Nov 28, 2023
4ceb5f6
Update schema-next.yaml
mjwolf Nov 28, 2023
3c92a86
Merge remote-tracking branch 'origin/main' into add-process-registry-…
mjwolf Dec 4, 2023
90d9b33
Merge remote-tracking branch 'origin/main' into add-process-registry-…
mjwolf Dec 7, 2023
d38dcec
Revert rename of parent_pid
mjwolf Dec 7, 2023
e2d4e36
Remove note on usage of process.owner
mjwolf Dec 7, 2023
7b7a518
Revert change to PPID description
mjwolf Dec 7, 2023
f2e8bd7
Merge remote-tracking branch 'origin/main' into add-process-registry-…
mjwolf Dec 12, 2023
14ffaa0
Change env_vars description to SHOULD filter
mjwolf Dec 12, 2023
4c3364c
Merge branch 'open-telemetry:main' into add-process-registry-fields
mjwolf Dec 12, 2023
b9b6b80
Merge branch 'main' into add-process-registry-fields
mjwolf Jan 17, 2024
16cf7dd
Merge remote-tracking branch 'origin/main' into add-process-registry-…
mjwolf Jan 29, 2024
edf0aa3
Remove env_vars from process schema
mjwolf Jan 29, 2024
86d3dad
Merge branch 'open-telemetry:main' into add-process-registry-fields
mjwolf Jan 30, 2024
29c99de
Move change to unreleased section of changelog
mjwolf Jan 30, 2024
1e0d5b2
Merge remote-tracking branch 'origin/main' into add-process-registry-…
mjwolf Feb 8, 2024
b79e269
Add changelog entry
mjwolf Feb 8, 2024
ab10ce1
Merge branch 'main' into add-process-registry-fields
mjwolf Mar 19, 2024
388bffb
Merge remote-tracking branch 'origin/main' into add-process-registry-…
mjwolf Apr 5, 2024
25c54a3
Add experimental stability tag to new fields
mjwolf Apr 5, 2024
5773996
Use namespaces to group process creation and exit fields
mjwolf Apr 5, 2024
2bc84d2
Merge branch 'add-process-registry-fields' of github.com:mjwolf/seman…
mjwolf Apr 5, 2024
8280d52
Undo change to CHANGELOG.md
mjwolf Apr 5, 2024
eca5bff
Merge remote-tracking branch 'origin/main' into add-process-registry-…
mjwolf Apr 5, 2024
07a368d
Merge branch 'main' into add-process-registry-fields
trisch-me Apr 9, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 22 additions & 0 deletions .chloggen/564.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Use this changelog template to create an entry for release notes.
#
# If your change doesn't affect end users you should instead start
# your pull request title with [chore] or use the "Skip Changelog" label.

# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
change_type: enhancement

# The name of the area of concern in the attributes-registry, (e.g. http, cloud, db)
component: process

# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
note: Add additional attributes to process attribute registry

# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists.
# The values here must be integers.
issues: [564]

# (Optional) One or more lines of additional information to render under the primary note.
# These lines will be padded with 2 spaces and then inserted directly into the document.
# Use pipe (|) for multiline entries.
subtext:
15 changes: 15 additions & 0 deletions docs/attributes-registry/process.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,27 @@
| `process.command` | string | The command used to launch the process (i.e. the command name). On Linux based systems, can be set to the zeroth string in `proc/[pid]/cmdline`. On Windows, can be set to the first parameter extracted from `GetCommandLineW`. | `cmd/otelcol` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.command_args` | string[] | All the command arguments (including the command/executable itself) as received by the process. On Linux-based systems (and some other Unixoid systems supporting procfs), can be set according to the list of null-delimited strings extracted from `proc/[pid]/cmdline`. For libc-based executables, this would be the full argv vector passed to `main`. | `[cmd/otecol, --config=config.yaml]` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.command_line` | string | The full command used to launch the process as a single string representing the full command. On Windows, can be set to the result of `GetCommandLineW`. Do not set this if you have to assemble it just for monitoring; use `process.command_args` instead. | `C:\cmd\otecol --config="my directory\config.yaml"` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.creation.time` | string | The date and time the process was created, in ISO 8601 format. | `2023-11-21T09:25:34.853Z` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.executable.name` | string | The name of the process executable. On Linux based systems, can be set to the `Name` in `proc/[pid]/status`. On Windows, can be set to the base name of `GetProcessImageFileNameW`. | `otelcol` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.executable.path` | string | The full path to the process executable. On Linux based systems, can be set to the target of `proc/[pid]/exe`. On Windows, can be set to the result of `GetProcessImageFileNameW`. | `/usr/bin/cmd/otelcol` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.exit.code` | int | The exit code of the process. | `127` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.exit.time` | string | The date and time the process exited, in ISO 8601 format. | `2023-11-21T09:26:12.315Z` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.group_leader.pid` | int | The PID of the process's group leader. This is also the process group ID (PGID) of the process. | `23` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.interactive` | boolean | Whether the process is connected to an interactive shell. | | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.owner` | string | The username of the user that owns the process. | `root` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.parent_pid` | int | Parent Process identifier (PPID). | `111` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.pid` | int | Process identifier (PID). | `1234` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.real_user.id` | int | The real user ID (RUID) of the process. | `1000` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.real_user.name` | string | The username of the real user of the process. | `operator` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.runtime.description` | string | An additional description about the runtime of the process, for example a specific vendor customization of the runtime environment. | `Eclipse OpenJ9 Eclipse OpenJ9 VM openj9-0.21.0` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.runtime.name` | string | The name of the runtime of this process. For compiled native binaries, this SHOULD be the name of the compiler. | `OpenJDK Runtime Environment` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.runtime.version` | string | The version of the runtime of this process, as returned by the runtime without modification. | `14.0.2` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.saved_user.id` | int | The saved user ID (SUID) of the process. | `1002` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.saved_user.name` | string | The username of the saved user. | `operator` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.session_leader.pid` | int | The PID of the process's session leader. This is also the session ID (SID) of the process. | `14` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.user.id` | int | The effective user ID (EUID) of the process. | `1001` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.user.name` | string | The username of the effective user of the process. | `root` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |
| `process.vpid` | int | Virtual process identifier. [1] | `12` | ![Experimental](https://img.shields.io/badge/-experimental-blue) |

**[1]:** The process ID within a PID namespace. This is not necessarily unique across all processes on the host but it is unique within the process namespace that the process exists within.
<!-- endsemconv -->
85 changes: 84 additions & 1 deletion model/registry/process.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,30 @@ groups:
brief: >
Parent Process identifier (PPID).
examples: [111]
- id: vpid
type: int
stability: experimental
brief: >
Virtual process identifier.
note: >
The process ID within a PID namespace. This is not necessarily unique
across all processes on the host but it is unique within the process
namespace that the process exists within.
examples: [12]
- id: session_leader.pid
type: int
stability: experimental
brief: >
The PID of the process's session leader. This is also the session ID
(SID) of the process.
examples: [14]
- id: group_leader.pid
type: int
stability: experimental
brief: >
The PID of the process's group leader. This is also the process group
ID (PGID) of the process.
examples: [23]
- id: executable.name
type: string
stability: experimental
Expand Down Expand Up @@ -65,7 +89,43 @@ groups:
stability: experimental
brief: >
The username of the user that owns the process.
examples: 'root'
examples: ['root']
- id: user.id
type: int
stability: experimental
brief: >
The effective user ID (EUID) of the process.
examples: [1001]
- id: user.name
type: string
stability: experimental
brief: >
The username of the effective user of the process.
examples: ['root']
- id: real_user.id
type: int
stability: experimental
brief: >
The real user ID (RUID) of the process.
examples: [1000]
- id: real_user.name
type: string
stability: experimental
brief: >
The username of the real user of the process.
examples: ['operator']
- id: saved_user.id
type: int
stability: experimental
brief: >
The saved user ID (SUID) of the process.
examples: [1002]
- id: saved_user.name
type: string
stability: experimental
brief: >
The username of the saved user.
examples: ['operator']
- id: runtime.name
type: string
stability: experimental
Expand All @@ -87,3 +147,26 @@ groups:
An additional description about the runtime of the process, for example
a specific vendor customization of the runtime environment.
examples: 'Eclipse OpenJ9 Eclipse OpenJ9 VM openj9-0.21.0'
- id: creation.time
type: string
stability: experimental
brief: >
The date and time the process was created, in ISO 8601 format.
examples: ['2023-11-21T09:25:34.853Z']
- id: exit.time
type: string
stability: experimental
brief: >
The date and time the process exited, in ISO 8601 format.
examples: ['2023-11-21T09:26:12.315Z']
- id: exit.code
type: int
stability: experimental
brief: >
The exit code of the process.
examples: [127]
- id: interactive
type: boolean
stability: experimental
brief: >
Whether the process is connected to an interactive shell.
Loading