Class MonitoringConfig.Builder (1.30.0)

public static final class MonitoringConfig.Builder extends GeneratedMessageV3.Builder<MonitoringConfig.Builder> implements MonitoringConfigOrBuilder

This field informs Fleet-based applications/services/UIs with the necessary information for where each underlying Cluster reports its metrics.

Protobuf type google.cloud.gkehub.v1beta1.MonitoringConfig

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public MonitoringConfig.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
MonitoringConfig.Builder
Overrides

build()

public MonitoringConfig build()
Returns
TypeDescription
MonitoringConfig

buildPartial()

public MonitoringConfig buildPartial()
Returns
TypeDescription
MonitoringConfig

clear()

public MonitoringConfig.Builder clear()
Returns
TypeDescription
MonitoringConfig.Builder
Overrides

clearCluster()

public MonitoringConfig.Builder clearCluster()

Immutable. Cluster name used to report metrics. For Anthos on VMWare/Baremetal, it would be in format memberClusters/cluster_name; And for Anthos on MultiCloud, it would be in format {azureClusters, awsClusters}/cluster_name.

string cluster = 3 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

clearClusterHash()

public MonitoringConfig.Builder clearClusterHash()

Immutable. Cluster hash, this is a unique string generated by google code, which does not contain any PII, which we can use to reference the cluster. This is expected to be created by the monitoring stack and persisted into the Cluster object as well as to GKE-Hub.

string cluster_hash = 5 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public MonitoringConfig.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
MonitoringConfig.Builder
Overrides

clearKubernetesMetricsPrefix()

public MonitoringConfig.Builder clearKubernetesMetricsPrefix()

Kubernetes system metrics, if available, are written to this prefix. This defaults to kubernetes.io for GKE, and kubernetes.io/anthos for Anthos eventually. Noted: Anthos MultiCloud will have kubernetes.io prefix today but will migration to be under kubernetes.io/anthos

string kubernetes_metrics_prefix = 4;

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

clearLocation()

public MonitoringConfig.Builder clearLocation()

Immutable. Location used to report Metrics

string location = 2 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public MonitoringConfig.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
MonitoringConfig.Builder
Overrides

clearProjectId()

public MonitoringConfig.Builder clearProjectId()

Immutable. Project used to report Metrics

string project_id = 1 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

clone()

public MonitoringConfig.Builder clone()
Returns
TypeDescription
MonitoringConfig.Builder
Overrides

getCluster()

public String getCluster()

Immutable. Cluster name used to report metrics. For Anthos on VMWare/Baremetal, it would be in format memberClusters/cluster_name; And for Anthos on MultiCloud, it would be in format {azureClusters, awsClusters}/cluster_name.

string cluster = 3 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
String

The cluster.

getClusterBytes()

public ByteString getClusterBytes()

Immutable. Cluster name used to report metrics. For Anthos on VMWare/Baremetal, it would be in format memberClusters/cluster_name; And for Anthos on MultiCloud, it would be in format {azureClusters, awsClusters}/cluster_name.

string cluster = 3 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
ByteString

The bytes for cluster.

getClusterHash()

public String getClusterHash()

Immutable. Cluster hash, this is a unique string generated by google code, which does not contain any PII, which we can use to reference the cluster. This is expected to be created by the monitoring stack and persisted into the Cluster object as well as to GKE-Hub.

string cluster_hash = 5 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
String

The clusterHash.

getClusterHashBytes()

public ByteString getClusterHashBytes()

Immutable. Cluster hash, this is a unique string generated by google code, which does not contain any PII, which we can use to reference the cluster. This is expected to be created by the monitoring stack and persisted into the Cluster object as well as to GKE-Hub.

string cluster_hash = 5 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
ByteString

The bytes for clusterHash.

getDefaultInstanceForType()

public MonitoringConfig getDefaultInstanceForType()
Returns
TypeDescription
MonitoringConfig

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getKubernetesMetricsPrefix()

public String getKubernetesMetricsPrefix()

Kubernetes system metrics, if available, are written to this prefix. This defaults to kubernetes.io for GKE, and kubernetes.io/anthos for Anthos eventually. Noted: Anthos MultiCloud will have kubernetes.io prefix today but will migration to be under kubernetes.io/anthos

string kubernetes_metrics_prefix = 4;

Returns
TypeDescription
String

The kubernetesMetricsPrefix.

getKubernetesMetricsPrefixBytes()

public ByteString getKubernetesMetricsPrefixBytes()

Kubernetes system metrics, if available, are written to this prefix. This defaults to kubernetes.io for GKE, and kubernetes.io/anthos for Anthos eventually. Noted: Anthos MultiCloud will have kubernetes.io prefix today but will migration to be under kubernetes.io/anthos

string kubernetes_metrics_prefix = 4;

