From be5391ca81bd368d5621c379897cf5b573606b53 Mon Sep 17 00:00:00 2001 From: Pulumi Bot <30351955+pulumi-bot@users.noreply.github.com> Date: Thu, 8 Aug 2024 01:51:30 -0700 Subject: [PATCH] Upgrade terraform-provider-spotinst to v1.185.0 (#795) This PR was generated via `$ upgrade-provider pulumi/pulumi-spotinst --kind=all --target-bridge-version=latest`. --- - Upgrading terraform-provider-spotinst from 1.184.0 to 1.185.0. Fixes #794 --- .../cmd/pulumi-resource-spotinst/schema.json | 4 ++ provider/go.mod | 4 +- provider/go.sum | 8 ++-- .../Aws/Inputs/OceanLaunchSpecStrategyArgs.cs | 6 +++ .../Inputs/OceanLaunchSpecStrategyGetArgs.cs | 6 +++ .../Aws/Outputs/OceanLaunchSpecStrategy.cs | 10 ++++- sdk/go/spotinst/aws/pulumiTypes.go | 9 +++++ .../inputs/OceanLaunchSpecStrategyArgs.java | 37 +++++++++++++++++++ .../aws/outputs/OceanLaunchSpecStrategy.java | 21 +++++++++++ sdk/nodejs/types/input.ts | 4 ++ sdk/nodejs/types/output.ts | 4 ++ sdk/python/pulumi_spotinst/aws/_inputs.py | 16 ++++++++ sdk/python/pulumi_spotinst/aws/outputs.py | 16 +++++++- 13 files changed, 137 insertions(+), 8 deletions(-) diff --git a/provider/cmd/pulumi-resource-spotinst/schema.json b/provider/cmd/pulumi-resource-spotinst/schema.json index 2cc5c4610..fa3f6cdeb 100644 --- a/provider/cmd/pulumi-resource-spotinst/schema.json +++ b/provider/cmd/pulumi-resource-spotinst/schema.json @@ -3725,6 +3725,10 @@ }, "spotinst:aws/OceanLaunchSpecStrategy:OceanLaunchSpecStrategy": { "properties": { + "drainingTimeout": { + "type": "integer", + "description": "The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used.\n" + }, "spotPercentage": { "type": "integer", "description": "The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage).\n" diff --git a/provider/go.mod b/provider/go.mod index 937227f45..bdfc050b1 100644 --- a/provider/go.mod +++ b/provider/go.mod @@ -5,7 +5,7 @@ go 1.21.12 require ( github.com/pulumi/pulumi-terraform-bridge/v3 v3.88.0 github.com/pulumi/pulumi/sdk/v3 v3.126.0 - github.com/spotinst/terraform-provider-spotinst v1.184.0 + github.com/spotinst/terraform-provider-spotinst v1.185.0 ) replace ( @@ -198,7 +198,7 @@ require ( github.com/spf13/cast v1.5.0 // indirect github.com/spf13/cobra v1.8.0 // indirect github.com/spf13/pflag v1.0.5 // indirect - github.com/spotinst/spotinst-sdk-go v1.361.0 // indirect + github.com/spotinst/spotinst-sdk-go v1.362.0 // indirect github.com/stretchr/testify v1.9.0 // indirect github.com/texttheater/golang-levenshtein v1.0.1 // indirect github.com/tweekmonster/luser v0.0.0-20161003172636-3fa38070dbd7 // indirect diff --git a/provider/go.sum b/provider/go.sum index ca4a57f81..af80439ce 100644 --- a/provider/go.sum +++ b/provider/go.sum @@ -2017,10 +2017,10 @@ github.com/spf13/pflag v1.0.2/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnIn github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= -github.com/spotinst/spotinst-sdk-go v1.361.0 h1:wYIW68kO5fBy/TVeOBFwiyB6JWQLh6bKDutWLgU2rMo= -github.com/spotinst/spotinst-sdk-go v1.361.0/go.mod h1:Tn4/eb0SFY6IXmxz71CClujvbD/PuT+EO6Ta8v6AML4= -github.com/spotinst/terraform-provider-spotinst v1.184.0 h1:KpsRU/ybmQ2onIG0sP9K05z69M9154vXtR+5eb9OD7I= -github.com/spotinst/terraform-provider-spotinst v1.184.0/go.mod h1:z1zXIRtUM9jFSc0G7H0H6nOn5LoSH+Ibg6OfgGT6wFA= +github.com/spotinst/spotinst-sdk-go v1.362.0 h1:hyhySd+WTZfC/J5670aumE+oWejGRRQ0ay8WF01+Pr4= +github.com/spotinst/spotinst-sdk-go v1.362.0/go.mod h1:Tn4/eb0SFY6IXmxz71CClujvbD/PuT+EO6Ta8v6AML4= +github.com/spotinst/terraform-provider-spotinst v1.185.0 h1:u89xeUrqeYu6i2KJ+iqyeg+oWzlR5jD682ijhh90gEE= +github.com/spotinst/terraform-provider-spotinst v1.185.0/go.mod h1:B6jKRw/+glNpq44Q0HVoPM3MPsMa8CV2OZS0qITCYDI= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= diff --git a/sdk/dotnet/Aws/Inputs/OceanLaunchSpecStrategyArgs.cs b/sdk/dotnet/Aws/Inputs/OceanLaunchSpecStrategyArgs.cs index bd6c9a64f..f81a5c547 100644 --- a/sdk/dotnet/Aws/Inputs/OceanLaunchSpecStrategyArgs.cs +++ b/sdk/dotnet/Aws/Inputs/OceanLaunchSpecStrategyArgs.cs @@ -12,6 +12,12 @@ namespace Pulumi.SpotInst.Aws.Inputs public sealed class OceanLaunchSpecStrategyArgs : global::Pulumi.ResourceArgs { + /// + /// The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + /// + [Input("drainingTimeout")] + public Input? DrainingTimeout { get; set; } + /// /// The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). /// diff --git a/sdk/dotnet/Aws/Inputs/OceanLaunchSpecStrategyGetArgs.cs b/sdk/dotnet/Aws/Inputs/OceanLaunchSpecStrategyGetArgs.cs index 4ed60defe..b6dd55fd8 100644 --- a/sdk/dotnet/Aws/Inputs/OceanLaunchSpecStrategyGetArgs.cs +++ b/sdk/dotnet/Aws/Inputs/OceanLaunchSpecStrategyGetArgs.cs @@ -12,6 +12,12 @@ namespace Pulumi.SpotInst.Aws.Inputs public sealed class OceanLaunchSpecStrategyGetArgs : global::Pulumi.ResourceArgs { + /// + /// The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + /// + [Input("drainingTimeout")] + public Input? DrainingTimeout { get; set; } + /// /// The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). /// diff --git a/sdk/dotnet/Aws/Outputs/OceanLaunchSpecStrategy.cs b/sdk/dotnet/Aws/Outputs/OceanLaunchSpecStrategy.cs index 4f31efbdd..dc7fac1d3 100644 --- a/sdk/dotnet/Aws/Outputs/OceanLaunchSpecStrategy.cs +++ b/sdk/dotnet/Aws/Outputs/OceanLaunchSpecStrategy.cs @@ -13,14 +13,22 @@ namespace Pulumi.SpotInst.Aws.Outputs [OutputType] public sealed class OceanLaunchSpecStrategy { + /// + /// The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + /// + public readonly int? DrainingTimeout; /// /// The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). /// public readonly int? SpotPercentage; [OutputConstructor] - private OceanLaunchSpecStrategy(int? spotPercentage) + private OceanLaunchSpecStrategy( + int? drainingTimeout, + + int? spotPercentage) { + DrainingTimeout = drainingTimeout; SpotPercentage = spotPercentage; } } diff --git a/sdk/go/spotinst/aws/pulumiTypes.go b/sdk/go/spotinst/aws/pulumiTypes.go index 033b9d6a1..672b851ea 100644 --- a/sdk/go/spotinst/aws/pulumiTypes.go +++ b/sdk/go/spotinst/aws/pulumiTypes.go @@ -21821,6 +21821,8 @@ func (o OceanLaunchSpecSchedulingTaskTaskHeadroomArrayOutput) Index(i pulumi.Int } type OceanLaunchSpecStrategy struct { + // The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + DrainingTimeout *int `pulumi:"drainingTimeout"` // The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). SpotPercentage *int `pulumi:"spotPercentage"` } @@ -21837,6 +21839,8 @@ type OceanLaunchSpecStrategyInput interface { } type OceanLaunchSpecStrategyArgs struct { + // The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + DrainingTimeout pulumi.IntPtrInput `pulumi:"drainingTimeout"` // The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). SpotPercentage pulumi.IntPtrInput `pulumi:"spotPercentage"` } @@ -21892,6 +21896,11 @@ func (o OceanLaunchSpecStrategyOutput) ToOceanLaunchSpecStrategyOutputWithContex return o } +// The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. +func (o OceanLaunchSpecStrategyOutput) DrainingTimeout() pulumi.IntPtrOutput { + return o.ApplyT(func(v OceanLaunchSpecStrategy) *int { return v.DrainingTimeout }).(pulumi.IntPtrOutput) +} + // The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). func (o OceanLaunchSpecStrategyOutput) SpotPercentage() pulumi.IntPtrOutput { return o.ApplyT(func(v OceanLaunchSpecStrategy) *int { return v.SpotPercentage }).(pulumi.IntPtrOutput) diff --git a/sdk/java/src/main/java/com/pulumi/spotinst/aws/inputs/OceanLaunchSpecStrategyArgs.java b/sdk/java/src/main/java/com/pulumi/spotinst/aws/inputs/OceanLaunchSpecStrategyArgs.java index 2671233b0..a3f241dee 100644 --- a/sdk/java/src/main/java/com/pulumi/spotinst/aws/inputs/OceanLaunchSpecStrategyArgs.java +++ b/sdk/java/src/main/java/com/pulumi/spotinst/aws/inputs/OceanLaunchSpecStrategyArgs.java @@ -15,6 +15,21 @@ public final class OceanLaunchSpecStrategyArgs extends com.pulumi.resources.Reso public static final OceanLaunchSpecStrategyArgs Empty = new OceanLaunchSpecStrategyArgs(); + /** + * The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + * + */ + @Import(name="drainingTimeout") + private @Nullable Output drainingTimeout; + + /** + * @return The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + * + */ + public Optional> drainingTimeout() { + return Optional.ofNullable(this.drainingTimeout); + } + /** * The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). * @@ -33,6 +48,7 @@ public Optional> spotPercentage() { private OceanLaunchSpecStrategyArgs() {} private OceanLaunchSpecStrategyArgs(OceanLaunchSpecStrategyArgs $) { + this.drainingTimeout = $.drainingTimeout; this.spotPercentage = $.spotPercentage; } @@ -54,6 +70,27 @@ public Builder(OceanLaunchSpecStrategyArgs defaults) { $ = new OceanLaunchSpecStrategyArgs(Objects.requireNonNull(defaults)); } + /** + * @param drainingTimeout The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + * + * @return builder + * + */ + public Builder drainingTimeout(@Nullable Output drainingTimeout) { + $.drainingTimeout = drainingTimeout; + return this; + } + + /** + * @param drainingTimeout The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + * + * @return builder + * + */ + public Builder drainingTimeout(Integer drainingTimeout) { + return drainingTimeout(Output.of(drainingTimeout)); + } + /** * @param spotPercentage The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). * diff --git a/sdk/java/src/main/java/com/pulumi/spotinst/aws/outputs/OceanLaunchSpecStrategy.java b/sdk/java/src/main/java/com/pulumi/spotinst/aws/outputs/OceanLaunchSpecStrategy.java index fe41e1a5f..9a7848e78 100644 --- a/sdk/java/src/main/java/com/pulumi/spotinst/aws/outputs/OceanLaunchSpecStrategy.java +++ b/sdk/java/src/main/java/com/pulumi/spotinst/aws/outputs/OceanLaunchSpecStrategy.java @@ -11,6 +11,11 @@ @CustomType public final class OceanLaunchSpecStrategy { + /** + * @return The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + * + */ + private @Nullable Integer drainingTimeout; /** * @return The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). * @@ -18,6 +23,13 @@ public final class OceanLaunchSpecStrategy { private @Nullable Integer spotPercentage; private OceanLaunchSpecStrategy() {} + /** + * @return The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + * + */ + public Optional drainingTimeout() { + return Optional.ofNullable(this.drainingTimeout); + } /** * @return The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). * @@ -35,13 +47,21 @@ public static Builder builder(OceanLaunchSpecStrategy defaults) { } @CustomType.Builder public static final class Builder { + private @Nullable Integer drainingTimeout; private @Nullable Integer spotPercentage; public Builder() {} public Builder(OceanLaunchSpecStrategy defaults) { Objects.requireNonNull(defaults); + this.drainingTimeout = defaults.drainingTimeout; this.spotPercentage = defaults.spotPercentage; } + @CustomType.Setter + public Builder drainingTimeout(@Nullable Integer drainingTimeout) { + + this.drainingTimeout = drainingTimeout; + return this; + } @CustomType.Setter public Builder spotPercentage(@Nullable Integer spotPercentage) { @@ -50,6 +70,7 @@ public Builder spotPercentage(@Nullable Integer spotPercentage) { } public OceanLaunchSpecStrategy build() { final var _resultValue = new OceanLaunchSpecStrategy(); + _resultValue.drainingTimeout = drainingTimeout; _resultValue.spotPercentage = spotPercentage; return _resultValue; } diff --git a/sdk/nodejs/types/input.ts b/sdk/nodejs/types/input.ts index a085a7828..e6f858e41 100644 --- a/sdk/nodejs/types/input.ts +++ b/sdk/nodejs/types/input.ts @@ -2706,6 +2706,10 @@ export namespace aws { } export interface OceanLaunchSpecStrategy { + /** + * The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + */ + drainingTimeout?: pulumi.Input; /** * The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). */ diff --git a/sdk/nodejs/types/output.ts b/sdk/nodejs/types/output.ts index fdc9e03d0..251d9d167 100644 --- a/sdk/nodejs/types/output.ts +++ b/sdk/nodejs/types/output.ts @@ -2707,6 +2707,10 @@ export namespace aws { } export interface OceanLaunchSpecStrategy { + /** + * The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + */ + drainingTimeout?: number; /** * The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). */ diff --git a/sdk/python/pulumi_spotinst/aws/_inputs.py b/sdk/python/pulumi_spotinst/aws/_inputs.py index ff574ddc9..57a043721 100644 --- a/sdk/python/pulumi_spotinst/aws/_inputs.py +++ b/sdk/python/pulumi_spotinst/aws/_inputs.py @@ -10018,13 +10018,29 @@ def memory_per_unit(self, value: Optional[pulumi.Input[int]]): @pulumi.input_type class OceanLaunchSpecStrategyArgs: def __init__(__self__, *, + draining_timeout: Optional[pulumi.Input[int]] = None, spot_percentage: Optional[pulumi.Input[int]] = None): """ + :param pulumi.Input[int] draining_timeout: The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. :param pulumi.Input[int] spot_percentage: The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). """ + if draining_timeout is not None: + pulumi.set(__self__, "draining_timeout", draining_timeout) if spot_percentage is not None: pulumi.set(__self__, "spot_percentage", spot_percentage) + @property + @pulumi.getter(name="drainingTimeout") + def draining_timeout(self) -> Optional[pulumi.Input[int]]: + """ + The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + """ + return pulumi.get(self, "draining_timeout") + + @draining_timeout.setter + def draining_timeout(self, value: Optional[pulumi.Input[int]]): + pulumi.set(self, "draining_timeout", value) + @property @pulumi.getter(name="spotPercentage") def spot_percentage(self) -> Optional[pulumi.Input[int]]: diff --git a/sdk/python/pulumi_spotinst/aws/outputs.py b/sdk/python/pulumi_spotinst/aws/outputs.py index 202af191b..76e134412 100644 --- a/sdk/python/pulumi_spotinst/aws/outputs.py +++ b/sdk/python/pulumi_spotinst/aws/outputs.py @@ -9980,7 +9980,9 @@ class OceanLaunchSpecStrategy(dict): @staticmethod def __key_warning(key: str): suggest = None - if key == "spotPercentage": + if key == "drainingTimeout": + suggest = "draining_timeout" + elif key == "spotPercentage": suggest = "spot_percentage" if suggest: @@ -9995,13 +9997,25 @@ def get(self, key: str, default = None) -> Any: return super().get(key, default) def __init__(__self__, *, + draining_timeout: Optional[int] = None, spot_percentage: Optional[int] = None): """ + :param int draining_timeout: The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. :param int spot_percentage: The desired percentage of the Spot instances out of all running instances for this VNG. Only available when the field is not set in the cluster directly (cluster.strategy.spotPercentage). """ + if draining_timeout is not None: + pulumi.set(__self__, "draining_timeout", draining_timeout) if spot_percentage is not None: pulumi.set(__self__, "spot_percentage", spot_percentage) + @property + @pulumi.getter(name="drainingTimeout") + def draining_timeout(self) -> Optional[int]: + """ + The configurable amount of time that Ocean will wait for the draining process to complete before terminating an instance. If you have not defined a draining timeout, the default of 300 seconds will be used. + """ + return pulumi.get(self, "draining_timeout") + @property @pulumi.getter(name="spotPercentage") def spot_percentage(self) -> Optional[int]: