Skip to content

Commit

Permalink
Update to semantic-conventions 1.28.0 (#91)
Browse files Browse the repository at this point in the history
  • Loading branch information
jack-berg authored Oct 14, 2024
1 parent e1254cf commit 44100fd
Show file tree
Hide file tree
Showing 21 changed files with 780 additions and 79 deletions.
3 changes: 2 additions & 1 deletion build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,10 @@ val snapshot = true
// end

// The release version of https://github.com/open-telemetry/semantic-conventions used to generate classes
var semanticConventionsVersion = "1.27.0"
var semanticConventionsVersion = "1.28.0"
val schemaUrlVersions = listOf(
semanticConventionsVersion,
"1.27.0",
"1.26.0",
"1.25.0",
"1.24.0",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,20 @@ public final class AndroidIncubatingAttributes {
* <p>The Android lifecycle states are defined in <a
* href="https://developer.android.com/guide/components/activities/activity-lifecycle#lc">Activity
* lifecycle callbacks</a>, and from which the {@code OS identifiers} are derived.
*
* <p>
*
* @deprecated Replaced by {@code device.app.lifecycle}.
*/
public static final AttributeKey<String> ANDROID_STATE = stringKey("android.state");
@Deprecated public static final AttributeKey<String> ANDROID_STATE = stringKey("android.state");

// Enum definitions
/** Values for {@link #ANDROID_STATE}. */
/**
* Values for {@link #ANDROID_STATE}
*
* @deprecated Replaced by {@code device.app.lifecycle}.
*/
@Deprecated
public static final class AndroidStateIncubatingValues {
/**
* Any time before Activity.onResume() or, if the app has no Activity, Context.startService()
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,13 @@
// buildscripts/templates/registry/incubating_java/IncubatingSemanticAttributes.java.j2
@SuppressWarnings("unused")
public final class AzIncubatingAttributes {
/**
* <a
* href="https://learn.microsoft.com/azure/azure-resource-manager/management/azure-services-resource-providers">Azure
* Resource Provider Namespace</a> as recognized by the client.
*/
public static final AttributeKey<String> AZ_NAMESPACE = stringKey("az.namespace");

/**
* The unique identifier of the service request. It's generated by the Azure service and returned
* with the response.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ public final class CloudIncubatingAttributes {
* href="https://docs.microsoft.com/rest/api/resources/resources/get-by-id">Fully Qualified
* Resource ID</a> of the invoked function, <em>not</em> the function app, having the form
* {@code
* /subscriptions/<SUBSCIPTION_GUID>/resourceGroups/<RG>/providers/Microsoft.Web/sites/<FUNCAPP>/functions/<FUNC>}.
* /subscriptions/<SUBSCRIPTION_GUID>/resourceGroups/<RG>/providers/Microsoft.Web/sites/<FUNCAPP>/functions/<FUNC>}.
* This means that a span attribute MUST be used, as an Azure function app can host multiple
* functions that would usually share a TracerProvider.
* </ul>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,160 @@
/*
* Copyright The OpenTelemetry Authors
* SPDX-License-Identifier: Apache-2.0
*/

package io.opentelemetry.semconv.incubating;

import static io.opentelemetry.api.common.AttributeKey.stringKey;

import io.opentelemetry.api.common.AttributeKey;

// DO NOT EDIT, this is an Auto-generated file from
// buildscripts/templates/registry/incubating_java/IncubatingSemanticAttributes.java.j2
@SuppressWarnings("unused")
public final class CloudfoundryIncubatingAttributes {
/**
* The guid of the application.
*
* <p>Notes:
*
* <p>Application instrumentation should use the value from environment variable {@code
* VCAP_APPLICATION.application_id}. This is the same value as reported by {@code cf app
* <app-name> --guid}.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_APP_ID = stringKey("cloudfoundry.app.id");

/**
* The index of the application instance. 0 when just one instance is active.
*
* <p>Notes:
*
* <p>CloudFoundry defines the {@code instance_id} in the <a
* href="https://github.com/cloudfoundry/loggregator-api#v2-envelope">Loggegator v2 envelope</a>.
* It is used for logs and metrics emitted by CloudFoundry. It is supposed to contain the
* application instance index for applications deployed on the runtime.
*
* <p>Application instrumentation should use the value from environment variable {@code
* CF_INSTANCE_INDEX}.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_APP_INSTANCE_ID =
stringKey("cloudfoundry.app.instance.id");

/**
* The name of the application.
*
* <p>Notes:
*
* <p>Application instrumentation should use the value from environment variable {@code
* VCAP_APPLICATION.application_name}. This is the same value as reported by {@code cf apps}.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_APP_NAME =
stringKey("cloudfoundry.app.name");

/**
* The guid of the CloudFoundry org the application is running in.
*
* <p>Notes:
*
* <p>Application instrumentation should use the value from environment variable {@code
* VCAP_APPLICATION.org_id}. This is the same value as reported by {@code cf org <org-name>
* --guid}.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_ORG_ID = stringKey("cloudfoundry.org.id");

/**
* The name of the CloudFoundry organization the app is running in.
*
* <p>Notes:
*
* <p>Application instrumentation should use the value from environment variable {@code
* VCAP_APPLICATION.org_name}. This is the same value as reported by {@code cf orgs}.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_ORG_NAME =
stringKey("cloudfoundry.org.name");

/**
* The UID identifying the process.
*
* <p>Notes:
*
* <p>Application instrumentation should use the value from environment variable {@code
* VCAP_APPLICATION.process_id}. It is supposed to be equal to {@code VCAP_APPLICATION.app_id} for
* applications deployed to the runtime. For system components, this could be the actual PID.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_PROCESS_ID =
stringKey("cloudfoundry.process.id");

/**
* The type of process.
*
* <p>Notes:
*
* <p>CloudFoundry applications can consist of multiple jobs. Usually the main process will be of
* type {@code web}. There can be additional background tasks or side-cars with different process
* types.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_PROCESS_TYPE =
stringKey("cloudfoundry.process.type");

/**
* The guid of the CloudFoundry space the application is running in.
*
* <p>Notes:
*
* <p>Application instrumentation should use the value from environment variable {@code
* VCAP_APPLICATION.space_id}. This is the same value as reported by {@code cf space <space-name>
* --guid}.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_SPACE_ID =
stringKey("cloudfoundry.space.id");

/**
* The name of the CloudFoundry space the application is running in.
*
* <p>Notes:
*
* <p>Application instrumentation should use the value from environment variable {@code
* VCAP_APPLICATION.space_name}. This is the same value as reported by {@code cf spaces}.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_SPACE_NAME =
stringKey("cloudfoundry.space.name");

/**
* A guid or another name describing the event source.
*
* <p>Notes:
*
* <p>CloudFoundry defines the {@code source_id} in the <a
* href="https://github.com/cloudfoundry/loggregator-api#v2-envelope">Loggregator v2 envelope</a>.
* It is used for logs and metrics emitted by CloudFoundry. It is supposed to contain the
* component name, e.g. "gorouter", for CloudFoundry components.
*
* <p>When system components are instrumented, values from the <a
* href="https://bosh.io/docs/jobs/#properties-spec">Bosh spec</a> should be used. The {@code
* system.id} should be set to {@code spec.deployment/spec.name}.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_SYSTEM_ID =
stringKey("cloudfoundry.system.id");

/**
* A guid describing the concrete instance of the event source.
*
* <p>Notes:
*
* <p>CloudFoundry defines the {@code instance_id} in the <a
* href="https://github.com/cloudfoundry/loggregator-api#v2-envelope">Loggregator v2 envelope</a>.
* It is used for logs and metrics emitted by CloudFoundry. It is supposed to contain the vm id
* for CloudFoundry components.
*
* <p>When system components are instrumented, values from the <a
* href="https://bosh.io/docs/jobs/#properties-spec">Bosh spec</a> should be used. The {@code
* system.instance.id} should be set to {@code spec.id}.
*/
public static final AttributeKey<String> CLOUDFOUNDRY_SYSTEM_INSTANCE_ID =
stringKey("cloudfoundry.system.instance.id");

// Enum definitions

private CloudfoundryIncubatingAttributes() {}
}
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,11 @@ public final class ContainerIncubatingAttributes {
*/
public static final AttributeKey<String> CONTAINER_COMMAND = stringKey("container.command");

/**
* All the command arguments (including the command/executable itself) run by the container. [2]
*/
/** All the command arguments (including the command/executable itself) run by the container. */
public static final AttributeKey<List<String>> CONTAINER_COMMAND_ARGS =
stringArrayKey("container.command_args");

/** The full command run by the container as a single string representing the full command. [2] */
/** The full command run by the container as a single string representing the full command. */
public static final AttributeKey<String> CONTAINER_COMMAND_LINE =
stringKey("container.command_line");

Expand All @@ -47,9 +45,34 @@ public final class ContainerIncubatingAttributes {
@Deprecated
public static final AttributeKey<String> CONTAINER_CPU_STATE = stringKey("container.cpu.state");

/**
* The name of the CSI (<a href="https://github.com/container-storage-interface/spec">Container
* Storage Interface</a>) plugin used by the volume.
*
* <p>Notes:
*
* <p>This can sometimes be referred to as a "driver" in CSI implementations. This should
* represent the {@code name} field of the GetPluginInfo RPC.
*/
public static final AttributeKey<String> CONTAINER_CSI_PLUGIN_NAME =
stringKey("container.csi.plugin.name");

/**
* The unique volume ID returned by the CSI (<a
* href="https://github.com/container-storage-interface/spec">Container Storage Interface</a>)
* plugin.
*
* <p>Notes:
*
* <p>This can sometimes be referred to as a "volume handle" in CSI implementations. This should
* represent the {@code Volume.volume_id} field in CSI spec.
*/
public static final AttributeKey<String> CONTAINER_CSI_VOLUME_ID =
stringKey("container.csi.volume.id");

/**
* Container ID. Usually a UUID, as for example used to <a
* href="https://docs.docker.com/engine/reference/run/#container-identification">identify Docker
* href="https://docs.docker.com/engine/containers/run/#container-identification">identify Docker
* containers</a>. The UUID might be abbreviated.
*/
public static final AttributeKey<String> CONTAINER_ID = stringKey("container.id");
Expand Down
Loading

0 comments on commit 44100fd

Please sign in to comment.