com.pulumi.azurenative.azurestackhci.UpdateRun Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of azure-native Show documentation
Show all versions of azure-native Show documentation
A native Pulumi package for creating and managing Azure resources.
// *** 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.azurenative.azurestackhci;
import com.pulumi.azurenative.Utilities;
import com.pulumi.azurenative.azurestackhci.UpdateRunArgs;
import com.pulumi.azurenative.azurestackhci.outputs.StepResponse;
import com.pulumi.azurenative.azurestackhci.outputs.SystemDataResponse;
import com.pulumi.core.Alias;
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 java.util.List;
import java.util.Optional;
import javax.annotation.Nullable;
/**
* Details of an Update run
* Azure REST API version: 2023-03-01.
*
* Other available API versions: 2022-12-15-preview, 2023-06-01, 2023-08-01, 2023-08-01-preview, 2023-11-01-preview, 2024-01-01, 2024-02-15-preview, 2024-04-01, 2024-09-01-preview.
*
* ## Example Usage
* ### Get Update runs under cluster resource
*
*
* {@code
* package generated_program;
*
* import com.pulumi.Context;
* import com.pulumi.Pulumi;
* import com.pulumi.core.Output;
* import com.pulumi.azurenative.azurestackhci.UpdateRun;
* import com.pulumi.azurenative.azurestackhci.UpdateRunArgs;
* import com.pulumi.azurenative.azurestackhci.inputs.StepArgs;
* 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) {
* var updateRun = new UpdateRun("updateRun", UpdateRunArgs.builder()
* .clusterName("testcluster")
* .description("Update Azure Stack.")
* .endTimeUtc("2022-04-06T13:58:42.969006+00:00")
* .errorMessage("")
* .lastUpdatedTimeUtc("2022-04-06T13:58:42.969006+00:00")
* .name("Unnamed step")
* .resourceGroupName("testrg")
* .startTimeUtc("2022-04-06T01:36:33.3876751+00:00")
* .status("Success")
* .steps(StepArgs.builder()
* .description("Prepare for SSU update")
* .endTimeUtc("2022-04-06T01:37:16.8728314+00:00")
* .errorMessage("")
* .lastUpdatedTimeUtc("2022-04-06T01:37:16.8728314+00:00")
* .name("PreUpdate Cloud")
* .startTimeUtc("2022-04-06T01:36:33.3876751+00:00")
* .status("Success")
* .steps()
* .build())
* .updateName("Microsoft4.2203.2.32")
* .updateRunName("23b779ba-0d52-4a80-8571-45ca74664ec3")
* .build());
*
* }
* }
*
* }
*
*
* ## Import
*
* An existing resource can be imported using its type token, name, and identifier, e.g.
*
* ```sh
* $ pulumi import azure-native:azurestackhci:UpdateRun Microsoft4.2203.2.32/23b779ba-0d52-4a80-8571-45ca74664ec3 /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI/clusters/{clusterName}/updates/{updateName}/updateRuns/{updateRunName}
* ```
*
*/
@ResourceType(type="azure-native:azurestackhci:UpdateRun")
public class UpdateRun extends com.pulumi.resources.CustomResource {
/**
* More detailed description of the step.
*
*/
@Export(name="description", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> description;
/**
* @return More detailed description of the step.
*
*/
public Output> description() {
return Codegen.optional(this.description);
}
/**
* Duration of the update run.
*
*/
@Export(name="duration", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> duration;
/**
* @return Duration of the update run.
*
*/
public Output> duration() {
return Codegen.optional(this.duration);
}
/**
* When the step reached a terminal state.
*
*/
@Export(name="endTimeUtc", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> endTimeUtc;
/**
* @return When the step reached a terminal state.
*
*/
public Output> endTimeUtc() {
return Codegen.optional(this.endTimeUtc);
}
/**
* Error message, specified if the step is in a failed state.
*
*/
@Export(name="errorMessage", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> errorMessage;
/**
* @return Error message, specified if the step is in a failed state.
*
*/
public Output> errorMessage() {
return Codegen.optional(this.errorMessage);
}
/**
* Timestamp of the most recently completed step in the update run.
*
*/
@Export(name="lastUpdatedTime", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> lastUpdatedTime;
/**
* @return Timestamp of the most recently completed step in the update run.
*
*/
public Output> lastUpdatedTime() {
return Codegen.optional(this.lastUpdatedTime);
}
/**
* Completion time of this step or the last completed sub-step.
*
*/
@Export(name="lastUpdatedTimeUtc", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> lastUpdatedTimeUtc;
/**
* @return Completion time of this step or the last completed sub-step.
*
*/
public Output> lastUpdatedTimeUtc() {
return Codegen.optional(this.lastUpdatedTimeUtc);
}
/**
* The geo-location where the resource lives
*
*/
@Export(name="location", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> location;
/**
* @return The geo-location where the resource lives
*
*/
public Output> location() {
return Codegen.optional(this.location);
}
/**
* The name of the resource
*
*/
@Export(name="name", refs={String.class}, tree="[0]")
private Output name;
/**
* @return The name of the resource
*
*/
public Output name() {
return this.name;
}
/**
* Provisioning state of the UpdateRuns proxy resource.
*
*/
@Export(name="provisioningState", refs={String.class}, tree="[0]")
private Output provisioningState;
/**
* @return Provisioning state of the UpdateRuns proxy resource.
*
*/
public Output provisioningState() {
return this.provisioningState;
}
/**
* When the step started, or empty if it has not started executing.
*
*/
@Export(name="startTimeUtc", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> startTimeUtc;
/**
* @return When the step started, or empty if it has not started executing.
*
*/
public Output> startTimeUtc() {
return Codegen.optional(this.startTimeUtc);
}
/**
* State of the update run.
*
*/
@Export(name="state", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> state;
/**
* @return State of the update run.
*
*/
public Output> state() {
return Codegen.optional(this.state);
}
/**
* Status of the step, bubbled up from the ECE action plan for installation attempts. Values are: 'Success', 'Error', 'InProgress', and 'Unknown status'.
*
*/
@Export(name="status", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> status;
/**
* @return Status of the step, bubbled up from the ECE action plan for installation attempts. Values are: 'Success', 'Error', 'InProgress', and 'Unknown status'.
*
*/
public Output> status() {
return Codegen.optional(this.status);
}
/**
* Recursive model for child steps of this step.
*
*/
@Export(name="steps", refs={List.class,StepResponse.class}, tree="[0,1]")
private Output* @Nullable */ List> steps;
/**
* @return Recursive model for child steps of this step.
*
*/
public Output>> steps() {
return Codegen.optional(this.steps);
}
/**
* Azure Resource Manager metadata containing createdBy and modifiedBy information.
*
*/
@Export(name="systemData", refs={SystemDataResponse.class}, tree="[0]")
private Output systemData;
/**
* @return Azure Resource Manager metadata containing createdBy and modifiedBy information.
*
*/
public Output systemData() {
return this.systemData;
}
/**
* Timestamp of the update run was started.
*
*/
@Export(name="timeStarted", refs={String.class}, tree="[0]")
private Output* @Nullable */ String> timeStarted;
/**
* @return Timestamp of the update run was started.
*
*/
public Output> timeStarted() {
return Codegen.optional(this.timeStarted);
}
/**
* The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
*
*/
@Export(name="type", refs={String.class}, tree="[0]")
private Output type;
/**
* @return The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"
*
*/
public Output type() {
return this.type;
}
/**
*
* @param name The _unique_ name of the resulting resource.
*/
public UpdateRun(java.lang.String name) {
this(name, UpdateRunArgs.Empty);
}
/**
*
* @param name The _unique_ name of the resulting resource.
* @param args The arguments to use to populate this resource's properties.
*/
public UpdateRun(java.lang.String name, UpdateRunArgs 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 UpdateRun(java.lang.String name, UpdateRunArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
super("azure-native:azurestackhci:UpdateRun", name, makeArgs(args, options), makeResourceOptions(options, Codegen.empty()), false);
}
private UpdateRun(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) {
super("azure-native:azurestackhci:UpdateRun", name, null, makeResourceOptions(options, id), false);
}
private static UpdateRunArgs makeArgs(UpdateRunArgs args, @Nullable com.pulumi.resources.CustomResourceOptions options) {
if (options != null && options.getUrn().isPresent()) {
return null;
}
return args == null ? UpdateRunArgs.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())
.aliases(List.of(
Output.of(Alias.builder().type("azure-native:azurestackhci/v20221201:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20221215preview:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20230201:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20230301:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20230601:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20230801:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20230801preview:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20231101preview:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20240101:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20240215preview:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20240401:UpdateRun").build()),
Output.of(Alias.builder().type("azure-native:azurestackhci/v20240901preview:UpdateRun").build())
))
.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 options Optional settings to control the behavior of the CustomResource.
*/
public static UpdateRun get(java.lang.String name, Output id, @Nullable com.pulumi.resources.CustomResourceOptions options) {
return new UpdateRun(name, id, options);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy