All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.pulumi.azure.appservice.inputs.LinuxFunctionAppSlotBackupScheduleArgs Maven / Gradle / Ivy

// *** 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.appservice.inputs;

import com.pulumi.core.Output;
import com.pulumi.core.annotations.Import;
import com.pulumi.exceptions.MissingRequiredPropertyException;
import java.lang.Boolean;
import java.lang.Integer;
import java.lang.String;
import java.util.Objects;
import java.util.Optional;
import javax.annotation.Nullable;


public final class LinuxFunctionAppSlotBackupScheduleArgs extends com.pulumi.resources.ResourceArgs {

    public static final LinuxFunctionAppSlotBackupScheduleArgs Empty = new LinuxFunctionAppSlotBackupScheduleArgs();

    /**
     * How often the backup should be executed (e.g. for weekly backup, this should be set to `7` and `frequency_unit` should be set to `Day`).
     * 
     * > **NOTE:** Not all intervals are supported on all Linux Function App SKUs. Please refer to the official documentation for appropriate values.
     * 
     */
    @Import(name="frequencyInterval", required=true)
    private Output frequencyInterval;

    /**
     * @return How often the backup should be executed (e.g. for weekly backup, this should be set to `7` and `frequency_unit` should be set to `Day`).
     * 
     * > **NOTE:** Not all intervals are supported on all Linux Function App SKUs. Please refer to the official documentation for appropriate values.
     * 
     */
    public Output frequencyInterval() {
        return this.frequencyInterval;
    }

    /**
     * The unit of time for how often the backup should take place. Possible values include: `Day` and `Hour`.
     * 
     */
    @Import(name="frequencyUnit", required=true)
    private Output frequencyUnit;

    /**
     * @return The unit of time for how often the backup should take place. Possible values include: `Day` and `Hour`.
     * 
     */
    public Output frequencyUnit() {
        return this.frequencyUnit;
    }

    /**
     * Should the service keep at least one backup, regardless of age of backup. Defaults to `false`.
     * 
     */
    @Import(name="keepAtLeastOneBackup")
    private @Nullable Output keepAtLeastOneBackup;

    /**
     * @return Should the service keep at least one backup, regardless of age of backup. Defaults to `false`.
     * 
     */
    public Optional> keepAtLeastOneBackup() {
        return Optional.ofNullable(this.keepAtLeastOneBackup);
    }

    /**
     * The time the backup was last attempted.
     * 
     */
    @Import(name="lastExecutionTime")
    private @Nullable Output lastExecutionTime;

    /**
     * @return The time the backup was last attempted.
     * 
     */
    public Optional> lastExecutionTime() {
        return Optional.ofNullable(this.lastExecutionTime);
    }

    /**
     * After how many days backups should be deleted. Defaults to `30`.
     * 
     */
    @Import(name="retentionPeriodDays")
    private @Nullable Output retentionPeriodDays;

    /**
     * @return After how many days backups should be deleted. Defaults to `30`.
     * 
     */
    public Optional> retentionPeriodDays() {
        return Optional.ofNullable(this.retentionPeriodDays);
    }

    /**
     * When the schedule should start working in RFC-3339 format.
     * 
     */
    @Import(name="startTime")
    private @Nullable Output startTime;

    /**
     * @return When the schedule should start working in RFC-3339 format.
     * 
     */
    public Optional> startTime() {
        return Optional.ofNullable(this.startTime);
    }

    private LinuxFunctionAppSlotBackupScheduleArgs() {}

    private LinuxFunctionAppSlotBackupScheduleArgs(LinuxFunctionAppSlotBackupScheduleArgs $) {
        this.frequencyInterval = $.frequencyInterval;
        this.frequencyUnit = $.frequencyUnit;
        this.keepAtLeastOneBackup = $.keepAtLeastOneBackup;
        this.lastExecutionTime = $.lastExecutionTime;
        this.retentionPeriodDays = $.retentionPeriodDays;
        this.startTime = $.startTime;
    }

    public static Builder builder() {
        return new Builder();
    }
    public static Builder builder(LinuxFunctionAppSlotBackupScheduleArgs defaults) {
        return new Builder(defaults);
    }

    public static final class Builder {
        private LinuxFunctionAppSlotBackupScheduleArgs $;

        public Builder() {
            $ = new LinuxFunctionAppSlotBackupScheduleArgs();
        }

