Class: Google::Apis::MonitoringV3::Service

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/monitoring_v3/classes.rb,
lib/google/apis/monitoring_v3/representations.rb,
lib/google/apis/monitoring_v3/representations.rb

Overview

A Service is a discrete, autonomous, and network-accessible unit, designed to solve an individual concern (Wikipedia (https://en.wikipedia.org/wiki/Service- orientation)). In Cloud Monitoring, a Service acts as the root resource under which operational aspects of the service are accessible.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ Service

Returns a new instance of Service.



3736
3737
3738
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3736

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#app_engineGoogle::Apis::MonitoringV3::AppEngine

App Engine service. Learn more at https://cloud.google.com/appengine. Corresponds to the JSON property appEngine



3652
3653
3654
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3652

def app_engine
  @app_engine
end

#cloud_endpointsGoogle::Apis::MonitoringV3::CloudEndpoints

Cloud Endpoints service. Learn more at https://cloud.google.com/endpoints. Corresponds to the JSON property cloudEndpoints



3657
3658
3659
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3657

def cloud_endpoints
  @cloud_endpoints
end

#cloud_runGoogle::Apis::MonitoringV3::CloudRun

Cloud Run service. Learn more at https://cloud.google.com/run. Corresponds to the JSON property cloudRun



3662
3663
3664
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3662

def cloud_run
  @cloud_run
end

#cluster_istioGoogle::Apis::MonitoringV3::ClusterIstio

Istio service scoped to a single Kubernetes cluster. Learn more at https:// istio.io. Clusters running OSS Istio will have their services ingested as this type. Corresponds to the JSON property clusterIstio



3669
3670
3671
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3669

def cluster_istio
  @cluster_istio
end

#customGoogle::Apis::MonitoringV3::Custom

Custom view of service telemetry. Currently a place-holder pending final design. Corresponds to the JSON property custom



3675
3676
3677
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3675

def custom
  @custom
end

#display_nameString

Name used for UI elements listing this Service. Corresponds to the JSON property displayName

Returns:

  • (String)


3680
3681
3682
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3680

def display_name
  @display_name
end

#gke_namespaceGoogle::Apis::MonitoringV3::GkeNamespace

GKE Namespace. The field names correspond to the resource metadata labels on monitored resources that fall under a namespace (e.g. k8s_container, k8s_pod). Corresponds to the JSON property gkeNamespace



3686
3687
3688
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3686

def gke_namespace
  @gke_namespace
end

#gke_serviceGoogle::Apis::MonitoringV3::GkeService

GKE Service. The "service" here represents a Kubernetes service object (https:/ /kubernetes.io/docs/concepts/services-networking/service). The field names correspond to the resource labels on k8s_service monitored resources: https:// cloud.google.com/monitoring/api/resources#tag_k8s_service Corresponds to the JSON property gkeService



3694
3695
3696
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3694

def gke_service
  @gke_service
end

#gke_workloadGoogle::Apis::MonitoringV3::GkeWorkload

A GKE Workload (Deployment, StatefulSet, etc). The field names correspond to the metadata labels on monitored resources that fall under a workload (e.g. k8s_container, k8s_pod). Corresponds to the JSON property gkeWorkload



3701
3702
3703
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3701

def gke_workload
  @gke_workload
end

#istio_canonical_serviceGoogle::Apis::MonitoringV3::IstioCanonicalService

Canonical service scoped to an Istio mesh. Anthos clusters running ASM >= 1.6. 8 will have their services ingested as this type. Corresponds to the JSON property istioCanonicalService



3707
3708
3709
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3707

def istio_canonical_service
  @istio_canonical_service
end

#mesh_istioGoogle::Apis::MonitoringV3::MeshIstio

Istio service scoped to an Istio mesh. Anthos clusters running ASM < 1.6.8 will have their services ingested as this type. Corresponds to the JSON property meshIstio



3713
3714
3715
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3713

def mesh_istio
  @mesh_istio
end

#nameString

Resource name for this Service. The format is: projects/[PROJECT_ID_OR_NUMBER]/ services/[SERVICE_ID] Corresponds to the JSON property name

Returns:

  • (String)


3719
3720
3721
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3719

def name
  @name
end

#telemetryGoogle::Apis::MonitoringV3::Telemetry

Configuration for how to query telemetry on a Service. Corresponds to the JSON property telemetry



3724
3725
3726
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3724

def telemetry
  @telemetry
end

#user_labelsHash<String,String>

Labels which have been used to annotate the service. Label keys must start with a letter. Label keys and values may contain lowercase letters, numbers, underscores, and dashes. Label keys and values have a maximum length of 63 characters, and must be less than 128 bytes in size. Up to 64 label entries may be stored. For labels which do not have a semantic value, the empty string may be supplied for the label value. Corresponds to the JSON property userLabels

Returns:

  • (Hash<String,String>)


3734
3735
3736
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3734

def user_labels
  @user_labels
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
# File 'lib/google/apis/monitoring_v3/classes.rb', line 3741

def update!(**args)
  @app_engine = args[:app_engine] if args.key?(:app_engine)
  @cloud_endpoints = args[:cloud_endpoints] if args.key?(:cloud_endpoints)
  @cloud_run = args[:cloud_run] if args.key?(:cloud_run)
  @cluster_istio = args[:cluster_istio] if args.key?(:cluster_istio)
  @custom = args[:custom] if args.key?(:custom)
  @display_name = args[:display_name] if args.key?(:display_name)
  @gke_namespace = args[:gke_namespace] if args.key?(:gke_namespace)
  @gke_service = args[:gke_service] if args.key?(:gke_service)
  @gke_workload = args[:gke_workload] if args.key?(:gke_workload)
  @istio_canonical_service = args[:istio_canonical_service] if args.key?(:istio_canonical_service)
  @mesh_istio = args[:mesh_istio] if args.key?(:mesh_istio)
  @name = args[:name] if args.key?(:name)
  @telemetry = args[:telemetry] if args.key?(:telemetry)
  @user_labels = args[:user_labels] if args.key?(:user_labels)
end