diff --git a/go.mod b/go.mod index f59e7602..4ebf7471 100644 --- a/go.mod +++ b/go.mod @@ -8,7 +8,7 @@ require ( github.com/aws/aws-sdk-go v1.55.6 github.com/aws/aws-sdk-go-v2 v1.36.0 github.com/aws/aws-sdk-go-v2/config v1.29.4 - github.com/aws/aws-sdk-go-v2/service/ec2 v1.201.1 + github.com/aws/aws-sdk-go-v2/service/ec2 v1.202.2 github.com/aws/aws-sdk-go-v2/service/ssm v1.56.4 github.com/mattn/go-isatty v0.0.20 github.com/onsi/ginkgo/v2 v2.22.2 diff --git a/go.sum b/go.sum index 6e41094b..3f975614 100644 --- a/go.sum +++ b/go.sum @@ -14,8 +14,8 @@ github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.31 h1:ACxDklUKKXb48+eg5R github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 v2.6.31/go.mod h1:yadnfsDwqXeVaohbGc/RaD287PuyRw2wugkh5ZL2J6k= github.com/aws/aws-sdk-go-v2/internal/ini v1.8.2 h1:Pg9URiobXy85kgFev3og2CuOZ8JZUBENF+dcgWBaYNk= github.com/aws/aws-sdk-go-v2/internal/ini v1.8.2/go.mod h1:FbtygfRFze9usAadmnGJNc8KsP346kEe+y2/oyhGAGc= -github.com/aws/aws-sdk-go-v2/service/ec2 v1.201.1 h1:HJUHMHbBg3stGO7ZZfpwbeK9xVhGS7GK8NScady6Moc= -github.com/aws/aws-sdk-go-v2/service/ec2 v1.201.1/go.mod h1:cRD0Fhzj0YD+uAh16NChQAv9/BB0S9x3YK9hLx1jb/k= +github.com/aws/aws-sdk-go-v2/service/ec2 v1.202.2 h1:qas57zkkMX8OM+MVz+4sMaOaD9HRmeFJRb8nzMdYkx0= +github.com/aws/aws-sdk-go-v2/service/ec2 v1.202.2/go.mod h1:2omfxRebtpbbFqQGqeurDzlyB7Txa2e1xe9rCDFqlwA= github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.12.2 h1:D4oz8/CzT9bAEYtVhSBmFj2dNOtaHOtMKc2vHBwYizA= github.com/aws/aws-sdk-go-v2/service/internal/accept-encoding v1.12.2/go.mod h1:Za3IHqTQ+yNcRHxu1OFucBh0ACZT4j4VQFF0BqpZcLY= github.com/aws/aws-sdk-go-v2/service/internal/presigned-url v1.12.12 h1:O+8vD2rGjfihBewr5bT+QUfYUHIxCVgG61LHoT59shM= diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/CHANGELOG.md b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/CHANGELOG.md index 16cb8431..07afb0b7 100644 --- a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/CHANGELOG.md +++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/CHANGELOG.md @@ -1,3 +1,15 @@ +# v1.202.2 (2025-01-31) + +* **Dependency Update**: Updated to the latest SDK module versions + +# v1.202.1 (2025-01-30) + +* **Dependency Update**: Updated to the latest SDK module versions + +# v1.202.0 (2025-01-28) + +* **Feature**: This release changes the CreateFleet CLI and SDK's such that if you do not specify a client token, a randomly generated token is used for the request to ensure idempotency. + # v1.201.1 (2025-01-24) * **Dependency Update**: Updated to the latest SDK module versions diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_CancelCapacityReservation.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_CancelCapacityReservation.go index 7d800237..88661628 100644 --- a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_CancelCapacityReservation.go +++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_CancelCapacityReservation.go @@ -21,6 +21,8 @@ import ( // elapsed. You can't cancel a future-dated Capacity Reservation during the // commitment duration. // +// You can't modify or cancel a Capacity Block. For more information, see [Capacity Blocks for ML]. +// // If a future-dated Capacity Reservation enters the delayed state, the commitment // duration is waived, and you can cancel it as soon as it enters the active state. // @@ -29,6 +31,8 @@ import ( // launch. Modify these instances to either target a different Capacity // Reservation, launch On-Demand Instance capacity, or run in any open Capacity // Reservation that has matching attributes and sufficient capacity. +// +// [Capacity Blocks for ML]: https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-capacity-blocks.html func (c *Client) CancelCapacityReservation(ctx context.Context, params *CancelCapacityReservationInput, optFns ...func(*Options)) (*CancelCapacityReservationOutput, error) { if params == nil { params = &CancelCapacityReservationInput{} diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_CreateFleet.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_CreateFleet.go index efbd13fb..addd63f7 100644 --- a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_CreateFleet.go +++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_CreateFleet.go @@ -50,7 +50,10 @@ type CreateFleetInput struct { TargetCapacitySpecification *types.TargetCapacitySpecificationRequest // Unique, case-sensitive identifier that you provide to ensure the idempotency of - // the request. For more information, see [Ensuring idempotency]. + // the request. If you do not specify a client token, a randomly generated token is + // used for the request to ensure idempotency. + // + // For more information, see [Ensuring idempotency]. // // [Ensuring idempotency]: https://docs.aws.amazon.com/AWSEC2/latest/APIReference/Run_Instance_Idempotency.html ClientToken *string @@ -218,6 +221,9 @@ func (c *Client) addOperationCreateFleetMiddlewares(stack *middleware.Stack, opt if err = addUserAgentRetryMode(stack, options); err != nil { return err } + if err = addIdempotencyToken_opCreateFleetMiddleware(stack, options); err != nil { + return err + } if err = addOpCreateFleetValidationMiddleware(stack); err != nil { return err } @@ -254,6 +260,39 @@ func (c *Client) addOperationCreateFleetMiddlewares(stack *middleware.Stack, opt return nil } +type idempotencyToken_initializeOpCreateFleet struct { + tokenProvider IdempotencyTokenProvider +} + +func (*idempotencyToken_initializeOpCreateFleet) ID() string { + return "OperationIdempotencyTokenAutoFill" +} + +func (m *idempotencyToken_initializeOpCreateFleet) HandleInitialize(ctx context.Context, in middleware.InitializeInput, next middleware.InitializeHandler) ( + out middleware.InitializeOutput, metadata middleware.Metadata, err error, +) { + if m.tokenProvider == nil { + return next.HandleInitialize(ctx, in) + } + + input, ok := in.Parameters.(*CreateFleetInput) + if !ok { + return out, metadata, fmt.Errorf("expected middleware input to be of type *CreateFleetInput ") + } + + if input.ClientToken == nil { + t, err := m.tokenProvider.GetIdempotencyToken() + if err != nil { + return out, metadata, err + } + input.ClientToken = &t + } + return next.HandleInitialize(ctx, in) +} +func addIdempotencyToken_opCreateFleetMiddleware(stack *middleware.Stack, cfg Options) error { + return stack.Initialize.Add(&idempotencyToken_initializeOpCreateFleet{tokenProvider: cfg.IdempotencyTokenProvider}, middleware.Before) +} + func newServiceMetadataMiddleware_opCreateFleet(region string) *awsmiddleware.RegisterServiceMetadata { return &awsmiddleware.RegisterServiceMetadata{ Region: region, diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_DescribeCapacityBlockOfferings.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_DescribeCapacityBlockOfferings.go index 716140f3..7855a8df 100644 --- a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_DescribeCapacityBlockOfferings.go +++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_DescribeCapacityBlockOfferings.go @@ -15,6 +15,14 @@ import ( // Describes Capacity Block offerings available for purchase in the Amazon Web // Services Region that you're currently using. With Capacity Blocks, you purchase // a specific instance type for a period of time. +// +// To search for an available Capacity Block offering, you specify a reservation +// duration and instance count. You must select one of the following options. +// +// - For reservation durations 1-day increments up 14 days and 7-day increments +// up to 182 days total +// +// - For instance count 1, 2, 4, 8, 16, 32, or 64 instances func (c *Client) DescribeCapacityBlockOfferings(ctx context.Context, params *DescribeCapacityBlockOfferingsInput, optFns ...func(*Options)) (*DescribeCapacityBlockOfferingsOutput, error) { if params == nil { params = &DescribeCapacityBlockOfferingsInput{} diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_DescribeInstanceTopology.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_DescribeInstanceTopology.go index 235d7d8f..af4ad055 100644 --- a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_DescribeInstanceTopology.go +++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/api_op_DescribeInstanceTopology.go @@ -33,7 +33,8 @@ import ( // - p3dn.24xlarge | p4d.24xlarge | p4de.24xlarge | p5.48xlarge | p5e.48xlarge | // p5en.48xlarge // -// - trn1.2xlarge | trn1.32xlarge | trn1n.32xlarge +// - trn1.2xlarge | trn1.32xlarge | trn1n.32xlarge | trn2.48xlarge | +// trn2u.48xlarge // // For more information, see [Amazon EC2 instance topology] in the Amazon EC2 User Guide. // diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/go_module_metadata.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/go_module_metadata.go index 68d468b5..7f51082b 100644 --- a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/go_module_metadata.go +++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/go_module_metadata.go @@ -3,4 +3,4 @@ package ec2 // goModuleVersion is the tagged release for this module -const goModuleVersion = "1.201.1" +const goModuleVersion = "1.202.2" diff --git a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/types/types.go b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/types/types.go index 5ab47a2a..f99696d4 100644 --- a/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/types/types.go +++ b/vendor/github.com/aws/aws-sdk-go-v2/service/ec2/types/types.go @@ -4515,8 +4515,12 @@ type EventInformation struct { // several attempts to launch instances have failed. For more information, see the // description of the event. // - // - launchSpecUnusable - The price in a launch specification is not valid - // because it is below the Spot price. + // - launchSpecUnusable - The price specified in a launch specification is not + // valid because it is below the Spot price for the requested Spot pools. + // + // Note: Even if a fleet with the maintain request type is in the process of being + // canceled, it may still publish a launchSpecUnusable event. This does not mean + // that the canceled fleet is attempting to launch a new instance. // // - registerWithLoadBalancersFailed - An attempt to register instances with load // balancers failed. For more information, see the description of the event. @@ -7095,7 +7099,7 @@ type InstanceBlockDeviceMappingSpecification struct { // launched. Ebs *EbsInstanceBlockDeviceSpecification - // suppress the specified device included in the block device mapping. + // Suppresses the specified device included in the block device mapping. NoDevice *string // The virtual device name. @@ -8009,9 +8013,11 @@ type InstanceRequirements struct { // The accelerator types that must be on the instance type. // + // - For instance types with FPGA accelerators, specify fpga . + // // - For instance types with GPU accelerators, specify gpu . // - // - For instance types with FPGA accelerators, specify fpga . + // - For instance types with Inference accelerators, specify inference . // // Default: Any accelerator type AcceleratorTypes []AcceleratorType @@ -8378,9 +8384,11 @@ type InstanceRequirementsRequest struct { // The accelerator types that must be on the instance type. // - // - To include instance types with GPU hardware, specify gpu . + // - For instance types with FPGA accelerators, specify fpga . + // + // - For instance types with GPU accelerators, specify gpu . // - // - To include instance types with FPGA hardware, specify fpga . + // - For instance types with Inference accelerators, specify inference . // // Default: Any accelerator type AcceleratorTypes []AcceleratorType @@ -17735,6 +17743,9 @@ type SpotMarketOptions struct { // // If you specify a maximum price, your Spot Instances will be interrupted more // frequently than if you do not specify this parameter. + // + // If you specify a maximum price, it must be more than USD $0.001. Specifying a + // value below USD $0.001 will result in an InvalidParameterValue error message. MaxPrice *string // The Spot Instance request type. For [RunInstances], persistent Spot Instance requests are diff --git a/vendor/modules.txt b/vendor/modules.txt index 8e2fd6ab..4a93729f 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -61,7 +61,7 @@ github.com/aws/aws-sdk-go-v2/internal/endpoints/v2 # github.com/aws/aws-sdk-go-v2/internal/ini v1.8.2 ## explicit; go 1.21 github.com/aws/aws-sdk-go-v2/internal/ini -# github.com/aws/aws-sdk-go-v2/service/ec2 v1.201.1 +# github.com/aws/aws-sdk-go-v2/service/ec2 v1.202.2 ## explicit; go 1.21 github.com/aws/aws-sdk-go-v2/service/ec2 github.com/aws/aws-sdk-go-v2/service/ec2/internal/endpoints