Documentation
¶
Overview ¶
Package gcp provides functions for detecting the GCP platform and resources.
Deprecated: This package is deprecated and will no longer be maintained. Use go.opentelemetry.io/contrib/detectors/gcp instead.
Index ¶
- type Detectordeprecated
- func NewDetector() *Detectordeprecated
- func (d *Detector) AppEngineFlexAvailabilityZoneAndRegion() (string, string, error)deprecated
- func (d *Detector) AppEngineServiceInstance() (string, error)deprecated
- func (d *Detector) AppEngineServiceName() (string, error)deprecated
- func (d *Detector) AppEngineServiceVersion() (string, error)deprecated
- func (d *Detector) AppEngineStandardAvailabilityZone() (string, error)deprecated
- func (d *Detector) AppEngineStandardCloudRegion() (string, error)deprecated
- func (d *Detector) BareMetalSolutionCloudRegion() (string, error)deprecated
- func (d *Detector) BareMetalSolutionInstanceID() (string, error)deprecated
- func (d *Detector) BareMetalSolutionProjectID() (string, error)deprecated
- func (d *Detector) CloudPlatform() Platformdeprecated
- func (d *Detector) CloudRunJobExecution() (string, error)deprecated
- func (d *Detector) CloudRunJobTaskIndex() (string, error)deprecated
- func (d *Detector) FaaSCloudRegion() (string, error)deprecated
- func (d *Detector) FaaSID() (string, error)deprecated
- func (d *Detector) FaaSName() (string, error)deprecated
- func (d *Detector) FaaSVersion() (string, error)deprecated
- func (d *Detector) GCEAvailabilityZoneAndRegion() (string, string, error)deprecated
- func (d *Detector) GCEHostID() (string, error)deprecated
- func (d *Detector) GCEHostName() (string, error)deprecated
- func (d *Detector) GCEHostType() (string, error)deprecated
- func (d *Detector) GCEInstanceHostname() (string, error)deprecated
- func (d *Detector) GCEInstanceName() (string, error)deprecated
- func (d *Detector) GCEManagedInstanceGroup() (ManagedInstanceGroup, error)deprecated
- func (d *Detector) GKEAvailabilityZoneOrRegion() (string, LocationType, error)deprecated
- func (d *Detector) GKEClusterName() (string, error)deprecated
- func (d *Detector) GKEHostID() (string, error)deprecated
- func (d *Detector) GKEHostType() (string, error)deprecated
- func (d *Detector) ProjectID() (string, error)deprecated
- type LocationTypedeprecated
- type ManagedInstanceGroupdeprecated
- type Platformdeprecated
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Detector
deprecated
type Detector struct {
// contains filtered or unexported fields
}
Detector collects resource information for all GCP platforms.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func NewDetector
deprecated
func NewDetector() *Detector
NewDetector returns a *Detector which can get detect the platform, and fetch attributes of the platform on which it is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) AppEngineFlexAvailabilityZoneAndRegion
deprecated
added in
v0.32.1
AppEngineFlexAvailabilityZoneAndRegion returns the zone and region in which this program is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) AppEngineServiceInstance
deprecated
AppEngineServiceInstance returns the service instance of the app engine service.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) AppEngineServiceName
deprecated
AppEngineServiceName returns the service name of the app engine service.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) AppEngineServiceVersion
deprecated
AppEngineServiceVersion returns the service version of the app engine service.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) AppEngineStandardAvailabilityZone
deprecated
added in
v0.32.1
AppEngineStandardAvailabilityZone returns the zone the app engine service is running in.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) AppEngineStandardCloudRegion
deprecated
added in
v0.32.1
AppEngineStandardCloudRegion returns the region the app engine service is running in.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) BareMetalSolutionCloudRegion
deprecated
added in
v1.23.0
BareMetalSolutionCloudRegion returns the region from the BMS_REGION environment variable.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) BareMetalSolutionInstanceID
deprecated
added in
v1.23.0
BareMetalSolutionInstanceID returns the instance ID from the BMS_INSTANCE_ID environment variable.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) BareMetalSolutionProjectID
deprecated
added in
v1.23.0
BareMetalSolutionProjectID returns the project ID from the BMS_PROJECT_ID environment variable.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) CloudPlatform
deprecated
CloudPlatform returns the platform on which this program is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) CloudRunJobExecution
deprecated
added in
v1.15.1
CloudRunJobExecution returns the execution id of the Cloud Run jobs.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) CloudRunJobTaskIndex
deprecated
added in
v1.15.1
CloudRunJobTaskIndex returns the task index for the execution of the Cloud Run jobs.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) FaaSCloudRegion
deprecated
FaaSCloudRegion detects region from the metadata server. It is in the format /projects/<project_number>/regions/<region>.
https://cloud.google.com/run/docs/reference/container-contract#metadata-server
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) FaaSID
deprecated
FaaSID returns the instance id of the Cloud Run or Cloud Function.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) FaaSName
deprecated
FaaSName returns the name of the Cloud Run, Cloud Run jobs or Cloud Functions service.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) FaaSVersion
deprecated
FaaSVersion returns the revision of the Cloud Run or Cloud Functions service.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GCEAvailabilityZoneAndRegion
deprecated
GCEAvailabilityZoneAndRegion returns the zone and region in which this program is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GCEHostID
deprecated
GCEHostID returns the instance ID of the instance on which this program is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GCEHostName
deprecated
GCEHostName returns the instance name of the instance on which this program is running. Recommended to use GCEInstanceName() or GCEInstanceHostname() to more accurately reflect which value is returned.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GCEHostType
deprecated
GCEHostType returns the machine type of the instance on which this program is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GCEInstanceHostname
deprecated
added in
v1.17.0
GCEInstanceHostname returns the full value of the default or custom hostname of the instance on which this program is running. See https://cloud.google.com/compute/docs/instances/custom-hostname-vm.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GCEInstanceName
deprecated
added in
v1.17.0
GCEInstanceName returns the instance name of the instance on which this program is running. This is the value visible in the Cloud Console UI, and the prefix for the default hostname of the instance as defined by the default internal DNS name (see https://cloud.google.com/compute/docs/internal-dns#instance-fully-qualified-domain-names).
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GCEManagedInstanceGroup
deprecated
added in
v1.24.3
func (d *Detector) GCEManagedInstanceGroup() (ManagedInstanceGroup, error)
GCEManagedInstanceGroup returns the managed instance group that created this VM, if any.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GKEAvailabilityZoneOrRegion
deprecated
func (d *Detector) GKEAvailabilityZoneOrRegion() (string, LocationType, error)
GKEAvailabilityZoneOrRegion returns the location of the cluster and whether the cluster is zonal or regional.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GKEClusterName
deprecated
GKEClusterName returns the name if the GKE cluster in which this program is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GKEHostID
deprecated
GKEHostID returns the instance ID of the instance on which this program is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) GKEHostType
deprecated
added in
v1.36.0
GKEHostType returns the machine type of the instance on which this program is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
func (*Detector) ProjectID
deprecated
ProjectID returns the ID of the project in which this program is running.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
type LocationType
deprecated
type LocationType int64
LocationType represents the location type (Zone or Region).
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
const ( UndefinedLocation LocationType = iota Zone Region )
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
type ManagedInstanceGroup
deprecated
added in
v1.24.3
type ManagedInstanceGroup struct {
Name string
Location string
Type LocationType
}
ManagedInstanceGroup describes a Google Compute Engine Managed Instance Group.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
type Platform
deprecated
type Platform int64
Platform represents a Google Cloud platform type.
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.
const ( UnknownPlatform Platform = iota GKE GCE CloudRun CloudRunJob CloudRunWorkerPool CloudFunctions AppEngineStandard AppEngineFlex BareMetalSolution )
Deprecated: Use go.opentelemetry.io/contrib/detectors/gcp instead.