OpenTelemetry PHP

Host
in package
implements ResourceDetectorInterface

FinalYes
Tags
see
https://github.com/open-telemetry/opentelemetry-specification/blob/v1.8.0/specification/resource/semantic_conventions/host.md#host

Table of Contents

Interfaces

ResourceDetectorInterface

Constants

PATH_ETC_HOSTID  = 'etc/hostid'
PATH_ETC_MACHINEID  = 'etc/machine-id'
PATH_VAR_LIB_DBUS_MACHINEID  = 'var/lib/dbus/machine-id'

Properties

$dir  : string
$os  : string

Methods

__construct()  : mixed
getResource()  : ResourceInfo
getBsdId()  : string|null
getLinuxId()  : string|null
getMachineId()  : string|null
getMacOsId()  : string|null
getWindowsId()  : string|null

Constants

PATH_ETC_HOSTID

private mixed PATH_ETC_HOSTID = 'etc/hostid'

PATH_ETC_MACHINEID

private mixed PATH_ETC_MACHINEID = 'etc/machine-id'

PATH_VAR_LIB_DBUS_MACHINEID

private mixed PATH_VAR_LIB_DBUS_MACHINEID = 'var/lib/dbus/machine-id'

Properties

$dir read-only

private string $dir = '/'

$os read-only

private string $os = PHP_OS_FAMILY

Methods

__construct()

public __construct([string $dir = '/' ][, string $os = PHP_OS_FAMILY ]) : mixed
Parameters
$dir : string = '/'
$os : string = PHP_OS_FAMILY

getBsdId()

private getBsdId() : string|null
Return values
string|null

getLinuxId()

private getLinuxId() : string|null
Return values
string|null

getMachineId()

private getMachineId() : string|null
Return values
string|null

getMacOsId()

private getMacOsId() : string|null
Return values
string|null

getWindowsId()

private getWindowsId() : string|null
Return values
string|null

        
On this page

Search results