Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removes AWS and Azure cloud resource detectors #114

Merged
merged 5 commits into from
Sep 10, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@

### BREAKING CHANGES

* Removes AWS and Azure resource detectors.
matt-hensley marked this conversation as resolved.
Show resolved Hide resolved
([#114](https://github.com/grafana/grafana-opentelemetry-dotnet/pull/114))
* Drops supports for .NET 7. EOL was May 24 2024
([#116](https://github.com/grafana/grafana-opentelemetry-dotnet/pull/116))
* Separates resource detectors and instrumentations. Removes resource detector
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,10 @@
<PackageReference Include="OpenTelemetry.Instrumentation.Http" Version="1.9.0" />
<PackageReference Include="OpenTelemetry.Instrumentation.Process" Version="0.5.0-beta.6" />
<PackageReference Include="OpenTelemetry.Instrumentation.SqlClient" Version="1.9.0-beta.1" />

<PackageReference Include="OpenTelemetry.Resources.Azure" Version="1.0.0-beta.8" />
</ItemGroup>

<!-- Non-stable instrumentation packages with no dependencies, non netstandard2.0 -->
<ItemGroup Condition=" '$(TargetFramework)' != 'netstandard2.0' ">
<PackageReference Include="OpenTelemetry.Resources.AWS" Version="1.5.0-beta.1" />
<PackageReference Include="OpenTelemetry.Resources.Host" Version="0.1.0-beta.2" />
<PackageReference Include="OpenTelemetry.Resources.OperatingSystem" Version="0.1.0-alpha.2" />
<PackageReference Include="OpenTelemetry.Resources.Process" Version="0.1.0-beta.2" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@ internal class AWSEBSDetectorInitializer : ResourceDetectorInitializer

protected override ResourceBuilder InitializeResourceDetector(ResourceBuilder builder)
{
return builder.AddAWSEBSDetector();
ReflectionHelper.CallStaticMethod(
"OpenTelemetry.Resources.AWS",
"OpenTelemetry.Resources.AWSResourceBuilderExtensions",
"AddAWSEBSDetector",
new object[] { builder });
return builder;
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@ internal class AWSEC2DetectorInitializer : ResourceDetectorInitializer

protected override ResourceBuilder InitializeResourceDetector(ResourceBuilder builder)
{
return builder.AddAWSEC2Detector();
ReflectionHelper.CallStaticMethod(
"OpenTelemetry.Resources.AWS",
"OpenTelemetry.Resources.AWSResourceBuilderExtensions",
"AddAWSEC2Detector",
new object[] { builder });
return builder;
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@ internal class AWSECSDetectorInitializer : ResourceDetectorInitializer

protected override ResourceBuilder InitializeResourceDetector(ResourceBuilder builder)
{
return builder.AddAWSECSDetector();
ReflectionHelper.CallStaticMethod(
"OpenTelemetry.Resources.AWS",
"OpenTelemetry.Resources.AWSResourceBuilderExtensions",
"AddAWSECSDetector",
new object[] { builder });
return builder;
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,12 @@ internal class AWSEKSDetectorInitializer : ResourceDetectorInitializer

protected override ResourceBuilder InitializeResourceDetector(ResourceBuilder builder)
{
return builder.AddAWSEKSDetector();
ReflectionHelper.CallStaticMethod(
"OpenTelemetry.Resources.AWS",
"OpenTelemetry.Resources.AWSResourceBuilderExtensions",
"AddAWSEKSDetector",
new object[] { builder });
return builder;
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,12 @@ internal class AzureAppServiceDetectorInitializer : ResourceDetectorInitializer

protected override ResourceBuilder InitializeResourceDetector(ResourceBuilder builder)
{
return builder.AddAzureAppServiceDetector();
ReflectionHelper.CallStaticMethod(
"OpenTelemetry.Resources.Azure",
"OpenTelemetry.Resources.AzureResourceBuilderExtensions",
"AddAzureAppServiceDetector",
new object[] { builder });
return builder;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,12 @@ internal class AzureContainerAppsDetectorInitializer : ResourceDetectorInitializ

protected override ResourceBuilder InitializeResourceDetector(ResourceBuilder builder)
{
return builder.AddAzureContainerAppsDetector();
ReflectionHelper.CallStaticMethod(
"OpenTelemetry.Resources.Azure",
"OpenTelemetry.Resources.AzureResourceBuilderExtensions",
"AddAzureContainerAppsDetector",
new object[] { builder });
return builder;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,12 @@ internal class AzureVMDetectorInitializer : ResourceDetectorInitializer

protected override ResourceBuilder InitializeResourceDetector(ResourceBuilder builder)
{
return builder.AddAzureVMDetector();
ReflectionHelper.CallStaticMethod(
"OpenTelemetry.Resources.Azure",
"OpenTelemetry.Resources.AzureResourceBuilderExtensions",
"AddAzureVMDetector",
new object[] { builder });
return builder;
}
}
}
Loading