Server Attributes

3 attributes in this category.2 stable·1 deprecated

3 attributes

Stable Attributes

server.address

stringScrub: ManualVisibility: PublicOTel: True

Preferably the server domain name if available without reverse DNS lookup, or an IP address or Unix domain socket name. For compatibility, it may contain what the hostname command returns on UNIX systems, the fully qualified hostname, or another name specified by the user.

Changelog
v0.24.0#645#647Broaden brief to allow hostnames
v0.21.0#588#602Added net.peer.name as an alias
v0.19.0#534Added address as an alias
v0.1.0#108#127
v0.0.0
Raw JSON
{
  "key": "server.address",
  "brief": "Preferably the server domain name if available without reverse DNS lookup, or an IP address or Unix domain socket name. For compatibility, it may contain what the hostname command returns on UNIX systems, the fully qualified hostname, or another name specified by the user.",
  "type": "string",
  "apply_scrubbing": {
    "key": "manual"
  },
  "is_in_otel": true,
  "visibility": "public",
  "example": "example.com",
  "alias": [
    "address",
    "http.server_name",
    "net.host.name",
    "http.host",
    "server_name",
    "net.peer.name"
  ],
  "changelog": [
    {
      "version": "0.24.0",
      "prs": [
        645,
        647
      ],
      "description": "Broaden brief to allow hostnames"
    },
    {
      "version": "0.21.0",
      "prs": [
        588,
        602
      ],
      "description": "Added net.peer.name as an alias"
    },
    {
      "version": "0.19.0",
      "prs": [
        534
      ],
      "description": "Added address as an alias"
    },
    {
      "version": "0.1.0",
      "prs": [
        108,
        127
      ]
    },
    {
      "version": "0.0.0"
    }
  ]
}

server.port

integerScrub: ManualVisibility: PublicOTel: True

Server port number.

Example1337
Changelog
v0.19.0#532Added port as an alias
v0.4.0#228
v0.0.0
Raw JSON
{
  "key": "server.port",
  "brief": "Server port number.",
  "type": "integer",
  "apply_scrubbing": {
    "key": "manual"
  },
  "is_in_otel": true,
  "visibility": "public",
  "example": 1337,
  "alias": [
    "net.host.port",
    "port"
  ],
  "changelog": [
    {
      "version": "0.19.0",
      "prs": [
        532
      ],
      "description": "Added port as an alias"
    },
    {
      "version": "0.4.0",
      "prs": [
        228
      ]
    },
    {
      "version": "0.0.0"
    }
  ]
}

Deprecated Attributes

These attributes are deprecated and should not be used in new code. See each attribute for migration guidance.

server.ext.typeDeprecated

stringScrub: ManualVisibility: PublicOTel: False

The request lifecycle extension point where the Hapi extension function runs.

ExamplesonRequestonPreResponse

Use hapi.ext.type instead.

Name from the OpenTelemetry Hapi instrumentation. The server namespace describes the network endpoint of the server, so the attribute moves to the hapi namespace.

Status: backfill

Changelog
v0.28.0#741Added server.ext.type attribute, deprecated in favor of hapi.ext.type
Raw JSON
{
  "key": "server.ext.type",
  "brief": "The request lifecycle extension point where the Hapi extension function runs.",
  "type": "string",
  "apply_scrubbing": {
    "key": "manual"
  },
  "is_in_otel": false,
  "visibility": "public",
  "examples": [
    "onRequest",
    "onPreResponse"
  ],
  "deprecation": {
    "replacement": "hapi.ext.type",
    "reason": "Name from the OpenTelemetry Hapi instrumentation. The `server` namespace describes the network endpoint of the server, so the attribute moves to the `hapi` namespace.",
    "_status": "backfill"
  },
  "alias": [
    "hapi.ext.type"
  ],
  "changelog": [
    {
      "version": "0.28.0",
      "prs": [
        741
      ],
      "description": "Added server.ext.type attribute, deprecated in favor of hapi.ext.type"
    }
  ]
}