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

com.pulumi.alicloud.oss.BucketDataRedundancyTransition Maven / Gradle / Ivy

There is a newer version: 3.63.0-alpha.1727424957
Show newest version
// *** 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.alicloud.oss;

import com.pulumi.alicloud.Utilities;
import com.pulumi.alicloud.oss.BucketDataRedundancyTransitionArgs;
import com.pulumi.alicloud.oss.inputs.BucketDataRedundancyTransitionState;
import com.pulumi.core.Output;
import com.pulumi.core.annotations.Export;
import com.pulumi.core.annotations.ResourceType;
import com.pulumi.core.internal.Codegen;
import java.lang.String;
import javax.annotation.Nullable;

/**
 * Provides a OSS Bucket Data Redundancy Transition resource. Create a storage redundancy transition task to convert local redundant storage(LRS) to zone redundant storage(ZRS).
 * 
 * For information about OSS Bucket Data Redundancy Transition and how to use it, see [What is Bucket Data Redundancy Transition](https://www.alibabacloud.com/help/en/oss/developer-reference/createbucketdataredundancytransition).
 * 
 * > **NOTE:** Available since v1.224.0.
 * 
 * ## Example Usage
 * 
 * Basic Usage
 * 
 * <!--Start PulumiCodeChooser -->
 * 
 * {@code
 * package generated_program;
 * 
 * import com.pulumi.Context;
 * import com.pulumi.Pulumi;
 * import com.pulumi.core.Output;
 * import com.pulumi.random.integer;
 * import com.pulumi.random.IntegerArgs;
 * import com.pulumi.alicloud.oss.Bucket;
 * import com.pulumi.alicloud.oss.BucketArgs;
 * import com.pulumi.alicloud.oss.BucketDataRedundancyTransition;
 * import com.pulumi.alicloud.oss.BucketDataRedundancyTransitionArgs;
 * import java.util.List;
 * import java.util.ArrayList;
 * import java.util.Map;
 * import java.io.File;
 * import java.nio.file.Files;
 * import java.nio.file.Paths;
 * 
 * public class App {
 *     public static void main(String[] args) {
 *         Pulumi.run(App::stack);
 *     }
 * 
 *     public static void stack(Context ctx) {
 *         final var config = ctx.config();
 *         final var name = config.get("name").orElse("terraform-example");
 *         var default_ = new Integer("default", IntegerArgs.builder()
 *             .min(10000)
 *             .max(99999)
 *             .build());
 * 
 *         var createBucket = new Bucket("createBucket", BucketArgs.builder()
 *             .storageClass("Standard")
 *             .bucket(String.format("%s-%s", name,default_.result()))
 *             .build());
 * 
 *         var defaultBucketDataRedundancyTransition = new BucketDataRedundancyTransition("defaultBucketDataRedundancyTransition", BucketDataRedundancyTransitionArgs.builder()
 *             .bucket(createBucket.bucket())
 *             .build());
 * 
 *     }
 * }
 * }
 * 
* <!--End PulumiCodeChooser --> * * ## Import * * OSS Bucket Data Redundancy Transition can be imported using the id, e.g. * * ```sh * $ pulumi import alicloud:oss/bucketDataRedundancyTransition:BucketDataRedundancyTransition example <bucket>:<task_id> * ``` * */ @ResourceType(type="alicloud:oss/bucketDataRedundancyTransition:BucketDataRedundancyTransition") public class BucketDataRedundancyTransition extends com.pulumi.resources.CustomResource { /** * Storage space name. * */ @Export(name="bucket", refs={String.class}, tree="[0]") private Output bucket; /** * @return Storage space name. * */ public Output bucket() { return this.bucket; } /** * Stores the creation time of the redundant transformation task. * */ @Export(name="createTime", refs={String.class}, tree="[0]") private Output createTime; /** * @return Stores the creation time of the redundant transformation task. * */ public Output createTime() { return this.createTime; } /** * Stores the state of the redundant translation task. The values are as follows: Queueing: in the queue. Processing: In progress. Finished: Finished. * */ @Export(name="status", refs={String.class}, tree="[0]") private Output status; /** * @return Stores the state of the redundant translation task. The values are as follows: Queueing: in the queue. Processing: In progress. Finished: Finished. * */ public Output status() { return this.status; } /** * Unique identification of the storage redundancy conversion task. * */ @Export(name="taskId", refs={String.class}, tree="[0]") private Output taskId; /** * @return Unique identification of the storage redundancy conversion task. * */ public Output taskId() { return this.taskId; } /** * * @param name The _unique_ name of the resulting resource. */ public BucketDataRedundancyTransition(java.lang.String name) { this(name, BucketDataRedundancyTransitionArgs.Empty); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. */ public BucketDataRedundancyTransition(java.lang.String name, BucketDataRedundancyTransitionArgs args) { this(name, args, null); } /** * * @param name The _unique_ name of the resulting resource. * @param args The arguments to use to populate this resource's properties. * @param options A bag of options that control this resource's behavior. */ public BucketDataRedundancyTransition(java.lang.String name, BucketDataRedundancyTransitionArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("alicloud:oss/bucketDataRedundancyTransition:BucketDataRedundancyTransition", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false); } private BucketDataRedundancyTransition(java.lang.String name, Output id, @Nullable BucketDataRedundancyTransitionState state, @Nullable com.pulumi.resources.CustomResourceOptions options) { super("alicloud:oss/bucketDataRedundancyTransition:BucketDataRedundancyTransition", name, state, makeResourceOptions(options, id), false); } private static BucketDataRedundancyTransitionArgs makeArgs(BucketDataRedundancyTransitionArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) { if (options != null && options.getUrn().isPresent()) { return null; } return args == null ? BucketDataRedundancyTransitionArgs.Empty : args; } private static com.pulumi.resources.CustomResourceOptions makeResourceOptions(@Nullable com.pulumi.resources.CustomResourceOptions options, @Nullable Output id) { var defaultOptions = com.pulumi.resources.CustomResourceOptions.builder() .version(Utilities.getVersion()) .build(); return com.pulumi.resources.CustomResourceOptions.merge(defaultOptions, options, id); } /** * Get an existing Host resource's state with the given name, ID, and optional extra * properties used to qualify the lookup. * * @param name The _unique_ name of the resulting resource. * @param id The _unique_ provider ID of the resource to lookup. * @param state * @param options Optional settings to control the behavior of the CustomResource. */ public static BucketDataRedundancyTransition get(java.lang.String name, Output id, @Nullable BucketDataRedundancyTransitionState state, @Nullable com.pulumi.resources.CustomResourceOptions options) { return new BucketDataRedundancyTransition(name, id, state, options); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy