Class BackupPlan.Builder (0.45.0)

public static final class BackupPlan.Builder extends GeneratedMessageV3.Builder<BackupPlan.Builder> implements BackupPlanOrBuilder

Defines the configuration and scheduling for a "line" of Backups.

Protobuf type google.cloud.gkebackup.v1.BackupPlan

Implements

BackupPlanOrBuilder

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public BackupPlan.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
BackupPlan.Builder
Overrides

build()

public BackupPlan build()
Returns
Type Description
BackupPlan

buildPartial()

public BackupPlan buildPartial()
Returns
Type Description
BackupPlan

clear()

public BackupPlan.Builder clear()
Returns
Type Description
BackupPlan.Builder
Overrides

clearBackupConfig()

public BackupPlan.Builder clearBackupConfig()

Optional. Defines the configuration of Backups created via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.BackupConfig backup_config = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.Builder

clearBackupSchedule()

public BackupPlan.Builder clearBackupSchedule()

Optional. Defines a schedule for automatic Backup creation via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.Schedule backup_schedule = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.Builder

clearCluster()

public BackupPlan.Builder clearCluster()

Required. Immutable. The source cluster from which Backups will be created via this BackupPlan. Valid formats:

  • projects/*/locations/*/clusters/*
  • projects/*/zones/*/clusters/*

string cluster = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearCreateTime()

public BackupPlan.Builder clearCreateTime()

Output only. The timestamp when this BackupPlan resource was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

clearDeactivated()

public BackupPlan.Builder clearDeactivated()

Optional. This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).

Default: False

bool deactivated = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearDescription()

public BackupPlan.Builder clearDescription()

Optional. User specified descriptive string for this BackupPlan.

string description = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearEtag()

public BackupPlan.Builder clearEtag()

Output only. etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to GetBackupPlan, and systems are expected to put that etag in the request to UpdateBackupPlan or DeleteBackupPlan to ensure that their change will be applied to the same version of the resource.

string etag = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearField(Descriptors.FieldDescriptor field)

public BackupPlan.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
BackupPlan.Builder
Overrides

clearLabels()

public BackupPlan.Builder clearLabels()
Returns
Type Description
BackupPlan.Builder

clearName()

public BackupPlan.Builder clearName()

Output only. The full name of the BackupPlan resource. Format: projects/*/locations/*/backupPlans/*

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public BackupPlan.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
BackupPlan.Builder
Overrides

clearProtectedPodCount()

public BackupPlan.Builder clearProtectedPodCount()

Output only. The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.

int32 protected_pod_count = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearRetentionPolicy()

public BackupPlan.Builder clearRetentionPolicy()

Optional. RetentionPolicy governs lifecycle of Backups created under this plan.

.google.cloud.gkebackup.v1.BackupPlan.RetentionPolicy retention_policy = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.Builder

clearRpoRiskLevel()

public BackupPlan.Builder clearRpoRiskLevel()

Output only. A number that represents the current risk level of this BackupPlan from RPO perspective with 1 being no risk and 5 being highest risk.

int32 rpo_risk_level = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearRpoRiskReason()

public BackupPlan.Builder clearRpoRiskReason()

Output only. Human-readable description of why the BackupPlan is in the current rpo_risk_level and action items if any.

string rpo_risk_reason = 17 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearState()

public BackupPlan.Builder clearState()

Output only. State of the BackupPlan. This State field reflects the various stages a BackupPlan can be in during the Create operation. It will be set to "DEACTIVATED" if the BackupPlan is deactivated on an Update

.google.cloud.gkebackup.v1.BackupPlan.State state = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearStateReason()

public BackupPlan.Builder clearStateReason()

Output only. Human-readable description of why BackupPlan is in the current state

string state_reason = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearUid()

public BackupPlan.Builder clearUid()

Output only. Server generated global unique identifier of UUID format.

string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

clearUpdateTime()

public BackupPlan.Builder clearUpdateTime()

Output only. The timestamp when this BackupPlan resource was last updated.

.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.Builder

clone()

public BackupPlan.Builder clone()
Returns
Type Description
BackupPlan.Builder
Overrides

containsLabels(String key)

public boolean containsLabels(String key)

Optional. A set of custom labels supplied by user.

map<string, string> labels = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
boolean

getBackupConfig()

public BackupPlan.BackupConfig getBackupConfig()

Optional. Defines the configuration of Backups created via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.BackupConfig backup_config = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.BackupConfig

The backupConfig.

getBackupConfigBuilder()

public BackupPlan.BackupConfig.Builder getBackupConfigBuilder()

Optional. Defines the configuration of Backups created via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.BackupConfig backup_config = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.BackupConfig.Builder

getBackupConfigOrBuilder()

public BackupPlan.BackupConfigOrBuilder getBackupConfigOrBuilder()

Optional. Defines the configuration of Backups created via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.BackupConfig backup_config = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.BackupConfigOrBuilder

getBackupSchedule()

public BackupPlan.Schedule getBackupSchedule()

Optional. Defines a schedule for automatic Backup creation via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.Schedule backup_schedule = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.Schedule

The backupSchedule.

getBackupScheduleBuilder()

public BackupPlan.Schedule.Builder getBackupScheduleBuilder()

Optional. Defines a schedule for automatic Backup creation via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.Schedule backup_schedule = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.Schedule.Builder

getBackupScheduleOrBuilder()

public BackupPlan.ScheduleOrBuilder getBackupScheduleOrBuilder()

Optional. Defines a schedule for automatic Backup creation via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.Schedule backup_schedule = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.ScheduleOrBuilder

getCluster()

public String getCluster()

Required. Immutable. The source cluster from which Backups will be created via this BackupPlan. Valid formats:

  • projects/*/locations/*/clusters/*
  • projects/*/zones/*/clusters/*

string cluster = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
String

The cluster.

getClusterBytes()

public ByteString getClusterBytes()

Required. Immutable. The source cluster from which Backups will be created via this BackupPlan. Valid formats:

  • projects/*/locations/*/clusters/*
  • projects/*/zones/*/clusters/*

string cluster = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Returns
Type Description
ByteString

The bytes for cluster.

getCreateTime()

public Timestamp getCreateTime()

Output only. The timestamp when this BackupPlan resource was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Timestamp

The createTime.

getCreateTimeBuilder()

public Timestamp.Builder getCreateTimeBuilder()

Output only. The timestamp when this BackupPlan resource was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Builder

getCreateTimeOrBuilder()

public TimestampOrBuilder getCreateTimeOrBuilder()

Output only. The timestamp when this BackupPlan resource was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
TimestampOrBuilder

getDeactivated()

public boolean getDeactivated()

Optional. This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).

Default: False

bool deactivated = 11 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

The deactivated.

getDefaultInstanceForType()

public BackupPlan getDefaultInstanceForType()
Returns
Type Description
BackupPlan

getDescription()

public String getDescription()

Optional. User specified descriptive string for this BackupPlan.

string description = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
String

The description.

getDescriptionBytes()

public ByteString getDescriptionBytes()

Optional. User specified descriptive string for this BackupPlan.

string description = 5 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
ByteString

The bytes for description.

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getEtag()

public String getEtag()

Output only. etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to GetBackupPlan, and systems are expected to put that etag in the request to UpdateBackupPlan or DeleteBackupPlan to ensure that their change will be applied to the same version of the resource.

string etag = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
String

The etag.

getEtagBytes()

public ByteString getEtagBytes()

Output only. etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to GetBackupPlan, and systems are expected to put that etag in the request to UpdateBackupPlan or DeleteBackupPlan to ensure that their change will be applied to the same version of the resource.

string etag = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ByteString

The bytes for etag.

getLabels() (deprecated)

public Map<String,String> getLabels()

Use #getLabelsMap() instead.

Returns
Type Description
Map<String,String>

getLabelsCount()

public int getLabelsCount()

Optional. A set of custom labels supplied by user.

map<string, string> labels = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
int

getLabelsMap()

public Map<String,String> getLabelsMap()

Optional. A set of custom labels supplied by user.

map<string, string> labels = 8 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
Map<String,String>

getLabelsOrDefault(String key, String defaultValue)

public String getLabelsOrDefault(String key, String defaultValue)

Optional. A set of custom labels supplied by user.

map<string, string> labels = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
key String
defaultValue String
Returns
Type Description
String

getLabelsOrThrow(String key)

public String getLabelsOrThrow(String key)

Optional. A set of custom labels supplied by user.

map<string, string> labels = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
String

getMutableLabels() (deprecated)

public Map<String,String> getMutableLabels()

Use alternate mutation accessors instead.

Returns
Type Description
Map<String,String>

getName()

public String getName()

Output only. The full name of the BackupPlan resource. Format: projects/*/locations/*/backupPlans/*

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
String

The name.

getNameBytes()

public ByteString getNameBytes()

Output only. The full name of the BackupPlan resource. Format: projects/*/locations/*/backupPlans/*

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ByteString

The bytes for name.

getProtectedPodCount()

public int getProtectedPodCount()

Output only. The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.

int32 protected_pod_count = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
int

The protectedPodCount.

getRetentionPolicy()

public BackupPlan.RetentionPolicy getRetentionPolicy()

Optional. RetentionPolicy governs lifecycle of Backups created under this plan.

.google.cloud.gkebackup.v1.BackupPlan.RetentionPolicy retention_policy = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.RetentionPolicy

The retentionPolicy.

getRetentionPolicyBuilder()

public BackupPlan.RetentionPolicy.Builder getRetentionPolicyBuilder()

Optional. RetentionPolicy governs lifecycle of Backups created under this plan.

.google.cloud.gkebackup.v1.BackupPlan.RetentionPolicy retention_policy = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.RetentionPolicy.Builder

getRetentionPolicyOrBuilder()

public BackupPlan.RetentionPolicyOrBuilder getRetentionPolicyOrBuilder()

Optional. RetentionPolicy governs lifecycle of Backups created under this plan.

.google.cloud.gkebackup.v1.BackupPlan.RetentionPolicy retention_policy = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
BackupPlan.RetentionPolicyOrBuilder

getRpoRiskLevel()

public int getRpoRiskLevel()

Output only. A number that represents the current risk level of this BackupPlan from RPO perspective with 1 being no risk and 5 being highest risk.

int32 rpo_risk_level = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
int

The rpoRiskLevel.

getRpoRiskReason()

public String getRpoRiskReason()

Output only. Human-readable description of why the BackupPlan is in the current rpo_risk_level and action items if any.

string rpo_risk_reason = 17 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
String

The rpoRiskReason.

getRpoRiskReasonBytes()

public ByteString getRpoRiskReasonBytes()

Output only. Human-readable description of why the BackupPlan is in the current rpo_risk_level and action items if any.

string rpo_risk_reason = 17 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ByteString

The bytes for rpoRiskReason.

getState()

public BackupPlan.State getState()

Output only. State of the BackupPlan. This State field reflects the various stages a BackupPlan can be in during the Create operation. It will be set to "DEACTIVATED" if the BackupPlan is deactivated on an Update

.google.cloud.gkebackup.v1.BackupPlan.State state = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
BackupPlan.State

The state.

getStateReason()

public String getStateReason()

Output only. Human-readable description of why BackupPlan is in the current state

string state_reason = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
String

The stateReason.

getStateReasonBytes()

public ByteString getStateReasonBytes()

Output only. Human-readable description of why BackupPlan is in the current state

string state_reason = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ByteString

The bytes for stateReason.

getStateValue()

public int getStateValue()

Output only. State of the BackupPlan. This State field reflects the various stages a BackupPlan can be in during the Create operation. It will be set to "DEACTIVATED" if the BackupPlan is deactivated on an Update

.google.cloud.gkebackup.v1.BackupPlan.State state = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
int

The enum numeric value on the wire for state.

getUid()

public String getUid()

Output only. Server generated global unique identifier of UUID format.

string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
String

The uid.

getUidBytes()

public ByteString getUidBytes()

Output only. Server generated global unique identifier of UUID format.

string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
ByteString

The bytes for uid.

getUpdateTime()

public Timestamp getUpdateTime()

Output only. The timestamp when this BackupPlan resource was last updated.

.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Timestamp

The updateTime.

getUpdateTimeBuilder()

public Timestamp.Builder getUpdateTimeBuilder()

Output only. The timestamp when this BackupPlan resource was last updated.

.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
Builder

getUpdateTimeOrBuilder()

public TimestampOrBuilder getUpdateTimeOrBuilder()

Output only. The timestamp when this BackupPlan resource was last updated.

.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
TimestampOrBuilder

hasBackupConfig()

public boolean hasBackupConfig()

Optional. Defines the configuration of Backups created via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.BackupConfig backup_config = 12 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the backupConfig field is set.

hasBackupSchedule()

public boolean hasBackupSchedule()

Optional. Defines a schedule for automatic Backup creation via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.Schedule backup_schedule = 9 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the backupSchedule field is set.

hasCreateTime()

public boolean hasCreateTime()

Output only. The timestamp when this BackupPlan resource was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the createTime field is set.

hasRetentionPolicy()

public boolean hasRetentionPolicy()

Optional. RetentionPolicy governs lifecycle of Backups created under this plan.

.google.cloud.gkebackup.v1.BackupPlan.RetentionPolicy retention_policy = 7 [(.google.api.field_behavior) = OPTIONAL];

Returns
Type Description
boolean

Whether the retentionPolicy field is set.

hasUpdateTime()

public boolean hasUpdateTime()

Output only. The timestamp when this BackupPlan resource was last updated.

.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Returns
Type Description
boolean

Whether the updateTime field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

internalGetMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)

internalGetMutableMapFieldReflection(int number)

protected MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
Parameter
Name Description
number int
Returns
Type Description
com.google.protobuf.MapFieldReflectionAccessor
Overrides
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeBackupConfig(BackupPlan.BackupConfig value)

public BackupPlan.Builder mergeBackupConfig(BackupPlan.BackupConfig value)

Optional. Defines the configuration of Backups created via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.BackupConfig backup_config = 12 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value BackupPlan.BackupConfig
Returns
Type Description
BackupPlan.Builder

mergeBackupSchedule(BackupPlan.Schedule value)

public BackupPlan.Builder mergeBackupSchedule(BackupPlan.Schedule value)

Optional. Defines a schedule for automatic Backup creation via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.Schedule backup_schedule = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value BackupPlan.Schedule
Returns
Type Description
BackupPlan.Builder

mergeCreateTime(Timestamp value)

public BackupPlan.Builder mergeCreateTime(Timestamp value)

Output only. The timestamp when this BackupPlan resource was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
BackupPlan.Builder

mergeFrom(BackupPlan other)

public BackupPlan.Builder mergeFrom(BackupPlan other)
Parameter
Name Description
other BackupPlan
Returns
Type Description
BackupPlan.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public BackupPlan.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
BackupPlan.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public BackupPlan.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
BackupPlan.Builder
Overrides

mergeRetentionPolicy(BackupPlan.RetentionPolicy value)

public BackupPlan.Builder mergeRetentionPolicy(BackupPlan.RetentionPolicy value)

Optional. RetentionPolicy governs lifecycle of Backups created under this plan.

.google.cloud.gkebackup.v1.BackupPlan.RetentionPolicy retention_policy = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value BackupPlan.RetentionPolicy
Returns
Type Description
BackupPlan.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

public final BackupPlan.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
BackupPlan.Builder
Overrides

mergeUpdateTime(Timestamp value)

public BackupPlan.Builder mergeUpdateTime(Timestamp value)

Output only. The timestamp when this BackupPlan resource was last updated.

.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
BackupPlan.Builder

putAllLabels(Map<String,String> values)

public BackupPlan.Builder putAllLabels(Map<String,String> values)

Optional. A set of custom labels supplied by user.

map<string, string> labels = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
values Map<String,String>
Returns
Type Description
BackupPlan.Builder

putLabels(String key, String value)

public BackupPlan.Builder putLabels(String key, String value)

Optional. A set of custom labels supplied by user.

map<string, string> labels = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameters
Name Description
key String
value String
Returns
Type Description
BackupPlan.Builder

removeLabels(String key)

public BackupPlan.Builder removeLabels(String key)

Optional. A set of custom labels supplied by user.

map<string, string> labels = 8 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
key String
Returns
Type Description
BackupPlan.Builder

setBackupConfig(BackupPlan.BackupConfig value)

public BackupPlan.Builder setBackupConfig(BackupPlan.BackupConfig value)

Optional. Defines the configuration of Backups created via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.BackupConfig backup_config = 12 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value BackupPlan.BackupConfig
Returns
Type Description
BackupPlan.Builder

setBackupConfig(BackupPlan.BackupConfig.Builder builderForValue)

public BackupPlan.Builder setBackupConfig(BackupPlan.BackupConfig.Builder builderForValue)

Optional. Defines the configuration of Backups created via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.BackupConfig backup_config = 12 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue BackupPlan.BackupConfig.Builder
Returns
Type Description
BackupPlan.Builder

setBackupSchedule(BackupPlan.Schedule value)

public BackupPlan.Builder setBackupSchedule(BackupPlan.Schedule value)

Optional. Defines a schedule for automatic Backup creation via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.Schedule backup_schedule = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value BackupPlan.Schedule
Returns
Type Description
BackupPlan.Builder

setBackupSchedule(BackupPlan.Schedule.Builder builderForValue)

public BackupPlan.Builder setBackupSchedule(BackupPlan.Schedule.Builder builderForValue)

Optional. Defines a schedule for automatic Backup creation via this BackupPlan.

.google.cloud.gkebackup.v1.BackupPlan.Schedule backup_schedule = 9 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue BackupPlan.Schedule.Builder
Returns
Type Description
BackupPlan.Builder

setCluster(String value)

public BackupPlan.Builder setCluster(String value)

Required. Immutable. The source cluster from which Backups will be created via this BackupPlan. Valid formats:

  • projects/*/locations/*/clusters/*
  • projects/*/zones/*/clusters/*

string cluster = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value String

The cluster to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setClusterBytes(ByteString value)

public BackupPlan.Builder setClusterBytes(ByteString value)

Required. Immutable. The source cluster from which Backups will be created via this BackupPlan. Valid formats:

  • projects/*/locations/*/clusters/*
  • projects/*/zones/*/clusters/*

string cluster = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... }

Parameter
Name Description
value ByteString

The bytes for cluster to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setCreateTime(Timestamp value)

public BackupPlan.Builder setCreateTime(Timestamp value)

Output only. The timestamp when this BackupPlan resource was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
BackupPlan.Builder

setCreateTime(Timestamp.Builder builderForValue)

public BackupPlan.Builder setCreateTime(Timestamp.Builder builderForValue)

Output only. The timestamp when this BackupPlan resource was created.

.google.protobuf.Timestamp create_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
BackupPlan.Builder

setDeactivated(boolean value)

public BackupPlan.Builder setDeactivated(boolean value)

Optional. This flag indicates whether this BackupPlan has been deactivated. Setting this field to True locks the BackupPlan such that no further updates will be allowed (except deletes), including the deactivated field itself. It also prevents any new Backups from being created via this BackupPlan (including scheduled Backups).

Default: False

bool deactivated = 11 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value boolean

The deactivated to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setDescription(String value)

public BackupPlan.Builder setDescription(String value)

Optional. User specified descriptive string for this BackupPlan.

string description = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value String

The description to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setDescriptionBytes(ByteString value)

public BackupPlan.Builder setDescriptionBytes(ByteString value)

Optional. User specified descriptive string for this BackupPlan.

string description = 5 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value ByteString

The bytes for description to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setEtag(String value)

public BackupPlan.Builder setEtag(String value)

Output only. etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to GetBackupPlan, and systems are expected to put that etag in the request to UpdateBackupPlan or DeleteBackupPlan to ensure that their change will be applied to the same version of the resource.

string etag = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value String

The etag to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setEtagBytes(ByteString value)

public BackupPlan.Builder setEtagBytes(ByteString value)

Output only. etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a backup plan from overwriting each other. It is strongly suggested that systems make use of the 'etag' in the read-modify-write cycle to perform BackupPlan updates in order to avoid race conditions: An etag is returned in the response to GetBackupPlan, and systems are expected to put that etag in the request to UpdateBackupPlan or DeleteBackupPlan to ensure that their change will be applied to the same version of the resource.

string etag = 10 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value ByteString

The bytes for etag to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setField(Descriptors.FieldDescriptor field, Object value)

public BackupPlan.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
BackupPlan.Builder
Overrides

setName(String value)

public BackupPlan.Builder setName(String value)

Output only. The full name of the BackupPlan resource. Format: projects/*/locations/*/backupPlans/*

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value String

The name to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setNameBytes(ByteString value)

public BackupPlan.Builder setNameBytes(ByteString value)

Output only. The full name of the BackupPlan resource. Format: projects/*/locations/*/backupPlans/*

string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value ByteString

The bytes for name to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setProtectedPodCount(int value)

public BackupPlan.Builder setProtectedPodCount(int value)

Output only. The number of Kubernetes Pods backed up in the last successful Backup created via this BackupPlan.

int32 protected_pod_count = 13 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value int

The protectedPodCount to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

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

public BackupPlan.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
BackupPlan.Builder
Overrides

setRetentionPolicy(BackupPlan.RetentionPolicy value)

public BackupPlan.Builder setRetentionPolicy(BackupPlan.RetentionPolicy value)

Optional. RetentionPolicy governs lifecycle of Backups created under this plan.

.google.cloud.gkebackup.v1.BackupPlan.RetentionPolicy retention_policy = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
value BackupPlan.RetentionPolicy
Returns
Type Description
BackupPlan.Builder

setRetentionPolicy(BackupPlan.RetentionPolicy.Builder builderForValue)

public BackupPlan.Builder setRetentionPolicy(BackupPlan.RetentionPolicy.Builder builderForValue)

Optional. RetentionPolicy governs lifecycle of Backups created under this plan.

.google.cloud.gkebackup.v1.BackupPlan.RetentionPolicy retention_policy = 7 [(.google.api.field_behavior) = OPTIONAL];

Parameter
Name Description
builderForValue BackupPlan.RetentionPolicy.Builder
Returns
Type Description
BackupPlan.Builder

setRpoRiskLevel(int value)

public BackupPlan.Builder setRpoRiskLevel(int value)

Output only. A number that represents the current risk level of this BackupPlan from RPO perspective with 1 being no risk and 5 being highest risk.

int32 rpo_risk_level = 16 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value int

The rpoRiskLevel to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setRpoRiskReason(String value)

public BackupPlan.Builder setRpoRiskReason(String value)

Output only. Human-readable description of why the BackupPlan is in the current rpo_risk_level and action items if any.

string rpo_risk_reason = 17 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value String

The rpoRiskReason to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setRpoRiskReasonBytes(ByteString value)

public BackupPlan.Builder setRpoRiskReasonBytes(ByteString value)

Output only. Human-readable description of why the BackupPlan is in the current rpo_risk_level and action items if any.

string rpo_risk_reason = 17 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value ByteString

The bytes for rpoRiskReason to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setState(BackupPlan.State value)

public BackupPlan.Builder setState(BackupPlan.State value)

Output only. State of the BackupPlan. This State field reflects the various stages a BackupPlan can be in during the Create operation. It will be set to "DEACTIVATED" if the BackupPlan is deactivated on an Update

.google.cloud.gkebackup.v1.BackupPlan.State state = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value BackupPlan.State

The state to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setStateReason(String value)

public BackupPlan.Builder setStateReason(String value)

Output only. Human-readable description of why BackupPlan is in the current state

string state_reason = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value String

The stateReason to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setStateReasonBytes(ByteString value)

public BackupPlan.Builder setStateReasonBytes(ByteString value)

Output only. Human-readable description of why BackupPlan is in the current state

string state_reason = 15 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value ByteString

The bytes for stateReason to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setStateValue(int value)

public BackupPlan.Builder setStateValue(int value)

Output only. State of the BackupPlan. This State field reflects the various stages a BackupPlan can be in during the Create operation. It will be set to "DEACTIVATED" if the BackupPlan is deactivated on an Update

.google.cloud.gkebackup.v1.BackupPlan.State state = 14 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value int

The enum numeric value on the wire for state to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setUid(String value)

public BackupPlan.Builder setUid(String value)

Output only. Server generated global unique identifier of UUID format.

string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value String

The uid to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setUidBytes(ByteString value)

public BackupPlan.Builder setUidBytes(ByteString value)

Output only. Server generated global unique identifier of UUID format.

string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value ByteString

The bytes for uid to set.

Returns
Type Description
BackupPlan.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final BackupPlan.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
BackupPlan.Builder
Overrides

setUpdateTime(Timestamp value)

public BackupPlan.Builder setUpdateTime(Timestamp value)

Output only. The timestamp when this BackupPlan resource was last updated.

.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
value Timestamp
Returns
Type Description
BackupPlan.Builder

setUpdateTime(Timestamp.Builder builderForValue)

public BackupPlan.Builder setUpdateTime(Timestamp.Builder builderForValue)

Output only. The timestamp when this BackupPlan resource was last updated.

.google.protobuf.Timestamp update_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];

Parameter
Name Description
builderForValue Builder
Returns
Type Description
BackupPlan.Builder