diff --git a/CHANGELOG.md b/CHANGELOG.md index 298f090d34..ad709c798b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -68,3 +68,5 @@ release. ([#13](https://github.com/open-telemetry/semantic-conventions/pull/13)) - Clarify `process.runtime.jvm.threads.count` refers to platform threads. ([#54](https://github.com/open-telemetry/semantic-conventions/pull/54)) +- Add `gcp.gce.instance.name` and `gcp.gce.instance.hostname` resource + attributes for GCP Compute Engine VMs. ([#15](https://github.com/open-telemetry/semantic-conventions/pull/15)) diff --git a/semantic_conventions/resource/cloud_provider/gcp/gce.yaml b/semantic_conventions/resource/cloud_provider/gcp/gce.yaml new file mode 100644 index 0000000000..879d0ea388 --- /dev/null +++ b/semantic_conventions/resource/cloud_provider/gcp/gce.yaml @@ -0,0 +1,22 @@ +groups: + - id: gcp.gce + prefix: gcp.gce + type: resource + brief: > + Resources used by Google Compute Engine (GCE). + attributes: + - id: instance.name + type: string + brief: > + The instance name of a GCE instance. This is the value + provided by `host.name`, the visible name of the instance in + the Cloud Console UI, and the prefix for the default + hostname of the instance as defined by the [default internal + DNS + name](https://cloud.google.com/compute/docs/internal-dns#instance-fully-qualified-domain-names). + examples: ['instance-1', 'my-vm-name'] + - id: instance.hostname + type: string + brief: > + The hostname of a GCE instance. This is the full value of the default or [custom hostname](https://cloud.google.com/compute/docs/instances/custom-hostname-vm). + examples: ['my-host1234.example.com', 'sample-vm.us-west1-b.c.my-project.internal'] diff --git a/specification/resource/semantic_conventions/cloud_provider/gcp/gce.md b/specification/resource/semantic_conventions/cloud_provider/gcp/gce.md new file mode 100644 index 0000000000..49d9954643 --- /dev/null +++ b/specification/resource/semantic_conventions/cloud_provider/gcp/gce.md @@ -0,0 +1,12 @@ +# Google Compute Engine + +**Type:** `gcp.gce` + +**Description:** Resource attributes for GCE instances. + + +| Attribute | Type | Description | Examples | Requirement Level | +|---|---|---|---|---| +| `gcp.gce.instance.name` | string | The instance name of a GCE instance. This is the value provided by `host.name`, the visible name of the instance in the Cloud Console UI, and the prefix for the default hostname of the instance as defined by the [default internal DNS name](https://cloud.google.com/compute/docs/internal-dns#instance-fully-qualified-domain-names). | `instance-1`; `my-vm-name` | Recommended | +| `gcp.gce.instance.hostname` | string | The hostname of a GCE instance. This is the full value of the default or [custom hostname](https://cloud.google.com/compute/docs/instances/custom-hostname-vm). | `my-host1234.example.com`; `sample-vm.us-west1-b.c.my-project.internal` | Recommended | +