Skip to content

Commit

Permalink
Add GCP Compute Engine resource attributes for host/instance (#15)
Browse files Browse the repository at this point in the history
Co-authored-by: Josh Suereth <joshuasuereth@google.com>
  • Loading branch information
damemi and jsuereth authored Jun 1, 2023
1 parent 62513fb commit 4f21138
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -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))
22 changes: 22 additions & 0 deletions semantic_conventions/resource/cloud_provider/gcp/gce.yaml
Original file line number Diff line number Diff line change
@@ -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']
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Google Compute Engine

**Type:** `gcp.gce`

**Description:** Resource attributes for GCE instances.

<!-- semconv gcp.gce -->
| 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 |
<!-- endsemconv -->

0 comments on commit 4f21138

Please sign in to comment.