diff --git a/buildscripts/semantic-convention/generate.sh b/buildscripts/semantic-convention/generate.sh index cff7a3fc9c4..6a2400ad549 100755 --- a/buildscripts/semantic-convention/generate.sh +++ b/buildscripts/semantic-convention/generate.sh @@ -4,7 +4,7 @@ SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" ROOT_DIR="${SCRIPT_DIR}/../../" # freeze the spec & generator tools versions to make SemanticAttributes generation reproducible -SEMCONV_VERSION=1.17.0 +SEMCONV_VERSION=1.18.0 SPEC_VERSION=v$SEMCONV_VERSION SCHEMA_URL=https://opentelemetry.io/schemas/$SEMCONV_VERSION GENERATOR_VERSION=0.14.0 diff --git a/buildscripts/semantic-convention/templates/SemanticAttributes.java.j2 b/buildscripts/semantic-convention/templates/SemanticAttributes.java.j2 index d5da66fcdd1..4b1a81e18ea 100644 --- a/buildscripts/semantic-convention/templates/SemanticAttributes.java.j2 +++ b/buildscripts/semantic-convention/templates/SemanticAttributes.java.j2 @@ -276,5 +276,16 @@ public final class {{class}} { {% endif %} + {%- if class == "ResourceAttributes" %} + + /** + * Red Hat OpenShift on Google Cloud. + * @deprecated This item has been removed as of 1.18.0 of the semantic conventions. Use {@link ResourceAttributes#GCP_OPENSHIFT} instead. + */ + @Deprecated + public static final String GCP_OPENSHIFT = "gcp_openshift"; + + {% endif %} + private {{class}}() {} } diff --git a/semconv/src/main/java/io/opentelemetry/semconv/resource/attributes/ResourceAttributes.java b/semconv/src/main/java/io/opentelemetry/semconv/resource/attributes/ResourceAttributes.java index b92e5f640e8..19060907f9e 100644 --- a/semconv/src/main/java/io/opentelemetry/semconv/resource/attributes/ResourceAttributes.java +++ b/semconv/src/main/java/io/opentelemetry/semconv/resource/attributes/ResourceAttributes.java @@ -18,7 +18,7 @@ @SuppressWarnings("unused") public final class ResourceAttributes { /** The URL of the OpenTelemetry schema for these keys and values. */ - public static final String SCHEMA_URL = "https://opentelemetry.io/schemas/1.17.0"; + public static final String SCHEMA_URL = "https://opentelemetry.io/schemas/1.18.0"; /** * Array of brand name and version separated by a space @@ -728,7 +728,7 @@ public static final class CloudPlatformValues { /** Google Cloud App Engine (GAE). */ public static final String GCP_APP_ENGINE = "gcp_app_engine"; /** Red Hat OpenShift on Google Cloud. */ - public static final String GOOGLE_CLOUD_OPENSHIFT = "google_cloud_openshift"; + public static final String GCP_OPENSHIFT = "gcp_openshift"; /** Red Hat OpenShift on IBM Cloud. */ public static final String IBM_CLOUD_OPENSHIFT = "ibm_cloud_openshift"; /** Tencent Cloud Cloud Virtual Machine (CVM). */ @@ -825,5 +825,13 @@ public static final class TelemetrySdkLanguageValues { private TelemetrySdkLanguageValues() {} } + /** + * Red Hat OpenShift on Google Cloud. + * + * @deprecated This item has been removed as of 1.18.0 of the semantic conventions. Use {@link + * ResourceAttributes#GCP_OPENSHIFT} instead. + */ + @Deprecated public static final String GCP_OPENSHIFT = "gcp_openshift"; + private ResourceAttributes() {} }