Returns
TypeDescription
ByteString

The bytes for kubernetesMetricsPrefix.

getLocation()

public String getLocation()

Immutable. Location used to report Metrics

string location = 2 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
String

The location.

getLocationBytes()

public ByteString getLocationBytes()

Immutable. Location used to report Metrics

string location = 2 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
ByteString

The bytes for location.

getProjectId()

public String getProjectId()

Immutable. Project used to report Metrics

string project_id = 1 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
String

The projectId.

getProjectIdBytes()

public ByteString getProjectIdBytes()

Immutable. Project used to report Metrics

string project_id = 1 [(.google.api.field_behavior) = IMMUTABLE];

Returns
TypeDescription
ByteString

The bytes for projectId.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(MonitoringConfig other)

public MonitoringConfig.Builder mergeFrom(MonitoringConfig other)
Parameter
NameDescription
otherMonitoringConfig
Returns
TypeDescription
MonitoringConfig.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public MonitoringConfig.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
MonitoringConfig.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public MonitoringConfig.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
MonitoringConfig.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final MonitoringConfig.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
MonitoringConfig.Builder
Overrides

setCluster(String value)

public MonitoringConfig.Builder setCluster(String value)

Immutable. Cluster name used to report metrics. For Anthos on VMWare/Baremetal, it would be in format memberClusters/cluster_name; And for Anthos on MultiCloud, it would be in format {azureClusters, awsClusters}/cluster_name.

string cluster = 3 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueString

The cluster to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setClusterBytes(ByteString value)

public MonitoringConfig.Builder setClusterBytes(ByteString value)

Immutable. Cluster name used to report metrics. For Anthos on VMWare/Baremetal, it would be in format memberClusters/cluster_name; And for Anthos on MultiCloud, it would be in format {azureClusters, awsClusters}/cluster_name.

string cluster = 3 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueByteString

The bytes for cluster to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setClusterHash(String value)

public MonitoringConfig.Builder setClusterHash(String value)

Immutable. Cluster hash, this is a unique string generated by google code, which does not contain any PII, which we can use to reference the cluster. This is expected to be created by the monitoring stack and persisted into the Cluster object as well as to GKE-Hub.

string cluster_hash = 5 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueString

The clusterHash to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setClusterHashBytes(ByteString value)

public MonitoringConfig.Builder setClusterHashBytes(ByteString value)

Immutable. Cluster hash, this is a unique string generated by google code, which does not contain any PII, which we can use to reference the cluster. This is expected to be created by the monitoring stack and persisted into the Cluster object as well as to GKE-Hub.

string cluster_hash = 5 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueByteString

The bytes for clusterHash to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public MonitoringConfig.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
MonitoringConfig.Builder
Overrides

setKubernetesMetricsPrefix(String value)

public MonitoringConfig.Builder setKubernetesMetricsPrefix(String value)

Kubernetes system metrics, if available, are written to this prefix. This defaults to kubernetes.io for GKE, and kubernetes.io/anthos for Anthos eventually. Noted: Anthos MultiCloud will have kubernetes.io prefix today but will migration to be under kubernetes.io/anthos

string kubernetes_metrics_prefix = 4;

Parameter
NameDescription
valueString

The kubernetesMetricsPrefix to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setKubernetesMetricsPrefixBytes(ByteString value)

public MonitoringConfig.Builder setKubernetesMetricsPrefixBytes(ByteString value)

Kubernetes system metrics, if available, are written to this prefix. This defaults to kubernetes.io for GKE, and kubernetes.io/anthos for Anthos eventually. Noted: Anthos MultiCloud will have kubernetes.io prefix today but will migration to be under kubernetes.io/anthos

string kubernetes_metrics_prefix = 4;

Parameter
NameDescription
valueByteString

The bytes for kubernetesMetricsPrefix to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setLocation(String value)

public MonitoringConfig.Builder setLocation(String value)

Immutable. Location used to report Metrics

string location = 2 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueString

The location to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setLocationBytes(ByteString value)

public MonitoringConfig.Builder setLocationBytes(ByteString value)

Immutable. Location used to report Metrics

string location = 2 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueByteString

The bytes for location to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setProjectId(String value)

public MonitoringConfig.Builder setProjectId(String value)

Immutable. Project used to report Metrics

string project_id = 1 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueString

The projectId to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setProjectIdBytes(ByteString value)

public MonitoringConfig.Builder setProjectIdBytes(ByteString value)

Immutable. Project used to report Metrics

string project_id = 1 [(.google.api.field_behavior) = IMMUTABLE];

Parameter
NameDescription
valueByteString

The bytes for projectId to set.

Returns
TypeDescription
MonitoringConfig.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public MonitoringConfig.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
MonitoringConfig.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final MonitoringConfig.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
MonitoringConfig.Builder
Overrides