Skip to content

Commit 7a35379

Browse files
authored
[chore] System Semconv Description Guidance (#2826)
1 parent f1b1d72 commit 7a35379

File tree

1 file changed

+53
-9
lines changed

1 file changed

+53
-9
lines changed

docs/non-normative/groups/system/design-philosophy.md

Lines changed: 53 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -168,22 +168,66 @@ applied in a cross-platform manner. See
168168

169169
### Value
170170

171-
For General Class, the value we can be prescriptive with the value of the
172-
instrumentation. We want to ensure General Class instrumentation most closely
173-
matches our vision for our general use cases, and we want to ensure that users
174-
who are not specialists and just want the most important basic information can
175-
acquire it as easily as possible using out-of-the-box semconv instrumentation.
176-
This means we are more likely within General Class instrumentation to make
177-
judgements about exactly what the value should be, and whether the value should
178-
be reshaped by instrumentation in any case when pulling the values from sources
179-
if it serves general purpose use cases.
171+
For General Class, we can be prescriptive with what the value of the
172+
instrumentation should be. We want to ensure General Class instrumentation most
173+
closely matches our vision for our general use cases, and we want to ensure that
174+
users who are not specialists and just want the most important basic information
175+
can acquire it as easily as possible using out-of-the-box semconv
176+
instrumentation. This means we are more likely within General Class
177+
instrumentation to make judgements about exactly what the value should be, and
178+
whether the value should be reshaped by instrumentation in any case when pulling
179+
the values from sources if it serves general purpose use cases.
180180

181181
For Specialist Class, we should strive not to be prescriptive and instead match
182182
the concept being modeled as closely as possible. We expect specialist class
183183
instrumentation to be enabled by the people who already understand it. In a
184184
System Semconv context, these may be things a user previously gathered manually
185185
or through existing OS tools that they want to model as OTLP.
186186

187+
### Descriptions
188+
189+
The concepts being modeled by System Semantic Conventions can be very complex,
190+
sometimes requiring deeper knowledge of operating system and computing concepts
191+
than most general practitioners would need. As a result, it is tempting to
192+
provide detailed explanations of the concepts we are modelling. However, we feel
193+
that the amount of explanation that would be required to teach these concepts
194+
to a reader with no knowledge would require so much context and nuance that it
195+
would clutter the resulting documentation and obscure the information we really
196+
need to convey, which is not just what the instrumentation is but details about
197+
how and why to instrument it certain ways.
198+
199+
This means that for System Semantic Conventions documentation,
200+
**we assume a baseline level of knowledge of the concepts being instrumented**.
201+
The `brief` and `note` fields of metrics and attributes should be used to convey
202+
information that is crucial to understanding the instrumentation intention,
203+
i.e.:
204+
205+
* Differences in the same piece of data when it is instrumented on different
206+
platforms
207+
* When we recommend calculations be done on particular data rather than
208+
surfacing direct values from existing tools
209+
* When particular names or enum values were chosen when there are common
210+
alternate terms for the same concept
211+
212+
For root metrics and attributes, we will strive to always have a `brief` field.
213+
The `brief` field should explain what the metric/attribute is, and if the
214+
explanation of a value is simple (i.e. simply surfacing a value from a common
215+
source like `procfs`) then the explanation of what the value should be can go
216+
in the brief. If the value needs some calculation explanation and justification,
217+
the information should be moved to the `note` field.
218+
For enum values, it is often the case that the intention of these values is
219+
obvious given whatever `brief` was provided for the attribute as a whole. A
220+
brief can be included in a scenario where we have had to make some choice on the
221+
value that isn't immediately obvious; the most common scenario is when some
222+
terminology differs across platforms and we had to choose one term to represent
223+
all scenarios. In this case, the `brief` can be used to clarify our intention.
224+
225+
In cases where information about a concept is required to describe our intention
226+
for instrumentation, all information must come with citations to authoritative
227+
documentation (i.e. Linux `man` pages, Win32 API docs, etc). We do not want to
228+
invent any new explanations about existing concepts in our own words within our
229+
convention documentation.
230+
187231
### Case study: `process.cgroup`
188232

189233
Relevant discussions:

0 commit comments

Comments
 (0)