composer require open-telemetry/sdk-configuration
Initialization from configuration file
$configuration = Configuration::parseFile(__DIR__ . '/kitchen-sink.yaml');
$sdkBuilder = $configuration->create();
Parsing and processing the configuration is rather expensive. It is highly recommended to provide the $cacheFile
parameter when running in a shared-nothing setup.
$configuration = Configuration::parseFile(
__DIR__ . '/kitchen-sink.yaml',
__DIR__ . '/var/cache/opentelemetry.php',
);
$sdkBuilder = $configuration->create();
This repository is a read-only git subtree split. To contribute, please see the main OpenTelemetry PHP monorepo.