#[non_exhaustive]pub struct Service {
pub name: String,
pub display_name: String,
pub basic_service: Option<BasicService>,
pub telemetry: Option<Telemetry>,
pub user_labels: HashMap<String, String>,
pub identifier: Option<Identifier>,
}Expand description
A Service is a discrete, autonomous, and network-accessible unit, designed
to solve an individual concern
(Wikipedia). In
Cloud Monitoring, a Service acts as the root resource under which
operational aspects of the service are accessible.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: StringIdentifier. Resource name for this Service. The format is:
projects/[PROJECT_ID_OR_NUMBER]/services/[SERVICE_ID]display_name: StringName used for UI elements listing this Service.
basic_service: Option<BasicService>Message that contains the service type and service labels of this service if it is a basic service. Documentation and examples here.
telemetry: Option<Telemetry>Configuration for how to query telemetry on a Service.
user_labels: HashMap<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.
identifier: Option<Identifier>REQUIRED. Service-identifying atoms specifying the underlying service.
Implementations§
Source§impl Service
impl Service
Sourcepub fn set_display_name<T: Into<String>>(self, v: T) -> Self
pub fn set_display_name<T: Into<String>>(self, v: T) -> Self
Sets the value of display_name.
Sourcepub fn set_basic_service<T: Into<Option<BasicService>>>(self, v: T) -> Self
pub fn set_basic_service<T: Into<Option<BasicService>>>(self, v: T) -> Self
Sets the value of basic_service.
Sourcepub fn set_telemetry<T: Into<Option<Telemetry>>>(self, v: T) -> Self
pub fn set_telemetry<T: Into<Option<Telemetry>>>(self, v: T) -> Self
Sets the value of telemetry.
Sourcepub fn set_user_labels<T, K, V>(self, v: T) -> Self
pub fn set_user_labels<T, K, V>(self, v: T) -> Self
Sets the value of user_labels.
Sourcepub fn set_identifier<T: Into<Option<Identifier>>>(self, v: T) -> Self
pub fn set_identifier<T: Into<Option<Identifier>>>(self, v: T) -> Self
Sets the value of identifier.
Sourcepub fn get_custom(&self) -> Option<&Box<Custom>>
pub fn get_custom(&self) -> Option<&Box<Custom>>
The value of identifier
if it holds a Custom, None if the field is not set or
holds a different branch.
Sourcepub fn get_app_engine(&self) -> Option<&Box<AppEngine>>
pub fn get_app_engine(&self) -> Option<&Box<AppEngine>>
The value of identifier
if it holds a AppEngine, None if the field is not set or
holds a different branch.
Sourcepub fn get_cloud_endpoints(&self) -> Option<&Box<CloudEndpoints>>
pub fn get_cloud_endpoints(&self) -> Option<&Box<CloudEndpoints>>
The value of identifier
if it holds a CloudEndpoints, None if the field is not set or
holds a different branch.
Sourcepub fn get_cluster_istio(&self) -> Option<&Box<ClusterIstio>>
pub fn get_cluster_istio(&self) -> Option<&Box<ClusterIstio>>
The value of identifier
if it holds a ClusterIstio, None if the field is not set or
holds a different branch.
Sourcepub fn get_mesh_istio(&self) -> Option<&Box<MeshIstio>>
pub fn get_mesh_istio(&self) -> Option<&Box<MeshIstio>>
The value of identifier
if it holds a MeshIstio, None if the field is not set or
holds a different branch.
Sourcepub fn get_istio_canonical_service(&self) -> Option<&Box<IstioCanonicalService>>
pub fn get_istio_canonical_service(&self) -> Option<&Box<IstioCanonicalService>>
The value of identifier
if it holds a IstioCanonicalService, None if the field is not set or
holds a different branch.
Sourcepub fn get_cloud_run(&self) -> Option<&Box<CloudRun>>
pub fn get_cloud_run(&self) -> Option<&Box<CloudRun>>
The value of identifier
if it holds a CloudRun, None if the field is not set or
holds a different branch.
Sourcepub fn get_gke_namespace(&self) -> Option<&Box<GkeNamespace>>
pub fn get_gke_namespace(&self) -> Option<&Box<GkeNamespace>>
The value of identifier
if it holds a GkeNamespace, None if the field is not set or
holds a different branch.
Sourcepub fn get_gke_workload(&self) -> Option<&Box<GkeWorkload>>
pub fn get_gke_workload(&self) -> Option<&Box<GkeWorkload>>
The value of identifier
if it holds a GkeWorkload, None if the field is not set or
holds a different branch.
Sourcepub fn get_gke_service(&self) -> Option<&Box<GkeService>>
pub fn get_gke_service(&self) -> Option<&Box<GkeService>>
The value of identifier
if it holds a GkeService, None if the field is not set or
holds a different branch.
Sourcepub fn set_custom<T: Into<Box<Custom>>>(self, v: T) -> Self
pub fn set_custom<T: Into<Box<Custom>>>(self, v: T) -> Self
Sets the value of identifier
to hold a Custom.
Note that all the setters affecting identifier are
mutually exclusive.
Sourcepub fn set_app_engine<T: Into<Box<AppEngine>>>(self, v: T) -> Self
pub fn set_app_engine<T: Into<Box<AppEngine>>>(self, v: T) -> Self
Sets the value of identifier
to hold a AppEngine.
Note that all the setters affecting identifier are
mutually exclusive.
Sourcepub fn set_cloud_endpoints<T: Into<Box<CloudEndpoints>>>(self, v: T) -> Self
pub fn set_cloud_endpoints<T: Into<Box<CloudEndpoints>>>(self, v: T) -> Self
Sets the value of identifier
to hold a CloudEndpoints.
Note that all the setters affecting identifier are
mutually exclusive.
Sourcepub fn set_cluster_istio<T: Into<Box<ClusterIstio>>>(self, v: T) -> Self
pub fn set_cluster_istio<T: Into<Box<ClusterIstio>>>(self, v: T) -> Self
Sets the value of identifier
to hold a ClusterIstio.
Note that all the setters affecting identifier are
mutually exclusive.
Sourcepub fn set_mesh_istio<T: Into<Box<MeshIstio>>>(self, v: T) -> Self
pub fn set_mesh_istio<T: Into<Box<MeshIstio>>>(self, v: T) -> Self
Sets the value of identifier
to hold a MeshIstio.
Note that all the setters affecting identifier are
mutually exclusive.
Sourcepub fn set_istio_canonical_service<T: Into<Box<IstioCanonicalService>>>(
self,
v: T,
) -> Self
pub fn set_istio_canonical_service<T: Into<Box<IstioCanonicalService>>>( self, v: T, ) -> Self
Sets the value of identifier
to hold a IstioCanonicalService.
Note that all the setters affecting identifier are
mutually exclusive.
Sourcepub fn set_cloud_run<T: Into<Box<CloudRun>>>(self, v: T) -> Self
pub fn set_cloud_run<T: Into<Box<CloudRun>>>(self, v: T) -> Self
Sets the value of identifier
to hold a CloudRun.
Note that all the setters affecting identifier are
mutually exclusive.
Sourcepub fn set_gke_namespace<T: Into<Box<GkeNamespace>>>(self, v: T) -> Self
pub fn set_gke_namespace<T: Into<Box<GkeNamespace>>>(self, v: T) -> Self
Sets the value of identifier
to hold a GkeNamespace.
Note that all the setters affecting identifier are
mutually exclusive.
Sourcepub fn set_gke_workload<T: Into<Box<GkeWorkload>>>(self, v: T) -> Self
pub fn set_gke_workload<T: Into<Box<GkeWorkload>>>(self, v: T) -> Self
Sets the value of identifier
to hold a GkeWorkload.
Note that all the setters affecting identifier are
mutually exclusive.
Sourcepub fn set_gke_service<T: Into<Box<GkeService>>>(self, v: T) -> Self
pub fn set_gke_service<T: Into<Box<GkeService>>>(self, v: T) -> Self
Sets the value of identifier
to hold a GkeService.
Note that all the setters affecting identifier are
mutually exclusive.