-
Notifications
You must be signed in to change notification settings - Fork 214
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
Define generic error.message
#1992
base: main
Are you sure you want to change the base?
Changes from all commits
b7509a7
c844ada
7387497
93ec7cf
2409bea
829aa0f
5c587fa
a44b437
c329f38
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
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: error | ||
|
||
# A brief description of the change. Surround your text with quotes ("") if it needs to start with a backtick (`). | ||
note: Add `error.message` property for human-readable error message. | ||
|
||
# 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: [1992] | ||
|
||
# (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: |
Original file line number | Diff line number | Diff line change | ||||
---|---|---|---|---|---|---|
|
@@ -9,9 +9,16 @@ This document defines the shared attributes used to report an error. | |||||
|
||||||
| Attribute | Type | Description | Examples | Stability | | ||||||
|---|---|---|---|---| | ||||||
| <a id="error-type" href="#error-type">`error.type`</a> | string | Describes a class of error the operation ended with. [1] | `timeout`; `java.net.UnknownHostException`; `server_certificate_invalid`; `500` |  | | ||||||
| <a id="error-message" href="#error-message">`error.message`</a> | string | A message providing more detail about an error in human-readable form. [1] | `Unexpected input type: string`; `The user has exceeded their storage quota` |  | | ||||||
| <a id="error-type" href="#error-type">`error.type`</a> | string | Describes a class of error the operation ended with. [2] | `timeout`; `java.net.UnknownHostException`; `server_certificate_invalid`; `500` |  | | ||||||
|
||||||
**[1] `error.type`:** The `error.type` SHOULD be predictable, and SHOULD have low cardinality. | ||||||
**[1] `error.message`:** `error.message` should provide additional context and detail about an error. | ||||||
It is NOT RECOMMENDED to duplicate the value of `error.type` in `error.message`. | ||||||
It is also NOT RECOMMENDED to duplicate the value of `exception.message` in `error.message`. | ||||||
|
||||||
`error.message` is recommended for events but not metrics or spans due to its unbounded cardinality and overlap with span status. | ||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||||
|
||||||
**[2] `error.type`:** The `error.type` SHOULD be predictable, and SHOULD have low cardinality. | ||||||
|
||||||
When `error.type` is set to a type (e.g., an exception type), its | ||||||
canonical class name identifying the type within the artifact SHOULD be used. | ||||||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -37,3 +37,14 @@ groups: | |
|
||
- Use a domain-specific attribute | ||
- Set `error.type` to capture all errors, regardless of whether they are defined within the domain-specific set or not. | ||
- id: error.message | ||
type: string | ||
stability: development | ||
examples: ["Unexpected input type: string", "The user has exceeded their storage quota"] | ||
brief: A message providing more detail about an error in human-readable form. | ||
note: | | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We should probably also recommend NOT using this in metrics due to cardinality. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. does the text below cover your concern?
|
||
`error.message` should provide additional context and detail about an error. | ||
It is NOT RECOMMENDED to duplicate the value of `error.type` in `error.message`. | ||
It is also NOT RECOMMENDED to duplicate the value of `exception.message` in `error.message`. | ||
|
||
`error.message` is recommended for events but not metrics or spans due to its unbounded cardinality and overlap with span status. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.