com.pulumi.azure.siterecovery.outputs.ReplicationRecoveryPlanFailoverRecoveryGroupPostAction Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure Show documentation
Show all versions of azure Show documentation
A Pulumi package for creating and managing Microsoft Azure cloud resources, based on the Terraform azurerm provider. We recommend using the [Azure Native provider](https://github.com/pulumi/pulumi-azure-native) to provision Azure infrastructure. Azure Native provides complete coverage of Azure resources and same-day access to new resources and resource updates.
// *** WARNING: this file was generated by pulumi-java-gen. ***
// *** Do not edit by hand unless you're certain you know what you are doing! ***
package com.pulumi.azure.siterecovery.outputs;
import com.pulumi.core.annotations.CustomType;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.String;
import java.util.List;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;
@CustomType
public final class ReplicationRecoveryPlanFailoverRecoveryGroupPostAction {
/**
* @return The fabric location of runbook or script. Possible values are `Primary` and `Recovery`. It must not be specified when `type` is `ManualActionDetails`.
*
* > **NOTE:** This is required when `type` is set to `AutomationRunbookActionDetails` or `ScriptActionDetails`.
*
*/
private @Nullable String fabricLocation;
/**
* @return Directions of fail over. Possible values are `PrimaryToRecovery` and `RecoveryToPrimary`
*
*/
private List failOverDirections;
/**
* @return Types of fail over. Possible values are `TestFailover`, `PlannedFailover` and `UnplannedFailover`
*
*/
private List failOverTypes;
/**
* @return Instructions of manual action.
*
* > **NOTE:** This property is required when `type` is set to `ManualActionDetails`.
*
*/
private @Nullable String manualActionInstruction;
/**
* @return The name of the Replication Plan. The name can contain only letters, numbers, and hyphens. It should start with a letter and end with a letter or a number. Can be a maximum of 63 characters. Changing this forces a new resource to be created.
*
*/
private String name;
/**
* @return Id of runbook.
*
* > **NOTE:** This property is required when `type` is set to `AutomationRunbookActionDetails`.
*
*/
private @Nullable String runbookId;
/**
* @return Path of action script.
*
* > **NOTE:** This property is required when `type` is set to `ScriptActionDetails`.
*
*/
private @Nullable String scriptPath;
/**
* @return Type of the action detail. Possible values are `AutomationRunbookActionDetails`, `ManualActionDetails` and `ScriptActionDetails`.
*
*/
private String type;
private ReplicationRecoveryPlanFailoverRecoveryGroupPostAction() {}
/**
* @return The fabric location of runbook or script. Possible values are `Primary` and `Recovery`. It must not be specified when `type` is `ManualActionDetails`.
*
* > **NOTE:** This is required when `type` is set to `AutomationRunbookActionDetails` or `ScriptActionDetails`.
*
*/
public Optional fabricLocation() {
return Optional.ofNullable(this.fabricLocation);
}
/**
* @return Directions of fail over. Possible values are `PrimaryToRecovery` and `RecoveryToPrimary`
*
*/
public List failOverDirections() {
return this.failOverDirections;
}
/**
* @return Types of fail over. Possible values are `TestFailover`, `PlannedFailover` and `UnplannedFailover`
*
*/
public List failOverTypes() {
return this.failOverTypes;
}
/**
* @return Instructions of manual action.
*
* > **NOTE:** This property is required when `type` is set to `ManualActionDetails`.
*
*/
public Optional manualActionInstruction() {
return Optional.ofNullable(this.manualActionInstruction);
}
/**
* @return The name of the Replication Plan. The name can contain only letters, numbers, and hyphens. It should start with a letter and end with a letter or a number. Can be a maximum of 63 characters. Changing this forces a new resource to be created.
*
*/
public String name() {
return this.name;
}
/**
* @return Id of runbook.
*
* > **NOTE:** This property is required when `type` is set to `AutomationRunbookActionDetails`.
*
*/
public Optional runbookId() {
return Optional.ofNullable(this.runbookId);
}
/**
* @return Path of action script.
*
* > **NOTE:** This property is required when `type` is set to `ScriptActionDetails`.
*
*/
public Optional scriptPath() {
return Optional.ofNullable(this.scriptPath);
}
/**
* @return Type of the action detail. Possible values are `AutomationRunbookActionDetails`, `ManualActionDetails` and `ScriptActionDetails`.
*
*/
public String type() {
return this.type;
}
public static Builder builder() {
return new Builder();
}
public static Builder builder(ReplicationRecoveryPlanFailoverRecoveryGroupPostAction defaults) {
return new Builder(defaults);
}
@CustomType.Builder
public static final class Builder {
private @Nullable String fabricLocation;
private List failOverDirections;
private List failOverTypes;
private @Nullable String manualActionInstruction;
private String name;
private @Nullable String runbookId;
private @Nullable String scriptPath;
private String type;
public Builder() {}
public Builder(ReplicationRecoveryPlanFailoverRecoveryGroupPostAction defaults) {
Objects.requireNonNull(defaults);
this.fabricLocation = defaults.fabricLocation;
this.failOverDirections = defaults.failOverDirections;
this.failOverTypes = defaults.failOverTypes;
this.manualActionInstruction = defaults.manualActionInstruction;
this.name = defaults.name;
this.runbookId = defaults.runbookId;
this.scriptPath = defaults.scriptPath;
this.type = defaults.type;
}
@CustomType.Setter
public Builder fabricLocation(@Nullable String fabricLocation) {
this.fabricLocation = fabricLocation;
return this;
}
@CustomType.Setter
public Builder failOverDirections(List failOverDirections) {
if (failOverDirections == null) {
throw new MissingRequiredPropertyException("ReplicationRecoveryPlanFailoverRecoveryGroupPostAction", "failOverDirections");
}
this.failOverDirections = failOverDirections;
return this;
}
public Builder failOverDirections(String... failOverDirections) {
return failOverDirections(List.of(failOverDirections));
}
@CustomType.Setter
public Builder failOverTypes(List failOverTypes) {
if (failOverTypes == null) {
throw new MissingRequiredPropertyException("ReplicationRecoveryPlanFailoverRecoveryGroupPostAction", "failOverTypes");
}
this.failOverTypes = failOverTypes;
return this;
}
public Builder failOverTypes(String... failOverTypes) {
return failOverTypes(List.of(failOverTypes));
}
@CustomType.Setter
public Builder manualActionInstruction(@Nullable String manualActionInstruction) {
this.manualActionInstruction = manualActionInstruction;
return this;
}
@CustomType.Setter
public Builder name(String name) {
if (name == null) {
throw new MissingRequiredPropertyException("ReplicationRecoveryPlanFailoverRecoveryGroupPostAction", "name");
}
this.name = name;
return this;
}
@CustomType.Setter
public Builder runbookId(@Nullable String runbookId) {
this.runbookId = runbookId;
return this;
}
@CustomType.Setter
public Builder scriptPath(@Nullable String scriptPath) {
this.scriptPath = scriptPath;
return this;
}
@CustomType.Setter
public Builder type(String type) {
if (type == null) {
throw new MissingRequiredPropertyException("ReplicationRecoveryPlanFailoverRecoveryGroupPostAction", "type");
}
this.type = type;
return this;
}
public ReplicationRecoveryPlanFailoverRecoveryGroupPostAction build() {
final var _resultValue = new ReplicationRecoveryPlanFailoverRecoveryGroupPostAction();
_resultValue.fabricLocation = fabricLocation;
_resultValue.failOverDirections = failOverDirections;
_resultValue.failOverTypes = failOverTypes;
_resultValue.manualActionInstruction = manualActionInstruction;
_resultValue.name = name;
_resultValue.runbookId = runbookId;
_resultValue.scriptPath = scriptPath;
_resultValue.type = type;
return _resultValue;
}
}
}