From 5a8d35b71e6e851b75510d0e2528e89370874de8 Mon Sep 17 00:00:00 2001 From: jeremydvoss Date: Mon, 27 Nov 2023 14:40:16 -0800 Subject: [PATCH] Fix Azure resource detector dependency --- CHANGELOG.md | 2 ++ resource/opentelemetry-resource-detector-azure/pyproject.toml | 2 +- .../src/opentelemetry/resource/detector/azure/vm.py | 1 - 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 01d9411162..8eaaf772c6 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -18,6 +18,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - `opentelemetry-instrumentation-urllib`/`opentelemetry-instrumentation-urllib3` Fix metric descriptions to match semantic conventions ([#1959]((https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1959)) +- `opentelemetry-resource-detector-azure` Added dependency for Cloud Resource ID attribute + ([#2072](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2072)) ## Version 1.21.0/0.42b0 (2023-11-01) diff --git a/resource/opentelemetry-resource-detector-azure/pyproject.toml b/resource/opentelemetry-resource-detector-azure/pyproject.toml index c4ae6fc191..403553be3d 100644 --- a/resource/opentelemetry-resource-detector-azure/pyproject.toml +++ b/resource/opentelemetry-resource-detector-azure/pyproject.toml @@ -25,7 +25,7 @@ classifiers = [ "Programming Language :: Python :: 3.11", ] dependencies = [ - "opentelemetry-sdk ~= 1.19", + "opentelemetry-sdk ~= 1.21", ] [project.optional-dependencies] diff --git a/resource/opentelemetry-resource-detector-azure/src/opentelemetry/resource/detector/azure/vm.py b/resource/opentelemetry-resource-detector-azure/src/opentelemetry/resource/detector/azure/vm.py index fd14b482ed..8dd741b901 100644 --- a/resource/opentelemetry-resource-detector-azure/src/opentelemetry/resource/detector/azure/vm.py +++ b/resource/opentelemetry-resource-detector-azure/src/opentelemetry/resource/detector/azure/vm.py @@ -24,7 +24,6 @@ ResourceAttributes, ) -# TODO: Remove when cloud resource id is no longer missing in Resource Attributes _AZURE_VM_METADATA_ENDPOINT = "http://169.254.169.254/metadata/instance/compute?api-version=2021-12-13&format=json" _AZURE_VM_SCALE_SET_NAME_ATTRIBUTE = "azure.vm.scaleset.name" _AZURE_VM_SKU_ATTRIBUTE = "azure.vm.sku"