Skip to content

Commit

Permalink
Fix default requirement level
Browse files Browse the repository at this point in the history
  • Loading branch information
pyohannes committed Mar 12, 2024
1 parent c0a006b commit b227621
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -134,9 +134,11 @@ def _get_attributes(self, templates: Optional[bool]):
or templates == AttributeType.is_template_type(attr.attr_type)
],
key=lambda attr: (
attr.requirement_level.value
if attr.requirement_level
else RequirementLevel.OPT_IN.value,
(
attr.requirement_level.value
if attr.requirement_level
else RequirementLevel.RECOMMENDED.value
),
attr.fqn,
),
)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,15 +7,15 @@
| `http.method` | string | HTTP request method. | `GET`; `POST`; `HEAD` | `Required` |
| [`http.server_name`](input_http.md) | string | The primary server name of the matched virtual host. [1] | `example.com` | `Conditionally Required` [2] |
| `http.status_code` | int | [HTTP response status code](https://tools.ietf.org/html/rfc7231#section-6). | `200` | `Conditionally Required` if and only if one was received/sent |
| `http.recommended_attribute` | string | brief | `foo` | `Recommended` short note |
| `http.recommended_attribute_long_note` | string | brief | `bar` | `Recommended` [3] |
| `http.user_agent` | string | Value of the [HTTP User-Agent](https://tools.ietf.org/html/rfc7231#section-5.5.3) header sent by the client. | `CERN-LineMode/2.15 libwww/2.17b3` | `Recommended` |
| `faas.execution` | string | The execution id of the current function execution. | `af9d5aa4-a685-4c5f-a22b-444f80b3cc28` | `Recommended` |
| `http.host` | string | The value of the [HTTP host header](https://tools.ietf.org/html/rfc7230#section-5.4). When the header is empty or not present, this attribute should be the same. | `www.example.org` | See below |
| `http.recommended_attribute` | string | brief | `foo` | `Recommended` short note |
| `http.recommended_attribute_long_note` | string | brief | `bar` | `Recommended` [3] |
| `http.scheme` | string | The URI scheme identifying the used protocol. | `http`; `https` | See below |
| `http.status_text` | string | [HTTP reason phrase](https://tools.ietf.org/html/rfc7230#section-3.1.2). | `OK` | `Recommended` |
| `http.target` | string | The full request target as passed in a HTTP request line or equivalent. | `/path/12314/?q=ddds#123` | See below |
| `http.url` | string | Full HTTP request URL in the form `scheme://host[:port]/path?query[#fragment]`. Usually the fragment is not transmitted over HTTP, but if it is known, it should be included nevertheless. | `https://www.foo.bar/search?q=OpenTelemetry#SemConv` | See below |
| `http.user_agent` | string | Value of the [HTTP User-Agent](https://tools.ietf.org/html/rfc7231#section-5.5.3) header sent by the client. | `CERN-LineMode/2.15 libwww/2.17b3` | `Recommended` |

**[1]:** This is an example

Expand Down

0 comments on commit b227621

Please sign in to comment.