        public Builder(LinuxFunctionAppSlotBackupScheduleArgs defaults) {
            $ = new LinuxFunctionAppSlotBackupScheduleArgs(Objects.requireNonNull(defaults));
        }

        /**
         * @param frequencyInterval How often the backup should be executed (e.g. for weekly backup, this should be set to `7` and `frequency_unit` should be set to `Day`).
         * 
         * > **NOTE:** Not all intervals are supported on all Linux Function App SKUs. Please refer to the official documentation for appropriate values.
         * 
         * @return builder
         * 
         */
        public Builder frequencyInterval(Output frequencyInterval) {
            $.frequencyInterval = frequencyInterval;
            return this;
        }

        /**
         * @param frequencyInterval How often the backup should be executed (e.g. for weekly backup, this should be set to `7` and `frequency_unit` should be set to `Day`).
         * 
         * > **NOTE:** Not all intervals are supported on all Linux Function App SKUs. Please refer to the official documentation for appropriate values.
         * 
         * @return builder
         * 
         */
        public Builder frequencyInterval(Integer frequencyInterval) {
            return frequencyInterval(Output.of(frequencyInterval));
        }

        /**
         * @param frequencyUnit The unit of time for how often the backup should take place. Possible values include: `Day` and `Hour`.
         * 
         * @return builder
         * 
         */
        public Builder frequencyUnit(Output frequencyUnit) {
            $.frequencyUnit = frequencyUnit;
            return this;
        }

        /**
         * @param frequencyUnit The unit of time for how often the backup should take place. Possible values include: `Day` and `Hour`.
         * 
         * @return builder
         * 
         */
        public Builder frequencyUnit(String frequencyUnit) {
            return frequencyUnit(Output.of(frequencyUnit));
        }

        /**
         * @param keepAtLeastOneBackup Should the service keep at least one backup, regardless of age of backup. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder keepAtLeastOneBackup(@Nullable Output keepAtLeastOneBackup) {
            $.keepAtLeastOneBackup = keepAtLeastOneBackup;
            return this;
        }

        /**
         * @param keepAtLeastOneBackup Should the service keep at least one backup, regardless of age of backup. Defaults to `false`.
         * 
         * @return builder
         * 
         */
        public Builder keepAtLeastOneBackup(Boolean keepAtLeastOneBackup) {
            return keepAtLeastOneBackup(Output.of(keepAtLeastOneBackup));
        }

        /**
         * @param lastExecutionTime The time the backup was last attempted.
         * 
         * @return builder
         * 
         */
        public Builder lastExecutionTime(@Nullable Output lastExecutionTime) {
            $.lastExecutionTime = lastExecutionTime;
            return this;
        }

        /**
         * @param lastExecutionTime The time the backup was last attempted.
         * 
         * @return builder
         * 
         */
        public Builder lastExecutionTime(String lastExecutionTime) {
            return lastExecutionTime(Output.of(lastExecutionTime));
        }

        /**
         * @param retentionPeriodDays After how many days backups should be deleted. Defaults to `30`.
         * 
         * @return builder
         * 
         */
        public Builder retentionPeriodDays(@Nullable Output retentionPeriodDays) {
            $.retentionPeriodDays = retentionPeriodDays;
            return this;
        }

        /**
         * @param retentionPeriodDays After how many days backups should be deleted. Defaults to `30`.
         * 
         * @return builder
         * 
         */
        public Builder retentionPeriodDays(Integer retentionPeriodDays) {
            return retentionPeriodDays(Output.of(retentionPeriodDays));
        }

        /**
         * @param startTime When the schedule should start working in RFC-3339 format.
         * 
         * @return builder
         * 
         */
        public Builder startTime(@Nullable Output startTime) {
            $.startTime = startTime;
            return this;
        }

        /**
         * @param startTime When the schedule should start working in RFC-3339 format.
         * 
         * @return builder
         * 
         */
        public Builder startTime(String startTime) {
            return startTime(Output.of(startTime));
        }

        public LinuxFunctionAppSlotBackupScheduleArgs build() {
            if ($.frequencyInterval == null) {
                throw new MissingRequiredPropertyException("LinuxFunctionAppSlotBackupScheduleArgs", "frequencyInterval");
            }
            if ($.frequencyUnit == null) {
                throw new MissingRequiredPropertyException("LinuxFunctionAppSlotBackupScheduleArgs", "frequencyUnit");
            }
            return $;
        }
    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy