Skip to content

Commit d5d54cb

Browse files
model/profile: add symbolization information (#2522)
Signed-off-by: Florian Lehner <[email protected]> Co-authored-by: Christos Kalkanis <[email protected]>
1 parent 585c4c3 commit d5d54cb

File tree

10 files changed

+134
-3
lines changed

10 files changed

+134
-3
lines changed

.chloggen/profiles-symb-level.yaml

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
# Use this changelog template to create an entry for release notes.
2+
#
3+
# If your change doesn't affect end users you should instead start
4+
# your pull request title with [chore] or use the "Skip Changelog" label.
5+
6+
# One of 'breaking', 'deprecation', 'new_component', 'enhancement', 'bug_fix'
7+
change_type: enhancement
8+
9+
# The name of the area of concern in the attributes-registry, (e.g. http, cloud, db)
10+
component: pprof
11+
12+
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`).
13+
note: Introduce pprof attributes.
14+
15+
# Mandatory: One or more tracking issues related to the change. You can use the PR number here if no issue exists.
16+
# The values here must be integers.
17+
issues: [2522]
18+
19+
# (Optional) One or more lines of additional information to render under the primary note.
20+
# These lines will be padded with 2 spaces and then inserted directly into the document.
21+
# Use pipe (|) for multiline entries.
22+
subtext:

.github/CODEOWNERS

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -135,6 +135,7 @@
135135
# Profiling semantic conventions
136136
/docs/general/profiles.md @open-telemetry/specs-semconv-approvers @open-telemetry/profiling-approvers
137137
/model/profile/ @open-telemetry/specs-semconv-approvers @open-telemetry/profiling-approvers
138+
/model/pprof/ @open-telemetry/specs-semconv-approvers @open-telemetry/profiling-approvers
138139

139140
# SDK health semantic conventions
140141
/docs/otel/ @open-telemetry/specs-semconv-approvers @open-telemetry/semconv-sdk-health-approvers

.github/ISSUE_TEMPLATE/bug_report.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,7 @@ body:
7878
- area:os
7979
- area:otel
8080
- area:peer
81+
- area:pprof
8182
- area:process
8283
- area:profile
8384
- area:rpc

.github/ISSUE_TEMPLATE/change_proposal.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -70,6 +70,7 @@ body:
7070
- area:os
7171
- area:otel
7272
- area:peer
73+
- area:pprof
7374
- area:process
7475
- area:profile
7576
- area:rpc

.github/ISSUE_TEMPLATE/new-conventions.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,7 @@ body:
8181
- area:os
8282
- area:otel
8383
- area:peer
84+
- area:pprof
8485
- area:process
8586
- area:profile
8687
- area:rpc

docs/general/profiles.md

Lines changed: 37 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,20 +2,24 @@
22
linkTitle: Profiles
33
--->
44

5-
# General profiles attributes
5+
# Profiles attributes
66

77
**Status**: [Development][DocumentStatus]
88

99
<!-- toc -->
1010

11-
- [Frame types](#frame-types)
11+
- [General profiles identification attributes](#general-profiles-identification-attributes)
12+
- [Frame types](#frame-types)
13+
- [Compatibility with pprof](#compatibility-with-pprof)
1214

1315
<!-- tocstop -->
1416

17+
## General profiles identification attributes
18+
1519
The attributes described in this section are rather generic.
1620
They may be used in any Profiles record they apply to.
1721

18-
## Frame types
22+
### Frame types
1923

2024
**Description:** Describes the origin of a single frame in a Profile.
2125

@@ -54,4 +58,34 @@ They may be used in any Profiles record they apply to.
5458
<!-- END AUTOGENERATED TEXT -->
5559
<!-- endsemconv -->
5660

61+
## Compatibility with pprof
62+
63+
Existing [pprof][pprofLink] formats can be unambiguously mapped to this data
64+
model. Reverse mapping from this data model is also possible to the extent that
65+
the target profiles format has equivalent capabilities.
66+
67+
The attributes described in this section are specific to support convertibility.
68+
They may be used in any Profiles record they apply to.
69+
70+
<!-- semconv pprof(full) -->
71+
<!-- NOTE: THIS TEXT IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
72+
<!-- see templates/registry/markdown/snippet.md.j2 -->
73+
<!-- prettier-ignore-start -->
74+
<!-- markdownlint-capture -->
75+
<!-- markdownlint-disable -->
76+
77+
| Attribute | Type | Description | Examples | [Requirement Level](https://opentelemetry.io/docs/specs/semconv/general/attribute-requirement-level/) | Stability |
78+
|---|---|---|---|---|---|
79+
| [`pprof.location.is_folded`](/docs/registry/attributes/pprof.md) | boolean | Provides an indication that multiple symbols map to this location's address, for example due to identical code folding by the linker. In that case the line information represents one of the multiple symbols. This field must be recomputed when the symbolization state of the profile changes. | | `Recommended` | ![Development](https://img.shields.io/badge/-development-blue) |
80+
| [`pprof.mapping.has_filenames`](/docs/registry/attributes/pprof.md) | boolean | Indicates that there are filenames related to this mapping. | | `Recommended` | ![Development](https://img.shields.io/badge/-development-blue) |
81+
| [`pprof.mapping.has_functions`](/docs/registry/attributes/pprof.md) | boolean | Indicates that there are functions related to this mapping. | | `Recommended` | ![Development](https://img.shields.io/badge/-development-blue) |
82+
| [`pprof.mapping.has_inline_frames`](/docs/registry/attributes/pprof.md) | boolean | Indicates that there are inline frames related to this mapping. | | `Recommended` | ![Development](https://img.shields.io/badge/-development-blue) |
83+
| [`pprof.mapping.has_line_numbers`](/docs/registry/attributes/pprof.md) | boolean | Indicates that there are line numbers related to this mapping. | | `Recommended` | ![Development](https://img.shields.io/badge/-development-blue) |
84+
85+
<!-- markdownlint-restore -->
86+
<!-- prettier-ignore-end -->
87+
<!-- END AUTOGENERATED TEXT -->
88+
<!-- endsemconv -->
89+
5790
[DocumentStatus]: https://opentelemetry.io/docs/specs/otel/document-status
91+
[pprofLink]: https://github.com/google/pprof

docs/registry/attributes/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,7 @@ Currently, the following namespaces exist:
8787
- [OS](os.md)
8888
- [OTel](otel.md)
8989
- [Peer](peer.md)
90+
- [Pprof](pprof.md)
9091
- [Process](process.md)
9192
- [Profile](profile.md)
9293
- [RPC](rpc.md)

docs/registry/attributes/pprof.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<!-- NOTE: THIS FILE IS AUTOGENERATED. DO NOT EDIT BY HAND. -->
2+
<!-- see templates/registry/markdown/attribute_namespace.md.j2 -->
3+
4+
# Pprof
5+
6+
## Pprof specific attributes for the Profiling signal
7+
8+
Attributes specific to pprof that help convert from pprof to Profiling signal.
9+
10+
| Attribute | Type | Description | Examples | Stability |
11+
|---|---|---|---|---|
12+
| <a id="pprof-location-is-folded" href="#pprof-location-is-folded">`pprof.location.is_folded`</a> | boolean | Provides an indication that multiple symbols map to this location's address, for example due to identical code folding by the linker. In that case the line information represents one of the multiple symbols. This field must be recomputed when the symbolization state of the profile changes. | | ![Development](https://img.shields.io/badge/-development-blue) |
13+
| <a id="pprof-mapping-has-filenames" href="#pprof-mapping-has-filenames">`pprof.mapping.has_filenames`</a> | boolean | Indicates that there are filenames related to this mapping. | | ![Development](https://img.shields.io/badge/-development-blue) |
14+
| <a id="pprof-mapping-has-functions" href="#pprof-mapping-has-functions">`pprof.mapping.has_functions`</a> | boolean | Indicates that there are functions related to this mapping. | | ![Development](https://img.shields.io/badge/-development-blue) |
15+
| <a id="pprof-mapping-has-inline-frames" href="#pprof-mapping-has-inline-frames">`pprof.mapping.has_inline_frames`</a> | boolean | Indicates that there are inline frames related to this mapping. | | ![Development](https://img.shields.io/badge/-development-blue) |
16+
| <a id="pprof-mapping-has-line-numbers" href="#pprof-mapping-has-line-numbers">`pprof.mapping.has_line_numbers`</a> | boolean | Indicates that there are line numbers related to this mapping. | | ![Development](https://img.shields.io/badge/-development-blue) |

model/pprof/common.yaml

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
groups:
2+
3+
- id: pprof
4+
type: attribute_group
5+
brief: >
6+
Attributes specific to pprof that help convert from pprof to Profiling signal.
7+
attributes:
8+
- ref: pprof.mapping.has_functions
9+
requirement_level: recommended
10+
- ref: pprof.mapping.has_filenames
11+
requirement_level: recommended
12+
- ref: pprof.mapping.has_line_numbers
13+
requirement_level: recommended
14+
- ref: pprof.mapping.has_inline_frames
15+
requirement_level: recommended
16+
- ref: pprof.location.is_folded
17+
requirement_level: recommended

model/pprof/registry.yaml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
groups:
2+
3+
- id: registry.pprof
4+
type: attribute_group
5+
display_name: Pprof specific attributes for the Profiling signal
6+
brief: >
7+
Attributes specific to pprof that help convert from pprof to Profiling signal.
8+
attributes:
9+
- id: pprof.mapping.has_functions
10+
brief: >
11+
Indicates that there are functions related to this mapping.
12+
type: boolean
13+
stability: development
14+
- id: pprof.mapping.has_filenames
15+
brief: >
16+
Indicates that there are filenames related to this mapping.
17+
type: boolean
18+
stability: development
19+
- id: pprof.mapping.has_line_numbers
20+
brief: >
21+
Indicates that there are line numbers related to this mapping.
22+
type: boolean
23+
stability: development
24+
- id: pprof.mapping.has_inline_frames
25+
brief: >
26+
Indicates that there are inline frames related to this mapping.
27+
type: boolean
28+
stability: development
29+
- id: pprof.location.is_folded
30+
brief: >
31+
Provides an indication that multiple symbols map to this location's
32+
address, for example due to identical code folding by the linker. In
33+
that case the line information represents one of the multiple symbols.
34+
This field must be recomputed when the symbolization state of the
35+
profile changes.
36+
stability: development
37+
type: boolean

0 commit comments

Comments
 (0)