From 1e948e8b5fd134d57d42ef6c47faef21deb02507 Mon Sep 17 00:00:00 2001 From: Brett McBride Date: Mon, 23 Dec 2024 20:11:14 +1100 Subject: [PATCH] fix SPI package dependencies --- rector.php | 10 ---------- .../ComponentProvider/Logs/LogRecordExporterOtlp.php | 2 +- .../ComponentProvider/Metrics/MetricExporterOtlp.php | 2 +- .../Propagator/TextMapPropagatorB3.php | 2 +- .../Propagator/TextMapPropagatorB3Multi.php | 2 +- .../Propagator/TextMapPropagatorJaeger.php | 2 +- .../SDK/ComponentProvider/Trace/SpanExporterOtlp.php | 2 +- .../SDK/ComponentProvider/Trace/SpanExporterZipkin.php | 2 +- 8 files changed, 7 insertions(+), 17 deletions(-) diff --git a/rector.php b/rector.php index a3643984e..06b786b35 100644 --- a/rector.php +++ b/rector.php @@ -2,13 +2,10 @@ declare(strict_types=1); -use Rector\CodeQuality\Rector\Array_\CallableThisArrayToAnonymousFunctionRector; use Rector\CodeQuality\Rector\ClassMethod\LocallyCalledStaticMethodToNonStaticRector; use Rector\CodeQuality\Rector\Identical\FlipTypeControlToUseExclusiveTypeRector; use Rector\CodeQuality\Rector\If_\ExplicitBoolCompareRector; use Rector\Config\RectorConfig; -//use Rector\Php81\Rector\ClassMethod\NewInInitializerRector; -//use Rector\Php82\Rector\Property\ReadOnlyPropertyRector; use Rector\PHPUnit\Set\PHPUnitSetList; use Rector\Strict\Rector\Empty_\DisallowedEmptyRuleFixerRector; use Rector\ValueObject\PhpVersion; @@ -29,13 +26,6 @@ ]); $rectorConfig->skip([ FlipTypeControlToUseExclusiveTypeRector::class, - /*NewInInitializerRector::class => [ - __DIR__ . '/src/SDK/Trace/Sampler/ParentBased.php', - ], - ReadOnlyPropertyRector::class => [ - __DIR__ . '/src/SDK/Metrics/Stream/SynchronousMetricStream.php', - __DIR__ . '/tests/Unit/Extension/Propagator', - ],*/ DisallowedEmptyRuleFixerRector::class, ExplicitBoolCompareRector::class, LocallyCalledStaticMethodToNonStaticRector::class, diff --git a/src/Config/SDK/ComponentProvider/Logs/LogRecordExporterOtlp.php b/src/Config/SDK/ComponentProvider/Logs/LogRecordExporterOtlp.php index 4a829797b..8de884c88 100644 --- a/src/Config/SDK/ComponentProvider/Logs/LogRecordExporterOtlp.php +++ b/src/Config/SDK/ComponentProvider/Logs/LogRecordExporterOtlp.php @@ -21,7 +21,7 @@ /** * @implements ComponentProvider */ -#[PackageDependency('open-telemetry/exporter-otlp', '^1.0.5')] +#[PackageDependency('open-telemetry/exporter-otlp', '^2')] final class LogRecordExporterOtlp implements ComponentProvider { diff --git a/src/Config/SDK/ComponentProvider/Metrics/MetricExporterOtlp.php b/src/Config/SDK/ComponentProvider/Metrics/MetricExporterOtlp.php index 6e566304e..bd49c8632 100644 --- a/src/Config/SDK/ComponentProvider/Metrics/MetricExporterOtlp.php +++ b/src/Config/SDK/ComponentProvider/Metrics/MetricExporterOtlp.php @@ -22,7 +22,7 @@ /** * @implements ComponentProvider */ -#[PackageDependency('open-telemetry/exporter-otlp', '^1.0.5')] +#[PackageDependency('open-telemetry/exporter-otlp', '^2')] final class MetricExporterOtlp implements ComponentProvider { diff --git a/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorB3.php b/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorB3.php index ca349743c..3556637ff 100644 --- a/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorB3.php +++ b/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorB3.php @@ -15,7 +15,7 @@ /** * @implements ComponentProvider */ -#[PackageDependency('open-telemetry/extension-propagator-b3', '^1.0.1')] +#[PackageDependency('open-telemetry/extension-propagator-b3', '^2')] final class TextMapPropagatorB3 implements ComponentProvider { diff --git a/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorB3Multi.php b/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorB3Multi.php index 8809b7df9..4fcc0048e 100644 --- a/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorB3Multi.php +++ b/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorB3Multi.php @@ -15,7 +15,7 @@ /** * @implements ComponentProvider */ -#[PackageDependency('open-telemetry/extension-propagator-b3', '^1.0.1')] +#[PackageDependency('open-telemetry/extension-propagator-b3', '^2')] final class TextMapPropagatorB3Multi implements ComponentProvider { diff --git a/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorJaeger.php b/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorJaeger.php index 3d8086d52..7c64caf67 100644 --- a/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorJaeger.php +++ b/src/Config/SDK/ComponentProvider/Propagator/TextMapPropagatorJaeger.php @@ -15,7 +15,7 @@ /** * @implements ComponentProvider */ -#[PackageDependency('open-telemetry/extension-propagator-jaeger', '^0.0.2')] +#[PackageDependency('open-telemetry/extension-propagator-jaeger', '^2')] final class TextMapPropagatorJaeger implements ComponentProvider { diff --git a/src/Config/SDK/ComponentProvider/Trace/SpanExporterOtlp.php b/src/Config/SDK/ComponentProvider/Trace/SpanExporterOtlp.php index 32e2c0521..08cdd8144 100644 --- a/src/Config/SDK/ComponentProvider/Trace/SpanExporterOtlp.php +++ b/src/Config/SDK/ComponentProvider/Trace/SpanExporterOtlp.php @@ -21,7 +21,7 @@ /** * @implements ComponentProvider */ -#[PackageDependency('open-telemetry/exporter-otlp', '^1.0.5')] +#[PackageDependency('open-telemetry/exporter-otlp', '^2')] final class SpanExporterOtlp implements ComponentProvider { diff --git a/src/Config/SDK/ComponentProvider/Trace/SpanExporterZipkin.php b/src/Config/SDK/ComponentProvider/Trace/SpanExporterZipkin.php index a5665ea46..ff71ebc04 100644 --- a/src/Config/SDK/ComponentProvider/Trace/SpanExporterZipkin.php +++ b/src/Config/SDK/ComponentProvider/Trace/SpanExporterZipkin.php @@ -17,7 +17,7 @@ /** * @implements ComponentProvider */ -#[PackageDependency('open-telemetry/exporter-zipkin', '^1.0')] +#[PackageDependency('open-telemetry/exporter-zipkin', '^2')] final class SpanExporterZipkin implements ComponentProvider {